This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Provide examples in Python doc for usage of various modules
Type: enhancement Stage: resolved
Components: Documentation Versions:
process
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: docs@python Nosy List: Sarbjit.singh, docs@python, eli.bendersky, ezio.melotti, r.david.murray
Priority: normal Keywords:

Created on 2012-08-08 04:27 by Sarbjit.singh, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (3)
msg167657 - (view) Author: Sarbjit singh (Sarbjit.singh) Date: 2012-08-08 04:26
For beginners who are learning Python, it would be very helpful if Python doc could provide examples on usage of various methods/attributes of different modules.

For eg: If you look at ElementTree XMl module or take any other standard module, examples which are provided are very limited making it hard for new users to learn those modules and have to search internet for its usage. Providing examples on usage of module attributes/methods will help users to quickly understand it.
msg167659 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2012-08-08 04:34
> If you look at ElementTree XMl module or take any other
> standard module, examples which are provided are very limited

We already try to provide examples where/when appropriate, and several modules have examples showing the basic usage.  Often, documenting all the methods will only make the documentation less readable, so only the most important/common functions/methods have examples.  Some modules also have separate howtos that contain extensive examples.

If you think some specific module (like ElementTree) needs more examples, feel free to open specific reports.
msg167661 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2012-08-08 05:07
I'm closing this with no specific resolution because the real resolution is "this issue is too general" :)

As Ezio said, specific suggestions are welcome, but should be in separate issues limited to the module/example proposed.
History
Date User Action Args
2022-04-11 14:57:34adminsetgithub: 59788
2012-08-08 05:07:46r.david.murraysetstatus: open -> closed

nosy: + r.david.murray
messages: + msg167661

stage: resolved
2012-08-08 04:34:27ezio.melottisetnosy: + eli.bendersky, ezio.melotti
messages: + msg167659
2012-08-08 04:27:00Sarbjit.singhcreate