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

[sdk/python] yaml._parse_yaml_object waits for all metadata #1674

Closed
SharpEdgeMarshall opened this issue Aug 10, 2021 · 0 comments · Fixed by #1675
Closed

[sdk/python] yaml._parse_yaml_object waits for all metadata #1674

SharpEdgeMarshall opened this issue Aug 10, 2021 · 0 comments · Fixed by #1675
Labels
kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed

Comments

@SharpEdgeMarshall
Copy link
Contributor

yaml._parse_yaml_object waits for all metadata with pulumi.Output.from_input(metadata) instead of waiting only for name and namespace

In case you have a ConfigFile with a transformation that adds an Output object to metadata, the preview will not show the resource.

Steps to reproduce

       def add_annotation(obj, opts):
                obj["metadata"]["annotations"]["foo"] = my_output_var

        k8s.yaml.ConfigFile(
            "foo-resource",
            file="foo.yaml",
            transformations=[add_annotation],
        )

Expected: Expect to see the resource in preview
Actual: The resource is applied only during pulumi up

@SharpEdgeMarshall SharpEdgeMarshall added the kind/bug Some behavior is incorrect or out of spec label Aug 10, 2021
SharpEdgeMarshall added a commit to SharpEdgeMarshall/pulumi-kubernetes that referenced this issue Aug 11, 2021
SharpEdgeMarshall added a commit to SharpEdgeMarshall/pulumi-kubernetes that referenced this issue Aug 11, 2021
SharpEdgeMarshall added a commit to SharpEdgeMarshall/pulumi-kubernetes that referenced this issue Aug 11, 2021
SharpEdgeMarshall added a commit to SharpEdgeMarshall/pulumi-kubernetes that referenced this issue Aug 11, 2021
@SharpEdgeMarshall SharpEdgeMarshall changed the title Python yaml._parse_yaml_object waits for all metadata [sdk/python] yaml._parse_yaml_object waits for all metadata Aug 12, 2021
lblackstone pushed a commit that referenced this issue Aug 12, 2021
@pulumi-bot pulumi-bot added the resolution/fixed This issue was fixed label Aug 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed
Projects
None yet
2 participants