File tree 2 files changed +19
-10
lines changed
resolve_proxy_encoder/queuer
2 files changed +19
-10
lines changed Original file line number Diff line number Diff line change @@ -348,18 +348,20 @@ def handle_offline_proxies(media_list: list) -> list:
348
348
349
349
if answer .lower ().startswith ("y" ):
350
350
pprint (f"[yellow]Queuing '{ offline_proxy ['file_name' ]} ' for re-render" )
351
- [
352
- x ["proxy" ].update ("None" )
353
- for x in media_list
354
- if x ["file_path" ] == offline_proxy ["file_path" ]
355
- ]
351
+
352
+ for x in media_list :
353
+ if x ["file_path" ] == offline_proxy ["file_path" ]:
354
+ x ["proxy" ] = "None"
356
355
357
356
elif answer .lower ().startswith ("a" ):
358
357
359
358
pprint (
360
359
f"[yellow]Queuing { len (offline_proxies )} offline proxies for re-render"
361
360
)
362
- [x ["proxy" ].update ("None" ) for x in media_list if x == "Offline" ]
361
+
362
+ for x in media_list :
363
+ if x == "Offline" :
364
+ x ["proxy" ] = "None"
363
365
364
366
global SOME_ACTION_TAKEN
365
367
SOME_ACTION_TAKEN = True
Original file line number Diff line number Diff line change @@ -275,12 +275,19 @@ def link_proxies_with_mpi(media_list):
275
275
if Confirm .ask (
276
276
f"[yellow]{ len (link_fail )} proxies failed to link. Would you like to re-render them?"
277
277
):
278
+ # Remove offline status, redefine media list
279
+ for x in media_list :
280
+ if x in link_fail :
281
+ x ["proxy" ] = "None"
278
282
279
- media_list = [
280
- x for x in media_list if x not in link_success or x not in link_fail
281
- ]
283
+ media_list = [x for x in media_list if x not in link_success ]
282
284
283
- media_list = [x for x in media_list if x not in link_success ]
285
+ else :
286
+
287
+ # Queue only those that remain
288
+ media_list = [
289
+ x for x in media_list if x not in link_success or x not in link_fail
290
+ ]
284
291
285
292
logger .debug (f"[magenta]Remaining unlinked media: { media_list } " )
286
293
return media_list
You can’t perform that action at this time.
0 commit comments