-
Notifications
You must be signed in to change notification settings - Fork 163
Enable Solidity compilation via IR for subgraph-service and issuance #1277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Update catalog versions: - eslint: 9.37.0 -> 9.39.2 - @typescript-eslint/*: 8.46.1 -> 8.53.0 - prettier: 3.6.2 -> 3.7.4 - mocha: 11.7.1 -> 11.7.5 - markdownlint-cli: 0.45.0 -> 0.47.0 - lint-staged: 16.2.4 -> 16.2.7 - ethers: 6.15.0 -> 6.16.0 - viem: pinned to 2.31.7 (2.37.6+ breaks WAGMI generation) Note: solhint kept at 6.0.1 (6.0.2 has debug logging bug)
…ment Replace overly-broad `**/*` glob patterns with targeted paths like `packages/**/*` to avoid scanning root node_modules directory. Add explicit prettierignore path for token-distribution package to prevent linting auto-generated .graphclient-extracted files. - Lint warm cache: 28s → 18s (36% faster) - Clean sequential output with no parallel execution - Protects .graphclient-extracted from formatting changes Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Disable markdownlint rule MD040 to permit fenced code blocks without language identifiers. This is useful for generic code examples or when the language is contextually obvious. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Runs `pnpm lint:forge` in CI for Solidity files in horizon and subgraph-service packages. Only triggers when relevant files change.
The glob pattern `*/.graphclient-extracted/*` only matched paths with one directory before .graphclient-extracted. Changed to substring matching so paths like `packages/token-distribution/.graphclient-extracted/` are correctly ignored.
- Add viaIR: true to issuance hardhat config (100 runs) - Add viaIR: true to subgraph-service hardhat config (100 runs) - Add via_ir = true to subgraph-service foundry.toml - Mark assembly blocks in Attestation.sol as memory-safe - Refactor DisputeManager.t.sol to fix stack-too-deep issues
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Enable Solidity compilation via IR for subgraph-service and issuance
🚨 Report Summary
For more details view the full report in OpenZeppelin Code Inspector |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1277 +/- ##
==========================================
+ Coverage 84.06% 86.74% +2.67%
==========================================
Files 42 46 +4
Lines 2071 2451 +380
Branches 615 730 +115
==========================================
+ Hits 1741 2126 +385
+ Misses 330 325 -5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR enables Solidity compilation via IR (Intermediate Representation) for the subgraph-service and issuance packages, which can improve gas efficiency and enable certain compiler optimizations. The changes include updating compilation settings, refactoring test constants to follow UPPER_SNAKE_CASE convention, fixing import statements, adding forge linting to the CI pipeline, and updating various dependencies.
Changes:
- Enable
viaIRcompilation flag in Hardhat and Foundry configurations for subgraph-service and issuance packages - Refactor test constants from camelCase to UPPER_SNAKE_CASE (e.g.,
disputePeriod→DISPUTE_PERIOD) - Add forge linting integration to package scripts and CI workflows
- Update dependencies including ESLint, TypeScript ESLint, Prettier, and others
- Add forge-lint disable directives for existing code patterns that don't follow forge-lint rules
- Fix import statements to use named imports instead of wildcard imports
- Update variable naming for consistency (e.g.,
allocationID→allocationId,signedRAV→signedRav)
Reviewed changes
Copilot reviewed 140 out of 142 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| hardhat.config.ts (subgraph-service, issuance) | Enable viaIR compilation and adjust optimizer runs |
| foundry.toml (subgraph-service, horizon) | Enable via_ir flag and add lint ignore configuration |
| pnpm-workspace.yaml | Update dependency versions (eslint, typescript-eslint, prettier, etc.) |
| package.json (root, packages) | Update pnpm version, add forge lint scripts |
| Test files (*.t.sol) | Refactor constants to UPPER_SNAKE_CASE, fix imports, rename variables |
| Contract files (*.sol) | Add forge-lint disable directives for legacy code patterns |
| scripts/lint-staged-run.sh | Fix ignore pattern from glob to substring matching |
| .github/workflows/lint.yml | Add forge linting step to CI |
| .markdownlint.json | Add MD040 exception |
| .gitignore | Add 'core' to ignored files |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.