classification
Title: getpass.getuser works on OSX
Type: behavior Stage: resolved
Components: Documentation Versions: Python 3.6, Python 3.5, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: berker.peksag, docs@python, eric.araujo, georg.brandl, gregory.p.smith, louiscipher, python-dev, r.david.murray, ronaldoussoren
Priority: normal Keywords: patch

Created on 2011-06-02 15:48 by louiscipher, last changed 2016-06-02 01:23 by python-dev. This issue is now closed.

Files
File name Uploaded Description Edit
getuser.patch louiscipher, 2011-06-02 15:48 review
Messages (13)
msg137483 - (view) Author: Bryce Verdier (louiscipher) Date: 2011-06-02 15:48
In the docs for getpass:
http://docs.python.org/release/2.6.6/library/getpass.html (as an example).

It hints that getuser() doesn't work on OSX. I tried this out and it works fine for python 2.6 on 10.6.

I have included a patch for this. I believe the cleanest way to handle this is to remove the "Availability" entry as it's no longer necessary.
msg137491 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2011-06-02 18:53
I think you are correct that the Availability can be removed, since the actual limits of the support are exactly as complicated as the code that supports them, and should give *some* result on most (all?) platforms.  However, OS/X is certainly covered by the current one, since OS/X is a unix flavor.  At this point in time it might be worth doing a sweep through the docs to remove all occurrences of 'Macintosh', since we don't support OS/9 any more.  There look to be less than a dozen such references in the Python3 docs.

I'm adding Gregory to nosy to see if he thinks it is appropriate to remove the 'availability' entirely, since he implemented the fallback.
msg137530 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2011-06-03 15:43
Yes, it’s unclear whether Unix in the docs included Mac OS X or not.
msg137540 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2011-06-03 16:00
Well, let's make it clear then.  What about replacing the text-only "Availability" with a directive that renders into a link that displays what the individual values mean?
msg137542 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2011-06-03 16:03
Only because we had Macintosh in there.  We don't mention OS/X explicitly anywhere else in the docs that I could find (except one prose mention in the logging docs).
msg137544 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2011-06-03 16:09
Georg: our post seem to have crossed despite Roundup's attempts at locking.  +1 to your idea about the directive.
msg137882 - (view) Author: Bryce Verdier (louiscipher) Date: 2011-06-07 20:39
I like the idea as well. But I'm not sure what is needed in order to help.
msg137937 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2011-06-09 03:18
It requires adding code to support a new Sphinx directive.  I'm not sure if it should be a generic Sphinx directive (in which case we should open an issue on the Sphinx bug tracker) or Python specific.  If the latter, I can't at the moment tell you where the python-specific Sphinx code lives, but someone will know.
msg137949 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2011-06-09 11:39
That would be Doc/tools/sphinxext/pyspecific.py
msg224038 - (view) Author: Ronald Oussoren (ronaldoussoren) * (Python committer) Date: 2014-07-26 09:57
The issue still is present, wouldn't it be better to just remove the availability annotation from the docs (2.7, 3.4 and trunk) while waiting for a better solution? 

That would at least remove confusion for these docs. At the very least the "Macintosh" availability note should be removed, that was used to document that a function is available on MacOS 9, which hasn't been supported in a long time now.
msg266855 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-06-02 01:16
New changeset c13198a2007e by Berker Peksag in branch '3.5':
Issue #12243: Remove redundant availability notes from getpass docs
https://hg.python.org/cpython/rev/c13198a2007e

New changeset 1bd3daae351d by Berker Peksag in branch 'default':
Issue #12243: Merge from 3.5
https://hg.python.org/cpython/rev/1bd3daae351d
msg266856 - (view) Author: Berker Peksag (berker.peksag) * (Python committer) Date: 2016-06-02 01:18
See issue 11233 for the availability directive patch. Thanks for the patch, Bryce.
msg266858 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-06-02 01:23
New changeset 98870f27d2ed by Berker Peksag in branch '2.7':
Issue #12243: Remove redundant availability notes from getpass docs
https://hg.python.org/cpython/rev/98870f27d2ed
History
Date User Action Args
2016-06-02 01:23:18python-devsetmessages: + msg266858
2016-06-02 01:18:30berker.peksagsetstatus: open -> closed

type: behavior
versions: + Python 3.6, - Python 3.4
nosy: + berker.peksag

messages: + msg266856
resolution: fixed
stage: resolved
2016-06-02 01:16:29python-devsetnosy: + python-dev
messages: + msg266855
2014-07-26 09:57:32ronaldoussorensetnosy: + ronaldoussoren

messages: + msg224038
versions: + Python 3.4, Python 3.5, - Python 3.2, Python 3.3
2011-06-09 11:39:56eric.araujosetmessages: + msg137949
2011-06-09 03:18:23r.david.murraysetmessages: + msg137937
2011-06-07 20:39:05louisciphersetmessages: + msg137882
2011-06-03 16:09:17r.david.murraysetmessages: + msg137544
2011-06-03 16:03:38r.david.murraysetmessages: + msg137542
2011-06-03 16:00:18georg.brandlsetnosy: + georg.brandl
messages: + msg137540
2011-06-03 15:43:29eric.araujosetnosy: + eric.araujo
messages: + msg137530
2011-06-02 18:53:23r.david.murraysetnosy: + gregory.p.smith, r.david.murray

messages: + msg137491
versions: - Python 2.6, Python 3.1, Python 3.4
2011-06-02 15:48:23louisciphercreate