Closed blaisep closed 2 years ago
Does PyCharm again generate documentation? It used to and that was a great feature (press """<enter>
) but when I redid this for the 2021 edition, it wouldn't generate them at all. Or are you saying there is some other venue that PyCharm uses the docs differently that is confusing?
Yes! It does have that cool completion feature and I just noticed that by default it uses the traditional rST style and not the sexy minimalistic Google style.
"""
:param url:
:return:
"""
The course materials use the Google style. Some, less clueful, readers may find it confusing.
I'm running: PyCharm 2021.2.2 (Professional Edition) Build #PY-212.5284.44, built on September 14, 2021
@mikeckennedy , I found it... the setting is in Preferences -> Tools -> Python Integrated Tools -> Docstrings -> Docstring format [ ReStructured | Google | Numpy ... ]
Hi @blaisep thanks a bunch. I didn't realize that was an option. For whatever reason, I can't get any of my PyCharm installs to react to """[cursor]"""
+ enter or even show the code intention to stub out the docs any more. What version of PyCharm are you using?
Anyway, I'll put a note in the steps to show you can configure your docstring format which is a cool find!
Hi @blaisep thanks a bunch. I didn't realize that was an option. For whatever reason, I can't get any of my PyCharm installs to react to
"""[cursor]"""
+ enter or even show the code intention to stub out the docs any more. What version of PyCharm are you using?
I'm running: PyCharm 2021.2.2 (Professional Edition) Build #PY-212.5284.44, built on September 14, 2021
Anyway, I'll put a note in the steps to show you can configure your docstring format which is a cool find!
Thanks @blaisep for the extra info. That is the latest one. Turns out on my laptop it does generate the docstring but on my desktop, no dice. I should probably just completely reinstall it there.
The journey from Keyboard to Screen is long and full of detours... you may have the keyboard shortcut assigned to something else? I kind of regret using vim bindings because it seems to reassign some functions to weird places.
On Sun, Oct 17, 2021 at 2:36 AM Michael Kennedy @.***> wrote:
Thanks @blaisep https://github.com/blaisep for the extra info. That is the latest one. Turns out on my laptop it does generate the docstring but on my desktop, no dice. I should probably just completely reinstall it there.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/talkpython/mastering-pycharm-course/issues/52#issuecomment-945059120, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAB6D6CSTZBNFZO3SKAU4UDUHJVGNANCNFSM5E3LK34Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
-- LinkedIn https://www.linkedin.com/in/blaisepabon/ | Quora https://www.quora.com/profile/Blaise-Pabon | Github https://github.com/blaisep “If you want to go fast, go alone. If you want to go far, go together.” --African proverb
Indeed! I thought it might be something like that. But the activation is simply pressing ENTER which obviously didn't get modified. I think it's because I started with an EAP version and something got whacked. I'll keep investigating.
Best, Michael
Sent via Superhuman @.***>
On Sun, Oct 17, 2021 at 2:30 PM, Blaise Pabon @.***> wrote:
The journey from Keyboard to Screen is long and full of detours... you may have the keyboard shortcut assigned to something else? I kind of regret using vim bindings because it seems to reassign some functions to weird places.
On Sun, Oct 17, 2021 at 2:36 AM Michael Kennedy @.***> wrote:
Thanks @blaisep https://github.com/blaisep for the extra info. That is the latest one. Turns out on my laptop it does generate the docstring but on my desktop, no dice. I should probably just completely reinstall it there.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/talkpython/mastering-pycharm-course/issues/ 52#issuecomment-945059120, or unsubscribe https://github.com/notifications/unsubscribe-auth/ AAB6D6CSTZBNFZO3SKAU4UDUHJVGNANCNFSM5E3LK34Q . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/ id1477376905?ct=notification-email&mt=8&pt=524675 or Android <https://play.google.com/store/apps/details?id=com.github. android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub .
-- LinkedIn https://www.linkedin.com/in/blaisepabon/ | Quora https://www.quora.com/profile/Blaise-Pabon | Github https://github.com/blaisep “If you want to go fast, go alone. If you want to go far, go together.” --African proverb
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/talkpython/mastering-pycharm-course/issues/52#issuecomment-945198122, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAPQ62LNODE3QFCWLOUQ7YLUHM57JANCNFSM5E3LK34Q .
@mikeckennedy , There's a discrepancy between the instructions and the behavior of PyCharm. The README has an example using Google style docstrings: https://github.com/talkpython/mastering-pycharm-course/blame/main/your-turn/02-the-editor/readme.md#L63
but Pycharm uses regular style by default. Some students may find this confusing.