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 .changeset/clean-spiders-smile.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@sei-js/registry": patch
---

Stop running Git submodule commands when consumers install the registry package.
1 change: 1 addition & 0 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch the full history instead of a shallow clone
submodules: recursive

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[nit] Correct and necessary now that postinstall is gone. Minor: neither entry in .gitmodules has nested submodules, so submodules: true would do and avoids the recursive walk. Both submodule URLs are public HTTPS, so this also works for fork PRs under the default GITHUB_TOKEN — no change needed there.


- uses: actions/setup-node@v4
with:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch the full history instead of a shallow clone
submodules: recursive
- name: Use Node.js
uses: actions/setup-node@v4
with:
Expand Down
8 changes: 4 additions & 4 deletions REVIEW.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ defect.
startup is the intent. Do not ask for a thrown error the caller might swallow.
- **`packages/registry/chain-registry` and `.../community-assetlist` are
missing from the tree.** Both are git submodules (`.gitmodules`) and are
listed in `.gitignore`. Only `release.yml` checks them out with
`submodules: recursive`; the PR gate in `checks.yml` does a plain checkout
and relies on the `registry` package's `postinstall`. Their JSON is vendored
upstream — review the TypeScript wrappers, not the data.
listed in `.gitignore`. Workflows that build the registry check them out with
`submodules: recursive`; local source builds must initialize them explicitly.
Their JSON is vendored upstream — review the TypeScript wrappers, not the
data.
- **Biome findings are not enforced anywhere.** `biome.json` configures tabs,
160-column lines, single quotes and no trailing commas, but no package
defines a `biome` script and `.github/workflows/checks.yml` runs only
Expand Down
3 changes: 1 addition & 2 deletions packages/registry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
"build:cjs": "tsc --outDir dist/cjs --module commonjs",
"build:esm": "tsc --outDir dist/esm --module esnext",
"build:types": "tsc --project ./tsconfig.declaration.json",
"test": "jest",
"postinstall": "git submodule update --init --recursive"
"test": "jest"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[suggestion] Removing this from the published package is right — git submodule update --init --recursive fails outside a Git checkout and, when a consumer does install inside one, it operates on their repo's submodules. But it was also the only thing initializing the submodules for local development, so a fresh clone followed by pnpm install && pnpm build:all now fails on registry with Cannot find module '../../chain-registry/chain_info.json'.

The root package.json is "private": true, so its scripts are never published. Moving the hook there keeps local dev working with zero consumer impact:

"scripts": {
  "postinstall": "git submodule update --init --recursive",
  ...
}

(Guard it with git rev-parse --git-dir > /dev/null 2>&1 && if you want it to no-op in tarball/CI contexts.) Alternatively, document the step in the root README — see the separate non-blocking note.

},
"homepage": "https://github.com/sei-protocol/sei-js#readme",
"keywords": [
Expand Down
Loading