Reading certificate output cause python error
See original GitHub issueHello,
Attempting to read a acm.Certificate() resource (certificate.domain_validation_options[0]["resourceRecordName"]
) output using the following versions:
pulumi == 2.12.1
pulumi-aws == 3.10.0
Will cause the following error at pulumi up
:
Diagnostics:
pulumi:pulumi:Stack (pulumi-sample-certificate-dev):
error: Program failed with an unhandled exception:
error: Traceback (most recent call last):
File "/home/eric/.pulumi/bin/pulumi-language-python-exec", line 85, in <module>
loop.run_until_complete(coro)
File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 83, in run_in_stack
await run_pulumi_func(lambda: Stack(func))
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/stack.py", line 51, in run_pulumi_func
await RPC_MANAGER.rpcs.pop()
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/rpc_manager.py", line 67, in rpc_wrapper
result = await rpc
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 88, in is_value_known
return await is_known and not contains_unknowns(await future)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 88, in is_value_known
return await is_known and not contains_unknowns(await future)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 88, in is_value_known
return await is_known and not contains_unknowns(await future)
[Previous line repeated 14 more times]
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/resource.py", line 327, in do_register
resolver = await prepare_resource(res, ty, custom, props, opts)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/resource.py", line 86, in prepare_resource
serialized_props = await rpc.serialize_properties(props, property_dependencies_resources, res.translate_input_property)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/rpc.py", line 71, in serialize_properties
result = await serialize_property(v, deps, input_transformer)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/rpc.py", line 178, in serialize_property
value = await serialize_property(output.future(), deps, input_transformer)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/runtime/rpc.py", line 164, in serialize_property
future_return = await asyncio.ensure_future(awaitable)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 113, in get_value
val = await self._future
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 175, in run
transformed: Input[U] = func(value)
File "/home/eric/git/pulumi_sample_certificate/venv/lib/python3.8/site-packages/pulumi/output.py", line 233, in <lambda>
return self.apply(lambda v: UNKNOWN if isinstance(v, Unknown) else cast(Any, v)[key], True)
KeyError: 'resourceRecordName'
error: an unhandled error occurred: Program exited with non-zero exit code: 1
Steps to reproduce:
- Clone https://github.com/edalongeville/pulumi_sample_certificate
- Create a python venv and pip install
requirements_broken.txt
- Run
pulumi up
Issue Analytics
- State:
- Created 3 years ago
- Comments:10 (6 by maintainers)
Top Results From Across the Web
python - urllib and "SSL: CERTIFICATE_VERIFY_FAILED" Error
There is nothing wrong with the URL and it can be successfully verified with the common trusted certificates. So you should better not...
Read more >SSL Error - unable to read server certificate from file
The error that you are currently encountering is caused because you are using a wrong command line for installing the CSR. You will...
Read more >What is an SSL 'Certificate_Verify_Failed' Error and How Do I ...
SSL certificate_verify_failed errors typically occur as a result of outdated Python default certificates or invalid root certificates.
Read more >How to fix Python KeyError Exceptions in simple steps?
A detailed guide to Errors and Exceptions in Python. ... Due to some errors or incorrect commands, the output will not be displayed....
Read more >ssl — TLS/SSL wrapper for socket objects — Python 3.11.1 ...
This section documents the objects and functions in the ssl module; for more general information about TLS, SSL, and certificates, the reader is...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks for the repro. I was able to reproduce with the steps you outlined above. It seems this is somehow related to the recently released preview functionality. We’ll continue to investigate. In the meantime, as mentioned above, downgrading is one path forward. Alternatively, you can also set the environment variable
PULUMI_DISABLE_PROVIDER_PREVIEW=1
(or true) with pulumi CLI2.12.x
and should be able to proceed.pulumi 2.12.0 gives the same issue as above.
pulumi up works with
2.11.2
see below $cat requirements.txt:/Users/…shah/Downloads/pulumi_2_11_2/pulumi/pulumi version
v2.11.2