graphprotocol / graphprotocol/contracts

ci: build test fails randomly

Open
#901 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Solidity
Stars
374
Forks
176
Avg merge
1d 15h
Merged PRs (30d)
4

Description

Build test fails randomly when ran on GitHub actions:

[@graphprotocol/contracts]: An unexpected error occurred:
[@graphprotocol/contracts]: 
[@graphprotocol/contracts]: Error: spawn /home/runner/.cache/hardhat-nodejs/compilers-v2/linux-amd64/solc-linux-amd64-v0.7.6+commit.7338295f EACCES
[@graphprotocol/contracts]:     at Process.ChildProcess._handle.onexit (node:internal/child_process:284:19)
[@graphprotocol/contracts]:     at onErrorNT (node:internal/child_process:477:16)
[@graphprotocol/contracts]:     at processTicksAndRejections (node:internal/process/task_queues:82:21) {
[@graphprotocol/contracts]:   errno: -13,
[@graphprotocol/contracts]:   code: 'EACCES',
[@graphprotocol/contracts]:   syscall: 'spawn /home/runner/.cache/hardhat-nodejs/compilers-v2/linux-amd64/solc-linux-amd64-v0.7.6+commit.7338295f',
[@graphprotocol/contracts]:   path: '/home/runner/.cache/hardhat-nodejs/compilers-v2/linux-amd64/solc-linux-amd64-v0.7.6+commit.7338295f',
[@graphprotocol/contracts]:   spawnargs: [ '--standard-json' ],
[@graphprotocol/contracts]:   cmd: '/home/runner/.cache/hardhat-nodejs/compilers-v2/linux-amd64/solc-linux-amd64-v0.7.6+commit.7338295f --standard-json'
[@graphprotocol/contracts]: }
[@graphprotocol/contracts]: Process exited (exit code 1), completed in 8s 876ms

[@graphprotocol/sdk]: Process started
[@graphprotocol/sdk]: 
[@graphprotocol/sdk]: > @graphprotocol/sdk@0.3.0 clean
[@graphprotocol/sdk]: > rm -rf build
[@graphprotocol/sdk]: 
Error: [@graphprotocol/sdk]: src/deployments/network/actions/bridge-to-l1.ts(10,56): error TS2306: File '/home/runner/work/contracts/contracts/packages/contracts/index.d.ts' is not a module.
Error: [@graphprotocol/sdk]: src/deployments/network/actions/bridge-to-l1.ts(141,54): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string | TransactionReceipt'.
[@graphprotocol/sdk]:   Type 'undefined' is not assignable to type 'string | TransactionReceipt'.
Error: [@graphprotocol/sdk]: src/deployments/network/deployment/contracts/load.ts(44,8): error TS2306: File '/home/runner/work/contracts/contracts/packages/contracts/index.d.ts' is not a module.
Error: [@graphprotocol/sdk]: src/helpers/epoch.ts(2,35): error TS2306: File '/home/runner/work/contracts/contracts/packages/contracts/index.d.ts' is not a module.
[@graphprotocol/sdk]: Process exited (exit code 1), completed in 2s 756ms
Done in 11s 639ms
Error: Process completed with exit code 1.

This is a known problem with hardhat:

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the failing GitHub Actions build and the Hardhat compiler cache path shown in the log, then compare the repository's Hardhat version with the linked upstream issues. Review the reported SDK errors in src/deployments/network/actions/bridge-to-l1.ts, src/deployments/network/deployment/contracts/load.ts, and src/helpers/epoch.ts. Done means the complete build passes reliably in CI.

Written by the indexing model from the issue text.

Assessment

Tech stack
github-actions, node.js, solidity, typescript
Domain
blockchain, ci-cd
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.