[issue40012] Avoid Python 2 documentation to appear in Web search results
New submission from Peter Bittner : Currently, when you do a Web search (e.g. using Google, Bing, Yahoo!, DuckDuckGo, et al.) for a Python module or function call you'll find a link to the related Python 2 documentation first. How to reproduce: 1. Search for simply "os.environ" in your favorite search engine. 2. Find a link to the Python documentation in the first 3 results. Typically, this will point to the Python 2 docs first. (Side note: Google seems to now actively manipulate the results ranking Python 3 results higher. Apparently, this is the only popular search engine behaving like that.) Expected result: - When searching for Python modules, functions, builtins, etc. on the Web, no search results for Python 2 should pop up at all if the same content exists for Python 3 Possible implementation: - Add a "noindex" meta tag to the header of the generated HTML documentation - see https://support.google.com/webmasters/answer/93710 -- messages: 364597 nosy: bittner priority: normal severity: normal status: open title: Avoid Python 2 documentation to appear in Web search results type: enhancement versions: Python 2.7 ___ Python tracker <https://bugs.python.org/issue40012> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue39383] Mention Darwin as a potential value for platform.system()
New submission from Peter Bittner : The platform module's documentation mentions 'Linux', 'Windows' and 'Java' explicitly as values for `platform.system()`. https://docs.python.org/3/library/platform.html#platform.system Given the popularity of macOS among developers, this gives the impression that the module won't detect 'Darwin' as a separate system type; developers may suspect this will be identified also as a "Linux-y" system (or so). Hence, 'Darwin' should be mentioned explicitly as one of the possible values. -- assignee: docs@python components: Documentation messages: 360248 nosy: bittner, docs@python priority: normal pull_requests: 17448 severity: normal status: open title: Mention Darwin as a potential value for platform.system() type: enhancement versions: Python 3.9 ___ Python tracker <https://bugs.python.org/issue39383> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue38623] Python documentation should mention how to find site-packages
Peter Bittner added the comment: Python learners deserve to know about "site-packages" and (optionally) "dist-packages". This is a "random note", it's an explanation that is missing in the tutorial. - Site-packages "is the target directory of manually built Python packages", does someone explain.[4] - It is the "expected convention for locally installed packages", explains Greg Ward in "Installing Python Modules".[5] - Their location is only a subset of `sys.path`, as visible from the Python code in the `site` module.[6] The tutorial currently mentions its special role only briefly [7], saying: > * The installation-dependent default. We should explain that part. I'll give it a shot replacing my earlier proposal. [4] https://stackoverflow.com/questions/31384639/what-is-pythons-site-packages-directory [5] https://docs.python.org/3.8/install/#modifying-python-s-search-path [6] https://github.com/python/cpython/blob/master/Lib/site.py#L319-L344 [7] https://docs.python.org/3.8/tutorial/modules.html?highlight=installation-dependent%20default#the-module-search-path -- ___ Python tracker <https://bugs.python.org/issue38623> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue38623] Python documentation should mention how to find site-packages
Peter Bittner added the comment: There is a specific question this change attempts to answer: "Where is the module I imported located in the file system?" I suspect this comes up a lot because developers want to inspect or mess with installed modules, add debug output and the like, to understand some of their development issues better. The site module documentation explains the details.[3] The paragraph the change adds links to that documentation. That should be sufficient (for a tutorial); other technical details probably fit well in the document being linked to. [3] https://docs.python.org/3/library/site.html#site.getusersitepackages I tried to keep it concise, adding value with a quick glance over the `site` module features that relate to the module paths topic. -- ___ Python tracker <https://bugs.python.org/issue38623> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue38623] Python documentation should mention how to find site-packages
Change by Peter Bittner : -- keywords: +patch pull_requests: +16500 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16974 ___ Python tracker <https://bugs.python.org/issue38623> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue38623] Python documentation should mention how to find site-packages
New submission from Peter Bittner : A popular question on StackOverflow is, "How do I find the location of my Python site-packages directory?" [1] While this may hint at a deeper problem that needs to be solved, a user suggested [2] the accepted answer to be added to Python's official documentation. The most appropriate place I could find to add related information is ``Doc/tutorial/modules.rst``. [1] https://stackoverflow.com/questions/122327/how-do-i-find-the-location-of-my-python-site-packages-directory/46071447 [2] https://stackoverflow.com/questions/122327/how-do-i-find-the-location-of-my-python-site-packages-directory/46071447#comment103247041_46071447 -- assignee: docs@python components: Documentation messages: 355599 nosy: bittner, docs@python priority: normal severity: normal status: open title: Python documentation should mention how to find site-packages type: enhancement versions: Python 2.7, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue38623> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com