coder / code-server

VS Code in the browser
https://coder.com
MIT License
66.63k stars 5.46k forks source link

[Bug]: Unable to build code-server from source code. Developer build commands `yarn install` and `yarn watch` failing. #6695

Closed toduyemi closed 4 days ago

toduyemi commented 4 months ago

Is there an existing issue for this?

OS/Web Information

Steps to Reproduce

1.git clone https://github.com/coder/code-server.git

  1. git submodule update --init - Clone vscode submodule
  2. quilt push -a
  3. yarn
  4. yarn watch

Expected

Dependencies should install and code-serve should go live at port 8080.

Actual

Errors are thrown in steps 3 and 4.

Logs

yarn global add code-server:

Internal Error: code-server@workspace:.: This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile at Xx.getCandidates (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:205:8149) at Dd.getCandidates (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:141:1311) at /Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:210:8409 at Ky (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:140:53916) at Fe (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:210:8389) at async Promise.allSettled (index 0) at async Uc (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:140:53244) at async /Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:210:9140 at async Qi.startProgressPromise (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:140:137284) at async Pt.resolveEverything (/Users/temioduyemi/.cache/node/corepack/yarn/4.1.0/yarn.js:210:7138)

Screenshot/Video

yarn:

Screenshot 2024-02-29 at 1 56 52 AM

yarn watch:

Screenshot 2024-02-29 at 1 57 12 AM

build.log:

Screenshot 2024-02-29 at 1 58 50 AM

Does this issue happen in VS Code or GitHub Codespaces?

Are you accessing code-server over a secure context?

Notes

No response

code-asher commented 4 months ago

Oh interesting, is this a new version of yarn without support for --no-default-rc? It seems to be 4.1.0 but we are still using Yarn v1. We should add the yarn version to the contributing docs.

code-asher commented 4 months ago

And I wonder if we can force the version of yarn in the package.json, maybe with the engines key.