Propagate internal errors to the master node
This should help users diagnose internal errors in workers like exceptions from hooks or in pytest itself.
This commit is contained in:
@@ -33,8 +33,10 @@ class WorkerInteractor:
|
||||
self.channel.send((name, kwargs))
|
||||
|
||||
def pytest_internalerror(self, excrepr):
|
||||
for line in str(excrepr).split("\n"):
|
||||
formatted_error = str(excrepr)
|
||||
for line in formatted_error.split("\n"):
|
||||
self.log("IERROR>", line)
|
||||
interactor.sendevent("internal_error", formatted_error=formatted_error)
|
||||
|
||||
def pytest_sessionstart(self, session):
|
||||
self.session = session
|
||||
|
||||
Reference in New Issue
Block a user