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: docstrings for the threading module
Type: behavior Stage: patch review
Components: Documentation Versions: Python 3.2, Python 3.3, Python 3.4, Python 2.7
process
Status: closed Resolution: duplicate
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, eli.bendersky, eric.araujo, ezio.melotti, gjcross, moijes12, pitrou
Priority: low Keywords: easy, patch

Created on 2011-08-17 02:43 by eli.bendersky, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
threading_docstrings.patch gjcross, 2011-08-22 04:39 Patch that adds missing docstrings for the threading module review
12768_2.patch moijes12, 2013-02-27 18:36 review
12768_3.patch moijes12, 2013-03-06 16:50 review
Messages (25)
msg142247 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-08-17 02:43
The threading module has very few methods with docstrings. Docstrings should be added to all public methods (contents can be borrowed from the documentation).
msg142668 - (view) Author: Graeme Cross (gjcross) Date: 2011-08-22 04:39
Threading module docstrings added for all classes and public methods; mainly used a summarised version of information from the documentation.
msg142671 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-08-22 05:11
On Mon, Aug 22, 2011 at 07:39, Graeme Cross <report@bugs.python.org> wrote:

>
> Graeme Cross <gjcross@gmail.com> added the comment:
>
> Threading module docstrings added for all classes and public methods;
> mainly used a summarised version of information from the documentation.
>

Thanks for the patch, Graeme.
I will try to find time to review and apply it in a few days, if no one else
will do it until then.

Eli
msg142672 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-08-22 05:12
Graeme - could you specify which version of Python this patch applies to?
msg142673 - (view) Author: Graeme Cross (gjcross) Date: 2011-08-22 05:18
The patch applies to tip.
msg142714 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-08-22 09:33
The usual procedure for committing to both 3.2 and 3.3 is to apply a patch to 3.2 and then merge it to 3.3 - could you check if the patch also works for 3.2 and if not, generate a patch for 3.2? I will do the merge when committing.
msg143019 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2011-08-26 15:53
I have made a review on Rietveld.
msg143022 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-08-26 17:14
Éric, yeah I received an email. Hopefully Graeme did too.

It's a shame a new review isn't notified in the tracker instead.
msg143057 - (view) Author: Graeme Cross (gjcross) Date: 2011-08-27 07:00
I will check that the patch works with 3.2; if not, I'll redo the patch for 3.2.
I will also incorporate the review changes from Ezio and Eric.
msg147464 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2011-11-12 04:52
Graeme, any news on this?

If you re-do the patch for current tip and address the review comments, I think we can commit it.
msg181579 - (view) Author: moijes12 (moijes12) Date: 2013-02-07 07:08
Hi

Is this still open to work on ?

If yes, what were the review comments from the previous review?
msg181716 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-02-09 03:37
moijes,

Yes, it's open. You can examine the comments for the previous patch by clicking on the "review" link near the patch. You need to be logged in to the issue tracker to see that.
msg183171 - (view) Author: moijes12 (moijes12) Date: 2013-02-27 18:40
I've attached a new patch with some changes.
msg183407 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-03-03 22:15
moijes, did you address the review comments?

Does your patch apply to 3.2?
msg183479 - (view) Author: moijes12 (moijes12) Date: 2013-03-04 17:30
Hi 

I am seen the review comments and made the changes accordingly. I am not sure if my changes apply to 3.2. How do I do that ?
msg183484 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2013-03-04 18:20
3.2$ hg imp --no-c http://bugs.python.org/file29268/12768_2.patch
applying http://bugs.python.org/file29268/12768_2.patch
patching file Lib/threading.py
Hunk #3 FAILED at 58
Hunk #4 FAILED at 79
Hunk #5 FAILED at 92
Hunk #6 FAILED at 125
Hunk #10 FAILED at 252
Hunk #12 succeeded at 386 with fuzz 1 (offset 82 lines).
Hunk #13 FAILED at 317
Hunk #17 FAILED at 405
Hunk #22 FAILED at 576
Hunk #23 FAILED at 589
Hunk #30 FAILED at 897
Hunk #33 succeeded at 1124 with fuzz 2 (offset 132 lines).
10 out of 35 hunks FAILED -- saving rejects to file Lib/threading.py.rej
abort: patch failed to apply

>  I am not sure if my changes apply to 3.2. How do I do that ?

