feat(controlplane): allow filtering workflow runs by workflow and version#3173
Conversation
…sion Workflow and version filters were mutually exclusive on the workflow run list endpoint. They are independent dimensions and compose as an AND: a run carries both a workflow edge and a version_id column, so filtering by both returns the runs of a given workflow at a given version. The version is a globally-unique UUID, so it does not need a project to disambiguate it. Assisted-by: Claude Code Signed-off-by: Miguel Martinez Trivino <miguel@chainloop.dev>
AI Session Analysis
|
| Status | Attribution | File | Lines |
|---|---|---|---|
| created | ai | app/cli/cmd/workflow_workflow_run_list_test.go |
+65 / -0 |
| modified | ai | app/controlplane/internal/service/workflowrun.go |
+34 / -6 |
| modified | ai | app/controlplane/api/controlplane/v1/workflow_run.proto |
+22 / -5 |
| modified | ai | app/cli/cmd/workflow_workflow_run_list.go |
+11 / -3 |
| modified | ai | app/cli/pkg/action/workflow_run_list.go |
+9 / -5 |
| modified | human | app/cli/documentation/cli-reference.mdx |
+1 / -0 |
Policies (4)
| Status | Policy | Material | Messages |
|---|---|---|---|
| ✅ Passed | ai-config-ai-agents-allowed |
ai-coding-session-62f19a |
- |
| ✅ Passed | ai-config-no-dangerous-commands |
ai-coding-session-62f19a |
- |
| ✅ Passed | ai-config-no-secrets |
ai-coding-session-62f19a |
- |
| ✅ Passed | ai-config-mcp-servers-allowed |
ai-coding-session-62f19a |
- |
Powered by Chainloop and Chainloop Trace
Add a --version flag to `workflow workflow-run list` so runs can be filtered by project version. The flag takes a version name (e.g. v1.2.0) and requires --project, since a version name is unique only within a project, and composes with --workflow. On the API, WorkflowRunServiceListRequest.project_version (UUID) is deprecated in favor of project_version_name, resolved to a version within the given project. The dependency on project_name is enforced both at the API layer (CEL) and server-side. Assisted-by: Claude Code Signed-off-by: Miguel Martinez Trivino <miguel@chainloop.dev> Chainloop-Trace-Sessions: 62f19a0d-f8a8-45d0-b208-c22bd4327f45
8f4bbeb to
59144fb
Compare
Description
Enables filtering workflow runs by workflow and project version together, and makes version filtering usable from the CLI.
--versionflag tochainloop workflow workflow-run list. The flag takes a project version name (e.g. v1.2.0) and requires--project, since a version name is unique only within a project. It can be combined with--workflow.WorkflowRunServiceListRequest.project_version(UUID) is deprecated in favor of a newproject_version_namefield that is resolved to a version within the given project. The dependency onproject_nameis enforced both at the API layer and server-side. The deprecated UUID field is kept for backward compatibility.closes #3172
AI Disclosure
This contribution was assisted by Claude Code.