From 77b70ba193fe52ba43c5e0c8f834b9eaa1674e44 Mon Sep 17 00:00:00 2001 From: Justine Tunney Date: Fri, 13 May 2022 05:05:27 -0700 Subject: [PATCH] Add fixes to previous commit --- third_party/python/Lib/mailbox.py | 5 +++-- third_party/python/Lib/test/test_gzip.py | 5 +++-- third_party/python/python.mk | 1 + 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/third_party/python/Lib/mailbox.py b/third_party/python/Lib/mailbox.py index 39f24f9a7..0ebf97d11 100644 --- a/third_party/python/Lib/mailbox.py +++ b/third_party/python/Lib/mailbox.py @@ -2121,8 +2121,9 @@ def _create_temporary(path): def _sync_flush(f): """Ensure changes to file f are physically on disk.""" f.flush() - if hasattr(os, 'fsync'): - os.fsync(f.fileno()) + # TODO(jart): Why does this need fsync() lool? + #if hasattr(os, 'fsync'): + # os.fsync(f.fileno()) def _sync_close(f): """Close file f, ensuring all changes are physically on disk.""" diff --git a/third_party/python/Lib/test/test_gzip.py b/third_party/python/Lib/test/test_gzip.py index 60150cfd0..eaaebcef6 100644 --- a/third_party/python/Lib/test/test_gzip.py +++ b/third_party/python/Lib/test/test_gzip.py @@ -71,8 +71,9 @@ class TestGzip(BaseTest): # Try flush and fileno. f.flush() f.fileno() - if hasattr(os, 'fsync'): - os.fsync(f.fileno()) + # TODO(jart): Why does this need fsync()? + #if hasattr(os, 'fsync'): + # os.fsync(f.fileno()) f.close() # Test multiple close() calls. diff --git a/third_party/python/python.mk b/third_party/python/python.mk index 5ec41cbe7..f286c192b 100644 --- a/third_party/python/python.mk +++ b/third_party/python/python.mk @@ -4207,6 +4207,7 @@ o/$(MODE)/third_party/python/Lib/test/test_tarfile.py.runs: QUOTA = -L120 -C64 o/$(MODE)/third_party/python/Lib/test/test_sqlite.py.runs: QUOTA = -L120 o/$(MODE)/third_party/python/Lib/test/test_gzip.py.runs: QUOTA = -L120 o/$(MODE)/third_party/python/Lib/test/test_logging.py.runs: QUOTA = -M512m +o/$(MODE)/third_party/python/Lib/test/test_resource.py.runs: QUOTA = -C1000000 o/$(MODE)/third_party/python/Lib/test/test_email/test_email.py.runs: QUOTA = -C32 -M1024m THIRD_PARTY_PYTHON_LIBS = \