Skip to content

Bug: recursively copies artifact dir when it's in source dir #382

Description

@julianzq

Recursively copies artifact dir when it's in source dir until it errors out:

JSON-RPC input:

{
...
"source_dir":    "path/to/source",
"artifacts_dir":  "path/to/source/.build/artifact",
...
}

Then running lambda-builders <JSON INPUT>

Results in

PythonPipBuilder:CopySource - [Errno 63] File name too long: '/path/to/source/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/.build/artifact/python_dateutil-2.8.2.dist-info/top_level.txt'

Setting artifact_dir outside the source_dir solves this issue.


Is this a bug, or is this expected? Perhaps we should add ignore: {} interface? I can contribute a PR for this if you guys can point me in the right direction.


Additional environment details (Ex: Windows, Mac, Amazon Linux etc)

  1. OS: Mac
  2. If using SAM CLI, sam --version:
  3. AWS region: us-east-1 (shouldn't matter)

Add --debug flag to any SAM CLI commands you are running

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions