From mboxrd@z Thu Jan 1 00:00:00 1970 From: Diane Trout Subject: Python 3.5 start of update Date: Fri, 26 Feb 2016 21:19:40 -0800 Message-ID: <3746864.VkbyMe6eV1@myrada> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="nextPart2274828.e9NFBdRVrT" Content-Transfer-Encoding: 7Bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44503) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZXIK-0002Fn-Uz for guix-devel@gnu.org; Sat, 27 Feb 2016 00:19:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aZXIG-0003Hf-6F for guix-devel@gnu.org; Sat, 27 Feb 2016 00:19:56 -0500 Received: from chaos.caltech.edu ([131.215.34.119]:52602) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZXIG-0003HS-00 for guix-devel@gnu.org; Sat, 27 Feb 2016 00:19:52 -0500 Received: from rachel.ghic.org ([50.1.221.254] helo=myrada.ghic.org) by chaos.caltech.edu with esmtpsa (TLS1.0:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84) (envelope-from ) id 1aZXI6-0003uo-3O for guix-devel@gnu.org; Fri, 26 Feb 2016 21:19:42 -0800 List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: guix-devel@gnu.org This is a multi-part message in MIME format. --nextPart2274828.e9NFBdRVrT Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Hi, Attached is the patch I used for trying to update python 3 to 3.5. I disabled a test and added an exception handler for some code calling pwd.getpwuid(0) and the group equivalent. It builds outside of the python.scm module but if I change the version in python.scm python-minimal ends up with a link error. *** WARNING: renaming "_ctypes" since importing it failed: build/lib.linux- x86_64-3.5/_ctypes.cpython-35m-x86_64-linux-gnu.so: cannot open shared object file: No such file or directory error: [Errno 2] No such file or directory: 'build/lib.linux- x86_64-3.5/_ctypes.cpython-35m-x86_64-linux-gnu.so' -> 'build/lib.linux- x86_64-3.5/_ctypes.cpython-35m-x86_64-linux-gnu_failed.so' Makefile:608: recipe for target 'sharedmods' failed I'm currently pretty baffled by the link error as if I do --keep-failed I can get it to build with: cd /tmp/nix-builc-python-minimal-3.5.1.drv chown -R me . guix environment python-minimal cd Python-3.5.1 make Diane --nextPart2274828.e9NFBdRVrT Content-Disposition: attachment; filename="0001-Update-python-3-to-3.5.1.-Disabling-a-test-that-depe.patch" Content-Transfer-Encoding: 7Bit Content-Type: text/x-patch; charset="UTF-8"; name="0001-Update-python-3-to-3.5.1.-Disabling-a-test-that-depe.patch" >From 834e5073580c9584b8daf533da6735d9402049b8 Mon Sep 17 00:00:00 2001 From: Diane Trout Date: Fri, 26 Feb 2016 16:12:31 -0800 Subject: [PATCH] Update python 3 to 3.5.1. Disabling a test that depended on home and adding exception handling for get{pwu,grg}id(0) --- gnu/packages/patches/python-fix-tests.patch | 33 +++++++++++++++++++++++++++++ gnu/packages/python.scm | 4 ++-- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/gnu/packages/patches/python-fix-tests.patch b/gnu/packages/patches/python-fix-tests.patch index 82c1998..1762531 100644 --- a/gnu/packages/patches/python-fix-tests.patch +++ b/gnu/packages/patches/python-fix-tests.patch @@ -1,6 +1,18 @@ See the discussion about the issues fixed here at: http://bugs.python.org/issue20868 . +--- Lib/test/test_pathlib.py 2014-03-01 03:02:36.088311000 +0100 ++++ Lib/test/test_pathlib.py 2014-03-01 04:56:37.768311000 +0100 +@@ -1986,8 +1986,9 @@ + expect = set() if not support.fs_is_case_insensitive(BASE) else given + self.assertEqual(given, expect) + self.assertEqual(set(p.rglob("FILEd*")), set()) + ++ @unittest.skipIf(True, "Guix builder home is '/' which causes trouble for these tests") + def test_expanduser(self): + P = self.cls + support.import_module('pwd') + import pwd --- Lib/test/test_shutil.py 2014-03-01 03:02:36.088311000 +0100 +++ Lib/test/test_shutil.py 2014-03-01 04:56:37.768311000 +0100 @@ -1053,6 +1053,7 @@ @@ -64,6 +76,27 @@ http://bugs.python.org/issue20868 . @unittest.skipUnless(support.is_resource_enabled('network'), 'network is not enabled') def test_idna(self): + +--- Lib/test/test_tarfile.py 2016-02-24 19:22:52.597208055 +0000 ++++ Lib/test/test_tarfile.py 2016-02-24 20:50:48.941950135 +0000 +@@ -2305,11 +2305,14 @@ + try: + import pwd, grp + except ImportError: + return False +- if pwd.getpwuid(0)[0] != 'root': +- return False +- if grp.getgrgid(0)[0] != 'root': ++ try: ++ if pwd.getpwuid(0)[0] != 'root': ++ return False ++ if grp.getgrgid(0)[0] != 'root': ++ return False ++ except KeyError: + return False + return True + + --- Lib/test/_test_multiprocessing.py 2014-04-06 23:12:27.575235000 +0200 +++ Lib/test/_test_multiprocessing.py 2014-04-06 23:13:04.827235000 +0200 @@ -1016,6 +1016,7 @@ diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index b67aed0..03cc549 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -260,7 +260,7 @@ data types.") (define-public python (package (inherit python-2) - (version "3.4.3") + (version "3.5.1") (source (origin (method url-fetch) (uri (string-append "https://www.python.org/ftp/python/" @@ -274,7 +274,7 @@ data types.") (patch-flags '("-p0")) (sha256 (base32 - "1f4nm4z08sy0kqwisvv95l02crv6dyysdmx44p1mz3bn6csrdcxm")))) + "1j95yx32ggqx8jf13h3c8qfp34ixpyg8ipqcdjmn143d6q67rmf6")))) (arguments (substitute-keyword-arguments (package-arguments python-2) ((#:tests? _) #t))) (native-search-paths -- 2.6.3 --nextPart2274828.e9NFBdRVrT--