Review: Schedule digest: feature flag gate + Week tab upload button

review-1453-2026-06-13 Review

review ready

Verdict: READY

Template Completeness

  • [x] Type -- Feature
  • [x] Lineage -- Follow-up to #204 (done)
  • [x] Repo -- ldraney/landscaping-assistant
  • [x] User Story -- As a super admin, toggle schedule digest feature
  • [x] Context -- Explains current flow, why it's not discoverable, what changes
  • [x] File Targets -- 4 modify targets + 4 do-not-touch targets
  • [x] Feature Flag -- schedule_digest flag fully specified (type, default, visibility, removal)
  • [x] Acceptance Criteria -- 7 criteria
  • [x] Test Expectations -- 3 test specs + run command
  • [x] Constraints -- References existing patterns, no Tailwind, week_start auto-pass
  • [x] Checklist -- Standard PR/tests/no-unrelated
  • [x] Related -- Links to project and parent issue #204

Traceability

  • [x] story:schedule-upload label -- present on board item
  • [x] story note verified -- found in project-landscaping-assistant user-stories section (Key: schedule-upload, Role: Landscaper, Summary: "Snap a photo of the paper schedule for later reference")
  • [x] arch:rails-app label -- present on board item
  • [ ] arch note MISSING -- [SCOPE] No arch-rails-app note exists in pal-e-docs. This is systemic across the board (most items carry arch:rails-app with no backing note). Not blocking for this ticket.
  • [x] Forgejo issue -- ldraney/landscaping-assistant#212, state: open

File Targets

  • [x] lib/tasks/feature_flags.rake -- verified: exists, contains existing flags (stripe, client_requests, pending_completion). Agent adds schedule_digest entry following same pattern.
  • [x] app/views/uploads/show.html.erb -- verified on origin/main: contains "Digest Schedule" button inside a vision_compatible? block. Agent wraps in feature_enabled?(:schedule_digest) check.
  • [x] app/views/weeks/index.html.erb -- verified: exists with feature_enabled?(:pending_completion) pattern on line 90. Agent adds "Upload Schedule" button following same gating pattern.
  • [x] app/controllers/uploads_controller.rb -- verified on origin/main: contains digest and confirm_digest actions. Agent adds feature flag guard.
Note: The working tree has staged changes that differ from origin/main. The digest/confirm_digest actions and the "Digest Schedule" button exist on origin/main (merged via PR #208) but are not visible in the working tree. An implementing agent must branch from clean main.

Repo Placement

OK. Issue filed on ldraney/landscaping-assistant, all file targets are in the same repo. Single-repo change.

Dependencies

  • Issue #204 (Schedule image digestion: Claude Vision OCR) -- DONE, merged as PR #208. This is the prerequisite feature being gated. Verified closed and merged.
  • No items in in_progress or next_up that block or are blocked by this ticket.
  • Board item #1450 (same issue #204) is in done column -- consistent.

Acceptance Criteria

All 7 acceptance criteria are verifiable by an agent:
  • AC 1-4 (flag OFF behaviors): testable via request specs with flag disabled
  • AC 5-6 (flag ON behaviors): testable via request specs with flag enabled + role checks
  • AC 7 (Photos tab unaffected): testable by verifying upload create/show still work without flag check
Test commands are real: bundle exec rspec spec/requests/uploads_spec.rb spec/requests/weeks_spec.rb -- both spec files exist.

Blast Radius

Low blast radius. Changes are additive (wrapping existing UI in conditionals, adding a new button). The feature_enabled? helper and FeatureFlag model are well-established patterns. No downstream consumers affected -- this gates entry points only, not the ScheduleDigester service itself. The constraint "Existing Photos tab upload flow still works regardless of flag state" correctly scopes the blast radius.

Decomposition Assessment

4 file targets in 1 repo, 7 acceptance criteria, 3 test expectations. Estimated agent work: ~3-4 minutes. No decomposition needed -- fits comfortably in a single agent pass under the 5-minute rule.

Recommendation

No action needed. Scope is solid and ready for implementation.
Minor non-blocking observation: The systemic lack of an arch-rails-app backing note affects many board items. Consider creating it as a separate housekeeping task rather than blocking individual tickets.