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: Documentation for socket.getfqdn incorrect?
Type: Stage: resolved
Components: Documentation Versions: Python 3.11, Python 3.10, Python 3.9
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: andrei.avk, cherdt, christian.heimes, docs@python, lukasz.langa, miss-islington
Priority: normal Keywords: patch

Created on 2020-05-15 17:02 by cherdt, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 27971 merged andrei.avk, 2021-08-26 13:09
PR 27977 merged miss-islington, 2021-08-26 18:40
PR 27978 merged miss-islington, 2021-08-26 18:40
Messages (4)
msg368960 - (view) Author: Chris Herdt (cherdt) Date: 2020-05-15 17:02
The documentation for socket.getfqdn() includes this info:

"In case no fully qualified domain name is available, the hostname as returned by gethostname() is returned."

However, that does not appear to be correct. To reproduce a case that exhibits contrary behavior:

>>> import socket
>>> socket.getfqdn("test")
'test'
>>> socket.gethostname()
'centos7minimal.osric.net'
msg400365 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-08-26 18:40
New changeset fdcb675eed47b1f6054fae381af4388b16a6fff4 by andrei kulakov in branch 'main':
bpo-40635: Fix getfqdn() docstring and docs (GH-27971)
https://github.com/python/cpython/commit/fdcb675eed47b1f6054fae381af4388b16a6fff4
msg400375 - (view) Author: miss-islington (miss-islington) Date: 2021-08-26 19:55
New changeset 719af92e108ea3b31729cb09077673b8f13905d2 by Miss Islington (bot) in branch '3.10':
bpo-40635: Fix getfqdn() docstring and docs (GH-27971)
https://github.com/python/cpython/commit/719af92e108ea3b31729cb09077673b8f13905d2
msg400376 - (view) Author: miss-islington (miss-islington) Date: 2021-08-26 19:55
New changeset f1e3fc4631da5e6ca1ea047c82bd9b42db9dd9ae by Miss Islington (bot) in branch '3.9':
bpo-40635: Fix getfqdn() docstring and docs (GH-27971)
https://github.com/python/cpython/commit/f1e3fc4631da5e6ca1ea047c82bd9b42db9dd9ae
History
Date User Action Args
2022-04-11 14:59:31adminsetgithub: 84815
2021-08-26 19:56:07lukasz.langasetstatus: open -> closed
stage: patch review -> resolved
resolution: fixed
versions: + Python 3.9, Python 3.10, Python 3.11, - Python 3.6
2021-08-26 19:55:31miss-islingtonsetmessages: + msg400376
2021-08-26 19:55:00miss-islingtonsetmessages: + msg400375
2021-08-26 18:40:41miss-islingtonsetpull_requests: + pull_request26426
2021-08-26 18:40:37miss-islingtonsetnosy: + miss-islington
pull_requests: + pull_request26425
2021-08-26 18:40:31lukasz.langasetnosy: + lukasz.langa
messages: + msg400365
2021-08-26 13:09:21andrei.avksetkeywords: + patch
nosy: + andrei.avk

pull_requests: + pull_request26418
stage: patch review
2020-05-16 00:18:57nanjekyejoannahsetnosy: + christian.heimes
2020-05-15 17:02:26cherdtcreate