Skip to content

Commit

Permalink
check for reactors returning None
Browse files Browse the repository at this point in the history
fixes #753
  • Loading branch information
trehn committed Apr 2, 2024
1 parent 55dca25 commit 26f21e2
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions bundlewrap/metagen.py
Original file line number Diff line number Diff line change
Expand Up @@ -466,6 +466,15 @@ def __run_reactor(self, node, reactor_name, reactor):
with suppress(KeyError):
del self._reactors_with_keyerrors[self._current_reactor]

if new_metadata is None:
raise ValueError(_(
"{reactor_name} on {node_name} returned None instead of a dict "
"(missing return?)"
).format(
node_name=node.name,
reactor_name=reactor_name,
))

if self._verify_reactor_provides and getattr(reactor, '_provides', None):
extra_paths = extra_paths_in_dict(new_metadata, reactor._provides)
if extra_paths:
Expand Down

0 comments on commit 26f21e2

Please sign in to comment.