acoustic-carpenter-78188
03/12/2026, 10:49 PMGetActionDetails implementation was a simplified stub that hardcoded a single attempt and did not leverage action events or the task_specs table. This PR rewrites it to:
• Fetch action details and attempts in parallel via errgroup
• Build real ActionAttempt objects from action events
• Look up resolved task/trace specs from the task_specs table by digest
• Set error info on failed actions from the last attempt
• Store detailed metadata (task spec digest, storage URIs) via a new RunInfo proto
What changes were proposed in this pull request?
New proto: flyteidl2/workflow/run_info.proto
• Adds RunInfo message with task_spec_digest, inputs_uri, outputs_uri, and run_spec fields
Action model changes (runs/repository/models/action.go)
• Added DetailedInfo []byte column — stores serialized RunInfo proto
• Added RunSpec []byte column — stores serialized task.RunSpec proto
New repo method: ListEvents
• Added to ActionRepo interface, implementation, and mocks
• Queries action_events table by action identifier
Rewritten GetActionDetails (runs/service/run_service.go)
• Uses errgroup to parallelize fetching action model + attempts
• Unmarshals DetailedInfo into RunInfo proto to get task spec digest
• Looks up task/trace spec from task_specs table by digest
• Builds real ActionAttempt list from events via `getAttempts`/`mergeEvents`
• Sets ErrorInfo on failed actions from the last attempt
Helper functions:
• getAttempts — groups events by attempt, merges into ActionAttempt
• mergeEvents — merges events within an attempt (logs, phase transitions, cluster events, etc.)
• IsTerminalPhase — checks for terminal action phases
How was this patch tested?
(kevin) (kevin) ➜ flyte-sdk git:(adil/non-recoverable-exception) ✗ flyte get action r9bkfxfdgzk2xbz95rpr 8aqubwegs8hrhe0iovsa8kmy7
[
{
'id': {
'run': {
'org': 'testorg',
'project': 'flytesnacks',
'domain': 'development',
'name': 'r9bkfxfdgzk2xbz95rpr'
},
'name': '8aqubwegs8hrhe0iovsa8kmy7'
},
'metadata': {
'parent': 'r9bkfxfdgzk2xbz95rpr',
'task': {
'id': {
'org': 'testorg',
'project': 'flytesnacks',
'domain': 'development',
'name': 'hello_world.main',
'version': '0c16c8d0d7185c2362a1de1ffbc46472'
},
'taskType': 'python',
'shortName': 'main'
},
'actionType': 'ACTION_TYPE_TASK',
'environmentName': 'hello_world',
'funtionName': 'hello_world.main'
},
'status': {
'phase': 'ACTION_PHASE_SUCCEEDED',
'startTime': '2026-03-13T05:57:25Z',
'endTime': '2026-03-13T05:57:25Z',
'attempts': 1,
'durationMs': '0'
}
}
]
• All existing unit tests pass (go test ./runs/...)
• go vet and go build pass cleanly
Labels
• changed: Rewrite GetActionDetails to use action events and task spec lookup
• added: New RunInfo proto and ListEvents repo method
Check all the applicable boxes
• I updated the documentation accordingly.
• All new and existing tests passed.
• All commits are signed-off.
• main
• #6583
• Ensure GetActionDetails works expected 👈
flyteorg/flyteacoustic-carpenter-78188
03/19/2026, 7:16 PM