Content-Length: 270065 | pFad | https://github.com/python/cpython/commit/22af5d35a620ee44393853036a8450ceb047688e

49 gh-127146: Emscripten: Set umask to zero in python.sh (#136740) · python/cpython@22af5d3 · GitHub
Skip to content

Commit 22af5d3

Browse files
authored
gh-127146: Emscripten: Set umask to zero in python.sh (#136740)
Clears the umask used during a test of pydoc.apropos when testing on Emscripten. This is to work around a known issue in Emscripten; but it's not clear if the chmod call that is causing the problem is actually testing anything of significance.
1 parent 180b3eb commit 22af5d3

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Lib/test/test_pydoc/test_pydoc.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1303,6 +1303,11 @@ def test_apropos_with_unreadable_dir(self):
13031303
@os_helper.skip_unless_working_chmod
13041304
def test_apropos_empty_doc(self):
13051305
pkgdir = os.path.join(TESTFN, 'walkpkg')
1306+
if support.is_emscripten:
1307+
# Emscripten's readdir implementation is buggy on directories
1308+
# with read permission but no execute permission.
1309+
old_umask = os.umask(0)
1310+
self.addCleanup(os.umask, old_umask)
13061311
os.mkdir(pkgdir)
13071312
self.addCleanup(rmtree, pkgdir)
13081313
init_path = os.path.join(pkgdir, '__init__.py')

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/python/cpython/commit/22af5d35a620ee44393853036a8450ceb047688e

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy