Skip to content

fix(a8n-attached): file identity を BigInt stat で比較し project 再読を最終観測に (#390) - #392

Merged
rebuildup merged 1 commit into
release-0-6-0from
390
Nov 20, 2026
Merged

rebuildup merged 1 commit into
release-0-6-0from
390

Conversation

@rebuildup

Copy link
Copy Markdown
Contributor

Closes #390。PR #379 の CodeRabbit 再レビュー指摘への対応。

変更

  • hostPathsEqual: statSync(path, { bigint: true }) で dev/ino を比較。file identifier が Number.MAX_SAFE_INTEGER を超える filesystem での誤同一視(誤った project pin の受理)を防ぐ。zero-inode 判定は 0n。
  • revalidateTarget: project attestation を最終 census の後に移動。census は process identity のみを見るため自身の await 中の project 切替を検出できず、従来は project 読み取り後の census が最後の観測だった。現在は census → version → census → project read の順で、最後の観測が project identity になる。残余の project-read → dispatch ウィンドウは feat(scripting-adapters): host script 内での project identity 再確認(mutation dispatch の TOCTOU 狭隘化) #385 の host-side guard(withHostProjectGuard、mutation と同一 ExtendScript 評価内で app.project.file.fsName を再検査)が塞ぐ。

検証

  • attached-session.test.mjs 26/26 pass(fake/mock レベル)。新規 test: fixture の project.info() と注入 probe の呼び出し順を記録し、revalidate 中のイベント列が [probe, census, project] ではなく [probe, probe, project](最終 census の後に project read)であることを assert。
  • 実機 AE は不要・未使用。

@coderabbitai

coderabbitai Bot commented Nov 20, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: fbe1924c-7399-413e-b10b-ec4d2ca70740

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@rebuildup
rebuildup merged commit 125c9df into release-0-6-0 Nov 20, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant