(aws-codecommit): from_directory working in synth but not deploy #19048
Labels
@aws-cdk/aws-codecommit
Related to AWS CodeCommit
bug
This issue is a bug.
needs-triage
This issue or PR still needs to be triaged.
What is the problem?
CDK synth will generate template using
from_directory
to initialize the code without issue.When using CDK deploy the deployment will fail with 'code supplied is not a valid .zip archive'
Reproduction Steps
aws_codecommit.Repository( self, "test-codecommit", repository_name="test-repo", code=aws_codecommit.Code.from_directory(os.path.join(self.current_dir, "../src")) )
What did you expect to happen?
The codecommit repository to be created with the source directory files as the initial code.
What actually happened?
CDK CLI Version
2.12.0
Framework Version
No response
Node.js Version
16.14.0
OS
macos
Language
Python
Language Version
No response
Other information
Workaround: zip directory using shutil.make_archive and use from_zip_file
The text was updated successfully, but these errors were encountered: