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

Cannot find package '@endo/init' with node LTS (v20.12.1) #35

Open
dckc opened this issue Apr 22, 2024 · 1 comment
Open

Cannot find package '@endo/init' with node LTS (v20.12.1) #35

dckc opened this issue Apr 22, 2024 · 1 comment
Assignees

Comments

@dckc
Copy link
Member

dckc commented Apr 22, 2024

reporting on behalf of @kbennett2000

work-around: use Node v18.18.0

INSTALLATION:

yarn create @agoric/dapp --dapp-template dapp-agoric-basics agoric-basics --dapp-branch 977-mint-tickets-ui
cd agoric-basics
yarn install
yarn start:docker
yarn docker:logs
yarn start:contract
yarn start:ui

ERRORS:

agoric@AgoricVM:~/Desktop/agoric-basics$ yarn start:contract
yarn run v1.22.22
$ cd contract && yarn start
$ make clean start-contract; yarn docker:make print-key
yarn node scripts/deploy-contract.js \
	--install src/sell-concert-tickets.contract.js \
	--eval src/platform-goals/board-aux.core.js \
	--eval src/sell-concert-tickets.proposal.js
node:internal/modules/esm/resolve:854
  throw new ERR_MODULE_NOT_FOUND(packageName, fileURLToPath(base), null);
        ^

Error [ERR_MODULE_NOT_FOUND]: Cannot find package '@endo/init' imported from /home/agoric/Desktop/agoric-basics/contract/scripts/deploy-contract.js
    at packageResolve (node:internal/modules/esm/resolve:854:9)
    at moduleResolve (node:internal/modules/esm/resolve:927:18)
    at defaultResolve (node:internal/modules/esm/resolve:1157:11)
    at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:390:12)
    at ModuleLoader.resolve (node:internal/modules/esm/loader:359:25)
    at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:234:38)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:87:39)
    at link (node:internal/modules/esm/module_job:86:36) {
  code: 'ERR_MODULE_NOT_FOUND'
}

Node.js v20.12.1
error Command failed.
Exit code: 1
Command: /home/agoric/.nvm/versions/node/v20.12.1/bin/node
Arguments: scripts/deploy-contract.js --install src/sell-concert-tickets.contract.js --eval src/platform-goals/board-aux.core.js --eval src/sell-concert-tickets.proposal.js
Directory: /home/agoric/Desktop/agoric-basics/contract
Output:

info Visit https://yarnpkg.com/en/docs/cli/node for documentation about this command.
make: *** [Makefile:74: start-contract-mint] Error 1
$ docker compose exec agd make -C /workspace/contract print-key
WARN[0000] /home/agoric/Desktop/agoric-basics/docker-compose.yml: `version` is obsolete 
make: Entering directory '/workspace/contract'
make: *** No rule to make target '/root/.agoric/user1.key', needed by 'print-key'.  Stop.
make: Leaving directory '/workspace/contract'
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
agoric@AgoricVM:~/Desktop/agoric-basics$ yarn start:ui
yarn run v1.22.22
$ cd ui && yarn dev
$ vite
/bin/sh: 1: vite: not found
error Command failed with exit code 127.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 127.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

originally: Agoric/documentation#1065 (comment)

@ivanlei
Copy link

ivanlei commented Apr 23, 2024

The upgrade-14 (current) release of Agoric-sdk says:

Node Version
Node.js 16.13 or higher (previous LTS) or Node.js 18.12 or higher (maintenance LTS).
Please note the current active LTS of Node 20 is not yet officially supported.

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

3 participants