Skip to content

Commit

Permalink
improve compatibility with future runner commands (ones that don't se…
Browse files Browse the repository at this point in the history
…t strategy)
  • Loading branch information
rsalmei committed Mar 25, 2021
1 parent bab04d4 commit f4e7701
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions alive_progress/animations/spinner_compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,8 +201,7 @@ def spinner_compiler(gen, natural, extra_commands):
"""

spec = SimpleNamespace(
data=tuple(tuple(fix_cells(frame) for frame in cycle) for cycle in gen),
natural=natural, strategy=None)
data=tuple(tuple(fix_cells(frame) for frame in cycle) for cycle in gen), natural=natural)
apply_extra_commands(spec, extra_commands)

# generate spec info.
Expand Down Expand Up @@ -245,7 +244,8 @@ def runner_check(*args, **kwargs):
spinner_runner.__dict__.update(spec.__dict__, check=fix_signature(runner_check, check, 1))
spec.__dict__.update(t_compile=t_compile, runner=spinner_runner) # set after the update above.

apply_extra_commands(spec, extra_commands or ((sequential, (), {}),))
sequential(spec)
apply_extra_commands(spec, extra_commands)
cycle_gen = spec.strategy(spec.data)
return spinner_runner

Expand Down

0 comments on commit f4e7701

Please sign in to comment.