fix progress bar printed too early
This commit is contained in:
parent
13e91d14af
commit
933ab8301a
|
@ -58,7 +58,7 @@ if args.output:
|
|||
if args.log_dir:
|
||||
args.log_dir = resolve_path(args.log_dir)
|
||||
elif not args.output and not args.log_dir:
|
||||
print('Must set --logs-dir when --output is not.')
|
||||
print('Must set --log-dir when --output is not.')
|
||||
sys.exit(1)
|
||||
else:
|
||||
args.log_dir = args.output / 'logs'
|
||||
|
@ -237,7 +237,6 @@ for k, v in url_list.items():
|
|||
url_count += 1
|
||||
|
||||
# Init bars
|
||||
progress_bar = tqdm(total=url_count, position=0, desc='Inputs', disable=args.daemon)
|
||||
video_bars = manager.list()
|
||||
if not args.daemon:
|
||||
for i in range(args.threads):
|
||||
|
@ -254,6 +253,7 @@ if not args.daemon:
|
|||
|
||||
while True:
|
||||
do_update()
|
||||
progress_bar = tqdm(total=url_count, position=0, desc='Inputs', disable=args.daemon)
|
||||
for output_path, urls in url_list.items():
|
||||
for target_url in urls:
|
||||
logger.info('Fetching playlist...')
|
||||
|
|
Reference in New Issue