Skip to content

Conversation

@dionhaefner
Copy link
Contributor

@dionhaefner dionhaefner commented Nov 12, 2025

Relevant issue or PR

#356, #357

Description of changes

This fixes the observed issue of missing logs (printed messages + tracebacks) in some scenarios, specifically when the interpreter crashes / exits before corresponding I/O pipes are exhausted.

Also renames LogPipe -> TeePipe because that's really what it does (teeing).

The primary difference is that TeePipe now blocks the main thread when exiting while there are messages waiting in the pipe. Only when nothing has been read for X seconds do we continue with shutdown. This ensures that all queued up messages are forwarded properly.

Testing done

new test + manual check that messages are now shown as expected on the reproducer from #356.

@codecov
Copy link

codecov bot commented Nov 12, 2025

Codecov Report

❌ Patch coverage is 79.26829% with 17 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.49%. Comparing base (4d9beb3) to head (851ceb0).

Files with missing lines Patch % Lines
tesseract_core/runtime/logs.py 61.53% 13 Missing and 2 partials ⚠️
tesseract_core/sdk/logs.py 94.87% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #392      +/-   ##
==========================================
+ Coverage   76.42%   76.49%   +0.06%     
==========================================
  Files          29       29              
  Lines        3359     3420      +61     
  Branches      526      534       +8     
==========================================
+ Hits         2567     2616      +49     
- Misses        558      569      +11     
- Partials      234      235       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants