-
-
Notifications
You must be signed in to change notification settings - Fork 409
plugins.rules: fix conflicting attributes in base classes #2220
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
Conversation
dgw
left a comment
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.
Below is more of an idea. The "request changes" review status is about what I said in the line notes.
Surely there's a way to deal with this that doesn't require removing the mixin pattern? Off the top of my head, adding an AnonymousRuleMixin that provides get_rule_label() for Rule, leaving NamedRuleMixin to provide it for the command-type rules.
|
Was troubleshooting for some other doc-related thing I'm trying to fix, and was checking to see if this patch affected that issue at all. It doesn't, but test-building the docs on this branch showed me that it breaks some of |
|
I stole the type-hint fix from #2223 and also the classmethod/abstractclassmethod warning since I'm touching the same files/area. |
|
My main issue is that I need to check if the doc properly build, which it doesn't, and specifically on the classes I touch/modify. So maybe I just need #2223 to be merged before I can move forward. As for the stolen part, don't worry: I did forgot the co-author tag, and that's my fault, I was a bit caught up into too many PRs at once, and I should have been more careful. |
942a368 to
4f6819e
Compare
dgw
left a comment
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.
Yeah, I'm just dropping this line note for posterity, not because I want something to change as a result. Let's say this is ready.
I spent a bit of time on that today and will shortly post a follow-up there with some things I noticed. But the bottom line for this patch is going to be that I no longer think it's a good idea to mess with Sphinx in this PR. Let's get the code changes from this in, only, and then I'll resume work on #2223 to check for any other warnings/issues in the docs. |
Part of this patch no longer seems wise; see comments.
I kept the strict minimum that makes sense in this PR regarding the documentation: I replaced the autodoc for the mixin by the autodoc for the abstract class. I feel like it's a fair change of the documentation while not messing with Sphinx, i.e. not trying to fix too much. |
|
Ack, thanks Exirel. I'll approve and merge once squashed. |
ea56c9b to
77ff78a
Compare
|
And done. |
dgw
left a comment
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.
Remaining changes look sane, plus I know we have oodles of tests for this part of the code. 😏
Description
One PR, two issues:
Type hint warning for documentationChecklist
make qa(runsmake qualityandmake test)