Migration: backfill CaseMembership for existing cases #69
Labels
No labels
agentic-osint
audit
blocked:commit-ready-failed
blocked:gate-fetch
blocked:gate-fetch
blocked:gate-lint
blocked:gate-plan
blocked:gate-research
blocked:needs-decision
blocked:needs-human
blocked:no-changes
blocked:preflight
blocked:verify-failed
bug
chore
deferred
enhancement
feature-request
in-progress
lint-baseline
lint-cleanup
needs-decompose
needs-triage
performance
quickfix
security/medium
triage-approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Mark/osint-hub#69
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent Issue: #36 (Case-level access control) / #53
Scope
Data migration to backfill
CaseMembershiprows for existing cases, plus a one-time admin "claim unowned cases" flow.Background
CaseMembershiprowscreated_byfield on Case model is never populatedAcceptance Criteria
created_byon existing cases where possible (e.g., from audit logCREATEevents)CaseMembership(owner)rows for each existing case, assigned to the creator (or first admin if creator unknown)Dependencies
Implementation Notes
AuditEventtable forCREATE Caseevents to determine original creatorrole=adminwho has the lowestidQuickfix overseer report
After 2 attempts, the quickfix could not proceed due to infrastructure issues:
All cloud provider API keys in the opencode config are expired/invalid. Retrying would produce the same result.
Action taken:
quickfixlabel → promoted to normal pipelinetriage-approvedTo resolve: Update one or more API keys in
/home/b/.config/opencode/opencode.jsonor start the local Ollama service, then re-applyquickfixlabel.GSD VERIFY phase failed after 3 attempts.
═══ Gate: verify-passed (osint-hub#69) ═══
Mode: Tier 1 (functional only)
GATE OK: All gates up to 'implement' pass
── Tier 1: Functional ────────────────────────────────
Running tests...
❌ Tests failed (exit 4)
configfile: pyproject.toml
plugins: anyio-4.13.0, httpx-0.36.2, timeout-2.4.0, xdist-3.8.0, cov-7.1.0, split-0.11.0, asyncio-1.4.0
timeout: 60.0s
timeout method: signal
timeout func_only: False
asyncio: mode=Mode.STRICT, debug=False, asyncio_default_fixture_loop_scope=None, asyncio_default_test_loop_scope=function
collected 0 items
============================ no tests ran in 0.00s =============================
ERROR: file or directory not found: tests/
============================= test session starts ==============================
platform linux -- Python 3.11.14, pytest-9.0.3, pluggy-1.6.0
rootdir: /home/b/Projects/osint-hub
configfile: pyproject.toml
plugins: anyio-4.13.0, httpx-0.36.2, timeout-2.4.0, xdist-3.8.0, cov-7.1.0, split-0.11.0, asyncio-1.4.0
asyncio: mode=Mode.STRICT, debug=False, asyncio_default_fixture_loop_scope=None, asyncio_default_test_loop_scope=function
collected 0 items
============================ no tests ran in 0.00s =============================
Running linter...
✅ Lint clean
Running type checker...
✅ Types check clean
Previous test count: unknown
❌ GATE FAIL: verify-passed
- Tests failed with exit code 4
GATE FAIL: verify — blocked at 2026-05-26T22:38:18Z
Class: test-failure
Evidence: Verification failed: 1 failures
Git tag: osint-hub#69-gate-verify-fail-85facb8335be (use gate-retry after fixing)
GSD PLAN: response missing GATE: line.