Skip to content

Define and enforce shuttle open/closed semantics: which user actions the deadline and status should guard #320

Description

@mithro

Background

Investigation during #312 / PR #314 showed the platform has no single definition of a "closed" shuttle, and the two closure signals (status and submission_deadline) are enforced inconsistently. As of #314, staff slot assignment is (correctly) never blocked — but user-facing operations have gaps.

There are two closure signals on Shuttle:

  • status — manually flipped by staff (openfull/locked/production/…). Nothing changes it automatically.
  • submission_deadline — seeded from the published schedule (23:59:59 AoE), but after fix(shuttles): never block staff slot assignment on shuttle state #314 it influences exactly one thing platform-wide: a warning string on the staff assignment dashboard. No user-facing page displays or enforces it. The ["status", "submission_deadline"] DB index is never used by any query.

The other schedule dates (production_start_date, estimated_completion_date, actual_completion_date) are staff/admin display only, which is fine.

Live example: G802's deadline passed on 2026-07-15 11:59:59 UTC. Unless staff manually flipped its status, it is still open — so it is still offered (and is the default, being the oldest open shuttle) for new projects, and users can still upload new GDS files against it.

Current state (verified by tests)

User action Guarded by status? Guarded by deadline?
Create project against shuttle ✅ form queryset filters status=open ❌ not checked
Change shuttle / project ID / slot size ✅ always locked after creation for non-staff (CORE_FIELDS, #297) — stronger than shuttle-based (n/a)
Toggle chip_on_board (packaging — cancels/requeues manufacturability checks) USER_FIELD, always editable
Submit a new design file (ProjectFileSubmitURLViewsubmit_file_from_url) ❌ no check
Submit project for manufacturing (Project.can_submit()) ❌ no check
Edit license / repository URL / name / description / CS order ID ✅ correctly NOT guarded ✅ correctly NOT guarded
Staff: assign/unassign slots ✅ correctly never blocked (#314, warning only) ✅ warning only

Proposed policy

Definition: a shuttle is closed to users when status != open or submission_deadline has passed. Suggest a single property, e.g. Shuttle.is_open_for_submissions, as the one source of truth.

When the shuttle is closed, users must NOT be able to:

  1. Create a new project against it (fix: also exclude deadline-passed shuttles from the create-form queryset and the default-shuttle pick).
  2. Submit a new design file (fix: guard ProjectFileSubmitURLView / submit_file_from_url; hide the upload button with an explanatory notice).
  3. Change any manufacturing-affecting setting — including chip_on_board, which today is a freely editable USER_FIELD despite cancelling and re-queuing manufacturability checks on change.
  4. Submit the project for manufacturing (fix: add shuttle check to can_submit() with a clear reason string).

Must remain possible when closed:

  • Users editing non-manufacturing fields: name, description, visibility, license fields, repository URL, CrowdSupply order ID (behaviour verified working today; keep it, add regression tests).
  • Staff: everything — slot assignment/removal (fix(shuttles): never block staff slot assignment on shuttle state #314), and staff bypass of field locks as already implemented.

User-facing visibility: users currently have no way to see a shuttle's deadline anywhere in the platform. The project form / detail page should show the deadline and a "closed" state instead of failing opaquely.

Open questions

  1. Should the deadline auto-close a shuttle (computed property, as proposed) or should we keep status manual and just add an alert/cron that nags staff to flip it? Computed property avoids the G802 situation recurring.
  2. Is chip_on_board the only USER_FIELD that affects manufacturing, or should the field taxonomy gain a third class (MANUFACTURING_USER_FIELDS) locked by shuttle closure while remaining user-editable when open?
  3. Grace handling: staff sometimes accept late GDS changes. Is the staff-bypass (already in place for core fields) sufficient, or do we need a per-project "late submission allowed" override?

References

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions