Preserve bug versus enhancement classification across portal, worker and workflow
Repro: player-bug-intake#72 explicitly requests an enhancement, but spiritech-known-issues#66 receives type/bug. Portal has no report kind, analyzer proposal lacks kind, executor hardcodes type/bug. Add validated Bug/Enhancement selection and durable original metadata, negotiated worker classification (including legacy reports), and exclusive canonical type labels. Preserve existing payload compatibility and original report evidence. Implemented on fix/preserve-report-type in engines (/home/mathias/Projects/engines) and worker (/home/mathias/Projects/worktrees/player-reporting-worker-report-type, based on origin/main). Portal persists validated original selection; migration 010 leaves legacy/imported type unknown. V5 jobs carry submittedReportType; worker requires classified reportType for all decisions, with explicit enhancement/legacy guidance. Executor applies type/bug or type/enhancement, removes opposite label on reclassification, and leaves duplicate targets unchanged. Deployment readiness/docs updated for portal/migration010 → coordinator v5 → worker v5 with model runs paused. Verified: 232 portal tests passed including real disposable SQL migration/compatibility tests; 3 unrelated game-database tests skipped. 9 UI JS tests, 35 worker Node tests, 14 worker deployment tests, and 26 engines deployment tests passed. Both diffs clean. Real-browser and real-model classification replay not run. Committed and pushed engines c05734071 and worker 912cb3e on fix/preserve-report-type; both working trees clean. Open PRs: engines #2807 https://git.project-rk.com/prk/engines/pulls/2807 (base develop), worker #7 https://git.project-rk.com/prk/player-reporting-worker/pulls/7 (base main). Workflow workflow_v0.1.2 is deployed and verified ready with contract v5 plus authenticated impossible-ID preview 204. Repaired the separately installed deployment helper under the shared nonblocking reporting lock: /usr/local/libexec/prk-reporting-deploy.py now matches merged worker main 3e4d29ca8b2cb85562fbc9d9c89e0914da377016, SHA256 4963b3472a485f0876150193300ed7607b688d7d8dca9e2b785ba1350ed71660, atomically installed root:root 0755. Previous helper backed up at /var/lib/prk-reporting-deploy/helper-backups/prk-reporting-deploy-20261022T095115Z.py. Verified new helper's v5 identity and authenticated empty preview checks before/after installation. Worker checkout HEAD and running container identities unchanged. CI deployment remains user-triggered; no triage started. Follow-up image-build failure reproduced: deployment tests lacked deploy/worker.example.json inside the build stage. Fixed by adding that file to the Dockerfile COPY; analyzer and controller image builds now pass, including 35 Node and 14 deployment tests. Committed 4545afa on build/include-worker-test-config; PR #8 https://git.project-rk.com/prk/player-reporting-worker/pulls/8 targets main. Working tree clean; follow-up not deployed. Worker build follow-up is deployed per user. User authorized deleting Spiritech known issue #66 and clearing intake #72 comments, then replaying only report 1bd8a15c-02d0-42c3-8ed6-04edbfff5cfb. Read-only inspection confirms two bot intake comments, one intake asset, published known #66 with type/bug and one publication comment. Private issue/comment/asset-metadata backup: ~/.local/state/prk/report-type-replay/20261022T095635Z. No deletes or replay performed yet. Safety constraint: ordinary retriage retains the canonical number/attempt marker, so this destructive replay required the scoped database reset under coordinator exclusion rather than a retriage marker alone. User confirmed ithaca.project-rk.com uses the wildcard SSH configuration; SSH and sudo -n docker are verified. Completed scoped reset with reporting coordinator stopped and worker shared lock held: verified report revision10/decision revision6, no dependent reports/decisions, and expected clean upload hash/asset3717. Backed up database at /home/mathias/.local/state/prk/report-type-replay/20261022T095834Z on Ithaca. Transaction reset only report #72 triage/closure/link state (revision11), deleted its decision and obsolete cache AF02F760-FA03-483A-8568-D5834B60EE39. Deleted known #66 and exactly two intake bot comments39379/39387; original intake body and asset metadata unchanged. Restored triage:ready and restarted only reporting coordinator. Verified v5 preview with one file, no notes/instructions and no #66 candidate. Started exactly report1bd8a15c-02d0-42c3-8ed6-04edbfff5cfb controller in systemd unit prk-report72-enhancement-20261022T095941, run receipts/logs /var/lib/prk-reporting-runs/report72-enhancement-20261022T095941Z on git-prk-server. Replay verified complete: controller exit0, exactly one processed report, shared reporting lock released. Fresh real-model v5 proposal classified known/enhancement with confidence0.94. Canonical Spiritech #71 https://git.project-rk.com/prk/spiritech-known-issues/issues/71 ('Snap hotbars and UI elements to shared axes') has type/enhancement and no type/bug, correct original intake and image links, and portal:published. SQL confirms one attempt, applied/succeeded decision to #71, v5 context, published Spiritech cache, no remaining analysis/publication or active report lease. Original report text/identity/routing/fingerprint/submitted time and full upload record exactly match backup; downloaded489263-byte original image SHA256 matches0752F2E925F40C2196434D5508D137D7767CE32D8BFECD38A3440EFB163212AA. Old #66 returns404. Intake now has only fresh assessment39609 and canonical backlink39617, final triage:complete. Reporting coordinator running again; portal/game engines untouched. Final SQL receipt database-after.json beside before backup; local issue snapshots include new canonical. No further rerun needed.
Checklist
2 of 2 complete- Validate form/submission, SQL migration and compatibility, label reclassification, worker contract/prompt, and deployment readiness; document ordered rollout and remaining live validation.
- Implement and verify durable Bug/Enhancement selection, legacy-aware negotiated classification, and exclusive canonical labels across portal/coordinator/worker.
- Area
- Project Rubi-Ka
- Project
- engines
- Kind
- Bug
- Task ID
tsk_jyvnhemz4g- Updated