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

Issues with package imports after migrating to crd2pulumi 1.5.1 #147

Closed
shamil opened this issue Sep 16, 2024 · 1 comment · Fixed by #149
Closed

Issues with package imports after migrating to crd2pulumi 1.5.1 #147

shamil opened this issue Sep 16, 2024 · 1 comment · Fixed by #149
Assignees
Labels
area/codegen Affects quality or correctness of generated code kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed

Comments

@shamil
Copy link
Contributor

shamil commented Sep 16, 2024

What happened?

Quite similar to #142

Example

Generating types from https://github.com/prometheus-operator/prometheus-operator/releases/download/v0.76.2/bundle.yaml causes to use types like pulumi.StringMapArrayMapOutput which doesn't really exist in pulumi

Output of pulumi about

$ crd2pulumi version
v1.5.1

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@shamil shamil added kind/bug Some behavior is incorrect or out of spec needs-triage Needs attention from the triage team labels Sep 16, 2024
@rquitales rquitales added area/codegen Affects quality or correctness of generated code and removed needs-triage Needs attention from the triage team labels Sep 16, 2024
@rquitales
Copy link
Member

Thanks for reporting this issue. We'll add this to our backlog to resolve!

@rquitales rquitales self-assigned this Sep 16, 2024
rquitales added a commit that referenced this issue Sep 16, 2024
We were previously not nesting maps of arrays, and treating them as
generic types instead. This is an issue in Golang codegen, generating
generic Pulumi input/output types that don't exists. This commit ensures
we also flatten map of arrays so Golang codegen works.

Fixes: #147
rquitales added a commit that referenced this issue Sep 16, 2024
We were previously not nesting maps of arrays, and treating them as
generic types instead. This is an issue in Golang codegen, generating
generic Pulumi input/output types that don't exists. This commit ensures
we also flatten map of arrays so Golang codegen works.

Fixes: #147
@pulumi-bot pulumi-bot added the resolution/fixed This issue was fixed label Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/codegen Affects quality or correctness of generated code kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants