Skip to content

aws_ecs_task_definition.deregistered_at column fails with time.Time type mismatch #2708

@phalverson

Description

@phalverson

Description

Querying aws_ecs_task_definition fails with the following error whenever any task definition in the scanned account/region has been deregistered:

    ERROR: rpc error: code = Unknown desc = <connection>: failed to populate column
    'deregistered_at': '' expected type 'int', got unconvertible type 'time.Time',
    value: '2026-02-16 23:30:41.346 +0000 UTC'

Versions

Steampipe: v2.3.5
Plugin: v1.29.0

Root Cause

In aws/table_aws_ecs_task_definition.go, the deregistered_at column applies transform.UnixToTimestamp to TaskDefinition.DeregisteredAt:

    Transform: transform.FromField("TaskDefinition.DeregisteredAt").
        Transform(transform.UnixToTimestamp).
        Transform(transform.NullIfZeroValue),

transform.UnixToTimestamp expects an int64, but in AWS SDK Go v2, types.TaskDefinition.DeregisteredAt is *time.Time. When non-nil, the transform fails.

Note: the sibling column registered_at does NOT apply UnixToTimestamp and works correctly.

Suggested Fix

Remove the Transform extensions from the field definition

    Transform: transform.FromField("TaskDefinition.DeregisteredAt"),

(and update the description to remove "Unix timestamp")

Impact

This affects ALL queries on aws_ecs_task_definition, not just ones referencing deregistered_at, because the column is hydrated for every row.

No SQL-level workaround exists.

Metadata

Metadata

Assignees

Labels

awsAWS plugin issuesbugSomething isn't workingsteampipeSteampipe plugin issues

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions