andreahlert opened a new pull request, #734:
URL: https://github.com/apache/burr/pull/734

   ## Summary
   
   Fixes bugs in the interceptor lifecycle hooks introduced in #602:
   
   - **`should_intercept` on async interceptor classes was declared `async 
def`**, but callers use it inside lambdas passed to `get_first_matching_hook()` 
which cannot `await`. An async `should_intercept` returns a coroutine object 
(always truthy), silently matching every action regardless of the predicate 
logic. Changed to `def` with a note explaining why.
   - **`StreamingActionInterceptorHookAsync.intercept_stream_run_and_update`** 
was `def` but the caller checks `isasyncgenfunction`, so it needs to be `async 
def` to match.
   - **Temporal example** called `worker_adapter_set.get_hooks()` which doesn't 
exist on `LifecycleAdapterSet`. Replaced with 
`call_all_lifecycle_hooks_async()`.
   - **Temporal worker hook signatures** used `str` for action and `**kwargs` 
instead of `Action` and `**future_kwargs`.
   
   ## Test plan
   
   - [x] All 311 tests pass (core + lifecycle + interceptor integration tests)
   - [x] No changes to test files needed (tests already used sync 
`should_intercept`)
   - [x] Verified no remaining `async def should_intercept` in codebase


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to