Skip to content

[audit] Refactor: split cmd/launch.go (4324 LOC god-file) along its 5 concerns #318

Closed

Description

@scttfrdmn

Filed from the 2026-07-11 spawn audit. Full report: docs/spawn-audit-2026-07-11.md. Assessment-only — no code changed yet.

Phase: Phase 3 — structural

Evidence

  • cmd/launch.go 4324 LOC — largest file by ~4x
  • seams: 697-1232 sweep orchestration, 3014-3496 + 3497-3996 job-array, 3997-4173 region filtering, 2509-2727 userdata

Recommendation
Same-package split into launch_sweep.go / launch_jobarray.go / launch_regions.go / launch_userdata.go. Residual launch.go ~2000-2100 LOC. Do this BEFORE the launchWithProgress extraction so that change is reviewable.

User-facing / SemVer: No — internal. No bump.

Adversarially verified during the audit (62/62 findings survived verification; severities/scope adjusted where the first pass was wrong).

Activity

  1. added
    area:launch
    audit:2026-07
    on Jul 11, 2026
  2. added a commit that references this issue on Jul 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:launchaudit:2026-07

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions