Automation API error: Program run without the Pulumi engine available; re-run using the pulumi
CLI\n' when using random provider
#16161
Labels
pulumi
CLI\n' when using random provider
#16161
What happened?
I am writing a lambda in Typescript that uses the automation api to provision resources.
I am encountering weird behaviour while using the random provider. When creating any resource with this provider inside an inline program i get this error:
If I remove the Randomstring resource the program runs correctly.
If I run the program with the pulumi cli, using the same example but by swapping pulumiProgram() with testRandom() as my main, all resources are created correctly.
From my understanding this only happens when I use a resource from the random provider inside an inline program.
I followed examples from the docs to configure the provider, I believe that there is some interaction between random and inline programs that causes this error, as it is the only combination that causes this behaviour.
Example
Output of
pulumi about
CLI
Version 3.115.2
Go Version go1.22.2
Go Compiler gc
Plugins
KIND NAME VERSION
resource aws 6.34.0
resource awsx 2.9.0
resource docker 4.5.3
resource docker 3.6.1
language nodejs unknown
resource random 3.2.0
Host
OS darwin
Version 14.4.1
Arch x86_64
This project is written in nodejs: executable='/usr/local/bin/node' version='v22.1.0'
Backend
Name REDACTED.local
URL s3://REDACTED?region=eu-south-1
User REDACTED
Organizations
Token type personal
Pulumi locates its logs in /var/folders/f8/4sbm64zj2937pgtb7nnzt7pjs0l5fh/T/ by default
warning: Failed to get information about the Pulumi program's dependencies: failed to run "/usr/local/bin/npm ls --json --depth=0": exit status 1
warning: Failed to get information about the current stack: No current stack
Additional context
No response
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).
The text was updated successfully, but these errors were encountered: