+ fixes #0001054: Show name of feature when it reports a warning
This commit is contained in:
parent
0954adf784
commit
f1e9966084
|
@ -170,7 +170,14 @@ int DocumentObjectPy::setCustomAttributes(const char* attr, PyObject *obj)
|
||||||
throw Py::AttributeError(s.str());
|
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;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user