You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
test: make downstream-raise reader-close test deterministic
The integration test asserted that reader.close() runs within 5s after a
downstream Map raises mid-bundle. On that path the SDF DoFn generator is
abandoned by the harness (no throw/close), so its finally -- and thus
reader.close() -- runs only when the generator is garbage-collected. That
frame is pinned by the in-flight exception traceback, and under a
loopback/subprocess SDK worker the reader may live in another process whose
GC the test cannot drive, so a bounded close-time assertion is inherently
racy (failed on Linux CI and locally).
Drop the racy close assertion from the integration test; it now asserts only
the deterministic guarantee -- that the downstream exception propagates.
Authoritative reader-close-on-drop coverage stays in the deterministic
test_dofn_finally_closes_reader_on_generator_close, which drives the
generator directly and calls generator.close() to force the
GeneratorExit/finally path. Renamed the integration test accordingly and
documented why close is not asserted there.
0 commit comments