You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since #3121 was recently merged, I have noticed a problem with some models that are slow to load. Specifically, if a model is spawned that contains a sensor plugin that is slow to load, it is possible that model plugins will fail to load, with the following error message:
[Err] [Model.cc:1061] Sensors failed to initialize when loading model[...] via the factory mechanism. Plugins for the model will not be loaded.
I believe this is caused by this logic in Model::LoadPlugins that skips loading of model plugins if the sensors take longer than 5 seconds to initialize, which includes the time required to load sensor plugins.
I have created a world file along with two test plugins to reproduce the failure in scpeters@8a2a4cc. The world has a WorldSpawnModelPlugin that spawns a model that has a single box with a camera sensor using the SlowLoadingSensorPlugin and the InitialVelocityPlugin as a model plugin. The box should be given an initial velocity after loading, but the slow-loading sensor plugin causes the model plugin to not be loaded, so the box remains at its initial pose.
The text was updated successfully, but these errors were encountered:
scpeters
added a commit
to scpeters/gazebo
that referenced
this issue
Oct 22, 2021
As noted in #3125, loading a model may timeout when
loading model plugins if the model contains sensor
plugins that are slow to load. Since this timeout seems more
likely to occur since #3121 was merged, the default timeout
is increased from 5 seconds to 30 seconds, and an SDFormat
world parameter <ignition:model_plugin_loading_timeout> is
added to make the timeout configurable.
A regression test using a test world and two test plugins is
added to demonstrate the problem and confirm the fix.
* Fix typos in World.hh doc-strings
* Add IGN_PROFILE to World::ProcessFactoryMsgs
* Disable shadow caster test on macOS
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Since #3121 was recently merged, I have noticed a problem with some models that are slow to load. Specifically, if a model is spawned that contains a sensor plugin that is slow to load, it is possible that model plugins will fail to load, with the following error message:
I believe this is caused by this logic in
Model::LoadPlugins
that skips loading of model plugins if the sensors take longer than 5 seconds to initialize, which includes the time required to load sensor plugins.I have created a world file along with two test plugins to reproduce the failure in scpeters@8a2a4cc. The world has a
WorldSpawnModelPlugin
that spawns a model that has a single box with a camera sensor using theSlowLoadingSensorPlugin
and theInitialVelocityPlugin
as a model plugin. The box should be given an initial velocity after loading, but the slow-loading sensor plugin causes the model plugin to not be loaded, so the box remains at its initial pose.The text was updated successfully, but these errors were encountered: