Fix exception when printing an error message

pkg may not be always set.
This commit is contained in:
Michal Sojka 2024-09-26 17:03:05 +02:00
parent c0dcec99ca
commit 61f9d71bc8

View file

@ -431,7 +431,7 @@ def ros2nix(args):
)
except Exception as e:
err('Failed to prepare Nix expression for package {}!'.format(pkg))
err(f'Failed to prepare Nix expression from {source}')
raise e
try: