Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-cmapfile for openSUSE:Factory
checked in at 2026-01-22 15:18:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-cmapfile (Old)
and /work/SRC/openSUSE:Factory/.python-cmapfile.new.1928 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-cmapfile"
Thu Jan 22 15:18:49 2026 rev:9 rq:1328633 version:2026.1.8
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-cmapfile/python-cmapfile.changes
2025-02-03 21:46:35.702125511 +0100
+++
/work/SRC/openSUSE:Factory/.python-cmapfile.new.1928/python-cmapfile.changes
2026-01-22 15:19:56.844650993 +0100
@@ -1,0 +2,8 @@
+Thu Jan 22 08:53:24 UTC 2026 - Dirk Müller <[email protected]>
+
+- update to 2026.1.8:
+ * Improve code quality.
+ * Improve code quality.
+ * Drop support for Python 3.10, support Python 3.14.
+
+-------------------------------------------------------------------
Old:
----
cmapfile-2025.1.1.tar.gz
New:
----
cmapfile-2026.1.8.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-cmapfile.spec ++++++
--- /var/tmp/diff_new_pack.c6e3pU/_old 2026-01-22 15:19:57.328671127 +0100
+++ /var/tmp/diff_new_pack.c6e3pU/_new 2026-01-22 15:19:57.328671127 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-cmapfile
#
-# Copyright (c) 2025 SUSE LLC
+# Copyright (c) 2026 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -18,7 +18,7 @@
%{?sle15_python_module_pythons}
Name: python-cmapfile
-Version: 2025.1.1
+Version: 2026.1.8
Release: 0
Summary: Write Chimera Map (CMAP) files
License: BSD-3-Clause
++++++ cmapfile-2025.1.1.tar.gz -> cmapfile-2026.1.8.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/.gitignore
new/cmapfile-2026.1.8/.gitignore
--- old/cmapfile-2025.1.1/.gitignore 2025-01-02 03:31:46.000000000 +0100
+++ new/cmapfile-2026.1.8/.gitignore 2026-01-09 00:59:44.000000000 +0100
@@ -32,7 +32,7 @@
MANIFEST
setup.cfg
PKG-INFO
-
+mypy.ini
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/CHANGES.rst
new/cmapfile-2026.1.8/CHANGES.rst
--- old/cmapfile-2025.1.1/CHANGES.rst 1970-01-01 01:00:00.000000000 +0100
+++ new/cmapfile-2026.1.8/CHANGES.rst 2026-01-09 00:59:44.000000000 +0100
@@ -0,0 +1,55 @@
+Revisions
+---------
+
+2026.1.8
+
+- Improve code quality.
+
+2025.12.18
+
+- Improve code quality.
+- Drop support for Python 3.10, support Python 3.14.
+
+2025.1.1
+
+- Improve type hints.
+- Support Python 3.13.
+
+2024.8.28
+
+- Fix lsm2cmap with tifffile > 2024.8.24.
+- Drop support for Python 3.9 and numpy < 1.24 (NEP29).
+
+2023.8.30
+
+- Drop support for Python 3.8 and numpy < 1.22 (NEP29).
+
+2022.9.29
+
+- Make subsampling compatible with ChimeraX (breaking).
+- Fix deprecated import of scipy.ndimage.interpolation.zoom.
+- Switch to Google style docstrings.
+
+2022.2.2
+
+- Add type hints.
+- Drop support for Python 3.7 and numpy < 1.19 (NEP29).
+
+2021.2.26
+
+- Fix LSM conversion with tifffile >= 2021.2.26.
+- Drop support for Python 3.6 (NEP 29).
+
+2020.1.1
+
+- Do not write name attribute.
+- Drop support for Python 2.7 and 3.5.
+- Update copyright.
+
+2018.8.30
+
+- Move cmapfile.py into cmapfile package.
+
+2014.10.10
+
+- Initial release.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/LICENSE
new/cmapfile-2026.1.8/LICENSE
--- old/cmapfile-2025.1.1/LICENSE 2025-01-02 03:31:46.000000000 +0100
+++ new/cmapfile-2026.1.8/LICENSE 2026-01-09 00:59:44.000000000 +0100
@@ -1,6 +1,6 @@
-BSD 3-Clause License
+BSD-3-Clause license
-Copyright (c) 2014-2025, Christoph Gohlke
+Copyright (c) 2014-2026, Christoph Gohlke
All rights reserved.
Redistribution and use in source and binary forms, with or without
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/MANIFEST.in
new/cmapfile-2026.1.8/MANIFEST.in
--- old/cmapfile-2025.1.1/MANIFEST.in 2025-01-02 03:31:46.000000000 +0100
+++ new/cmapfile-2026.1.8/MANIFEST.in 2026-01-09 00:59:44.000000000 +0100
@@ -1,10 +1,16 @@
include LICENSE
include README.rst
+include CHANGES.rst
+include pyproject.toml
include test.oib
include cmapfile/py.typed
+exclude .env
exclude *.cmd
+exclude *.yaml
+exclude mypy.ini
+exclude ruff.toml
recursive-exclude doc *
recursive-exclude docs *
recursive-exclude test *
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/README.rst
new/cmapfile-2026.1.8/README.rst
--- old/cmapfile-2025.1.1/README.rst 2025-01-02 03:31:46.000000000 +0100
+++ new/cmapfile-2026.1.8/README.rst 2026-01-09 00:59:44.000000000 +0100
@@ -14,8 +14,9 @@
visualization and analysis of molecular structures and related data.
:Author: `Christoph Gohlke <https://www.cgohlke.com>`_
-:License: BSD 3-Clause
-:Version: 2025.1.1
+:License: BSD-3-Clause
+:Version: 2026.1.8
+:DOI: `10.5281/zenodo.17979877 <https://doi.org/10.5281/zenodo.17979877>`_
Quickstart
----------
@@ -40,59 +41,35 @@
This revision was tested with the following requirements and dependencies
(other versions may work):
-- `CPython <https://www.python.org>`_ 3.10.11, 3.11.9, 3.12.8, 3.13.1 64-bit
-- `NumPy <https://pypi.org/project/numpy/>`_ 2.1.3
-- `Scipy <https://pypi.org/project/scipy/>`_ 1.14.1
-- `H5py <https://pypi.org/project/h5py/>`_ 3.12.1
-- `Tifffile <https://pypi.org/project/tifffile/>`_ 2024.12.12
-- `Oiffile <https://pypi.org/project/oiffile/>`_ 2025.1.1
+- `CPython <https://www.python.org>`_ 3.11.9, 3.12.10, 3.13.11, 3.14.2 64-bit
+- `NumPy <https://pypi.org/project/numpy/>`_ 2.4.0
+- `Scipy <https://pypi.org/project/scipy/>`_ 1.16.3
+- `H5py <https://pypi.org/project/h5py/>`_ 3.15.1
+- `Tifffile <https://pypi.org/project/tifffile/>`_ 2025.12.20
+- `Oiffile <https://pypi.org/project/oiffile/>`_ 2026.1.8
Revisions
---------
-2025.1.1
-
-- Improve type hints.
-- Support Python 3.13.
-
-2024.8.28
-
-- Fix lsm2cmap with tifffile > 2024.8.24.
-- Drop support for Python 3.9 and numpy < 1.24 (NEP29).
-
-2023.8.30
-
-- Drop support for Python 3.8 and numpy < 1.22 (NEP29).
+2026.1.8
-2022.9.29
+- Improve code quality.
-- Make subsampling compatible with ChimeraX (breaking).
-- Fix deprecated import of scipy.ndimage.interpolation.zoom.
-- Switch to Google style docstrings.
+2025.12.18
-2022.2.2
+- Improve code quality.
+- Drop support for Python 3.10, support Python 3.14.
-- Add type hints.
-- Drop support for Python 3.7 and numpy < 1.19 (NEP29).
-
-2021.2.26
-
-- Fix LSM conversion with tifffile >= 2021.2.26.
-- Drop support for Python 3.6 (NEP 29).
-
-2020.1.1
-
-- Do not write name attribute.
-- Drop support for Python 2.7 and 3.5.
-- Update copyright.
+2025.1.1
-2018.8.30
+- Improve type hints.
+- Support Python 3.13.
-- Move cmapfile.py into cmapfile package.
+2024.8.28
-2014.10.10
+- …
-- Initial release.
+Refer to the CHANGES file for older revisions.
Notes
-----
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/cmapfile/__init__.py
new/cmapfile-2026.1.8/cmapfile/__init__.py
--- old/cmapfile-2025.1.1/cmapfile/__init__.py 2025-01-02 03:31:46.000000000
+0100
+++ new/cmapfile-2026.1.8/cmapfile/__init__.py 2026-01-09 00:59:44.000000000
+0100
@@ -1,4 +1,9 @@
# cmapfile/__init__.py
-from .cmapfile import __doc__, __all__, __version__, main
from .cmapfile import *
+from .cmapfile import __all__, __doc__, __version__, main
+
+# constants are repeated for documentation
+
+__version__ = __version__
+"""Cmapfile version string."""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/cmapfile/cmapfile.py
new/cmapfile-2026.1.8/cmapfile/cmapfile.py
--- old/cmapfile-2025.1.1/cmapfile/cmapfile.py 2025-01-02 03:31:46.000000000
+0100
+++ new/cmapfile-2026.1.8/cmapfile/cmapfile.py 2026-01-09 00:59:44.000000000
+0100
@@ -1,6 +1,6 @@
# cmapfile.py
-# Copyright (c) 2014-2025, Christoph Gohlke
+# Copyright (c) 2014-2026, Christoph Gohlke
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -41,8 +41,9 @@
visualization and analysis of molecular structures and related data.
:Author: `Christoph Gohlke <https://www.cgohlke.com>`_
-:License: BSD 3-Clause
-:Version: 2025.1.1
+:License: BSD-3-Clause
+:Version: 2026.1.8
+:DOI: `10.5281/zenodo.17979877 <https://doi.org/10.5281/zenodo.17979877>`_
Quickstart
----------
@@ -67,59 +68,35 @@
This revision was tested with the following requirements and dependencies
(other versions may work):
-- `CPython <https://www.python.org>`_ 3.10.11, 3.11.9, 3.12.8, 3.13.1 64-bit
-- `NumPy <https://pypi.org/project/numpy/>`_ 2.1.3
-- `Scipy <https://pypi.org/project/scipy/>`_ 1.14.1
-- `H5py <https://pypi.org/project/h5py/>`_ 3.12.1
-- `Tifffile <https://pypi.org/project/tifffile/>`_ 2024.12.12
-- `Oiffile <https://pypi.org/project/oiffile/>`_ 2025.1.1
+- `CPython <https://www.python.org>`_ 3.11.9, 3.12.10, 3.13.11, 3.14.2 64-bit
+- `NumPy <https://pypi.org/project/numpy/>`_ 2.4.0
+- `Scipy <https://pypi.org/project/scipy/>`_ 1.16.3
+- `H5py <https://pypi.org/project/h5py/>`_ 3.15.1
+- `Tifffile <https://pypi.org/project/tifffile/>`_ 2025.12.20
+- `Oiffile <https://pypi.org/project/oiffile/>`_ 2026.1.8
Revisions
---------
-2025.1.1
-
-- Improve type hints.
-- Support Python 3.13.
-
-2024.8.28
-
-- Fix lsm2cmap with tifffile > 2024.8.24.
-- Drop support for Python 3.9 and numpy < 1.24 (NEP29).
+2026.1.8
-2023.8.30
+- Improve code quality.
-- Drop support for Python 3.8 and numpy < 1.22 (NEP29).
+2025.12.18
-2022.9.29
+- Improve code quality.
+- Drop support for Python 3.10, support Python 3.14.
-- Make subsampling compatible with ChimeraX (breaking).
-- Fix deprecated import of scipy.ndimage.interpolation.zoom.
-- Switch to Google style docstrings.
-
-2022.2.2
-
-- Add type hints.
-- Drop support for Python 3.7 and numpy < 1.19 (NEP29).
-
-2021.2.26
-
-- Fix LSM conversion with tifffile >= 2021.2.26.
-- Drop support for Python 3.6 (NEP 29).
-
-2020.1.1
-
-- Do not write name attribute.
-- Drop support for Python 2.7 and 3.5.
-- Update copyright.
+2025.1.1
-2018.8.30
+- Improve type hints.
+- Support Python 3.13.
-- Move cmapfile.py into cmapfile package.
+2024.8.28
-2014.10.10
+- …
-- Initial release.
+Refer to the CHANGES file for older revisions.
Notes
-----
@@ -202,16 +179,16 @@
from __future__ import annotations
-__version__ = '2025.1.1'
+__version__ = '2026.1.8'
__all__ = [
- '__version__',
'CmapFile',
+ '__version__',
+ 'array2cmap',
'bin2cmap',
- 'tif2cmap',
'lsm2cmap',
'oif2cmap',
- 'array2cmap',
+ 'tif2cmap',
]
import glob
@@ -288,7 +265,7 @@
data:
Map data to store. Must be three dimensional.
name:
- Name of map.
+ Name of map (unused).
step:
Spacing between samples in XYZ dimensions.
Chimera defaults to (1.0, 1.0, 1.0).
@@ -326,12 +303,14 @@
Print messages to stdout.
"""
+ del name # unused, see comment below
if astype:
data = numpy.ascontiguousarray(data, astype)
else:
data = numpy.ascontiguousarray(data)
if data.ndim != 3:
- raise ValueError('map data must be 3 dimensional')
+ msg = 'map data must be 3 dimensional'
+ raise ValueError(msg)
# create group and write attributes
group = self.create_group(f'map{self.mapcounter:05d}')
@@ -403,6 +382,7 @@
dtype: DTypeLike,
offset: int = 0,
cmapfile: str | os.PathLike[Any] | None = None,
+ *,
fail: bool = True,
**kwargs: Any,
) -> None:
@@ -446,7 +426,7 @@
cmapfile = os.fspath(binfiles_list[0]) + '.cmap'
verbose = kwargs.get('verbose', False)
if verbose:
- print(f"Creating '{cmapfile}'", flush=True)
+ print(f'Creating {cmapfile!r}', flush=True)
with CmapFile(cmapfile, 'w') as cmap:
for binfile in binfiles_list:
if verbose:
@@ -472,6 +452,7 @@
tiffiles: Sequence[str | os.PathLike[Any]],
/,
cmapfile: str | os.PathLike[Any] | None = None,
+ *,
fail: bool = True,
**kwargs: Any,
) -> None:
@@ -511,9 +492,11 @@
shape = data.shape
dtype = data.dtype
if len(shape) != 3 or any(i <= 4 for i in shape):
- raise ValueError('not a 3D map')
+ msg = 'not a 3D map'
+ raise ValueError(msg)
elif shape != data.shape or dtype != data.dtype:
- raise ValueError('shape or dtype mismatch')
+ msg = 'shape or dtype mismatch'
+ raise ValueError(msg)
except Exception as exc:
if fail:
raise
@@ -552,8 +535,8 @@
series = lsm.series[0] # first series contains the image data
if hasattr(series, 'get_shape'):
# tifffile > 2020.2.25 return squeezed shape and axes
- shape = series.get_shape(False)
- axes = series.get_axes(False)
+ shape = series.get_shape(squeeze=False)
+ axes = series.get_axes(squeeze=False)
if axes[:2] == 'MP' and shape[:2] == (1, 1):
axes = axes[2:]
shape = shape[2:]
@@ -563,9 +546,10 @@
if axes != 'TZCYX':
if axes == 'ZCYX':
axes = 'TZCYX'
- shape = (1,) + shape
+ shape = (1, *shape)
else:
- raise ValueError(f'not a 5D LSM file ({axes=} != TZCYX)')
+ msg = f'not a 5D LSM file ({axes=} != TZCYX)'
+ raise ValueError(msg)
if verbose:
print(lsm)
print(shape, axes, flush=True)
@@ -576,7 +560,7 @@
cmapfile = f'{lsmfile}.ch%04d.cmap'
cmaps = [CmapFile(cmapfile % i) for i in range(shape[2])]
# voxel/step sizes
- if not kwargs.get('step', None):
+ if not kwargs.get('step'):
try:
attrs = lsm.lsm_metadata
if attrs is not None:
@@ -628,7 +612,8 @@
"""
if len(data.shape) != len(axes):
- raise ValueError('Number of axes do not match data shape')
+ msg = 'number of axes do not match data shape'
+ raise ValueError(msg)
data = transpose_axes(data, axes, 'CTZYX')
try:
# create one CMAP file per channel
@@ -655,6 +640,7 @@
def oif2cmap(
oiffile: str | os.PathLike[Any],
/,
+ *,
cmapfile: str | os.PathLike[Any] | None = None,
**kwargs: Any,
) -> None:
@@ -680,7 +666,7 @@
if verbose:
print(data.shape, axes, flush=True)
# voxel/step sizes
- if not kwargs.get('step', None):
+ if not kwargs.get('step'):
try:
size = oif_axis_size(oif.mainfile)
shape = data.shape
@@ -703,6 +689,9 @@
Parameters:
oifsettings: OIF main settings.
+ Returns:
+ Mapping of axis codes to sizes.
+
"""
scale = {'nm': 1000.0, 'ms': 1000.0}
result = {}
@@ -759,11 +748,12 @@
"""
try:
if length is not None and len(shape) != length:
- raise ValueError()
+ raise ValueError
if any(i < 1 and i != -1 for i in shape):
- raise ValueError()
+ raise ValueError
except Exception as exc:
- raise ValueError('invalid shape') from exc
+ msg = 'invalid shape'
+ raise ValueError(msg) from exc
def parse_numbers(
@@ -785,7 +775,8 @@
try:
return [dtype(i) for i in numbers.split(sep)]
except Exception as exc:
- raise ValueError(f'not a {sep!r} separated list of numbers') from exc
+ msg = f'not a {sep!r} separated list of numbers'
+ raise ValueError(msg) from exc
def parse_files(
@@ -815,10 +806,11 @@
# glob pattern
assert isinstance(files[0], str)
files = natural_sorted(glob.glob(files[0]))
- files[0] # noqa: validation
- return files
+ files[0] # validation
except Exception as exc:
- raise ValueError('no files found') from exc
+ msg = 'no files found'
+ raise ValueError(msg) from exc
+ return files
def main(argv: list[str] | None = None) -> int:
@@ -906,7 +898,7 @@
if filetype == 'LSM':
if len(files) > 1:
- warnings.warn('too many input files')
+ warnings.warn('too many input files', stacklevel=1)
lsm2cmap(
files[0],
step=step,
@@ -917,7 +909,7 @@
)
elif filetype in ('OIB', 'OIF'):
if len(files) > 1:
- warnings.warn('too many input files')
+ warnings.warn('too many input files', stacklevel=1)
oif2cmap(
files[0],
step=step,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/pyproject.toml
new/cmapfile-2026.1.8/pyproject.toml
--- old/cmapfile-2025.1.1/pyproject.toml 1970-01-01 01:00:00.000000000
+0100
+++ new/cmapfile-2026.1.8/pyproject.toml 2026-01-09 00:59:44.000000000
+0100
@@ -0,0 +1,13 @@
+[build-system]
+requires = ["setuptools"]
+build-backend = "setuptools.build_meta"
+
+[tool.black]
+line-length = 79
+target-version = ["py311", "py312", "py313"]
+skip-string-normalization = true
+
+[tool.isort]
+known_first_party = ["cmapfile"]
+profile = "black"
+line_length = 79
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/cmapfile-2025.1.1/setup.py
new/cmapfile-2026.1.8/setup.py
--- old/cmapfile-2025.1.1/setup.py 2025-01-02 03:31:46.000000000 +0100
+++ new/cmapfile-2026.1.8/setup.py 2026-01-09 00:59:44.000000000 +0100
@@ -8,15 +8,16 @@
from setuptools import setup
-def search(pattern, string, flags=0):
+def search(pattern: str, string: str, flags: int = 0) -> str:
"""Return first match of pattern in string."""
match = re.search(pattern, string, flags)
if match is None:
- raise ValueError(f'{pattern!r} not found')
+ msg = f'{pattern=!r} not found'
+ raise ValueError(msg)
return match.groups()[0]
-def fix_docstring_examples(docstring):
+def fix_docstring_examples(docstring: str) -> str:
"""Return docstring with examples fixed for GitHub."""
start = True
indent = False
@@ -48,7 +49,7 @@
)
readme = '\n'.join(
- [description, '=' * len(description)] + readme.splitlines()[1:]
+ [description, '=' * len(description), *readme.splitlines()[1:]]
)
if 'sdist' in sys.argv:
@@ -65,13 +66,27 @@
license = license.replace('# ', '').replace('#', '')
with open('LICENSE', 'w', encoding='utf-8') as fh:
- fh.write('BSD 3-Clause License\n\n')
+ fh.write('BSD-3-Clause license\n\n')
fh.write(license)
+ revisions = search(
+ r'(?:\r\n|\r|\n){2}(Revisions.*)- …',
+ readme,
+ re.MULTILINE | re.DOTALL,
+ ).strip()
+
+ with open('CHANGES.rst', encoding='utf-8') as fh:
+ old = fh.read()
+
+ old = old.split(revisions.splitlines()[-1])[-1]
+ with open('CHANGES.rst', 'w', encoding='utf-8') as fh:
+ fh.write(revisions.strip())
+ fh.write(old)
+
setup(
name='cmapfile',
version=version,
- license='BSD',
+ license='BSD-3-Clause',
description=description,
long_description=readme,
long_description_content_type='text/x-rst',
@@ -85,7 +100,7 @@
},
packages=['cmapfile'],
package_data={'cmapfile': ['py.typed']},
- python_requires='>=3.10',
+ python_requires='>=3.11',
install_requires=[
'numpy',
'scipy',
@@ -98,14 +113,13 @@
platforms=['any'],
classifiers=[
'Development Status :: 4 - Beta',
- 'License :: OSI Approved :: BSD License',
'Intended Audience :: Science/Research',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python :: 3 :: Only',
- 'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3.13',
+ 'Programming Language :: Python :: 3.14',
],
)