Broken documentation GitHub action
See original GitHub issueAs you may already noticed, the “documentation” action is failing (and thus the deployment action).
The action started to fail after merging #241. The error message is far from being helpful in solving the issue.
I have the feeling that this could be related to the new callbacks hierarchy. As of now, the base class StrategyCallbacks
, which defines all possible plugin/loggers/metrics callbacks, declares its methods as:
def before_training(self, *args, **kwargs) -> CallbackResult:
pass
while child classes define a different arguments signature (for instance, by adding a mandatory strategy
argument and/or by removing the *args
and **kwargs
ones. I was thinking that maybe the docstring action, in order to create the documentation for the method arguments, expects the child classes to strictly follow the Liskov substitution principle (which is a good thing, in general).
One possible solution is to introduce a different base class for each category (plugin, metric, logger) to adhere to this principle.
I’ll try to test if this is the actual problem. I’ll keep you posted!
@AntonioCarta if my assumption is correct, this would require updating the class hierarchy. I don’t think this should interfere with #226, but keep it under consideration.
Note: using sphinx 3.3.1 everything works fine from my side -_-, so this problem only apply to the latest version.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top GitHub Comments
I just successfully tested a fix on my rig. I’m now waiting for actions to complete on my fork. I’m planning to open a PR in the next 10/20 minutes.
I identified the problem with the
astroid
package, which is internally used by sphinx. Forcing astroid to version 2.4.2 (latest) via pip fixes the issue. For some reason conda doesn’t seem to pick the latest version of that package. Also works with astroid 2.4.1