Repository navigation
Modernize toolchain and check deployed bytecode - #20
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
🟢 Approval recommended
The development and release tooling changes have no active review issues.
No open issues 🎉
What changed in this PR
Modernizes seaport-core’s development and release tooling while preserving the source and compiler settings used for canonical Seaport 1.6.
Changes:
- Adds canonical init-code hash and deployment-address checks, plus frozen-source checksums.
- Introduces pinned lint tools, formatting configuration, and automated build and lint CI.
- Updates npm publishing, corrects the dependency lockfile, and refreshes contributor documentation.
| File | Description |
|---|---|
yarn.lock |
Aligns seaport-types resolution with the declared 1.6.3 dependency. |
scripts/lint.sh |
Adds shared lint, formatting, and source-freeze commands. |
scripts/install-tools.sh |
Installs pinned lint tools with checksum verification. |
scripts/frozen-src.sha256 |
Records checksums for frozen Solidity sources. |
scripts/check-deployed-bytecode.sh |
Checks canonical init-code hash and derived deployment address. |
README.md |
Refreshes installation, development, and documentation guidance. |
lefthook.yml |
Adds formatting hooks that exclude frozen Solidity sources. |
foundry.toml |
Excludes frozen sources from formatting and linting without changing compiler settings. |
biome.json |
Configures formatting, linting, and generated-directory exclusions. |
AGENTS.md |
Documents source-preservation rules and contributor commands. |
.taplo.toml |
Configures TOML formatting. |
.nvmrc |
Selects Node 26 for publishing. |
.gitignore |
Excludes npm dependencies and installed lint tools. |
.github/workflows/test.yml |
Automates build, bytecode verification, and lint checks. |
.github/workflows/tag.yml |
Modernizes output handling and adds branch-level concurrency. |
.github/workflows/publish.yml |
Updates Node setup and adds frozen installs and npm provenance. |
.github/pull_request_template.md |
Adds motivation and solution prompts for contributors. |
.github/actions/setup-foundry/action.yml |
Centralizes pinned Foundry installation and caching. |
.editorconfig |
Defines shared whitespace and indentation settings. |
Review effort: Balanced
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tomhirst
approved these changes
Nov 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Brings seaport-core's tooling in line with seaport's modernized main and adds a CI check that the build still matches canonical Seaport 1.6. No file under
src/, thelib/seaport-typespin, and no compiler setting changes.Deployed bytecode check
scripts/check-deployed-bytecode.shbuilds withfoundry.tomlas it is on main and hashes the Seaport creation code plus the abi-encoded ConduitController (0x00000000F9490004C11Cef243f5400493c00Ad63). The result must equal the canonical init code hash0xde057106...902d94. It also checks that this hash and salt0x...d738b7f0bb99901b1c83f249derive0x0000000000000068F116a894984e2DB1123eB395through the ImmutableCreate2Factory. It uses onlyforge,cast, andjq, so the repo still has no forge-std.Main's own settings (solc 0.8.24, via_ir, cancun,
bytecode_hash = "none",optimizer_runs = 4_294_967_295) reproduce the hash with Foundry 1.9.0. WithFOUNDRY_OPTIMIZER_RUNS=200the script fails as expected.Lint tooling
scripts/install-tools.sh,scripts/lint.sh,lefthook.yml,biome.json,.taplo.toml, and.editorconfigcome from seaport, trimmed to this repo. The tools are pinned binaries checked by SHA-256 and installed into.tools/bin, which is gitignored.src/**is excluded fromforge fmtandforge lintinfoundry.tomland in lefthook's exclude list.lint_on_buildis off, soforge buildno longer prints lint notes for the frozen source.scripts/frozen-src.sha256records a hash of every file insrc/. Lint fails if one changes.CI
test.ymlnow runs on pushes to main and on pull requests (it wasworkflow_dispatchonly, on Foundry nightly). It has a build job (build plus the bytecode check) and a lint job, with Foundry pinned to v1.9.0, least-privilegepermissions, andconcurrency.publish.ymlkeeps its trigger and theNPM_TOKENsecret. It now uses Node 26 (current LTS, from.nvmrc),yarn install --frozen-lockfile, andnpm publish --provenance --access publicwithid-token: write.package.jsonspells outrepositoryin thegit+httpsform that provenance checks against.tag.ymlkeeps its triggers and behavior. It replaces the deprecated::set-outputwith$GITHUB_OUTPUT, passes the tag throughenv, and force-pushes only the new tag instead of every local tag.npm package
yarn.lockstill pinnedseaport-types@^0.0.1whilepackage.jsonasks for1.6.3, so--frozen-lockfilewould have failed. It is regenerated and now resolvesseaport-types@1.6.3, whosegitHeadmatches thelib/seaport-typespin.npm pack --dry-runlists the same 28 files as the published 1.6.6 tarball. npm never packsnode_modules, even whenfileslists it, so seaport-types reaches consumers as a normal dependency. The onlypackage.jsonchange is therepositoryfield.Docs
Adds a short
AGENTS.md, refreshes the README with links to seaport's docs and deployments, and adds seaport's pull request template.Verification
scripts/lint.sh checkis clean with Foundry 1.9.0, and fails after a one-byte edit tosrc/Seaport.sol.scripts/check-deployed-bytecode.shpasses.git diff origin/main -- src/ lib/is empty.🤖 Generated with Claude Code