Skip to content

Commit 6c45ed9

Browse files
authored
Merge branch 'epics-base:master' into master
2 parents df902e4 + 6355223 commit 6c45ed9

11 files changed

Lines changed: 99 additions & 51 deletions

File tree

.github/workflows/build.yml

Lines changed: 58 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,11 @@ jobs:
4343
# Check build from .tar
4444
- name: Source
4545
os: ubuntu-latest
46-
python: "3.9"
46+
python: "3.12"
4747
source: true
4848

4949
# Linux py builds x64
50+
# TODO: manylinux1 and 2014 are EOL, even more reason to remove these supported versions
5051
- name: linux 2.7 amd64
5152
os: ubuntu-latest
5253
pyver: cp27-cp27m
@@ -109,9 +110,17 @@ jobs:
109110
piparch: manylinux2014_x86_64
110111
numpy: numpy==1.23.5
111112
cython: Cython==0.29.35
113+
114+
- name: linux 3.12 amd64
115+
os: ubuntu-latest
116+
pyver: cp312-cp312
117+
piparch: manylinux2014_x86_64
118+
numpy: numpy==2.0.1
119+
cython: Cython==3.0.10
112120
skip_cothread: yes
113121

114122
# Linux py builds x64
123+
# TODO: manylinux1 and 2014 are EOL, even more reason to remove these supported versions
115124
- name: linux 2.7 i686
116125
os: ubuntu-latest
117126
pyver: cp27-cp27m
@@ -151,74 +160,88 @@ jobs:
151160
numpy: numpy==1.16.2
152161
cython: Cython==0.29.2
153162
pre: linux32
163+
skip_cothread: yes
154164

155165
- name: linux 3.8 i686
156166
os: ubuntu-latest
157167
pyver: cp38-cp38
158168
piparch: manylinux1_i686
159-
numpy: numpy==1.17.3
169+
numpy: numpy==1.19.5
160170
cython: Cython==0.29.2
161171
pre: linux32
172+
skip_cothread: yes
162173

163174
- name: linux 3.9 i686
164175
os: ubuntu-latest
165176
pyver: cp39-cp39
166177
piparch: manylinux2010_i686
167-
numpy: numpy==1.19.3
178+
numpy: numpy==1.19.5
168179
cython: Cython==0.29.23
169180
pre: linux32
181+
skip_cothread: yes
170182

171183
# numpy i386 wheels not built >= 3.10
172184

173185
# OSX py builds
174186
- name: osx 3.6 intel
175-
os: macos-latest
187+
os: macos-13
176188
python: "3.6"
177189
piparch: macosx_10_9_intel
178190
numpy: numpy==1.11.3
179191
cython: Cython==0.29.2
180192

181193
- name: osx 3.7 intel
182-
os: macos-latest
194+
os: macos-13
183195
python: "3.7"
184196
piparch: macosx_10_9_intel
185197
numpy: numpy==1.16.2
186198
cython: Cython==0.29.2
187199

188-
- name: osx 3.8 intel
200+
- name: osx 3.8 arm64
189201
os: macos-latest
190202
python: "3.8"
191-
piparch: macosx_10_9_intel
192-
numpy: numpy==1.17.3
203+
piparch: macosx_11_0_universal2
204+
numpy: numpy==1.24.4
193205
cython: Cython==0.29.2
206+
skip_cothread: yes
194207

195-
- name: osx 3.9 intel
208+
- name: osx 3.9 arm64
196209
os: macos-latest
197210
python: "3.9"
198-
piparch: macosx_10_9_intel
199-
numpy: numpy==1.19.3
200-
cython: Cython==0.29.23
211+
piparch: macosx_11_0_universal2
212+
numpy: numpy==2.0.1
213+
cython: Cython==3.0.10
214+
skip_cothread: yes
201215

202-
- name: osx 3.10 intel
216+
- name: osx 3.10 arm64
203217
os: macos-latest
204218
python: "3.10"
205-
piparch: macosx_10_9_intel
206-
numpy: numpy==1.22.0
207-
cython: Cython==0.29.23
219+
piparch: macosx_11_0_universal2
220+
numpy: numpy==2.0.1
221+
cython: Cython==3.0.10
222+
skip_cothread: yes
208223

