Closed Nov1kov closed 3 years ago
Do you think this bug and fix is also related to #1505?
@sijis Hello, I'm not sure. In my case, I have exception: Plugin dependency Child1 needs to be listed in section [Core] key "DependsOn" to be used in get_plugin.
.
My unit test shows root of the problemm.
So, I can add unit test like from https://github.com/errbotio/errbot/issues/1397, and we'll see about that.
So, I can add unit test like from #1397, and we'll see about that.
If you can, that would be extremely helpful.
@sijis
@sijis code-style fixed!
Hello maintainers! @gbin @sijis @zoni what about the merge request? I must use my fork.
I should have from free cycles this weekend to look at this more in-depth.
Thank you again for the fixes. I truly appreciate the amount of testing included.
Bug reproduce
Complicated plugin structure.
It works correctly after load on my MacBook. But didn't after deploy & run in Docker on a Linux machine. Plugin "Parent1" can't find Childs plugins, by method
get_plugin
.Research
This behavior depends on a file system. Method
pathlib.Path.glob
works differently on Linux & Mac. Bot load plugins depending on the order of the files. PluginManager can activate plugins by direct load, or if the plugin is DependOn. So if the plugin activates by the second way, the plugin doesn't set depends list.Merge request
_activate_plugin_dependencies
inPluginManager
.