-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
[CodeBuild] resource imported without a role error #10234
Comments
* With latest cdk version, it does not like to import external fragments i.e. `cb.Project.from_project_name(...)` return object fragment from jsii reflection. Hence, not resolving full object state. * Related aws/aws-cdk#10234
* With latest cdk version, it does not like to import external fragments i.e. `cb.Project.from_project_name(...)` return object fragment from jsii reflection. Hence, not resolving full object state. * Related aws/aws-cdk#10234
Hey @reisingerf , thanks for the report. I tried running
Can you try to minimize the reproduction steps a little bit? I'm very curious of this error, but it's hard for me to tell you more about it without being able to reproduce it locally. Thanks, |
Hi @skinny85, I have tried to remove all non-essential parts and our custom resources. I pushed the result into a new independent repo: https://github.com/reisingerf/cdk-cross-stack-ref-error After cloning that repo, I run the usual:
Which results in the same I am still on cdk version: I hope that helps! p.s. note that as @victorskl mentioned above, switching to object references, rather than by name, solved our issue. |
@reisingerf since the problem is fixed, and the issue is that you previously imported a Project that didn't have a Role specified, is there anything else you'd like our assistance on? Thanks, |
|
I am hitting this error, a version of which seems to have been reported before in #4613 and was fixed by @skinny85 .
This might be a regression, as reverting back to version 1.58 of CDK seems to solve it.
cc @brainstorm @victorskl
In my scenario I have two stacks, one (
cicd
) to deploy a CodeBuild project and one (slack
) to deploy a SNS topic and Lambda to send messages (from CodeBuild events) to Slack.The second one uses
cb.Project.from_project_name
to load the deployed CodeBuild project from the first stack to grant publish permissions.This second stack is now giving me issues with the import error preventing even a simple
cdk list
.Reproduction Steps
Our CDK code is hosted here:
https://github.com/umccr/infrastructure/tree/master/cdk/apps/umccrise
Things to note:
These stacks were initially deployed a while ago and have been working well without any issues. We've since updated CDK to its latest version and I now tried to make small changes.
The
cicd
stack has since also drifted and the role that is causing the error has gained an additional policy (not sure yet from where), now having two policies attached as opposed to the initial single one.What did you expect to happen?
The
cdk list
to list the stacks.What actually happened?
The error below.
Environment
Other
The full error
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: