Skip to content

Conversation

@timothymcmackin
Copy link
Collaborator

@timothymcmackin timothymcmackin commented Dec 4, 2025

Lots of updates needed to this tutorial for the new version of Hardhat, which requires node 22. For the changes to the completed application, see trilitech/tutorial-applications#30.

To verify, I recommend you go through the tutorial from start to finish.

Preview: https://docs-etherlink-git-shadownet-tutorial-trili-tech.vercel.app/tutorials/marketpulse/

Note that there is a lot in this tutorial that I'd like to rewrite and clarify but for now we need to get the tutorial working on Shadownet. I'll clarify or replace it later.

Major changes:

  • Many changes needed for the new version of hardhat, including using Node 22 and reformatting of the hardhat.config.ts file
  • Updates to chain ID and default RPC
  • Changes in the test based on changes to hardhat and Viem
  • Some reuse for simplicity in App.tsx

@timothymcmackin timothymcmackin self-assigned this Dec 4, 2025
@vercel
Copy link

vercel bot commented Dec 4, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
docs-etherlink Ready Ready Preview, Comment Dec 19, 2025 5:33pm

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the very last step (pushing a commit to check the CI), I first had a failed deploy_contract with: unknown variable DEPLOYER_PRIVATE_KEY.
For fixing that, I edited .github/workflow/marketpulse.yml:
to set
DEPLOYER_PRIVATE_KEY: ${{ secrets.DEPLOYER_PRIVATE_KEY }}
and it worked fine.

Copy link
Collaborator

@NicNomadic NicNomadic Dec 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tim changed the file .github/workflow/marketpulse.yml and after that the CI test still didn't work for me. I managed to executed only one time correctly after renaming the variable used by Tim HARDHAT_VAR_DEPLOYER_PRIVATE_KEY to DEPLOYER_PRIVATE_KEY

But after that one successful shot, it fails again with:

Error: Futures timed out with transactions unconfirmed after maximum fee bumps

IDK what to do...

@yfalcone
Copy link
Collaborator

Got some issue, right in the beginning:

npx hardhat init
WARNING: You are using Node.js 23.10.0 which is not supported by Hardhat.
Please upgrade to 22.10.0 or a later LTS version (even major version number)

Error HHE3: No Hardhat config file found.

You can initialize a new project by running Hardhat with --init

For more info go to https://hardhat.org/HHE3 or run Hardhat with --show-stack-traces

@yfalcone
Copy link
Collaborator

Similarly got different quetion:

Screenshot 2025-12-16 at 10 19 32

@yfalcone
Copy link
Collaborator

Got some issue, right in the beginning:

npx hardhat init
WARNING: You are using Node.js 23.10.0 which is not supported by Hardhat.
Please upgrade to 22.10.0 or a later LTS version (even major version number)

Error HHE3: No Hardhat config file found.

You can initialize a new project by running Hardhat with --init

For more info go to https://hardhat.org/HHE3 or run Hardhat with --show-stack-traces

Even though the message provided by the command is inconsistent, perhaps we should say version 22 should be installed.

@yfalcone
Copy link
Collaborator

I've got weird errors (see below) and access requests to my local photo and music librairies, strange.

👷 Welcome to Hardhat v3.1.0 👷

✔ Which version of Hardhat would you like to use? · hardhat-3
✔ Where would you like to initialize the project?

Please provide either a relative or an absolute path: · .
✔ What type of project would you like to initialize? · node-test-runner-viem
✔ Hardhat only supports ESM projects. Would you like to change "./package.json" to turn your project into ESM? (Y/n) · true
An unexpected error occurred:

FileSystemAccessError: EPERM: operation not permitted, scandir '/Users/yliesfalcone/.Trash'
    at readdir (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:492:11)
    at async readdirOrEmpty (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:503:12)
    ... 6 lines matching cause stack trace ...
    at async file:///Users/yliesfalcone/node_modules/hardhat/dist/src/cli.js:21:1 {
  [cause]: Error: EPERM: operation not permitted, scandir '/Users/yliesfalcone/.Trash'
      at async Object.readdir (node:internal/fs/promises:957:18)
      at async readdir (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:481:12)
      at async readdirOrEmpty (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:503:12)
      at async getAllFilesMatching (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:62:22)
      at async Promise.all (index 3)
      at async getAllFilesMatching (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:64:19)
      at async copyProjectFiles (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/init/init.ts:431:42)
      at async initHardhat (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/init/init.ts:123:5)
      at async main (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/main.ts:96:14)
      at async file:///Users/yliesfalcone/node_modules/hardhat/dist/src/cli.js:21:1 {
    errno: -1,
    code: 'EPERM',
    syscall: 'scandir',
    path: '/Users/yliesfalcone/.Trash'
  }
}

@yfalcone
Copy link
Collaborator

I've got weird errors (see below) and access requests to my local photo and music librairies, strange.

👷 Welcome to Hardhat v3.1.0 👷

✔ Which version of Hardhat would you like to use? · hardhat-3
✔ Where would you like to initialize the project?

Please provide either a relative or an absolute path: · .
✔ What type of project would you like to initialize? · node-test-runner-viem
✔ Hardhat only supports ESM projects. Would you like to change "./package.json" to turn your project into ESM? (Y/n) · true
An unexpected error occurred:

FileSystemAccessError: EPERM: operation not permitted, scandir '/Users/yliesfalcone/.Trash'
    at readdir (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:492:11)
    at async readdirOrEmpty (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:503:12)
    ... 6 lines matching cause stack trace ...
    at async file:///Users/yliesfalcone/node_modules/hardhat/dist/src/cli.js:21:1 {
  [cause]: Error: EPERM: operation not permitted, scandir '/Users/yliesfalcone/.Trash'
      at async Object.readdir (node:internal/fs/promises:957:18)
      at async readdir (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:481:12)
      at async readdirOrEmpty (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:503:12)
      at async getAllFilesMatching (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:62:22)
      at async Promise.all (index 3)
      at async getAllFilesMatching (/Users/yliesfalcone/node_modules/@nomicfoundation/hardhat-utils/src/fs.ts:64:19)
      at async copyProjectFiles (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/init/init.ts:431:42)
      at async initHardhat (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/init/init.ts:123:5)
      at async main (/Users/yliesfalcone/node_modules/hardhat/src/internal/cli/main.ts:96:14)
      at async file:///Users/yliesfalcone/node_modules/hardhat/dist/src/cli.js:21:1 {
    errno: -1,
    code: 'EPERM',
    syscall: 'scandir',
    path: '/Users/yliesfalcone/.Trash'
  }
}

Note, I was running the script from my home directory, which explains probably the access requests.
Perhaps it should be said that the commands should be run from a fresh directory?

@NicNomadic
Copy link
Collaborator

Note, I was running the script from my home directory, which explains probably the access requests. Perhaps it should be said that the commands should be run from a fresh directory?

Good idea, done

@NicNomadic
Copy link
Collaborator

I've got weird errors (see below) and access requests to my local photo and music librairies, strange.

Consider opening threads for comments requiring an action, to be able to follow the issue.

In this case, I guess a comment on the concerned file would have been appropriate.

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

Successfully merging this pull request may close these issues.

4 participants