Public: anyone can read this; the crew can change it.

"refused: private address" lives in one place, read by outbound requests and webhooks #5635

Parked opened this
Closed without merging

"refused: private address" is now typed out in one place under src/: REFUSEDSENTENCE in src/kernel/outbound.ts, which already owned and exported it (since #2998). RefusedError uses it as its default message, so no new module was needed.

Notes

stopped parked by the crew deploy 0bb1633

opened this

"refused: private address" is now typed out in one place under src/: REFUSED_SENTENCE in src/kernel/outbound.ts, which already owned and exported it (since #2998). RefusedError uses it as its default message, so no new module was needed.

The only other copy was in a doc comment on DeliveryInfo.lastError in src/core/webhooks.ts:391. The comment now names outbound.ts's REFUSED_SENTENCE instead of quoting the words. Webhooks still doesn't import the constant, because its code never uses the sentence: refusals come in through outboundFetch. Since only a comment changed, pages, screens and answers are byte-for-byte the same.

The new test/outbound-words.test.ts reads src/core/webhooks.ts as text and fails if the sentence is typed back in. It also checks that outbound.ts still holds the literal and that the constant still reads "refused: private address".

About the earlier red check (#5628): 86 of 6,329 tests failed, all of them "(unnamed)" hook failures in test/hand-decider.test.ts, test/home-kpi-page.test.ts and test/ledger.test.ts. None of those files touch what this pull changes. They pass here (29 tests, 0 fail across the three files plus the new test), and the checks on #5627, #5626 and #5609 passed at the same time. The branch carries an empty commit so the check runs again on the same code. If those three fail again, they are flaky on a loaded check machine and need their own issue.

Checked:

  • grep -rn "refused: private address" src/ finds only src/kernel/outbound.ts:56.
  • test/outbound-words.test.ts and the existing webhook and outbound tests: 41 pass.
  • bun x tsc --noEmit is clean.
  • src/web did not change, so the design lint didn't apply.

🤖 Generated with Claude Code

Closes #5617

commented

"refused: private address" is now typed out in one place under src/: REFUSED_SENTENCE in src/kernel/outbound.ts, which already owned and exported it (since #2998). RefusedError uses it as its default message, so no new module was needed.

The only other copy was in a doc comment on DeliveryInfo.lastError in src/core/webhooks.ts:391. The comment now names outbound.ts's REFUSED_SENTENCE instead of quoting the words. Webhooks still doesn't import the constant, because its code never uses the sentence: refusals come in through outboundFetch. Since only a comment changed, pages, screens and answers are byte-for-byte the same.

The new test/outbound-words.test.ts reads src/core/webhooks.ts as text and fails if the sentence is typed back in. It also checks that outbound.ts still holds the literal and that the constant still reads "refused: private address".

About the earlier red check (#5628): 86 of 6,329 tests failed, all of them "(unnamed)" hook failures in test/hand-decider.test.ts, test/home-kpi-page.test.ts and test/ledger.test.ts. None of those files touch what this pull changes. They pass here (29 tests, 0 fail across the three files plus the new test), and the checks on #5627, #5626 and #5609 passed at the same time. The branch carries an empty commit so the check runs again on the same code. If those three fail again, they are flaky on a loaded check machine and need their own issue.

Checked:

  • grep -rn "refused: private address" src/ finds only src/kernel/outbound.ts:56.
  • test/outbound-words.test.ts and the existing webhook and outbound tests: 41 pass.
  • bun x tsc --noEmit is clean.
  • src/web did not change, so the design lint didn't apply.

🤖 Generated with Claude Code

commented

Parked by the crew: the check failed in the place it ran, not in the change, and failed the same way when it was run again

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs