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:
        nuxi@3.10.0 (default)
            binary tools: nuxi, nuxi-ng, nuxt, nuxt-cli
            platform:
                runtime: node@20.9.0
                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/cli@3.52.0 (default)
            binary tools: shopify
            platform:
                runtime: node@18.17.1
                package manager: npm@built-in
        @shopify/theme@3.52.0 (default)
            binary tools:
            platform:
                runtime: node@18.17.1
                package manager: npm@built-in
        @vue/cli@5.0.8 (default)
            binary tools: vue
            platform:
                runtime: node@18.17.1
                package manager: npm@built-in
        @withgraphite/graphite-cli@1.0.13 (default)
            binary tools: graphite, gt
            platform:
                runtime: node@18.17.1
                package manager: npm@built-in
        nuxi@3.8.3 (default)
            binary tools: nuxi, nuxi-ng, nuxt, nuxt-cli
            platform:
                runtime: node@18.17.1
                package manager: npm@built-in
        tailwind@4.0.0 (default)
            binary tools:
            platform:
                runtime: node@18.17.1
                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