New submission from Michael Felt <>:

test_mode assumes that the SGID bit is not set in the parent directory. If it 
is set the assertEqual() tests fail.

This PR checks the mode of 'base' to see if the SGID bit is set, or not, and 
compares results accordingly.

Back-porting requested.

components: Tests
messages: 323414
nosy: Michael.Felt
priority: normal
severity: normal
status: open
title: test_os.test_mode fails when directory base directory has g+s set
type: behavior
versions: Python 3.8

Python tracker <>
Python-bugs-list mailing list

Reply via email to