Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(aws-codecommit): from_directory working in synth but not deploy #19048

Closed
robdhondt opened this issue Feb 18, 2022 · 2 comments
Closed

(aws-codecommit): from_directory working in synth but not deploy #19048

robdhondt opened this issue Feb 18, 2022 · 2 comments
Assignees
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.

Comments

@robdhondt
Copy link

robdhondt commented Feb 18, 2022

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?

image

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

@robdhondt robdhondt added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Feb 18, 2022
@github-actions github-actions bot added the @aws-cdk/aws-codecommit Related to AWS CodeCommit label Feb 18, 2022
@robdhondt robdhondt changed the title (aws-codecommit): from_directory (aws-codecommit): from_directory working in synth but not deploy Feb 18, 2022
@robdhondt
Copy link
Author

already reported: #19012

@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
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.
Projects
None yet
Development

No branches or pull requests

2 participants