Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing additional exception information for better clarity #392

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions Framework/src/ObjectsManager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,12 @@ void ObjectsManager::stopPublishing(const string& name)
{
auto* mo = dynamic_cast<MonitorObject*>(mMonitorObjects->FindObject(name.data()));
if (mo == nullptr) {
BOOST_THROW_EXCEPTION(ObjectNotFoundError() << errinfo_object_name(name));
// TODO: ideally we want to pass the object name to the exception but the implementation
// of AliceO2::Common::ObjectNotFoundError drops additional information. For clarity we
// better skip
// << errinfo_object_name(name));
// until this is fixed
BOOST_THROW_EXCEPTION(ObjectNotFoundError());
}
mMonitorObjects->Remove(mo);
}
Expand All @@ -102,7 +107,12 @@ MonitorObject* ObjectsManager::getMonitorObject(std::string objectName)
if (mo != nullptr) {
return dynamic_cast<MonitorObject*>(mo);
} else {
BOOST_THROW_EXCEPTION(ObjectNotFoundError() << errinfo_object_name(objectName));
// TODO: ideally we want to pass the object name to the exception but the implementation
// of AliceO2::Common::ObjectNotFoundError drops additional information. For clarity we
// better skip
// << errinfo_object_name(objectName));
// until this is fixed
BOOST_THROW_EXCEPTION(ObjectNotFoundError());
}
}

Expand Down