You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
While using 5.5.4-next.25 veramo dependencies to implement coordinate mediation protocol in my application, apparently that some of the underlying child dependencies [will be elaborated below] has switched to use ethers as their dependency but are missing from their corresponding package.json configuration.
Therefore, it will fail if we attempt to use them separately as individual node modules.
To Reproduce
Steps to reproduce the behaviour:
Create empty folder with NodeJS installed (version stated below) and run npm init to create a package.json.
Create get-all-mediation.ts and insert the following:
import{agent}from'./setup';asyncfunctionmain(){try{// This is just an example of API call. It should fail if we use any of agent API call involving 'ethers'constmediations=awaitagent.mediationManagerGetAllMediations();console.log(mediations);}catch(e){console.error(e);}}main().catch(console.log);
Run npm run esrun get-all-mediation.ts at project root directory and fails with error shown in Observed behaviour
Observed behaviour
Expected behaviour
Success message without dependency error
Short term Fix / Remediation
Upon identifying the root cause, run npm install ethers at project root directory. package.json should be updated as shown below:
After installed ethers as dependency, all veramo modules ran as expected. Despite solving this with the temporary workaround, however it is less than ideal as the ethers version might cause breaking changes.
Suggestion
Since the error persist due to the missing dependency in each of the module, I would like to suggest to include the ethers into the impacted modules in packages folder. For example: @veramo/utils
I would be gladly to make the necessary changes as PR if it is deemed acceptable. Of course would be more than happy to accept any feedbacks on such approach.
Additional context
There is a relevant discussion here that might be point of interest on how to manage shared dependency across each modules in packages folder albeit no active updates recently.
Versions (please complete the following information):
Veramo: 5.5.4-next.25
Browser NA
Node Version v21.1.0
The text was updated successfully, but these errors were encountered:
Bug severity
3
Describe the bug
While using
5.5.4-next.25
veramo dependencies to implement coordinate mediation protocol in my application, apparently that some of the underlyingchild dependencies
[will be elaborated below] has switched to useethers
as their dependency but are missing from their correspondingpackage.json
configuration.Therefore, it will fail if we attempt to use them separately as individual node modules.
To Reproduce
Steps to reproduce the behaviour:
Create empty folder with NodeJS installed (version stated below) and run
npm init
to create apackage.json
.Add the example dependencies to
package.json
:Run
npm install
to install all dependenciesCreate
tsconfig.json
and insert the following:Create
setup.ts
and insert the following:Create
get-all-mediation.ts
and insert the following:Run
npm run esrun get-all-mediation.ts
at project root directory and fails with error shown in Observed behaviourObserved behaviour
Expected behaviour
Success message without dependency error
Short term Fix / Remediation
npm install ethers
at project root directory.package.json
should be updated as shown below:"dependencies": { "@veramo/core": "5.5.4-next.25", "@veramo/credential-eip712": "5.5.4-next.25", "@veramo/credential-w3c": "5.5.4-next.25", "@veramo/data-store": "5.5.4-next.25", "@veramo/did-comm": "5.5.4-next.25", "@veramo/did-manager": "5.5.4-next.25", "@veramo/did-provider-ethr": "5.5.4-next.25", "@veramo/did-resolver": "5.5.4-next.25", "@veramo/key-manager": "5.5.4-next.25", "@veramo/kms-local": "5.5.4-next.25", "@veramo/kv-store": "5.5.4-next.25", "@veramo/mediation-manager": "5.5.4-next.25", "@veramo/message-handler": "5.5.4-next.25", + "ethers": "6.9.0", }, "devDependencies": { "@digitak/esrun": "3.2.24", "sqlite3": "^5.1.6", "typescript": "^5.1.6" }
ethers
as dependency, all veramo modules ran as expected. Despite solving this with the temporary workaround, however it is less than ideal as theethers
version might cause breaking changes.Suggestion
ethers
into the impacted modules inpackages
folder. For example:@veramo/utils
veramo/packages/utils/package.json
Lines 12 to 25 in 462735d
The following are the other modules that use
ethers
as dependency:I would be gladly to make the necessary changes as PR if it is deemed acceptable. Of course would be more than happy to accept any feedbacks on such approach.
Additional context
packages
folder albeit no active updates recently.Versions (please complete the following information):
5.5.4-next.25
NA
v21.1.0
The text was updated successfully, but these errors were encountered: