Repository navigation
test(cachekitio): drop the dead walks guard in the interrupt frame test (LAB-8742) - #571
Conversation
The interrupt branch now walks through the shared module's own _raised_during_request, so patching the backend module's name only reaches the transport handler's walk and the len(walks) guard was always true. Also corrects two stale test comments.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 56 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Providing Context (Files & MCPs)Add these hints in your PR description (or a comment) to unlock deeper checks:
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
The interrupt branch in
CachekitIOBackend._sendnow calls the shared_clear_interrupted, which walks the chain throughcachekit.backends._uninterrupted._raised_during_requestdirectly. Patchingbackend_module._raised_during_requesttherefore only reaches the transport handler's walk, so thelen(walks) == 1guard intest_interrupt_while_dropping_a_transport_failures_tracebacks_holds_no_exceptionwas always true. This removes thewalkslist and the guard, makes the patched walk yield the first exception and then raiseKeyboardInterrupt, and documents in the docstring that only the transport handler's walk is patched.It also fixes two stale test comments: the keyring test no longer claims the sync wrapper lacks an outer
finally, and the context-leak fixture docstring reads "without it, one leaking test would also fail".Test-only change; no behaviour change. A mutation check on
_send's interrupt branch gives the same result before and after the edit: deleting the_clear_interrupted(...)call survives in both, and deletingraised = error = Nonefails_cachekit_frames_holding_an_exception(exc) == []in both.Closes LAB-8742