Member
Changes look good ๐ What would you think about adding a unit test for this? i.e. check for every file that's named __init__.py or doesn't have an underscore in the path (like telegram/ext/filters.py) that
- it has
__all__ __all__comes directly after the docstring- for inits, that all non-underscore modules of that directory are included in
__all__
I guess that could be done with a bit of regex. E.g. for the second one something like ^(\#[^\n]*\n)*((\"{3}[^\"]*\"{3})|)([\n ]*)__all__ could work
Not sure if this actually helps or just makes more problems ๐
Member Author
- it has
__all__
hm, I specifically removed __all__ for filters because iirc, it messed up with the docs (only rendered those in __all__) but maybe there's a setting for that.
__all__comes directly after the docstring
actually I think this is something pylint should warn about. I'll open an issue upstream and see if they want to support it or not.
- for inits, that all non-underscore modules of that directory are included in
__all__
yes sounds reasonable.
Member
- it has
__all__hm, I specifically removed
__all__for filters because iirc, it messed up with the docs (only rendered those in__all__) but maybe there's a setting for that.
to me that sounds like __all__ was missing a lot of stuff ๐ฌ
__all__comes directly after the docstringactually I think this is something pylint should warn about. I'll open an issue upstream and see if they want to support it or not.
nice idea ๐ช
Member
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice ๐ about dunder names coming first: do you want to, wait for pylint, add a custom test temporarily or just merge? I'm open for all :)
Member Author
about dunder names coming first: do you want to, wait for pylint, add a custom test temporarily or just merge? I'm open for all :)
I think we can merge and then just update pylint dependency if they support it.