janhq / jan

Jan is an open source alternative to ChatGPT that runs 100% offline on your computer. Multiple engine support (llama.cpp, TensorRT-LLM)
https://jan.ai/
GNU Affero General Public License v3.0
23.6k stars 1.37k forks source link

bug: Couldn't find package "@nut-tree/nut-js@^4.0.0" required by "jan@0.1.3" on the "npm" registry. #2850

Closed weavetolga closed 6 months ago

weavetolga commented 6 months ago

Describe the bug When running docker compose -f docker-compose-dev.yml --profile cpu-fs up -d in the jan repo, the Docker image will not build because of this error: "Couldn't find package "@nut-tree/nut-js@^4.0.0" required by "jan@0.1.3" on the "npm" registry.".

EDIT 30th April 13:18 Seems like creator is moving away from open source: https://nutjs.dev/blog/i-give-up

Steps to reproduce Steps to reproduce the behavior:

  1. Checkout 'dev' branch
  2. Run docker compose -f docker-compose-dev.yml --profile cpu-fs up -d
  3. Package not found error

Expected behavior Docker image builds successfully.

Environment details

Logs

 > [app_cpu_fs builder 5/5] RUN make install-and-build:                                                                                                                                                       
0.114 cd uikit && yarn install && yarn build                                                                                                                                                                  
0.251 yarn install v1.22.19                                                                                                                                                                                   
0.264 info No lockfile found.                                                                                                                                                                                 
0.272 [1/4] Resolving packages...                                                                                                                                                                             
0.678 warning cpx > chokidar@1.7.0: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
0.717 warning cpx > babel-runtime > core-js@2.6.12: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
0.764 warning cpx > chokidar > fsevents@1.2.13: The v1 package contains DANGEROUS / INSECURE binaries. Upgrade to safe fsevents v2
1.002 warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
1.084 warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
1.090 warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
1.095 warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
2.437 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/uikit > tsup@7.3.0: Breaking node 16
2.594 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/core > rollup-plugin-json@3.1.0: This module has been deprecated and is no longer maintained. Please use @rollup/plugin-json.
2.624 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/core > rollup-plugin-sourcemaps > source-map-resolve@0.6.0: See https://github.com/lydell/source-map-resolve#deprecated
2.749 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > jan > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
2.749 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/server > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
3.132 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/core > rollup-plugin-node-resolve@5.2.0: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-node-resolve.
3.220 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/core > rollup-plugin-commonjs@9.3.4: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-commonjs.
3.313 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/web > react-scroll-to-bottom > core-js@3.18.3: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
3.320 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > jan > request > uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
4.040 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/web > @types/react-icons@3.0.0: This is a stub types definition. react-icons provides its own type definitions, so you do not need this installed.
5.582 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > jan > request > har-validator@5.1.5: this library is no longer supported
8.210 warning workspace-aggregator-fc554989-d811-4dc5-b461-13b81395f4f5 > @janhq/core > rollup-plugin-commonjs > magic-string > sourcemap-codec@1.4.8: Please use @jridgewell/sourcemap-codec instead
12.64 error Couldn't find package "@nut-tree/nut-js@^4.0.0" required by "jan@0.1.3" on the "npm" registry.
12.64 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
12.68 make: *** [Makefile:18: build-uikit] Error 1
------
failed to solve: process "/bin/sh -c make install-and-build" did not complete successfully: exit code: 2
matthnig commented 6 months ago

I am facing the same issue when building it locally according to the README:

PS> make dev
cd uikit && yarn config set network-timeout 300000 && yarn install && yarn build
yarn config v1.22.19
success Set "network-timeout" to "300000".
Done in 0.05s.
yarn install v1.22.19
info No lockfile found.
[1/4] Resolving packages...
warning cpx > chokidar@1.7.0: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
warning cpx > chokidar > fsevents@1.2.13: The v1 package contains DANGEROUS / INSECURE binaries. Upgrade to safe fsevents v2
warning cpx > babel-runtime > core-js@2.6.12: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
warning cpx > chokidar > readdirp > micromatch > snapdragon > source-map-resolve > source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/uikit > tsup@7.3.0: Breaking node 16
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/core > rollup-plugin-commonjs@9.3.4: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-commonjs.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/core > rollup-plugin-json@3.1.0: This module has been deprecated and is no longer maintained. Please use @rollup/plugin-json.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/core > rollup-plugin-node-resolve@5.2.0: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-node-resolve.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/core > rollup-plugin-sourcemaps > source-map-resolve@0.6.0: See https://github.com/lydell/source-map-resolve#deprecated
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > jan > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/server > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > jan > request > uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/web > react-scroll-to-bottom > core-js@3.18.3: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/web > @types/react-icons@3.0.0: This is a stub types definition. react-icons provides its own type definitions, so you do not need this installed.
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > jan > request > har-validator@5.1.5: this library is no longer supported
warning workspace-aggregator-3301b9a0-1f67-4910-815f-bbd687f8ef62 > @janhq/core > rollup-plugin-commonjs > magic-string > sourcemap-codec@1.4.8: Please use @jridgewell/sourcemap-codec instead
error Couldn't find package "@nut-tree/nut-js@^4.0.0" required by "jan@0.1.3" on the "npm" registry.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
make: *** [Makefile:16: build-uikit] Error 1
ckerr commented 6 months ago

See https://github.com/nut-tree/nut.js/issues/587 and https://nutjs.dev/blog/i-give-up

All of my packages around nut.js will cease to exist publicly on npm. Ready-to-use packages will only be available through the private nut.js package registry, which requires an active subscription to be used.

Van-QA commented 6 months ago

Reopen this to wait for a workaround solution for nut-js