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: test_getgroups failure under Solaris
Type: behavior Stage: resolved
Components: Tests Versions: Python 3.1, Python 3.2, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: jcea, laca, pitrou, ronaldoussoren, rosslagerwall
Priority: normal Keywords: patch

Created on 2011-01-04 11:08 by pitrou, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
10822.patch rosslagerwall, 2011-01-11 06:52 Fix test
Messages (5)
msg125303 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2011-01-04 11:08
Under OpenSolaris, I get the following failure:

$ pfexec ./python -m test test_posix
[1/1] test_posix
test test_posix failed -- Traceback (most recent call last):
  File "/home/antoine/py3k/cc/Lib/test/test_posix.py", line 402, in test_getgroups
    set(posix.getgroups()))
AssertionError: Items in the first set but not the second:
0
msg125984 - (view) Author: Ross Lagerwall (rosslagerwall) (Python committer) Date: 2011-01-11 06:52
It seems to work fine on OpenIndiana (running normally or as root).

According to the posix specification, "It is implementation-defined whether getgroups() also returns the effective group ID in the grouplist array."

But, id -G prints all group IDs. Perhaps, it failed because 0 was the effective gid & it was included by "id -G" but wasn't being returned by posix.getgroups().

This fix changes the test to compare the output from "id -G" with the union of getgroups() & getegid().
msg126125 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2011-01-12 18:58
Thanks for the patch! Committed in r87958 (3.2), r87959 (3.1) and r87961 (2.7).
msg126775 - (view) Author: Jesús Cea Avión (jcea) * (Python committer) Date: 2011-01-21 19:33
Antoine, can you confirm that the problem is solved, and mark this issue as closed/fixed?.

Thanks.
msg126777 - (view) Author: Jesús Cea Avión (jcea) * (Python committer) Date: 2011-01-21 19:38
Sorry, Firefox insists in cache-ing the tracker, with bad results.

I beg your pardon.
History
Date User Action Args
2022-04-11 14:57:10adminsetgithub: 55031
2011-01-21 19:38:07jceasetstatus: open -> closed

nosy: + rosslagerwall
messages: + msg126777

resolution: fixed
stage: needs patch -> resolved
2011-01-21 19:33:03jceasetstatus: closed -> open

nosy: - rosslagerwall
messages: + msg126775

resolution: fixed -> (no value)
stage: resolved -> needs patch
2011-01-12 18:58:12pitrousetstatus: open -> closed
nosy: jcea, ronaldoussoren, pitrou, laca, rosslagerwall
messages: + msg126125

resolution: fixed
stage: needs patch -> resolved
2011-01-11 06:52:49rosslagerwallsetfiles: + 10822.patch

messages: + msg125984
keywords: + patch
nosy: jcea, ronaldoussoren, pitrou, laca, rosslagerwall
2011-01-10 19:58:40rosslagerwallsetnosy: + rosslagerwall
2011-01-04 11:08:34pitroucreate