Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

build-train: fast-path hash checks with mtime/size stats

オープン
#481 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
node.js, typescript

調査の方向性

Start with workspace.ts:339 and trace memberInputHash, hashWorkspaceTree, and recordBuilt; first check how #480 narrows the input files, since this issue is blocked by it. Add tests for unchanged, touched, added, deleted, and manifest-free trees, and verify old cache entries invalidate; done means matching stats reuse the hash while mismatches trigger a full rehash.

索引モデルが issue の本文から書いたものです。

説明

ready-for-agent

What to build

Every staleness judgement re-reads and hashes every file in every member's tree (memberInputHash → hashWorkspaceTree, workspace.ts:339). Turbo's trick avoids this: persist a per-file mtime/size manifest alongside the hash; if no file's stats changed since the recorded hash, skip rehashing the tree entirely.

.bos/build-cache.json already persists per-member state — extend the cache entry with a stats manifest:

{
  "every-plugin": {
    "hash": "...",
    "files": { "src/index.ts": [1700000000000, 4021], ... }  // mtimeMs, size
  }
}

Fast path: walk the tree collecting stats only (cheap), compare against the manifest — exact match → reuse the recorded input hash without reading file contents. Any mismatch (new/removed/changed file, or no manifest) → full rehash as today. A stats match with changed content and unchanged mtime+size is theoretically possible but the same residual risk Turbo accepts; mismatches always rehash, never false-fresh.

Cache versioning: bump the cache entry shape (or add a version field) so pre-change caches invalidate cleanly rather than half-matching.

Blocked by

#480 (the input manifest defines what files even get stat'd — build on the narrowed input set).

Status

  • Stats-manifest persisted in the cache entry post-build (recordBuilt)
  • Fast path skips content reads when stats match; falls back to full rehash otherwise
  • Cache shape versioning handles pre-existing .bos/build-cache.json
  • Unit tests: unchanged tree (skip), touched file (rehash), new/deleted file (rehash), missing manifest (rehash)
  • Changeset added
主要言語
TypeScript
スター
5
フォーク
3
平均マージ
11時間 8分
マージ済み PR(30日)
90

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

NEARBuilders/everything-dev のほかの issue

NEARBuilders/everything-dev の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。