mirror of https://github.com/pulumi/pulumi.git
43a9bd7fe6
Automation API is useful for writing tests for Pulumi programs, and a user could write a test as follows: ```python def program(): with pytest.raises(ValueError): _a = 1 + 2 # No error here, pytest.raises should fail stack = create_stack("mystack", program=program, project_name="proj") with pytest.raises(InlineSourceRuntimeError): stack.preview() ``` If the block in `pytest.raises` does not raise the expected error or any error, `pytest.raises` fails the test by raising an `OutcomeException`. This exception class inherits from `BaseException`, not `Exception`, so we would previously not catch this, and fail to report an error from the automation API server's `Run` method, causing the call to `stack.preview` to hang indefinitely. Fixes https://github.com/pulumi/pulumi/issues/17133 |
||
---|---|---|
.. | ||
20241109--auto-go-nodejs-python--fixed-a-bug-where-token-information-was-not-present-in-types.yaml | ||
20241125--programgen-dotnet-nodejs-python--emit-deferred-outputs-for-mutually-dependant-components.yaml | ||
20241125--sdk-nodejs--throw-from-output-on-circular-structures.yaml | ||
20241126--protobuf--add-handshake-to-the-provider-protocol.yaml | ||
20241126--sdkgen--include-parameterization-details-in-pulumi-plugin-json.yaml | ||
20241127--sdk-python--drop-python-3-8-support.yaml | ||
20241127--sdk-python--switch-to-ruff-for-linting.yaml | ||
20241202--auto-nodejs--dont-hang-indefinitely-on-failed-inputs.yaml | ||
20241202--cli-install--dont-recreate-virtualenvs-when-using-venv.yaml | ||
20241203--auto-python--catch-baseexception-in-automation-api-server.yaml |