File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,6 @@ async def run_in_background(
157
157
try :
158
158
pending_requests = []
159
159
while True :
160
- await asyncio .sleep (0.001 )
161
160
pending_requests = await self .prefill (
162
161
pending_requests ,
163
162
lit_api ,
@@ -167,6 +166,7 @@ async def run_in_background(
167
166
batch_timeout ,
168
167
response_queues ,
169
168
)
169
+ await asyncio .sleep (0 )
170
170
except Exception as e :
171
171
logger .exception ("An error occurred in run_in_background: %s" , e )
172
172
finally :
@@ -194,7 +194,7 @@ async def run(
194
194
"""Main loop that processes batches of requests."""
195
195
try :
196
196
prev_outputs = None
197
- while await lit_api .has_active_requests ():
197
+ while lit_api .has_active_requests ():
198
198
# Process one step for all active sequences
199
199
responses = await self .step (prev_outputs , lit_api , lit_spec )
200
200
if len (responses ) == 0 :
Original file line number Diff line number Diff line change @@ -476,7 +476,7 @@ async def _wrapper():
476
476
workers_setup_status ,
477
477
callback_runner ,
478
478
)
479
- await asyncio .sleep (0.00001 )
479
+ await asyncio .sleep (0 )
480
480
except Exception as e :
481
481
logger .exception ("An error occurred in the loop: %s" , e )
482
482
# Optionally, break the loop or handle the error as needed
You can’t perform that action at this time.
0 commit comments