From e02a16a7d103b6af0543bba6919662f31434b4cb Mon Sep 17 00:00:00 2001 From: William Deegan Date: Mon, 15 Jun 2020 20:27:44 -0700 Subject: Fix Issue #3628 - limit pickle protocol to 4 --- CHANGES.txt | 2 ++ SCons/compat/__init__.py | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 4921fe6..ea6b2b3 100755 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -56,6 +56,8 @@ RELEASE VERSION/DATE TO BE FILLED IN LATER - Add CompilationDatabase() builder in compilation_db tool. Contributed by MongoDB. Setting COMPILATIONDB_USE_ABSPATH to True|False controls whether the files are absolute or relative paths. Address Issue #3693 and #3694 found during development. + - Fixed Github Issue 3628 - Hardcoding pickle protocol to 4 (supports python 3.4+) + and skipping Python 3.8's new pickle protocol 5 whose main advantage is for out-of-band data buffers From Andrii Doroshenko: - Extended `Environment.Dump()` to select a format to serialize construction variables (pretty, json). diff --git a/SCons/compat/__init__.py b/SCons/compat/__init__.py index abf663d..9fb4898 100644 --- a/SCons/compat/__init__.py +++ b/SCons/compat/__init__.py @@ -84,8 +84,9 @@ def rename_module(new, old): import pickle # Was pickle.HIGHEST_PROTOCOL -# Changed to 2 so py3.5+'s pickle will be compatible with py2.7. -PICKLE_PROTOCOL = pickle.HIGHEST_PROTOCOL +# Changed to 4 so that python 3.8's not incompatible with previous versions +# Python 3.8 introduced protocol 5 which is mainly an improvement for for out-of-band data buffers +PICKLE_PROTOCOL = 4 import shutil try: -- cgit v0.12