Skip to content

CLI not working with yarn 3.6.4 or yarn 4.0.1 on Windows #1624

Open
@bre7

Description

@bre7

Describe the bug
Unable to run CLI when using latest stable versions of yarn 3 or 4

Tried with latest stable (4.0.2) and then 3.6.4 (#1380)
Deleted yarn.lock/.yarn/.pnp.*

To Reproduce

  1. Open terminal
  2. Run yarn supabase -h

Full repro:

# yarn 3
mkdir test-yarn3 && cd test-yarn3 && yarn init -y && yarn set version 3.6.4 && yarn add -D supabase && yarn supabase -h
# yarn 4
mkdir test-yarn4 && cd test-yarn4 && yarn init -y && yarn set version 4.0.2 && yarn add -D supabase && yarn supabase -h

Expected behavior

CLI's help screen

Screenshots

$ node -v
v19.6.0
$ yarn -v
4.6.4
$ yarn supabase -h
G:\dev\proj-15-demo\.pnp.cjs:28556
  return Object.defineProperties(new Error(message), {
                                 ^

Error: Qualified path resolution failed: we looked for the following paths, but none could be accessed.

Source path: G:\dev\proj-15-demo\.yarn\unplugged\supabase-npm-1.110.2-8a9a0308b6\node_modules\supabase\bin\supabase
Not found:   G:\dev\proj-15-demo\.yarn\unplugged\supabase-npm-1.110.2-8a9a0308b6\node_modules\supabase\bin\supabase  

    at makeError (G:\dev\proj-15-demo\.pnp.cjs:28556:34)
    at resolveUnqualified (G:\dev\proj-15-demo\.pnp.cjs:30328:13)
    at resolveRequest (G:\dev\proj-15-demo\.pnp.cjs:30369:14)
    at Object.resolveRequest (G:\dev\proj-15-demo\.pnp.cjs:30425:26)
    at resolve$1 (file:///G:/dev/proj-15-demo/.pnp.loader.mjs:1989:21)
    at nextResolve (node:internal/modules/esm/loader:163:28)
    at ESMLoader.resolve (node:internal/modules/esm/loader:835:30)
    at ESMLoader.getModuleJob (node:internal/modules/esm/loader:416:18)
    at ESMLoader.import (node:internal/modules/esm/loader:517:22)
    at node:internal/modules/run_main:56:28

Node.js v19.6.0

Desktop (please complete the following information):

  • OS: Windows 10
  • Version of CLI v1.106.1
  • Version of supabase-js v2.38.4
  • Version of Node.js v19.6.0

Additional context
Works as expected on Linux with Docker (e.g. docker run --rm --workdir=/tmp -it node:slim bash)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions