@@ -121,7 +121,7 @@ def execute_local_activity(input)
121121 end
122122 end
123123
124- def execute_activity_with_local_backoffs ( local :, cancellation :, result_hint :, &)
124+ def execute_activity_with_local_backoffs ( local :, cancellation :, result_hint :, &block )
125125 # We do not even want to schedule if the cancellation is already cancelled. We choose to use canceled
126126 # failure instead of wrapping in activity failure which is similar to what other SDKs do, with the accepted
127127 # tradeoff that it makes rescue more difficult (hence the presence of Error.canceled? helper).
@@ -130,7 +130,7 @@ def execute_activity_with_local_backoffs(local:, cancellation:, result_hint:, &)
130130 # This has to be done in a loop for local activity backoff
131131 last_local_backoff = nil
132132 loop do
133- result = execute_activity_once ( local :, cancellation :, last_local_backoff :, result_hint :, &)
133+ result = execute_activity_once ( local :, cancellation :, last_local_backoff :, result_hint :, &block )
134134 return result unless result . is_a? ( Bridge ::Api ::ActivityResult ::DoBackoff )
135135
136136 # @type var result: untyped
@@ -142,9 +142,9 @@ def execute_activity_with_local_backoffs(local:, cancellation:, result_hint:, &)
142142 end
143143
144144 # If this doesn't raise, it returns success | DoBackoff
145- def execute_activity_once ( local :, cancellation :, last_local_backoff :, result_hint :, &)
145+ def execute_activity_once ( local :, cancellation :, last_local_backoff :, result_hint :, &block )
146146 # Add to pending activities (removed by the resolver)
147- seq = yield last_local_backoff
147+ seq = block . call ( last_local_backoff )
148148 @instance . pending_activities [ seq ] = Fiber . current
149149
150150 # Add cancellation hook
0 commit comments