Skip to content

Commit

Permalink
+ fixes #1054: Show name of feature when it reports a warning
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Jan 10, 2015
1 parent 0954adf commit f1e9966
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/App/DocumentObjectPyImp.cpp
Expand Up @@ -170,7 +170,14 @@ int DocumentObjectPy::setCustomAttributes(const char* attr, PyObject *obj)
throw Py::AttributeError(s.str());
}

prop->setPyObject(obj);
try {
prop->setPyObject(obj);
}
catch (const Base::TypeError& e) {
std::stringstream s;
s << "Property '" << prop->getName() << "': " << e.what();
throw Py::TypeError(s.str());
}
return 1;
}

Expand Down

0 comments on commit f1e9966

Please sign in to comment.