209-
- name: osx 3.11 intel
224+
- name: osx 3.11 arm64
210225
os: macos-latest
211226
python: "3.11"
212-
piparch: macosx_10_9_intel
213-
numpy: numpy==1.23.5
214-
cython: Cython==0.29.35
227+
piparch: macosx_11_0_universal2
228+
numpy: numpy==2.0.1
229+
cython: Cython==3.0.10
230+
skip_cothread: yes
231+
232+
- name: osx 3.12 arm64
233+
os: macos-latest
234+
python: "3.12"
235+
piparch: macosx_11_0_universal2
236+
numpy: numpy==2.0.1
237+
cython: Cython==3.0.10
215238
skip_cothread: yes
216239

217240
# Windows py builds
218241

219242
## missing Microsoft Visual C++ 9.0
220243
#- os: windows-latest
221-
# python: "2.7"
244+
# python: "3.12"
222245
# piparch: win_amd64
223246

224247
- name: win64 3.5
@@ -270,18 +293,31 @@ jobs:
270293
profile: latest
271294
skip_cothread: yes
272295

296+
- name: win64 3.12
297+
os: windows-latest
298+
python: "3.12"
299+
piparch: win_amd64
300+
profile: latest
301+
skip_cothread: yes
302+
273303
steps:
274304
- uses: actions/checkout@v3
275305
with:
276306
submodules: recursive
277307

278308
- name: Setup native python
279309
if: matrix.python
280-
uses: actions/setup-python@v4
310+
uses: actions/setup-python@v5
281311
with:
282312
python-version: ${{ matrix.python }}
283313
#architecture: x64
284314

315+
# TLS 1.0 and 1.1 support was removed from pypi so the cached pip won't work
316+
- name: Python 3.5 Fix
317+
if: ${{ matrix.python == '3.5' }}
318+
run: |
319+
curl https://bootstrap.pypa.io/pip/3.5/get-pip.py | python
320+
285321
- name: Automatic core dumper analysis
286322
uses: mdavidsaver/ci-core-dumper@master
287323

