I have a DAG to query some small set of data from elasticsearch.
I have one task to generate the body to query the elastic with some logic.
I’m pushing the body to xcom and then pulling it in the next task that queries the elastic.
I’m getting an error “Expected [SRART_OBJECT] but found [START_ARRAY]”.
Apparently the problem was with xcom.
It is somehow corrupting the body, maybe the indentation or something else, but when I use the same body without passing it in xcom it works good with no error.