Skip to content

DockerOperator / XCOM : TypeError: Object of type bytes is not JSON serializable #13535

Description

@AlessioM

Apache Airflow version: 2.0.0

Kubernetes version (if you are using kubernetes) (use kubectl version): NA

Environment:

  • local Ubuntu 18.04 LTS /
  • docker-compose version 1.25.3, build d4d1b42b
  • docker 20.10.1, build 831ebea

What happened:

when enabling xcom push for a docker operator the following error is thrown after the task finishes succesfully:
TypeError: Object of type bytes is not JSON serializable

What you expected to happen:

  • error is not thrown
  • if xcom_all is True: xcom contains all log lines
  • if xcom_all is False: xcom contains last log line

How to reproduce it:

see docker compose and readme here:
https://github.com/AlessioM/airflow-xcom-issue

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions