gpx: remove eager list call when printing exceptions

This commit is contained in:
Sean Breckenridge 2023-04-14 16:01:49 -07:00
parent 87c13defd1
commit e1cb229913

View file

@ -547,7 +547,7 @@ def query_hpi_functions(
# can ignore the mypy warning here, locations_to_gpx yields any errors # can ignore the mypy warning here, locations_to_gpx yields any errors
# if you didnt pass it something that matches the LocationProtocol # if you didnt pass it something that matches the LocationProtocol
for exc in list(locations_to_gpx(res, sys.stdout)): # type: ignore[arg-type] for exc in locations_to_gpx(res, sys.stdout): # type: ignore[arg-type]
click.echo(str(exc), err=True) click.echo(str(exc), err=True)
sys.stdout.flush() sys.stdout.flush()
else: else: