public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/python-nmrglue] rawhide: Update to 0.11 + spec cleanup and modernization
@ 2026-08-07 20:04 Filipe Rosset
  0 siblings, 0 replies; only message in thread
From: Filipe Rosset @ 2026-08-07 20:04 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : rpms/python-nmrglue
            Branch : rawhide
            Commit : 756e18e786aa69777a64ed3412e9e5860e727230
            Author : Filipe Rosset <rosset.filipe@gmail.com>
            Date   : 2026-07-29T00:34:20-03:00
            Stats  : +147/-11 in 4 file(s)
            URL    : https://src.fedoraproject.org/rpms/python-nmrglue/c/756e18e786aa69777a64ed3412e9e5860e727230?branch=rawhide

            Log:
            Update to 0.11 + spec cleanup and modernization

Resolves: rhbz#2377931
Resolves: rhbz#2504554

---
diff --git a/.gitignore b/.gitignore
index 74232a2..52fc5f5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,3 +3,4 @@
 /v0.7.tar.gz
 /v0.8.tar.gz
 /v0.9.tar.gz
+/v0.11.tar.gz

diff --git a/python-nmrglue-numpy-dtype.patch b/python-nmrglue-numpy-dtype.patch
new file mode 100644
index 0000000..fc94bf4
--- /dev/null
+++ b/python-nmrglue-numpy-dtype.patch
@@ -0,0 +1,130 @@
+diff --git a/nmrglue/fileio/tecmag.py b/nmrglue/fileio/tecmag.py
+index a5931e3..ddd78f6 100644
+--- a/nmrglue/fileio/tecmag.py
++++ b/nmrglue/fileio/tecmag.py
+@@ -24,8 +24,8 @@ from . import fileiobase
+ 
+ TNTMAGIC_RE = re.compile(br"^TNT1\.\d\d\d$")
+ 
+-TNTMAGIC = np.dtype('a8')
+-TNTTLV = np.dtype([('tag', 'a4'), ('bool', '<u4'), ('length', '<u4')])
++TNTMAGIC = np.dtype('S8')
++TNTTLV = np.dtype([('tag', 'S4'), ('bool', '<u4'), ('length', '<u4')])
+ 
+ TNTTMAG = np.dtype([
+     ('npts', '<i4', 4),
+@@ -38,7 +38,7 @@ TNTTMAG = np.dtype([
+     ('repeat_times', '<i4'),
+     ('sadimension', '<i4'),
+     ('samode', '<i4'),
+-    # ('space1', 'a0'),
++    # ('space1', 'S0'),
+ 
+     ('magnet_field', '<f8'),
+     ('ob_freq', '<f8', 4),
+@@ -47,7 +47,7 @@ TNTTMAG = np.dtype([
+     ('ref_freq', '<f8'),
+     ('NMR_frequency', '<f8'),
+     ('obs_channel', '<i2'),
+-    ('space2', 'a42'),
++    ('space2', 'S42'),
+ 
+     ('sw', '<f8', 4),
+     ('dwell', '<f8', 4),
+@@ -61,14 +61,14 @@ TNTTMAG = np.dtype([
+     ('Type', '<i2'),
+     ('bDigRec', '<u4'),
+     ('nDigitalCenter', '<i4'),
+-    ('space3', 'a16'),
++    ('space3', 'S16'),
+ 
+     ('transmitter_gain', '<i2'),
+     ('receiver_gain', '<i2'),
+     ('NumberOfReceivers', '<i2'),
+     ('RG2', '<i2'),
+     ('receiver_phase', '<f8'),
+-    ('space4', 'a4'),
++    ('space4', 'S4'),
+ 
+     ('set_spin_rate', '<u2'),
+     ('actual_spin_rate', '<u2'),
+@@ -80,7 +80,7 @@ TNTTMAG = np.dtype([
+     ('lock_freq_mhz', '<f8'),
+     ('lock_ppm', '<f8'),
+     ('H2O_freq_ref', '<f8'),
+-    ('space5', 'a16'),
++    ('space5', 'S16'),
+ 
+     ('set_temperature', '<f8'),
+     ('actual_temperature', '<f8'),
+@@ -93,21 +93,21 @@ TNTTMAG = np.dtype([
+     ('DF_DN', '<i2'),
+     ('F1_tran_mode', '<i2', 7),
+     ('dec_BW', '<i2'),
+-    ('grd_orientation', 'a4'),
++    ('grd_orientation', 'S4'),
+     ('LatchLP', '<i4'),
+     ('grd_Theta', '<f8'),
+     ('grd_Phi', '<f8'),
+-    ('space6', 'a264'),
++    ('space6', 'S264'),
+ 
+     ('start_time', '<u4'),
+     ('finish_time', '<u4'),
+     ('elapsed_time', '<i4'),
+ 
+-    ('date', 'a32'),
+-    ('nuclei', 'a16', 4),
+-    ('sequence', 'a32'),
+-    ('lock_solvent', 'a16'),
+-    ('lock_nucleus', 'a16')
++    ('date', 'S32'),
++    ('nuclei', 'S16', 4),
++    ('sequence', 'S32'),
++    ('lock_solvent', 'S16'),
++    ('lock_nucleus', 'S16')
+ ])
+ 
+ 
+@@ -122,8 +122,8 @@ TNTGRIDANDAXIS = np.dtype([
+     ('showGridLabels', '<u4'),
+     ('adjustOnZoom', '<u4'),
+     ('showDistanceUnits', '<u4'),
+-    ('axisName', 'a32'),
+-    ('space', 'a52'),
++    ('axisName', 'S32'),
++    ('space', 'S52'),
+ ])
+ 
+ 
+@@ -217,18 +217,18 @@ TNTTMG2 = np.dtype([
+     ('Poly_point_avr', '<i2'),
+     ('Poly_order', '<i2'),
+ 
+-    ('space', 'a610'),
+-
+-    ('line_simulation_name', 'a32'),
+-    ('integral_template_name', 'a32'),
+-    ('baseline_template_name', 'a32'),
+-    ('layout_name', 'a32'),
+-    ('relax_information_name', 'a32'),
+-    ('username', 'a32'),
+-    ('user_string_1', 'a16'),
+-    ('user_string_2', 'a16'),
+-    ('user_string_3', 'a16'),
+-    ('user_string_4', 'a16')
++    ('space', 'S610'),
++
++    ('line_simulation_name', 'S32'),
++    ('integral_template_name', 'S32'),
++    ('baseline_template_name', 'S32'),
++    ('layout_name', 'S32'),
++    ('relax_information_name', 'S32'),
++    ('username', 'S32'),
++    ('user_string_1', 'S16'),
++    ('user_string_2', 'S16'),
++    ('user_string_3', 'S16'),
++    ('user_string_4', 'S16')
+ ])
+ 
+ 

diff --git a/python-nmrglue.spec b/python-nmrglue.spec
index 4dde2b8..db29db1 100644
--- a/python-nmrglue.spec
+++ b/python-nmrglue.spec
@@ -2,7 +2,7 @@
 %global pkgsum Python module for processing NMR data
 
 Name:		python-%{pkgname}
-Version:	0.9
+Version:	0.11
 Release:	%autorelease
 Summary:	%{pkgsum}
 
@@ -10,14 +10,15 @@ Summary:	%{pkgsum}
 License:	LicenseRef-Callaway-BSD
 URL:		https://github.com/jjhelmus/%{pkgname}
 Source0:	https://github.com/jjhelmus/%{pkgname}/archive/v%{version}.tar.gz
+Patch:		python-nmrglue-numpy-dtype.patch
 
 BuildArch:	noarch
 BuildRequires:	python3-devel
-BuildRequires:	python3-setuptools
-# these are required for tests
+BuildRequires:	python3-h5py
 BuildRequires:	python3-numpy
 BuildRequires:	python3-scipy
 
+
 %description
 nmrglue is a module for working with NMR data in Python. When used with the 
 numpy, scipy, and matplotlib packages nmrglue provides a robust interpreted 
@@ -25,7 +26,6 @@ environment for processing, analyzing, and inspecting NMR data.
 
 %package -n python3-%{pkgname}
 Summary:	%{pkgsum}
-%{?python_provide:%python_provide python3-%{pkgname}}
 Requires:	python3-numpy
 Requires:	python3-scipy
 
@@ -35,7 +35,7 @@ numpy, scipy, and matplotlib packages nmrglue provides a robust interpreted
 environment for processing, analyzing, and inspecting NMR data.
 
 %prep
-%autosetup -n %{pkgname}-%{version}
+%autosetup -p1 -n %{pkgname}-%{version}
 
 # disable tests bundling
 sed -i '/nmrglue.fileio.tests/d' setup.py
@@ -43,13 +43,20 @@ sed -i '/package_data/d' setup.py
 sed -i '/fileio\/tests\/data\//d' setup.py
 
 
+%generate_buildrequires
+%pyproject_buildrequires
+
+
 %build
-%py3_build
+%pyproject_wheel
 
 %install
-%py3_install
+%pyproject_install
+%pyproject_save_files -l '*'
 
 %check
+%pyproject_check_import
+
 
 pushd nmrglue/fileio/tests
 
@@ -58,10 +65,8 @@ PYTHONPATH="%{buildroot}%{python3_sitelib}" %{__python3} test_pipe.py
 
 popd
 
-%files -n python3-%{pkgname}
-%license LICENSE.txt
+%files -n python3-%{pkgname} -f %{pyproject_files}
 %doc README.rst TODO.txt
-%{python3_sitelib}/*
 
 %changelog
 %autochangelog

diff --git a/sources b/sources
index 2b0ddef..9f77d9a 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (v0.9.tar.gz) = 8e20a53cf53df6fb0f0ddba1361b1ead0f03c5cdd34cc7199fb9d6727060596a1f79c5c0139dd978f6b09551216a0042e8858603ce4c9b1f4063f04e06d912e5
+SHA512 (v0.11.tar.gz) = c3bd3489c0159df77ec91d13c2df79549e6696810831fbbdc249ede94f65ad31ff4e302dbfe963d1ed68efcb74f6c26703860d18617a8d4113cee14be5fa19ac

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-08-07 20:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-07 20:04 [rpms/python-nmrglue] rawhide: Update to 0.11 + spec cleanup and modernization Filipe Rosset

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox