Package Details: python2 2.7.18-14

Git Clone URL: https://aur.archlinux.org/python2.git (read-only, click to copy)
Package Base: python2
Description: A high-level scripting language
Upstream URL: https://www.python.org/
Licenses: PSF-2.0
Conflicts: python
Submitter: jelly
Maintainer: andreas_baumann
Last Packager: andreas_baumann
Votes: 76
Popularity: 0.107333
First Submitted: 2022-09-23 10:01 (UTC)
Last Updated: 2026-05-07 08:44 (UTC)

Required by (739)

Sources (4)

Pinned Comments

Latest Comments

1 2 3 4 5 6 .. 21 Next › Last »

andreas_baumann commented on 2026-05-13 14:33 (UTC) (edited on 2026-05-13 14:33 (UTC) by andreas_baumann)

Actually, I added the patches locally and fixed a test, see https://aur.archlinux.org/cgit/aur.git/log/?h=python2 somehow the AUR currently doesn't show the correct current PKGBUILD?

stef204 commented on 2026-05-09 03:27 (UTC) (edited on 2026-05-09 03:38 (UTC) by stef204)

Here is a link to a modified PKGBUILD which should compile successfully (it includes the url to the patches which @cedric-air posted); I've tested it:

https://paste.xinu.at/dEKoXj/

The patches download properly. The PKGBUILD will take care of that.

If you want the patches to create your own PKGBUILD, you can do:

curl -L "https://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/pub/proj/python/patchsets/2.7/python-gentoo-patches-2.7.18_p16.tar.xz" -o python-gentoo-patches-2.7.18_p16.tar.xz

patlefort commented on 2026-05-09 01:56 (UTC)

Gentoo patches fails to download. pokes

cedric-air commented on 2026-05-07 07:20 (UTC)

It seems the gentoo patches can be downloaded here: https://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/pub/proj/python/patchsets/2.7/

gschwarz commented on 2026-04-26 10:40 (UTC)

Building fails because the python Gentoo patches cannot be downloaded.

micwoj92 commented on 2025-07-21 20:25 (UTC)

@nroth no issues here. "Python 2 on Arch" already ended and this package is only on life support with each day less and less packages requiring it.

nroth commented on 2025-07-16 01:22 (UTC)

Looks like something to do with network access is at least partially broken in Python 2.7 on some systems, which breaks the build. Feel free to correct me if I'm wrong or if anyone has a fix.

For now, installing/updating with yay -S python2 --mflags "--nocheck" works, but network access and URL processing apparently do not work as expected. This will also not alert when additional things break.

The end of Python 2 on Arch seems imminent, unless someone wants to step in to fix this.

nroth commented on 2025-07-16 00:57 (UTC)

First failure:

test_ftp_basic (test.test_urllib2net.TimeoutTest) ... ERROR
test_ftp_default_timeout (test.test_urllib2net.TimeoutTest) ... ERROR
test_ftp_no_timeout (test.test_urllib2net.TimeoutTest) ... ERROR
test_ftp_timeout (test.test_urllib2net.TimeoutTest) ... ERROR
test_http_basic (test.test_urllib2net.TimeoutTest) ... ok
test_http_default_timeout (test.test_urllib2net.TimeoutTest) ... ok
test_http_no_timeout (test.test_urllib2net.TimeoutTest) ... ok
test_http_timeout (test.test_urllib2net.TimeoutTest) ... ok

======================================================================
ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 300, in test_ftp_basic
    u = _urlopen_with_retry(self.FTP_HOST)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 25, in wrapped
    return _retry_thrice(func, exc, *args, **kwargs)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 21, in _retry_thrice
    raise last_exc
URLError: <urlopen error ftp error: [Errno 101] Network is unreachable>

======================================================================
ERROR: test_ftp_default_timeout (test.test_urllib2net.TimeoutTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 309, in test_ftp_default_timeout
    u = _urlopen_with_retry(self.FTP_HOST)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 25, in wrapped
    return _retry_thrice(func, exc, *args, **kwargs)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 21, in _retry_thrice
    raise last_exc
URLError: <urlopen error ftp error: [Errno 101] Network is unreachable>

======================================================================
ERROR: test_ftp_no_timeout (test.test_urllib2net.TimeoutTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 320, in test_ftp_no_timeout
    u = _urlopen_with_retry(self.FTP_HOST, timeout=None)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 25, in wrapped
    return _retry_thrice(func, exc, *args, **kwargs)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 21, in _retry_thrice
    raise last_exc
URLError: <urlopen error ftp error: [Errno 101] Network is unreachable>

======================================================================
ERROR: test_ftp_timeout (test.test_urllib2net.TimeoutTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 328, in test_ftp_timeout
    u = _urlopen_with_retry(self.FTP_HOST, timeout=60)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 25, in wrapped
    return _retry_thrice(func, exc, *args, **kwargs)
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllib2net.py", line 21, in _retry_thrice
    raise last_exc
URLError: <urlopen error ftp error: [Errno 101] Network is unreachable>

----------------------------------------------------------------------
Ran 15 tests in 0.887s

FAILED (errors=4, skipped=1)
0:04:27 load avg: 1.71 [365/394/1] test_urllibnet -- test_urllib2net failed

nroth commented on 2025-07-16 00:56 (UTC) (edited on 2025-07-16 00:56 (UTC) by nroth)

Second failure:

======================================================================
FAIL: test_multiple_ftp_urlopen_same_host (test.test_urllibnet.urlopen_FTPTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/nroth/.cache/yay/python2/src/Python-2.7.18/Lib/test/test_urllibnet.py", line 245, in test_multiple_ftp_urlopen_same_host
    "Error message was: %s" % e)
AssertionError: Failed FTP binary file open. Error message was: [Errno ftp error] [Errno 101] Network is unreachable

----------------------------------------------------------------------
Ran 15 tests in 0.330s

FAILED (failures=2)
0:04:27 load avg: 1.71 [366/394/2] test_urlparse -- test_urllibnet failed

nroth commented on 2025-07-16 00:13 (UTC)

I'm getting the same issue as patriot-8891

2 tests failed:
    test_urllib2 test_urllibnet

And then the package install cancels.

Does anyone have a workaround?