Skip to content

impit.TimeoutException in _streamed_log.py after successful actor completion #945

Description

@dinyelum

Environment

  • apify-client: 3.0.4
  • Python: 3.13.x
  • OS: Windows 11

Description
When running an actor with client.actor(...).call(...), the actor completes successfully.
But, the background log-streaming thread prints the traceback:

Exception in thread Thread-2 (_stream_log):
Traceback (most recent call last):
  File ".../threading.py", line 1043, in _bootstrap_inner
    self.run()
  File ".../threading.py", line 994, in run
    self._target(*self._args, **self._kwargs)
  File ".../site-packages/apify_client/_streamed_log.py", line 149, in _stream_log
    for data in log_stream.iter_bytes():
impit.TimeoutException: Request timeout (unknown) exceeded.

[apify.ultimate-x-twitter-advanced-search-scraper runId:SFCyH4ZTFDerYbBHC]
-> Status: SUCCEEDED

Despite this exception:

  • the actor completes successfully,
  • the dataset is complete,
  • all items are processed successfully.

The exception appears to originate from the background log-streaming thread rather than affecting the actor execution itself.

Expected behavior
The log-streaming thread should handle the timeout gracefully or exit without printing an uncaught exception if the timeout is expected.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working.t-toolingIssues with this label are in the ownership of the tooling team.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions