GitHub user KukumavMozolo created a discussion: Airflow tasks fails with 
Response ended prematurely when the job remains silent for more then 15 minutes

When a task (using the DockerOperator) does not print any outputs for more than 
15 minutes the tasks will be terminated.



Here is the error message: 
```
{taskinstance.py:3336} ERROR - Task failed with exception
Traceback (most recent call last):
  File "/home/airflow/.local/lib/python3.11/site-packages/requests/models.py", 
line 820, in generate
    yield from self.raw.stream(chunk_size, decode_content=True)
  File "/home/airflow/.local/lib/python3.11/site-packages/urllib3/response.py", 
line 1063, in stream
    yield from self.read_chunked(amt, decode_content=decode_content)
  File "/home/airflow/.local/lib/python3.11/site-packages/urllib3/response.py", 
line 1219, in read_chunked
    self._update_chunk_length()
  File "/home/airflow/.local/lib/python3.11/site-packages/urllib3/response.py", 
line 1149, in _update_chunk_length
    raise ProtocolError("Response ended prematurely") from None
```
So far, I was unable to find any timeout parameter that changes this behavior.
My current workaround is to have a background task that periodically prints 
something to the console to prevent this from happening. I have not been able 
to find a similar error reported in the issues here. 
Does anybody know of a way to properly address this issue?

Any pointers would be greatly appreciated

GitHub link: https://github.com/apache/airflow/discussions/58614

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: [email protected]

Reply via email to