https://pulumi.com logo
q

quiet-plastic-34312

12/19/2021, 11:11 PM
anyone can help me... im trying to integrate gitlab cicd with pulumi and when im runing the #pulumi up comand i get a [Failed to parse python version: ''] at console... but dont know how to debug it
l

little-cartoon-10569

12/19/2021, 11:19 PM
Are you using the python runtime?
q

quiet-plastic-34312

12/19/2021, 11:28 PM
yes. and i install it on the gitlab runner
l

little-cartoon-10569

12/19/2021, 11:54 PM
You can increase the log level by adding
-v 9 --logtostderr
or similar.
q

quiet-plastic-34312

12/20/2021, 12:29 AM
Copy code
I1220 00:24:30.955728     260 plugin.go:125] Launching plugin 'python' from '/root/.pulumi/bin/pulumi-language-python' with args: -root=/builds/edson.cs.dev/devops/infrastructure,127.0.0.1:40925
I1220 00:24:30.965243     260 eventsink.go:78] eventSink::Infoerr(<{%reset%}>Failed to parse python version: ''
<{%reset%}>)
    pulumi:pulumi:Stack infrastructure-dev  Failed to parse python version: ''
I1220 00:24:30.967211     260 langruntime_plugin.go:207] langhost[python].GetPluginInfo() executing
I1220 00:24:30.967913     260 langruntime_plugin.go:115] langhost[python].GetRequiredPlugins(proj=infrastructure,pwd=/builds/edson.cs.dev/devops/infrastructure,program=.) executing
I1220 00:24:30.981316     260 langruntime_plugin.go:124] langhost[python].GetRequiredPlugins(proj=infrastructure,pwd=/builds/edson.cs.dev/devops/infrastructure,program=.) failed: err=exit status 1
I1220 00:24:30.982400     260 update.go:189] *** Update(preview=true) complete ***
    pulumi:pulumi:Stack infrastructure-dev  1 message

Diagnostics:
  pulumi:pulumi:Stack (infrastructure-dev):
    Failed to parse python version: ''
i can see the log but still dont have any clue on where are the poblem
l

little-cartoon-10569

12/20/2021, 12:37 AM
I'm guessing that if you run
/root/.pulumi/bin/pulumi-language-python
you'll see the same error.
Let's look at the plugin's source code.
q

quiet-plastic-34312

12/20/2021, 12:46 AM
But its running inside the pulumi infrastructure, right? i dont know how to fix it. I just made a pulumi install from "curl -fsSL https://get.pulumi.com | sh"
l

little-cartoon-10569

12/20/2021, 12:58 AM
Yes, sorry, I don't know this code so I'm going fairly slowly.
I presume it's a difference between an assumption that Pulumi makes about the environment / path / something, and the reality of that something.
I've found the error, but not its cause (yet).
f

freezing-van-87649

12/20/2021, 1:23 AM
Python is installed, right?
Is this running in a docker image? Can you share the gitlab ci file (or a portion or it)?
q

quiet-plastic-34312

12/20/2021, 1:30 AM
looks like the image i was using to build my app in golang use python 2.7 version...witch was not suported... i gona try fix the python version to build
looks like its working now... just a credential error to build
🎉 2
g

great-sunset-355

12/20/2021, 8:50 AM
How about using the official docker Pulumi docker image and saving yourself some trouble? https://hub.docker.com/r/pulumi/pulumi
3 Views