Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Infura RPC API Key (https://infura.io)
INFURA_API_KEY=your_infura_api_key_here

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Use the env key that the network config actually reads

This template defines INFURA_API_KEY, but the project’s Hardhat network config expects SEPOLIA_RPC_URL and never consumes INFURA_API_KEY. A developer following this file will leave SEPOLIA_RPC_URL unset, and Sepolia deployment commands will fail unless they infer and add a different variable manually.

Useful? React with 👍 / 👎.


# Private key of the deployer wallet (NO 0x prefix)
PRIVATE_KEY=your_private_key_here
30 changes: 30 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: CI

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
test:
name: Hardhat Tests
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Compile contracts
run: npx hardhat compile

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Provide required env vars before Hardhat CI steps

The workflow runs npx hardhat compile and npx hardhat test without setting SEPOLIA_RPC_URL and PRIVATE_KEY, but hardhat.config.js unconditionally reads both in networks.sepolia (lines 8-9). On a clean GitHub runner these variables are unset, which causes Hardhat config validation (HH8: Invalid Hardhat config) before compile/tests execute, so this CI job can fail even when code is correct.

Useful? React with 👍 / 👎.


- name: Run tests
run: npx hardhat test
Loading