Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Volta/Nuxt problems between multiple user accounts? #1730

Open
MorningstarPhoenix opened this issue Mar 30, 2024 · 2 comments
Open

Volta/Nuxt problems between multiple user accounts? #1730

MorningstarPhoenix opened this issue Mar 30, 2024 · 2 comments

Comments

@MorningstarPhoenix
Copy link

This is probably a consequence of my lack of knowledge but, on my Windows machine I have two profiles (one work and one personal). I use Volta to manage my node.
Nuxt projects build and run correctly in my work profile, but the same projects fail in my personal profile.
The various paths relating to Volta are these:

  • The system path has C:\Program Files\Volta\
  • The personal profile's path has C:\Users\personalusername\AppData\Local\Volta\bin
  • The work profile's path has C:\Users\workusername\AppData\Local\Volta\bin

The only difference I can spot between the personal and work profile is that I use node 18 in the work profile, and node 20 in the personal profile.

Either way, on the personal profile Nuxt seems to be looking for Devtools in C:/Program Files/nodejs/node_modules/@nuxt/devtools/module.cjs but C:/Program Files/nodejs does not exist, generating the "Cannot find module" error.

I have not validated this problem with other frameworks/projects outside Nuxt.

Anyone has any idea about what's going on?

@charlespierce
Copy link
Contributor

Hi @MorningstarPhoenix, that's surprising! I don't have any insights into what Nuxt is doing internally, but if it works in one profile it should work in the other. What is the output of volta list all for the two profiles? It's possible that the Nuxt devtools are installed for one and not the other, which is causing it to fall back to searching the "default" locations for Node.

@MorningstarPhoenix
Copy link
Author

Hi!
Nuxt Devtools is not installed in neither profile... I have tried installing in the personal profile, but no dice.

Either way, running the command in the personal profile gives this output:

 User toolchain:

    Node runtimes:
        v20.9.0 (default)

    Package managers:


    Packages:
        [email protected] (default)
            binary tools: nuxi, nuxi-ng, nuxt, nuxt-cli
            platform:
                runtime: [email protected]
                package manager: npm@built-in

While running in the work profile returns this:

User toolchain:

    Node runtimes:
        v18.17.1 (default)

    Package managers:
        Yarn:
            v4.0.0 (default)

    Packages:
        @shopify/[email protected] (default)
            binary tools: shopify
            platform:
                runtime: [email protected]
                package manager: npm@built-in
        @shopify/[email protected] (default)
            binary tools:
            platform:
                runtime: [email protected]
                package manager: npm@built-in
        @vue/[email protected] (default)
            binary tools: vue
            platform:
                runtime: [email protected]
                package manager: npm@built-in
        @withgraphite/[email protected] (default)
            binary tools: graphite, gt
            platform:
                runtime: [email protected]
                package manager: npm@built-in
        [email protected] (default)
            binary tools: nuxi, nuxi-ng, nuxt, nuxt-cli
            platform:
                runtime: [email protected]
                package manager: npm@built-in
        [email protected] (default)
            binary tools:
            platform:
                runtime: [email protected]
                package manager: npm@built-in

There's a version mismatch with Nuxi but I don't think that's the problem, could it be?

While I have Yarn installed in the work profile only, I'm using npm as the package manager for the Nuxt project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants