Skip to content

The adapters package imported under another name is an import of the writer's adapter, and record 0215 says which aliased harness.apply records (#876) - #877

Merged
don-petry merged 1 commit into
mainfrom
claude/opening-writer-alias-876
Nov 14, 2026
Merged

don-petry merged 1 commit into
mainfrom
claude/opening-writer-alias-876

Conversation

@don-petry

@don-petry don-petry commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #876

This follows #875 (record 0215), on the Factory Builder's ruling of 2026-11-14.

  • Importing the adapters package under another name. import adapters as api is ordinary style, so good-faith code may write it. In tools/check_authority.py _calls_a_recorder, a step that imports, under any name, a package holding the writer's adapter is now refused as one that imports the writer's adapter. A step that does that cannot call api.opening.open_pull_request itself beside the recorder it reaches. A step that imports adapters.github as gh, or from adapters import github, is unaffected. A plain import adapters was already refused.
  • Record 0215 states which aliased harness.apply records the opening. A new Boundaries row says that import harness.apply as a; a.opened(...) records the opening. What records nothing is harness.apply.opened spelt out when only that alias is bound. Every Harness module that reaches the opening records it, or reaches it only through a call into one that does (Carbon on #819, record 0215) #875's row meant this, but its wording said otherwise. No existing row changes.

Recorder calls in nested or dead code are still declined, under 0215's good-faith row, as ruled.

Held by

  • tests/test_tools.py::test_a_role_named_to_open_pull_requests_waits_on_its_writer gains the import adapters as api case, which is refused.
  • The new mutant, "the adapters package imported under another name is no import of the writer's adapter", is killed by that case.
  • All 154 mutants of check_authority.py and check_examples.py are killed.
  • make checks passes.

Second readers

Reader Head Result
Kimi 77775e66 no findings
Astra 77775e66 no findings
Claude + security 77775e66 One low, taken: the new row read as if the import were refused only beside a direct call; the code refuses the import itself. Reworded in c40e223. It ran the new mutant alone (killed), tried good-faith job and step imports (none newly refused), and confirmed that no existing row changed
Carbon — not run: this week's quota goes to the S3 stack. Owed
Muse — not run (quota: the window resets 2026-11-16). Owed

🤖 Generated with Claude Code

View guided diff Turn on auto-fix

…writer's adapter, and record 0215 says which aliased harness.apply records (#876, record 0215)

The Factory Builder's ruling. `import adapters as api` is ordinary style, and `api.opening.open_pull_request` then
calls the writer directly, so a step that imports a package holding a writer's adapter, under any name, does not
pass as calling a recorder alone. A new Boundaries row corrects the row #875 added: `import harness.apply as a` with
`a.opened(...)` records the opening; only `harness.apply.opened` spelt out with that alias alone records nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@don-petry
don-petry requested a review from a team as a code owner November 14, 2026 08:53
@coderabbitai

coderabbitai Bot commented Nov 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. 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

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-14T08:55:54.838794Z c40e223 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@codeant-ai

codeant-ai Bot commented Nov 14, 2026 •

Copy link
Copy Markdown

CodeAnt  CodeAnt Review Status

✅  Review completed

Status Commit Started (UTC) Finished (UTC)
✅  #e71f7 Reviewed your PR c40e223 Nov 14, 2026 · 08:53 08:56

@codeant-ai

codeant-ai Bot commented Nov 14, 2026

Copy link
Copy Markdown

Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request updates the architectural decision record and the implementation of _calls_a_recorder in tools/check_authority.py to refuse imports of a package holding a writer's adapter under any alias (e.g., import adapters as api). The check is implemented by adding m.startswith(full + ".") to the import validation logic. There are no review comments, and I have no additional feedback to provide.

@sonarqubecloud

Copy link
Copy Markdown

@codeant-ai

codeant-ai Bot commented Nov 14, 2026

Copy link
Copy Markdown

CodeAnt  CodeAnt PR Risk

🟢  Low Risk

  • The PR appears safe to merge; no actionable issues were identified in the review.

Assessed commit: c40e223d1709

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

All reported issues were addressed across 4 files

Reply with feedback, questions, or to request a fix.

View guided diff | Turn on auto-fix | Re-trigger cubic

@don-petry
don-petry added this pull request to the merge queue Nov 14, 2026
Merged via the queue into main with commit b929787 Nov 14, 2026
33 checks passed
@don-petry
don-petry deleted the claude/opening-writer-alias-876 branch November 14, 2026 13:45
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.

Record 0215's #875 row says an aliased harness.apply import records nothing; it means the harness.apply.opened spelling with only an alias bound

2 participants