Skip to content

Commit f89f0f0

Browse files
committed
Remove official Py2 support but keep building Linux wheels for it.
1 parent 375d793 commit f89f0f0

File tree

4 files changed

+5
-65
lines changed

4 files changed

+5
-65
lines changed

.github/workflows/ci.yml

+1-8
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ jobs:
8888
steps:
8989
- uses: actions/checkout@v4
9090

91-
- name: Set up Python 3.12
91+
- name: Set up Python
9292
uses: actions/setup-python@v5
9393
with:
9494
python-version: "3.12"
@@ -126,7 +126,6 @@ jobs:
126126
matrix:
127127
os: [macos-latest, windows-latest]
128128
python-version:
129-
- "2.7"
130129
- "3.8"
131130
- "3.9"
132131
- "3.10"
@@ -135,11 +134,6 @@ jobs:
135134
- "3.13"
136135
- "3.14-dev"
137136

138-
exclude:
139-
# fails due to lack of a compatible compiler
140-
- os: windows-latest
141-
python-version: 2.7
142-
143137
runs-on: ${{ matrix.os }}
144138

145139
env:
@@ -150,7 +144,6 @@ jobs:
150144

151145
- name: Set up Python
152146
uses: actions/setup-python@v5
153-
if: startsWith(matrix.python-version, '3.')
154147
with:
155148
python-version: ${{ matrix.python-version }}
156149

README.rst

+2-54
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ code slips in accidentally.
5757
How fast is it?
5858
---------------
5959

60-
Here are some timings for Python 2.7 for the following scenarios:
60+
Here are some timings for the following scenarios:
6161

6262
1) five acquire-release cycles ('lock_unlock')
6363
2) five acquire calls followed by five release calls (nested locking, 'reentrant_lock_unlock')
@@ -71,59 +71,7 @@ substantially slower for both locks and the benchmark includes the thread
7171
creation time, so I only looped 1000x here to get useful
7272
timings instead of 100000x for the single threaded case.
7373

74-
::
75-
76-
Testing _RLock (2.7.18)
77-
78-
sequential (x100000):
79-
lock_unlock : 853.55 msec
80-
reentrant_lock_unlock : 684.52 msec
81-
mixed_lock_unlock : 758.27 msec
82-
lock_unlock_nonblocking : 860.40 msec
83-
context_manager : 2876.00 msec
84-
85-
threaded 10T (x1000):
86-
lock_unlock : 2210.69 msec
87-
reentrant_lock_unlock : 1864.38 msec
88-
mixed_lock_unlock : 1963.10 msec
89-
lock_unlock_nonblocking : 3709.91 msec
90-
context_manager : 2640.32 msec
91-
92-
Testing FastRLock (0.8.1)
93-
94-
sequential (x100000):
95-
lock_unlock : 139.76 msec
96-
reentrant_lock_unlock : 137.56 msec
97-
mixed_lock_unlock : 140.75 msec
98-
lock_unlock_nonblocking : 164.64 msec
99-
context_manager : 593.06 msec
100-
101-
threaded 10T (x1000):
102-
lock_unlock : 1621.13 msec
103-
reentrant_lock_unlock : 1807.09 msec
104-
mixed_lock_unlock : 1834.21 msec
105-
lock_unlock_nonblocking : 1642.06 msec
106-
context_manager : 1730.29 msec
107-
108-
Testing Cython interface of FastRLock (0.8.1)
109-
110-
sequential (x100000):
111-
lock_unlock : 19.14 msec
112-
reentrant_lock_unlock : 19.12 msec
113-
mixed_lock_unlock : 16.81 msec
114-
lock_unlock_nonblocking : 14.49 msec
115-
116-
threaded 10T (x1000):
117-
lock_unlock : 1511.85 msec
118-
reentrant_lock_unlock : 1541.96 msec
119-
mixed_lock_unlock : 1585.70 msec
120-
lock_unlock_nonblocking : 1585.35 msec
121-
122-
123-
How does it compare to Python 3.7 and later?
124-
--------------------------------------------
125-
126-
The results here are more mixed. Depending on the optimisation of the CPython
74+
The results here are mixed. Depending on the optimisation of the CPython
12775
installation, it can be faster, about the same speed, or somewhat slower.
12876
In any case, the direct Cython interface is always faster than going through
12977
the Python API, because it avoids the Python call overhead and executes

setup.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -94,14 +94,13 @@ def read_file(filename):
9494
'Intended Audience :: Information Technology',
9595
'License :: OSI Approved :: MIT License',
9696
'Programming Language :: Cython',
97-
'Programming Language :: Python :: 2',
9897
'Programming Language :: Python :: 3',
9998
'Operating System :: OS Independent',
10099
'Topic :: Software Development',
101100
],
102101

103102
packages=[PKGNAME],
104-
package_data={PKGNAME: ['*.pxd', '*.pxi']},
103+
package_data={PKGNAME: ['*.pyx', '*.pxd', '*.pxi']},
105104
ext_modules=ext_modules,
106105
zip_safe=False,
107106

tox.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[tox]
2-
envlist = py{27,37,38,39,310,311,312,313}
2+
envlist = py{37,38,39,310,311,312,313}
33

44
[testenv]
55
platform =

0 commit comments

Comments
 (0)