platform-api-docs: `scan` strategy misses ESM-only packages, which ship `.d.ts` rather than `.d.cts`
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 76/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- typescript
調査の方向性
packages/platform-api-docs/src/generate.ts の 393 行目付近から始め、スキャン glob とその重複排除の動作を調べます。両方の宣言拡張子に一致させた後、fresh な yarn build を実行します。両方の拡張子が存在する場合でも、ESM-only パッケージが重複したドキュメントなしで含まれれば完了です。
索引モデルが issue の本文から書いたものです。
説明
platform-api-docs's scan strategy reads published declaration files with this glob (generate.ts):
node_modules/@metamask/*/dist/**/*.d.cts
That only matches CommonJS declaration files. A package published ESM-only emits .d.ts, so it is skipped silently: no warning, it just contributes nothing to the docs.
Current impact: none
Worth stating plainly so this isn't over-prioritised. Measured on main with a fresh yarn build:
- 654
.d.ctsfiles still match, so the glob is not dead. - 112 of 150
@metamaskpackages with adistwould be missed (they ship only.d.ts). - 99 of those are workspace symlinks, already covered by the
packages/*/srcscan, and since #10085 source is preferred over build output anyway. - The remaining 13 are real npm dependencies:
abi-utils,action-utils,api-specs,browser-passworder,create-release-branch,eth-json-rpc-infura,eth-sig-util,metamask-eth-abis,nonce-tracker,object-multiplex,scure-bip39,snaps-registry,swappable-obj-proxy. - Zero of those 13 contain messenger types, so nothing is missing from the docs today.
Why file it anyway
The monorepo is migrating to ESM-only (#9536 did platform-api-docs itself). As published @metamask packages follow, their declaration files become .d.ts and this glob stops seeing them. The failure mode is a silent omission rather than an error, which is the part that makes it worth fixing before it bites.
Suggested fix
Match both extensions, e.g. **/*.d.cts and **/*.d.ts, keeping them in the same call so the exclusion scoping established in #10085 is preserved. Note that a package shipping both would then be matched twice, so it is worth checking that deduplication resolves that the way we want.
- 主要言語
- TypeScript
- スター
- 414
- フォーク
- 309
- 平均マージ
- 22時間 25分
- マージ済み PR(30日)
- 367
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
MetaMask/core のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
メンテナーはふだん 1 日以内に返信
-
[utils] Replace the `uuid` dependency with `crypto.randomUUID()`対応中かも @avantikonde が 4 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
MetaMask/core#10210 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
eth-json-rpc-middleware: `TransactionParamsStruct` rejects numeric `chainId`, breaking dapp transactions対応中かも @truehazker が 48 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
MetaMask/core#9964 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
[eth-block-tracker]: `json-rpc-engine` should be a production dependency対応中かも @SnowingFox が 62 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
MetaMask/core#6864 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
better-auth/better-auth#11723 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area: docs difficulty: easy documentation good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
Worker-Erstellung bricht langsame Git-Worktree-Checkouts nach 20 Sekunden ab対応中かも @KajoVanBuyten が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 69/100
AgentSystemLabs/agent-office#367 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
pierrecomputer/pierre#1187 ·
メンテナーはふだん 1 日以内に返信
-
area: frontend bug
難易度 1/5 1〜3時間 初心者へのやさしさ 85/100
snapotter-hq/SnapOtter#2425 ·
メンテナーはふだん 1 日以内に返信