-
Notifications
You must be signed in to change notification settings - Fork 315
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
[Core, Simulation.Core] Registration: (re)enable deprecation warnings #5155
[Core, Simulation.Core] Registration: (re)enable deprecation warnings #5155
Conversation
[ci-build][with-all-tests] |
b34767b
to
4338187
Compare
[ci-build][with-all-tests][force-full-build] |
[ci-depends-on] detected during build #4. To unlock the merge button, you must
|
[ci-depends-on] detected during build #5. To unlock the merge button, you must
|
adffeea
to
346459f
Compare
[ci-depends-on] detected during build #6. To unlock the merge button, you must
|
@@ -775,7 +775,7 @@ bool ObjectFactory::registerObjectsFromPlugin(const std::string& pluginName) | |||
// do not register if it was already done before | |||
if(m_registeredPluginSet.count(pluginName) > 0) | |||
{ | |||
// msg_warning("ObjectFactory") << pluginName << " has already registered its components."; | |||
msg_warning("ObjectFactory") << pluginName << " has already registered its components."; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This warning is a bit problematic.
It will be displayed if a plugin registers twice (or more) so I felt it could be nice to warn the user somehow.
But in effect, if runSofa uses the "autoloadplugin" feature and the requiredPlugin in the scene, it will try to register twice the components (thus spamming).
Quite problematic as it is quite the default behavior with runSofa...
Should it be removed ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe to keep it commented indeed with an additional comment:
msg_warning("ObjectFactory") << pluginName << " has already registered its components."; | |
// msg_warning("ObjectFactory") << pluginName << " has already registered its components."; // Warning to re-activate when runSofa will not auto-load modules/plugins anymore |
The fact that no plugin has been ported is also problematic. Just running runSofa with default flags would already throws some warnings:
Moreover we have to think that the install version comes with much more plugins as well.... There will be quite a lot of warnings. I guess we should ignore outputting warnings for the moment... (or only in dev mode maybe ?) |
Messages should be addressed to developer only (using dmsg based on the CMake flag SOFA_WITH_DEVTOOLS) |
[ci-depends-on] detected during build #8. To unlock the merge button, you must
|
a09d4d3
to
a822c44
Compare
[ci-depends-on] detected during build #9. To unlock the merge button, you must
|
[ci-build][with-all-tests][force-full-build] |
[ci-depends-on] detected during build #10. To unlock the merge button, you must
|
[ci-build][with-all-tests][force-full-build] |
[ci-depends-on] detected during build #11. To unlock the merge button, you must
|
a822c44
to
adcd311
Compare
[ci-depends-on] detected during build #12. To unlock the merge button, you must
|
…#5155) * enable deprecation warnings for RegisterObject * enable runtime deprecation warnings * re enable disabled tests * fix typo * fix units tests * expect a warning when loading pluginA * load plugins once (avoiding registering several times) * add more info when warning the user of a deprecated registration * set warnings only if dev mode is enabled (SOFA_WITH_DEVTOOLS enabled) * apply new mechanism registration to AugmentedLagrangianConstraint
To enforce the new registration mechanism (#4429 )
This PR:
[ci-depends-on https://github.com/sofa-framework/BeamAdapter/pull/158]
[ci-depends-on https://github.com/sofa-framework/CGALPlugin/pull/20]
By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).
Reviewers will merge this pull-request only if