Sphereon-Opensource / OID4VC-demo

Demo for OID4VC, containing a configurable agent, OID4VCI Issuer and demopage as well as SIOPv2 and OID4VP RPs with demo page
Apache License 2.0
18 stars 8 forks source link

Bug: Module not found #16

Closed cre8 closed 1 year ago

cre8 commented 1 year ago

After a fresh clone and pnpm install I tried to run the project with pnpm run start:dev and got this error:

packages/agent start:dev:     throw new ERR_MODULE_NOT_FOUND(
packages/agent start:dev:           ^
packages/agent start:dev: CustomError: Cannot find module '/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/@sphereon+did-auth-siop@0.3.2-unstable.10/node_modules/@sphereon/did-auth-siop/dist/module/schemas/validation/schemaValidation.js' imported from /home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/@sphereon+did-auth-siop@0.3.2-unstable.10/node_modules/@sphereon/did-auth-siop/dist/module/schemas/validation/index.mjs
packages/agent start:dev:     at finalizeResolution (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:352:11)
packages/agent start:dev:     at moduleResolve (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:801:10)
packages/agent start:dev:     at Object.defaultResolve (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/dist-raw/node-internal-modules-esm-resolve.js:912:11)
packages/agent start:dev:     at /home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/esm.ts:218:35
packages/agent start:dev:     at entrypointFallback (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/esm.ts:168:34)
packages/agent start:dev:     at /home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/esm.ts:217:14
packages/agent start:dev:     at addShortCircuitFlag (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/esm.ts:409:21)
packages/agent start:dev:     at resolve (/home/mimo/Projects/OID4VC-demo/node_modules/.pnpm/ts-node@10.9.1_@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/esm.ts:197:12)
packages/agent start:dev:     at nextResolve (node:internal/modules/esm/loader:163:28)
packages/agent start:dev:     at ESMLoader.resolve (node:internal/modules/esm/loader:835:30)
packages/agent start:dev: Failed
/home/mimo/Projects/OID4VC-demo/packages/agent:
 ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  @sphereon/oid4vc-demo-agent@0.1.0 start:dev: `node --experimental-specifier-resolution=node --loader ts-node/esm src/agent.ts`
Exit status 1
 ELIFECYCLE  Command failed with exit code 1.

I tried to run the pnpm install with the --frozen-lockfile parameter, but this returned me this error:

ERR_PNPM_LOCKFILE_CONFIG_MISMATCH  Cannot proceed with the frozen installation. The current "overrides" configuration doesn't match the value found in the lockfile
mwaheed-dev commented 1 year ago

I am also facing the same issue, then I updated did-auth-siop@0.3.2-unstable.10 to did-auth-siop@0.4.0, facing new error now. TypeError: Cannot create proxy with a non-object as target or handler at new r (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:38932) at /Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:199308 at Object.manage (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:284816) at _h (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:288654) at Jh (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:295832) at O (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/esm@3.2.25/node_modules/esm/esm.js:1:811) at Object. (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/node_modules/.pnpm/@digitalbazaar+http-client@1.2.0/node_modules/@digitalbazaar/http-client/index.js:7:25) at Module._compile (node:internal/modules/cjs/loader:1105:14) at Module._extensions..js (node:internal/modules/cjs/loader:1159:10) at Object.require.extensions. [as .js] (/Users/waheedashraf/Documents/FAME/FAME_CODE/Sphereon-Opensource/OID4VC-demo/OID4VC-demo/nodemodules/.pnpm/ts-node@10.9.1@types+node@18.17.3_typescript@4.9.5/node_modules/ts-node/src/index.ts:1608:43)  ELIFECYCLE  Command failed with exit code 1.

nklomp commented 1 year ago

We are currently releasing multiple versions of lower level libraries and the SDK. This should be resolved early next week. Sorry for the issues

mwaheed-dev commented 1 year ago

@nklomp Thanks for providing quick fix, now its working fine.

nklomp commented 1 year ago

Ah haven't come around to checking it, but good to hear it is resolved now.

cre8 commented 1 year ago

After pulling the latest version, it is working for me too :)