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.

Author JDLH
Recipients JDLH
Date 2017-02-15.02:19:32
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1487125173.78.0.785382984644.issue29562@psf.upfronthosting.co.za>
In-reply-to
Content
I have pushed a branch for this issue to my cpython fork:

https://github.com/JDLH/cpython/tree/bpo-29562_failing_test_getgroups_on_os_x

It modifies test_getgroups in test_posix.py to give better diagnostics in the event of a test failure. It says specifically which groups were in id -G, and posix.getgroups(), but not in the other.

% ./python.exe -m unittest -v test.test_posix.PosixTester.test_getgroups 
test_getgroups (test.test_posix.PosixTester) ... FAIL

======================================================================
FAIL: test_getgroups (test.test_posix.PosixTester)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/jdlh/workspace/cpython/Lib/test/test_posix.py", line 841, in test_getgroups
    self.assertEqual(len(symdiff), 0, msg)
AssertionError: 2 != 0 : id -G and posix.groups() should have zero difference.
Groups in id -G but not posix.groups(): [(701, 'com.apple.sharepoint.group.1'), (398, 'com.apple.access_screensharing')]
Groups in posix.groups() but not id -G: []
(Effective GID (20) was disregarded.)

----------------------------------------------------------------------
Ran 1 test in 0.020s

I don't think this branch is ready yet to submit to the main codebase, but it may help people diagnose the issue.
History
Date User Action Args
2017-02-15 02:19:33JDLHsetrecipients: + JDLH
2017-02-15 02:19:33JDLHsetmessageid: <1487125173.78.0.785382984644.issue29562@psf.upfronthosting.co.za>
2017-02-15 02:19:33JDLHlinkissue29562 messages
2017-02-15 02:19:32JDLHcreate