https://pulumi.com logo
#general
Title
# general
f

faint-motherboard-95438

07/06/2023, 2:25 PM
Hi there, From a fresh install of the pulumi CLI on a linux, running a stack we use elsewhere without any issue, I get during preview this weird error I've never seen before :
Copy code
error: could not find latest version for provider pulumi-nodejs: 404 HTTP error fetching plugin from <https://api.github.com/repos/pulumi/pulumi-pulumi-nodejs/releases/latest>. If this is a private GitHub repository, try providing a token via the GITHUB_TOKEN environment variable. See: <https://github.com/settings/tokens>
I didn't see really relevant issues on the github, so asking here before opening a ticket
b

billowy-army-68599

07/06/2023, 2:53 PM
@faint-motherboard-95438 this is usually because your code or stack config is incorrect. Can you share both?
f

faint-motherboard-95438

07/06/2023, 3:05 PM
hey @billowy-army-68599 thanks for answering. Thing is, that works for my coworkers and in the CI, so I don't think the code nor stack have a problem, it's only me with a fresh install of the CLI on a new linux
(arch package
3.74.0-1
)
I can open an issue if you think that's relevant
b

billowy-army-68599

07/06/2023, 3:08 PM
we’d need a repro at the very least
what does
pulumi about
say?
f

faint-motherboard-95438

07/06/2023, 3:13 PM
Copy code
CLI          
Version      3.74.0
Go Version   go1.20.5
Go Compiler  gc

Plugins
NAME        VERSION
aws         5.19.0
aws         4.38.1
docker      3.4.1
eks         0.37.1
gcp         4.16.1
kubernetes  3.17.0
nodejs      unknown
postgresql  3.3.0
random      4.4.0

Host     
OS       arch
Version  
Arch     x86_64

This project is written in nodejs: executable='/usr/bin/node' version='v20.3.0'

Backend        
Name           <http://pulumi.com|pulumi.com>
URL            <https://app.pulumi.com/[redacted]>
User           [redacted]
Organizations  [redacted]

Dependencies:
NAME                        VERSION
@pulumi/pulumi              3.46.0
typescript                  4.8.4
@aws-sdk/types              3.201.0
@pulumi/aws                 5.19.0
@materya/pulumi             4.8.0
@types/node                 18.11.9
nunjucks                    3.2.3
@aws-sdk/client-cloudfront  3.202.0
@aws-sdk/client-sts         3.202.0

Pulumi locates its logs in /tmp by default
I tried commands like
Copy code
pulumi plugin install language nodejs
or
Copy code
pulumi plugin install language pulumi-nodejs
but same error as during a
pulumi preview
b

billowy-army-68599

07/06/2023, 3:17 PM
it’s trying to reference a provider that doesn’t exist, usually because there’s configuration euther in the stack or the code that references a nodejs provider, see here: https://github.com/pulumi/pulumi/blob/50e548a0b31a8ff482a99dbc780a6f7378dc4a54/pkg/workspace/plugin.go#L65
you might try verbose logs, but without code or stack config it’s going to be hard to debug
f

faint-motherboard-95438

07/06/2023, 3:19 PM
the
Pulumi.yaml
looks like this
Copy code
name: [redacted]
runtime: nodejs
description: [redacted]
config: stacks/
and we have nearly nothing in the stacks, that's a small deployment to CDN project :
Copy code
config:
  aws:region: eu-west-1
so that would be the
runtime
then ? but we always used this one and it works (still) elsewhere. CLI version compatibility issue maybe ? Mine would be too recent ?
b

billowy-army-68599

07/06/2023, 3:26 PM
I don’t believe so, but downgrading is an option to eliminate it as a possibility
f

faint-motherboard-95438

07/06/2023, 3:43 PM
I tried the oldest I have in cache : 3.46.1 The error at this time had a tip for this problem :
Copy code
error: could not load plugin for pulumi-nodejs provider 'urn:pulumi:staging::cresh-admin::pulumi:providers:pulumi-nodejs::default': Could not automatically download and install resource plugin 'pulumi-resource-pulumi-nodejs', install the plugin using `pulumi plugin install resource pulumi-nodejs`.
But as I stated before, this exact suggested command outputs the same error as the preview, so...
I'll rely on a patch of our CI for now, since it works there. I thought it would be a straightforward easy issue but apparently not, so.. Thanks for having looked into it, maybe I'll open an issue later with more infos (if I can get some)
b

billowy-army-68599

07/06/2023, 3:47 PM
and as I stated before, the error message isn’t giving you the solution, it’s telling you the problem. The error message is generated from here: https://github.com/pulumi/pulumi/blob/50e548a0b31a8ff482a99dbc780a6f7378dc4a54/pkg/workspace/plugin.go#L45 There is no such resource plugin as
nodejs
that’s a language plugin This isn’t a valid urn:
Copy code
urn:pulumi:staging::cresh-admin::pulumi:providers:pulumi-nodejs::default
there’s no such provider as
pulumi-nodejs
so you’ll need to try and find in your code where your that provider is instantiated. Are you using a dynamic provider?
f

faint-motherboard-95438

07/06/2023, 3:50 PM
We don't and there's no reference to
nodejs
anywhere in the code, which is very small, as I said that's just a deploy project to a bucket+cdn. Again the code, stack and all work well within other environments (local and github CI), so my main guess is a local issue on my end. I'll dig into it later, thanks again for being always so reactive 🙏
e

echoing-dinner-19531

07/06/2023, 4:48 PM
This looks like a bad install. There should be a
pulumi-language-nodejs
binary next to the
pulumi
binary. If that's missing you'll see this error.