Skip to content

Commit 8315402

Browse files
committed
Show more details in error message
1 parent 13de375 commit 8315402

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

include/openPMD/IO/AbstractIOHandlerImpl.hpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,17 @@ class AbstractIOHandlerImpl
204204
break;
205205
}
206206
}
207+
catch (std::exception const &e)
208+
{
209+
std::cerr << "[AbstractIOHandlerImpl] IO Task "
210+
<< internal::operationAsString(i.operation)
211+
<< " failed with exception. Removing task"
212+
<< " from IO queue and passing on the exception. "
213+
<< "Original exception was: \n"
214+
<< e.what() << std::endl;
215+
(*m_handler).m_work.pop();
216+
throw;
217+
}
207218
catch (...)
208219
{
209220
std::cerr << "[AbstractIOHandlerImpl] IO Task "

0 commit comments

Comments
 (0)