vmware-labs / vmware-image-builder-action

GitHub action code for VMware Image Builder (VIB).
BSD 2-Clause "Simplified" License
16 stars 6 forks source link

Error downloading bundle files #148

Closed fmulero closed 12 months ago

fmulero commented 1 year ago

Describe the bug

We are facing some sporadic errors apparently related to action. The execution-graph finishes OK, with SUCCESS but the action fails when it is trying to download and parse the bundle. The error is like this one:

Warning: Error downloading bundle files for execution graph 65ed49d3-a8ab-47f2-8d6a-794b63b17131, error: TypeError: Converting circular structure to JSON
    --> starting at object with constructor 'TLSSocket'
    |     property 'parser' -> object with constructor 'HTTPParser'
    --- property 'socket' closes the circle

For that execution graph, I could download the bundle and this is the report.json file and it looks correct:

{
    "passed": true,
    "actions": [
        {
            "task_id": "299337aa-f15e-4f7c-91fd-d2506e19973d",
            "action_id": "osspi-application",
            "passed": true
        },
        {
            "task_id": "3f5361df-dd48-4cf3-a201-b5937c0b1d32",
            "action_id": "trivy",
            "passed": true,
            "vulnerabilities": {
                "minimal": 0,
                "low": 82,
                "medium": 10,
                "high": 13,
                "critical": 1,
                "unknown": 0
            }
        },
        {
            "task_id": "4b9f36f1-3600-454c-8d9b-b8ac08c2bd3d",
            "action_id": "goss",
            "passed": true,
            "tests": {
                "passed": 51,
                "skipped": 0,
                "failed": 0
            }
        },
        {
            "task_id": "df794d57-7af6-4dc5-a18f-bf9f4ee9008a",
            "action_id": "container-image-publish",
            "application": {
                "kind": "CONTAINER_IMAGE",
                "location": "oci://registry.marketplace.cloud.vmware.com/transient-oci-8b8499c6-703d-4b32-a49e-36d6fd47eb00/containers/bitnami/postgresql-repmgr:13@sha256:71e05efad2520596748a539215c80a9fa33acb91d2caacdc0f0d2ed354c673cb",
                "name": "postgresql-repmgr",
                "repository": "oci://registry.marketplace.cloud.vmware.com/transient-oci-8b8499c6-703d-4b32-a49e-36d6fd47eb00/containers/bitnami",
                "sha256": "71e05efad2520596748a539215c80a9fa33acb91d2caacdc0f0d2ed354c673cb",
                "tag": "13.10.0-debian-11-r17",
                "additionalTags": [
                    "13",
                    "13-debian-11",
                    "13.10.0"
                ]
            }
        },
        {
            "task_id": "eec3bc6b-991d-4dac-ace7-cf704ea63786",
            "action_id": "grype",
            "passed": true,
            "vulnerabilities": {
                "minimal": 76,
                "low": 7,
                "medium": 12,
                "high": 14,
                "critical": 3,
                "unknown": 0
            }
        }
    ]
}

To be perfectly blunt, I am not sure if the error is in the action side but is becoming more frequent.

Reproduction steps

Some examples:

Expected behavior

The action finish OK and the artifacts are correctly attached to the workflow execution.

Additional context

No response

gdelgadot commented 12 months ago

This issue was fixed in version 0.5.0