@@ -358,7 +394,6 @@ jobs:
358394
python -m pip install p4p*.whl
359395
python -m ci_core_dumper exec python -m nose2 -v p4p
360396
361-
362397
- name: Docker PY build
363398
if: matrix.pyver && !matrix.base && !matrix.source
364399
run: |
@@ -370,7 +405,6 @@ jobs:
370405
[ -d dist ]
371406
ls dist/*
372407
export PATH="/opt/python/${{ matrix.pyver }}/bin:\$PATH"
373-
export SETUPTOOLS_USE_DISTUTILS=stdlib
374408
which python
375409
python -m pip install -U pip
376410
python -m pip install setuptools wheel nose2

example/dynamicbox_server.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919

2020
import sys
2121
import time, logging
22+
2223
_log = logging.getLogger(__name__)
2324

2425
from threading import Lock

example/monitor_meta.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ def cb(value):
1717
for fld in value.raw.asSet():
1818
print(" ",fld,value.raw[fld])
1919

20+
2021
print("Create Context")
2122
with Context('pva') as ctxt:
2223
print("Subscribe to", sys.argv[1])

example/rpc_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ def getargs():
2424
P.add_argument('prefix')
2525
P.add_argument('method')
2626
P.add_argument('args', nargs='*')
27-
return P.parse_args()
27+
return P, P.parse_args()
2828

29-
args = getargs()
29+
P, args = getargs()
3030

3131
logging.basicConfig(level=logging.DEBUG if args.debug else logging.INFO)
3232

makehelper.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,14 @@
3333
incdirs = [get_python_inc()]
3434
libdir = get_config_var('LIBDIR') or ''
3535

36-
try:
37-
from numpy.distutils.misc_util import get_numpy_include_dirs
38-
except ImportError:
39-
def get_numpy_include_dirs():
40-
from numpy import get_include
41-
return [get_include()]
4236

43-
incdirs = get_numpy_include_dirs()+incdirs
37+
def get_numpy_include_dirs():
38+
from numpy import get_include
39+
40+
return [get_include()]
41+
42+
43+
incdirs = get_numpy_include_dirs() + incdirs
4444

4545
print('TARGET_CFLAGS +=',get_config_var('BASECFLAGS'), file=out)
4646
print('TARGET_CXXFLAGS +=',get_config_var('BASECFLAGS'), file=out)

pyproject.toml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,14 @@
11
[build-system]
2-
requires = ["setuptools", "setuptools_dso>=1.3a1", "wheel", "numpy", "Cython>=0.20", "epicscorelibs>=7.0.3.99.2.0a1", "pvxslibs"]
2+
requires = [
3+
"setuptools",
4+
"setuptools_dso>=2.7a1,<=2.10; python_version<='3.11'",
5+
"setuptools_dso>=2.11a2; python_version>='3.12'",
6+
"wheel",
7+
"numpy",
8+
"numpy>=2.0.1; python_version>='3.10'",
9+
"Cython>=0.20",
10+
"epicscorelibs==7.0.7.99.0.2; python_version<='3.11'",
11+
"epicscorelibs>=7.0.7.99.1.1a2; python_version>='3.12'",
12+
"pvxslibs==1.3.1; python_version<='3.11'",
13+
"pvxslibs>=1.3.2a1; python_version>='3.12'",
14+
]

setup.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,6 @@
88
from setuptools_dso import Extension, setup, cythonize
99

1010
import numpy
11-
try:
12-
from numpy.distutils.misc_util import get_numpy_include_dirs
13-
except ImportError:
14-
def get_numpy_include_dirs():
15-
return [numpy.get_include()]
1611

1712
import epicscorelibs.path
1813
import epicscorelibs.version
@@ -21,6 +16,11 @@ def get_numpy_include_dirs():
2116
import pvxslibs.path
2217
import pvxslibs.version
2318

19+
20+
def get_numpy_include_dirs():
21+
return [numpy.get_include()]
22+
23+
2424
with open('src/p4p/version.py', 'r') as F:
2525
lcl = {}
2626
exec(F.read(), None, lcl)

src/p4p/disect.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
"""Python reference counter statistics.
2-
"""
31

42
from __future__ import print_function
3+
"""Python reference counter statistics."""
54

65
import sys
76
import gc

src/p4p/test/test_value.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
from .. import pvdVersion
1212
from .utils import RefTestCase
1313

14+
1415
class TestWrapper(RefTestCase):
1516
def testCall(self):
1617
T = Type([('ival', 'I')])
@@ -183,12 +184,12 @@ def testArray(self):
183184
('sval', 'as'),
184185
]), {
185186
'ival': [1, 2, 3],
186-
'dval': np.asfarray([1.1, 2.2]),
187+
'dval': np.asarray([1.1, 2.2], dtype=np.float64),
187188
'sval': ['a', u'b'],
188189
})
189190

190191
assert_aequal(V.ival, np.asarray([1, 2, 3]))
191-
assert_aequal(V.dval, np.asfarray([1.1, 2.2]))
192+
assert_aequal(V.dval, np.asarray([1.1, 2.2], dtype=np.float64))
192193
self.assertListEqual(V.sval, [u'a', u'b'])
193194

194195
# i4 <- u8 violates "safe" casting rules
@@ -296,8 +297,8 @@ def testVariantUnion(self):
296297
V.x = np.asarray([1, 2])
297298
assert_aequal(V.x, np.asarray([1, 2]))
298299

299-
V.x = np.asfarray([1, 2])
300-
assert_aequal(V.x, np.asfarray([1, 2]))
300+
V.x = np.asarray([1, 2], dtype=np.float64)
301+
assert_aequal(V.x, np.asarray([1, 2], dtype=np.float64))
301302

302303
# clearing unions is broken prior to 7.0.0
303304
if pvdVersion() >= (7, 0, 0, 0):
@@ -317,7 +318,7 @@ def testVariantUnionExplicit(self):
317318
self.assertEqual(type(V.x), float)
318319

319320
V.x = ('ad', np.asarray([1, 2]))
320-
assert_aequal(V.x, np.asfarray([1, 2]))
321+
assert_aequal(V.x, np.asarray([1, 2], dtype=np.float64))
321322

322323
V.x = ('as', ['one', 'two'])
323324
self.assertEqual(V.x, ['one', 'two'])

src/p4p/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,4 +67,4 @@ def __ge__(self, o):
6767
def __gt__(self, o):
6868
return self._cmp(o)>0
6969

70-
version = Version('4.1.12')
70+
version = Version('4.2.0a1')

0 commit comments

Comments
 (0)