Skip to content

Commit

Permalink
Fix all-facts fact listing.
Browse files Browse the repository at this point in the history
This was broken by the new `pyinfra fact ...` CLI.
  • Loading branch information
Fizzadar committed Apr 26, 2021
1 parent 564be36 commit a53829b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pyinfra_cli/main.py
Expand Up @@ -363,17 +363,17 @@ def _main(
), err=True)

command = 'fact'
fact_names = []
fact_ops = []

for fact_name in get_fact_names():
fact_class = get_fact_class(fact_name)
if (
not issubclass(fact_class, ShortFactBase)
and not callable(fact_class.command)
):
fact_names.append(fact_name)
fact_ops.append((fact_class, None, None))

operations = [(name, None) for name in fact_names]
operations = fact_ops

# Get one or more facts
elif operations[0] == 'fact':
Expand Down

0 comments on commit a53829b

Please sign in to comment.