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

The connect limit keeps its window in a module-level map that only tests clear: `resetConnectLimit` is an exported action no surface calls #685

shipped production is serving it opened this
opened this

Found by the hollow work check (#615, pull #681), which lists it in scripts/hollow-allow.ts under this issue.

What is there. src/actions/origins.ts keeps connect attempts per user in a module-level Map, and exports resetConnectLimit() so tests can clear it. Seventeen test files call it; nothing under src/ does. An exported action that only tests call is what the check refuses, and the map is one window shared by every forge in the process.

Outcome (what a person sees). Nothing changes for a person: the sixth connect in fifteen minutes is still refused. The window belongs to the forge it limits, so a fresh createApp starts with a fresh one and no test needs a seam.

Acceptance.

Start from: tooManyAttempts in src/actions/origins.ts, src/app.ts, and grep -l resetConnectLimit test/.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs