
Victor CasadoandClaude Sonnet 4.6
d4486a7a29
refactor: apply code-review findings to github-native coordination
scripts/github-coordination.js:
- parseArgs: replace 13-entry if/else chain with BOOL_FLAGS/VALUE_FLAGS
lookup maps; shrinks from 119 to ~45 lines
- Extract dispatchCommand(options, ctx) and formatOutput(payload, options)
from main(); main() shrinks to ~20 lines
scripts/lib/github-coordination.js:
- Split 1041-line monolith into 6 focused sub-modules under
scripts/lib/github-coordination/ (policy, parsing, gh-api, state,
actions, store); index becomes a thin re-export (~55 lines)
- Document ECC_GH_SHIM trust boundary in runGh() (gh-api.js)
- Document applyClaim() read→check→write race condition (actions.js)
tests/lib/github-coordination.test.js:
- Refactor runTests() to data-driven DESCRIPTORS array + runGroup()
helper; runTests() shrinks to ~10 lines
- Add 5 new edge-case tests: normalizeRepo('') and normalizeRepo(' ')
throw, desiredLabelsForState for blocked/ready statuses, and
buildIssueStateFromAction for validate action (15 → 20 tests)
tests/scripts/github-coordination.test.js:
- Replace console.log in test runner with process.stdout.write
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-11 14:05:42 -04:00
..
2026-05-28 07:32:52 -04:00
2026-02-22 16:19:16 +05:30
2026-06-11 00:31:33 -04:00
2026-03-29 23:09:26 +09:00
2026-06-09 21:40:40 -04:00
2026-06-11 00:31:33 -04:00
2026-06-11 14:05:42 -04:00
2026-04-29 21:01:27 -04:00
2026-04-05 14:47:26 -07:00
2026-03-27 05:56:39 -04:00
2026-06-07 13:25:48 +08:00
2026-05-11 18:11:05 -04:00
2026-06-04 21:45:13 +08:00
2026-05-19 06:42:17 -04:00
2026-03-28 11:28:12 +08:00
2026-06-03 21:54:30 +08:00
2026-03-31 22:57:48 -07:00
2026-04-08 15:38:49 -07:00
2026-06-11 14:05:42 -04:00
2026-05-12 02:59:52 -04:00
2026-06-07 13:01:21 +08:00
2026-05-19 12:14:27 -04:00
2026-05-11 02:10:36 -04:00
2026-03-28 11:28:12 +08:00
2026-04-30 12:25:14 -04:00
2026-06-06 03:55:17 +08:00
2026-05-14 21:15:35 -04:00
2026-05-19 23:25:38 -04:00
2026-03-16 01:59:53 -07:00
2026-03-12 15:40:25 -07:00
2026-03-14 12:55:25 -07:00
2026-05-19 22:09:45 -04:00
2026-05-19 22:09:45 -04:00
2026-05-19 18:18:54 -04:00
2026-05-19 09:16:35 -04:00
2026-05-12 23:00:00 -04:00
2026-03-28 11:28:12 +08:00
2026-03-14 23:21:18 -07:00
2026-03-28 11:28:12 +08:00
2026-02-13 03:37:46 -08:00
2026-03-29 21:21:18 -04:00
2026-03-16 14:01:41 -07:00
2026-06-11 12:58:11 -04:00
2026-04-01 16:08:03 -07:00
2026-03-28 11:28:12 +08:00
2026-05-11 13:07:29 -04:00
2026-06-07 13:00:08 +08:00