generated from coulomb/repo-seed
Compare commits
2 Commits
a0dba9a96b
...
699ef15ee2
| Author | SHA1 | Date | |
|---|---|---|---|
| 699ef15ee2 | |||
| 24301ccd60 |
@@ -1,11 +1,10 @@
|
|||||||
# Repo classification (Repo Classification Standard v1.0).
|
# Repo classification (Repo Classification Standard v1.0).
|
||||||
# First-pass agent classification (CUST-WP-0050 T02) — pending human review.
|
|
||||||
|
|
||||||
repo_classification:
|
repo_classification:
|
||||||
standard: Repo Classification Standard
|
standard: Repo Classification Standard
|
||||||
version: '1.0'
|
version: '1.0'
|
||||||
classified_at: '2026-06-22'
|
classified_at: '2026-06-22'
|
||||||
classified_by: agent
|
classified_by: human
|
||||||
category: tooling
|
category: tooling
|
||||||
domain: infotech
|
domain: infotech
|
||||||
secondary_domains: []
|
secondary_domains: []
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ def create_progress_router(
|
|||||||
*,
|
*,
|
||||||
topic_id: uuid.UUID | None = None,
|
topic_id: uuid.UUID | None = None,
|
||||||
workstream_id: uuid.UUID | None = None,
|
workstream_id: uuid.UUID | None = None,
|
||||||
|
workplan_id: uuid.UUID | None = None,
|
||||||
task_id: uuid.UUID | None = None,
|
task_id: uuid.UUID | None = None,
|
||||||
decision_id: uuid.UUID | None = None,
|
decision_id: uuid.UUID | None = None,
|
||||||
event_type: str | None = None,
|
event_type: str | None = None,
|
||||||
@@ -37,9 +38,9 @@ def create_progress_router(
|
|||||||
offset: int = 0,
|
offset: int = 0,
|
||||||
) -> list[Any]:
|
) -> list[Any]:
|
||||||
q = select(progress_model)
|
q = select(progress_model)
|
||||||
|
scope_id = workplan_id if workplan_id is not None else workstream_id
|
||||||
for field, value in (
|
for field, value in (
|
||||||
("topic_id", topic_id),
|
("topic_id", topic_id),
|
||||||
("workstream_id", workstream_id),
|
|
||||||
("task_id", task_id),
|
("task_id", task_id),
|
||||||
("decision_id", decision_id),
|
("decision_id", decision_id),
|
||||||
):
|
):
|
||||||
@@ -51,6 +52,16 @@ def create_progress_router(
|
|||||||
detail=f"Progress events do not support filtering by {field}",
|
detail=f"Progress events do not support filtering by {field}",
|
||||||
)
|
)
|
||||||
q = q.where(column == value)
|
q = q.where(column == value)
|
||||||
|
if scope_id is not None:
|
||||||
|
column = getattr(progress_model, "workplan_id", None) or getattr(
|
||||||
|
progress_model, "workstream_id", None
|
||||||
|
)
|
||||||
|
if column is None:
|
||||||
|
raise HTTPException(
|
||||||
|
status_code=400,
|
||||||
|
detail="Progress events do not support filtering by workplan_id",
|
||||||
|
)
|
||||||
|
q = q.where(column == scope_id)
|
||||||
if event_type:
|
if event_type:
|
||||||
q = q.where(progress_model.event_type == event_type)
|
q = q.where(progress_model.event_type == event_type)
|
||||||
if event_types is not None:
|
if event_types is not None:
|
||||||
@@ -66,6 +77,7 @@ def create_progress_router(
|
|||||||
async def list_progress(
|
async def list_progress(
|
||||||
topic_id: uuid.UUID | None = None,
|
topic_id: uuid.UUID | None = None,
|
||||||
workstream_id: uuid.UUID | None = None,
|
workstream_id: uuid.UUID | None = None,
|
||||||
|
workplan_id: uuid.UUID | None = None,
|
||||||
task_id: uuid.UUID | None = None,
|
task_id: uuid.UUID | None = None,
|
||||||
decision_id: uuid.UUID | None = None,
|
decision_id: uuid.UUID | None = None,
|
||||||
event_type: str | None = None,
|
event_type: str | None = None,
|
||||||
@@ -78,6 +90,7 @@ def create_progress_router(
|
|||||||
session,
|
session,
|
||||||
topic_id=topic_id,
|
topic_id=topic_id,
|
||||||
workstream_id=workstream_id,
|
workstream_id=workstream_id,
|
||||||
|
workplan_id=workplan_id,
|
||||||
task_id=task_id,
|
task_id=task_id,
|
||||||
decision_id=decision_id,
|
decision_id=decision_id,
|
||||||
event_type=event_type,
|
event_type=event_type,
|
||||||
|
|||||||
Reference in New Issue
Block a user