You have to switch to the 3.2 branch using "hg up 3.2", and then use "hg import" as showed above to apply the patch.  You will also need to run configure/make again to build 3.2, so you can run tests.
msg183485 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2013-03-04 18:24
FWIW it applies cleanly on 3.3, but unless we decide to target 3.3+ only, the patch needs to be adapted for 2.7/3.2.
msg183594 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-03-06 14:43
I wouldn't expend too much effort on older versions though. So unless it's simple to adapt, IMHO 3.3+ is good enough.
msg183605 - (view) Author: moijes12 (moijes12) Date: 2013-03-06 16:50
This patch was built on 3.2(I made the changes on the local repo after running command "hg up 3.2"). I've run the test suite and only test_site failed. This patch has some improvements over 12768_2.patch.
msg183614 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2013-03-06 20:53
I haven't read the patch in detail but I think the reference to Java's threading model could probably be discarded. First, I don't know if it's still true, second, I don't think anyone cares :)
msg183616 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-03-06 21:39
> I haven't read the patch in detail but I think the reference to Java's
> threading model could probably be discarded. First, I don't know if it's
> still true, second, I don't think anyone cares :)
>
>
I agree. It could be a remnant of a time where the threading library was
very new and so it helped "relating" it to something familiar. These days
there are (thankfully) many programmers coming to Python without any Java
background.
msg184079 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-03-13 13:22
See also #17375
msg184748 - (view) Author: moijes12 (moijes12) Date: 2013-03-20 09:45
Hi

Since this is a duplicate of #17375, is the patch not going to make to the review stage at all?
msg184756 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-03-20 12:13
moijes12, since Raymond went ahead and committed a patch to 2.7 in #17375, I think patches to other versions should also be based on his patch. The most constructive thing you can do at this point is review his changes in 2.7 and help porting them to 3.x. Also, you can see if anything is missing/wrong since you've gained some experience about the module while writing the docstrings.

I'm sorry it went like that; don't take it personally - open-source development is a bazaar :-)
msg186688 - (view) Author: Eli Bendersky (eli.bendersky) * (Python committer) Date: 2013-04-13 03:03
Issue #17375 supersedes this one. Please post updated patches there.
History
Date User Action Args
2022-04-11 14:57:20adminsetgithub: 56977
2013-04-13 03:04:07eli.benderskysetstatus: open -> closed
resolution: duplicate
2013-04-13 03:03:55eli.benderskysetmessages: + msg186688
2013-03-20 12:13:39eli.benderskysetmessages: + msg184756
2013-03-20 09:45:43moijes12setmessages: + msg184748
2013-03-13 13:22:38eli.benderskysetmessages: + msg184079
2013-03-06 21:39:11eli.benderskysetmessages: + msg183616
2013-03-06 20:53:46pitrousetnosy: + pitrou

messages: + msg183614
stage: needs patch -> patch review
2013-03-06 16:50:59moijes12setfiles: + 12768_3.patch

messages: + msg183605
2013-03-06 14:43:25eli.benderskysetmessages: + msg183594
2013-03-04 18:24:57ezio.melottisetmessages: + msg183485
2013-03-04 18:20:15ezio.melottisetmessages: + msg183484
2013-03-04 17:30:19moijes12setmessages: + msg183479
2013-03-03 22:15:44eli.benderskysetmessages: + msg183407
2013-02-27 18:40:05moijes12setmessages: + msg183171
2013-02-27 18:36:37moijes12setfiles: + 12768_2.patch
2013-02-09 03:37:34eli.benderskysetmessages: + msg181716
2013-02-07 08:17:05ezio.melottisetnosy: + ezio.melotti

versions: + Python 3.4
2013-02-07 07:08:55moijes12setnosy: + moijes12
messages: + msg181579
2011-11-12 04:52:23eli.benderskysetmessages: + msg147464
2011-08-27 07:00:40gjcrosssetmessages: + msg143057
2011-08-26 17:14:50eli.benderskysetmessages: + msg143022
2011-08-26 15:53:55eric.araujosetmessages: + msg143019
2011-08-22 09:33:24eli.benderskysetmessages: + msg142714
2011-08-22 05:18:05gjcrosssetmessages: + msg142673
2011-08-22 05:12:51eli.benderskysetmessages: + msg142672
2011-08-22 05:12:28eli.benderskysetfiles: - unnamed
2011-08-22 05:11:33eli.benderskysetfiles: + unnamed

messages: + msg142671
2011-08-22 04:39:26gjcrosssetfiles: + threading_docstrings.patch

nosy: + gjcross
messages: + msg142668

keywords: + patch
2011-08-20 20:54:18eric.araujosetnosy: + eric.araujo
2011-08-17 02:43:09eli.benderskycreate