Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 41ea1f4

Browse files
committed
Closes #19342: improve docstrings in grp module.
1 parent ea7ec2b commit 41ea1f4

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

Modules/grpmodule.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -152,11 +152,11 @@ grp_getgrall(PyObject *self, PyObject *ignore)
152152

153153
static PyMethodDef grp_methods[] = {
154154
{"getgrgid", grp_getgrgid, METH_O,
155-
"getgrgid(id) -> tuple\n\
155+
"getgrgid(id) -> (gr_name,gr_passwd,gr_gid,gr_mem)\n\
156156
Return the group database entry for the given numeric group ID. If\n\
157157
id is not valid, raise KeyError."},
158158
{"getgrnam", grp_getgrnam, METH_VARARGS,
159-
"getgrnam(name) -> tuple\n\
159+
"getgrnam(name) -> (gr_name,gr_passwd,gr_gid,gr_mem)\n\
160160
Return the group database entry for the given group name. If\n\
161161
name is not valid, raise KeyError."},
162162
{"getgrall", grp_getgrall, METH_NOARGS,
@@ -173,10 +173,10 @@ PyDoc_STRVAR(grp__doc__,
173173
Group entries are reported as 4-tuples containing the following fields\n\
174174
from the group database, in order:\n\
175175
\n\
176-
name - name of the group\n\
177-
passwd - group password (encrypted); often empty\n\
178-
gid - numeric ID of the group\n\
179-
mem - list of members\n\
176+
gr_name - name of the group\n\
177+
gr_passwd - group password (encrypted); often empty\n\
178+
gr_gid - numeric ID of the group\n\
179+
gr_mem - list of members\n\
180180
\n\
181181
The gid is an integer, name and password are strings. (Note that most\n\
182182
users are not explicitly listed as members of the groups they are in\n\

0 commit comments

Comments
 (0)