From unknown Sat Jun 21 03:27:34 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#21375 <21375@debbugs.gnu.org> To: bug#21375 <21375@debbugs.gnu.org> Subject: Status: 25.0.50; Python tests fail on MS-Windows -- portability issues Reply-To: bug#21375 <21375@debbugs.gnu.org> Date: Sat, 21 Jun 2025 10:27:34 +0000 retitle 21375 25.0.50; Python tests fail on MS-Windows -- portability issues reassign 21375 emacs submitter 21375 Eli Zaretskii severity 21375 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Aug 29 08:13:42 2015 Received: (at submit) by debbugs.gnu.org; 29 Aug 2015 12:13:42 +0000 Received: from localhost ([127.0.0.1]:42021 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVf0v-0005c5-Vd for submit@debbugs.gnu.org; Sat, 29 Aug 2015 08:13:42 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41158) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVf0t-0005bx-7d for submit@debbugs.gnu.org; Sat, 29 Aug 2015 08:13:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZVf0r-0004Pp-EF for submit@debbugs.gnu.org; Sat, 29 Aug 2015 08:13:39 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:53959) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVf0r-0004Pl-Ax for submit@debbugs.gnu.org; Sat, 29 Aug 2015 08:13:37 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51157) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVf0p-00059Q-GL for bug-gnu-emacs@gnu.org; Sat, 29 Aug 2015 08:13:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZVf0l-0004OU-D6 for bug-gnu-emacs@gnu.org; Sat, 29 Aug 2015 08:13:35 -0400 Received: from mtaout29.012.net.il ([80.179.55.185]:49017) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVf0k-0004OE-Uk; Sat, 29 Aug 2015 08:13:31 -0400 Received: from conversion-daemon.mtaout29.012.net.il by mtaout29.012.net.il (HyperSendmail v2007.08) id <0NTU00400EPKH500@mtaout29.012.net.il>; Sat, 29 Aug 2015 15:13:42 +0300 (IDT) Received: from HOME-C4E4A596F7 ([84.94.185.246]) by mtaout29.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NTU002ETFATRS30@mtaout29.012.net.il>; Sat, 29 Aug 2015 15:13:42 +0300 (IDT) Date: Sat, 29 Aug 2015 15:13:33 +0300 From: Eli Zaretskii Subject: 25.0.50; Python tests fail on MS-Windows -- portability issues To: bug-gnu-emacs@gnu.org, =?iso-8859-1?Q?Fabi=E1n?= Ezequiel Gallina Message-id: <83d1y62sya.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-transfer-encoding: QUOTED-PRINTABLE X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -6.0 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) As I reported in the past, some Python tests fail on MS-Windows. 13 of them, to be more accurate. The changes below reduce those 13 to just 4. The main problems fixed by these changes are: (a) the assumption that "/foo" is an absolute file name that expand-file-name cannot possibly change, and (b) use of a literal ':' character is PATH-style lists of directories. Also, one of the failures was because python-shell-calculate-command always quotes the interpreter's file name on MS-Windows, which the test didn't expect. Fabi=E1n, if these are OK with you, I will commit them. I will file a separate bug about the other 4 failures, as I need help there in figuring out how to fix them. Thanks. Here are the proposed changes, relative to today's master: diff --git a/test/automated/python-tests.el b/test/automated/python-t= ests.el index 30b1b48..219f99e 100644 --- a/test/automated/python-tests.el +++ b/test/automated/python-tests.el @@ -2436,7 +2436,7 @@ (ert-deftest python-shell-calculate-command-1 (= ) (python-shell-interpreter-args "-B")) (should (string=3D (format "%s %s" - python-shell-interpreter + (shell-quote-argument python-shell-interpreter) python-shell-interpreter-args) (python-shell-calculate-command))))) =20 @@ -2445,14 +2445,17 @@ (ert-deftest python-shell-calculate-pythonpat= h-1 () (let ((process-environment '("PYTHONPATH=3D/path0")) (python-shell-extra-pythonpaths '("/path1" "/path2"))) (should (string=3D (python-shell-calculate-pythonpath) - "/path1:/path2:/path0")))) + (concat "/path1" path-separator + "/path2" path-separator "/path0"))))) =20 (ert-deftest python-shell-calculate-pythonpath-2 () "Test existing paths are moved to front." - (let ((process-environment '("PYTHONPATH=3D/path0:/path1")) + (let ((process-environment + (list (concat "PYTHONPATH=3D/path0" path-separator "/path1"= ))) (python-shell-extra-pythonpaths '("/path1" "/path2"))) (should (string=3D (python-shell-calculate-pythonpath) - "/path1:/path2:/path0")))) + (concat "/path1" path-separator + "/path2" path-separator "/path0"))))) =20 (ert-deftest python-shell-calculate-process-environment-1 () "Test `python-shell-process-environment' modification." @@ -2468,7 +2471,9 @@ (ert-deftest python-shell-calculate-process-env= ironment-2 () (original-pythonpath (setenv "PYTHONPATH" "/path0")) (python-shell-extra-pythonpaths '("/path1" "/path2")) (process-environment (python-shell-calculate-process-enviro= nment))) - (should (equal (getenv "PYTHONPATH") "/path1:/path2:/path0")))) + (should (equal (getenv "PYTHONPATH") + (concat "/path1" path-separator + "/path2" path-separator "/path0"))))) =20 (ert-deftest python-shell-calculate-process-environment-3 () "Test `python-shell-virtualenv-root' modification." @@ -2545,7 +2550,8 @@ (ert-deftest python-shell-calculate-exec-path-2= () (let* ((exec-path '("/path0")) (python-shell-virtualenv-root "/env") (new-exec-path (python-shell-calculate-exec-path))) - (should (equal new-exec-path '("/env/bin" "/path0"))))) + (should (equal new-exec-path + (list (expand-file-name "/env/bin") "/path0"))))) =20 (ert-deftest python-shell-calculate-exec-path-3 () "Test complete `python-shell-virtualenv-root' modification." @@ -2553,7 +2559,9 @@ (ert-deftest python-shell-calculate-exec-path-3= () (python-shell-exec-path '("/path1" "/path2")) (python-shell-virtualenv-root "/env") (new-exec-path (python-shell-calculate-exec-path))) - (should (equal new-exec-path '("/env/bin" "/path1" "/path2" "/pa= th0"))))) + (should (equal new-exec-path + (list (expand-file-name "/env/bin") + "/path1" "/path2" "/path0"))))) =20 (ert-deftest python-shell-calculate-exec-path-4 () "Test complete `python-shell-virtualenv-root' with remote." @@ -2562,7 +2570,9 @@ (ert-deftest python-shell-calculate-exec-path-4= () (python-shell-exec-path '("/path1" "/path2")) (python-shell-virtualenv-root "/env") (new-exec-path (python-shell-calculate-exec-path))) - (should (equal new-exec-path '("/env/bin" "/path1" "/path2" "/pa= th0"))))) + (should (equal new-exec-path + (list (expand-file-name "/env/bin") + "/path1" "/path2" "/path0"))))) =20 (ert-deftest python-shell-calculate-exec-path-5 () "Test no side-effects on `exec-path'." @@ -2590,7 +2600,9 @@ (ert-deftest python-shell-with-environment-1 () (original-exec-path exec-path) (python-shell-virtualenv-root "/env")) (python-shell-with-environment - (should (equal exec-path '("/env/bin" "/path1" "/path2" "/path= 0"))) + (should (equal exec-path + (list (expand-file-name "/env/bin") + "/path1" "/path2" "/path0"))) (should (not (getenv "PYTHONHOME"))) (should (string=3D (getenv "VIRTUAL_ENV") "/env"))) (should (equal exec-path original-exec-path)))) @@ -2605,7 +2617,8 @@ (ert-deftest python-shell-with-environment-2 () (python-shell-virtualenv-root "/env")) (python-shell-with-environment (should (equal (python-shell-calculate-exec-path) - '("/env/bin" "/path1" "/path2" "/remote1" "/rem= ote2"))) + (list (expand-file-name "/env/bin") + "/path1" "/path2" "/remote1" "/remote2"))= ) (let ((process-environment (python-shell-calculate-process-env= ironment))) (should (not (getenv "PYTHONHOME"))) (should (string=3D (getenv "VIRTUAL_ENV") "/env")) In GNU Emacs 25.0.50.384 (i686-pc-mingw32) of 2015-08-29 Repository revision: 5e63c842007b0f85e91735a7c4e00be0b7fe9ba5 Windowing system distributor `Microsoft Corp.', version 5.1.2600 Configured using: `configure --prefix=3D/d/usr --enable-checking=3Dyes,glyphs --with-w= ide-int 'CFLAGS=3D-gdwarf-4 -g3 -O0'' Configured features: XPM JPEG TIFF GIF PNG RSVG SOUND NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS Important settings: value of $LANG: ENU locale-coding-system: cp1255 Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Load-path shadows: None found. Features: (shadow sort gnus-util mail-extr emacsbug message dired format-spec rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util help-fns help-mode easymenu cl-loaddefs pcase cl-lib mail-prs= vr mail-utils time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel dos-w32 ls-lisp disp-table w32-win w32-vars term/common-win tool-bar dnd fontset image regexp-op= t fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode regis= ter page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote w32notify w32 multi-tty make-network-process emacs) Memory information: ((conses 16 84975 6948) (symbols 56 19924 0) (miscs 48 36 107) (strings 16 15967 5012) (string-bytes 1 393017) (vectors 16 11212) (vector-slots 8 402827 5209) (floats 8 125 127) (intervals 40 260 63) (buffers 856 11)) From debbugs-submit-bounces@debbugs.gnu.org Sat Aug 29 09:51:47 2015 Received: (at submit) by debbugs.gnu.org; 29 Aug 2015 13:51:47 +0000 Received: from localhost ([127.0.0.1]:42041 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVgXr-0008TA-0t for submit@debbugs.gnu.org; Sat, 29 Aug 2015 09:51:47 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41543) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVgXo-0008Sz-2B for submit@debbugs.gnu.org; Sat, 29 Aug 2015 09:51:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZVgXm-0007DS-G1 for submit@debbugs.gnu.org; Sat, 29 Aug 2015 09:51:43 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:33668) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVgXm-0007DJ-Ds for submit@debbugs.gnu.org; Sat, 29 Aug 2015 09:51:42 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51528) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVgXl-0000Gn-HP for bug-gnu-emacs@gnu.org; Sat, 29 Aug 2015 09:51:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZVgXg-00079g-7z for bug-gnu-emacs@gnu.org; Sat, 29 Aug 2015 09:51:41 -0400 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49685) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZVgXg-00079a-56 for bug-gnu-emacs@gnu.org; Sat, 29 Aug 2015 09:51:36 -0400 Received: from [190.246.172.180] (port=59996 helo=localhost) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1ZVgXf-0003Ih-8x; Sat, 29 Aug 2015 09:51:35 -0400 From: fgallina@gnu.org (=?utf-8?Q?Fabi=C3=A1n?= Ezequiel Gallina) To: Eli Zaretskii Subject: Re: 25.0.50; Python tests fail on MS-Windows -- portability issues References: <83d1y62sya.fsf@gnu.org> Date: Sat, 29 Aug 2015 10:51:30 -0300 In-Reply-To: <83d1y62sya.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 29 Aug 2015 15:13:33 +0300") Message-ID: <877foejj8d.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -6.0 (------) X-Debbugs-Envelope-To: submit Cc: bug-gnu-emacs@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) Eli Zaretskii writes: > As I reported in the past, some Python tests fail on MS-Windows. 13 > of them, to be more accurate. The changes below reduce those 13 to > just 4. > > The main problems fixed by these changes are: (a) the assumption that > "/foo" is an absolute file name that expand-file-name cannot possibly > change, and (b) use of a literal ':' character is PATH-style lists of > directories. Also, one of the failures was because > python-shell-calculate-command always quotes the interpreter's file > name on MS-Windows, which the test didn't expect. > > Fabi=C3=A1n, if these are OK with you, I will commit them. > > I will file a separate bug about the other 4 failures, as I need help > there in figuring out how to fix them. > Hi Eli, Patch looks good, please install. Thanks for taking care of this. Fabi=C3=A1n. From debbugs-submit-bounces@debbugs.gnu.org Sat Aug 29 10:42:03 2015 Received: (at 21375-done) by debbugs.gnu.org; 29 Aug 2015 14:42:03 +0000 Received: from localhost ([127.0.0.1]:42191 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVhKU-0001MO-QG for submit@debbugs.gnu.org; Sat, 29 Aug 2015 10:42:03 -0400 Received: from mtaout26.012.net.il ([80.179.55.182]:35773) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVhKR-0001Lw-8y for 21375-done@debbugs.gnu.org; Sat, 29 Aug 2015 10:42:00 -0400 Received: from conversion-daemon.mtaout26.012.net.il by mtaout26.012.net.il (HyperSendmail v2007.08) id <0NTU00700LOEOA00@mtaout26.012.net.il> for 21375-done@debbugs.gnu.org; Sat, 29 Aug 2015 17:44:03 +0300 (IDT) Received: from HOME-C4E4A596F7 ([84.94.185.246]) by mtaout26.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NTU007HTM9EE420@mtaout26.012.net.il>; Sat, 29 Aug 2015 17:44:03 +0300 (IDT) Date: Sat, 29 Aug 2015 17:42:03 +0300 From: Eli Zaretskii Subject: Re: 25.0.50; Python tests fail on MS-Windows -- portability issues In-reply-to: <877foejj8d.fsf@gnu.org> X-012-Sender: halo1@inter.net.il To: fgallina@gnu.org (=?utf-8?Q?Fabi=C3=A1n?= Ezequiel Gallina) Message-id: <838u8u2m2s.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-transfer-encoding: 8BIT References: <83d1y62sya.fsf@gnu.org> <877foejj8d.fsf@gnu.org> X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: 21375-done Cc: 21375-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.0 (+) > From: fgallina@gnu.org (Fabián Ezequiel Gallina) > Cc: bug-gnu-emacs@gnu.org > Date: Sat, 29 Aug 2015 10:51:30 -0300 > > Eli Zaretskii writes: > > > As I reported in the past, some Python tests fail on MS-Windows. 13 > > of them, to be more accurate. The changes below reduce those 13 to > > just 4. > > > > The main problems fixed by these changes are: (a) the assumption that > > "/foo" is an absolute file name that expand-file-name cannot possibly > > change, and (b) use of a literal ':' character is PATH-style lists of > > directories. Also, one of the failures was because > > python-shell-calculate-command always quotes the interpreter's file > > name on MS-Windows, which the test didn't expect. > > > > Fabián, if these are OK with you, I will commit them. > > > > I will file a separate bug about the other 4 failures, as I need help > > there in figuring out how to fix them. > > > > Hi Eli, > > Patch looks good, please install. Done as master commit 57e1205. > Thanks for taking care of this. You are welcome. I'm closing this bug. From unknown Sat Jun 21 03:27:34 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 27 Sep 2015 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator