Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-quantities for openSUSE:Factory checked in at 2026-02-26 18:52:01 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-quantities (Old) and /work/SRC/openSUSE:Factory/.python-quantities.new.29461 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-quantities" Thu Feb 26 18:52:01 2026 rev:13 rq:1335181 version:0.16.4 Changes: -------- --- /work/SRC/openSUSE:Factory/python-quantities/python-quantities.changes 2024-11-27 22:15:09.378048652 +0100 +++ /work/SRC/openSUSE:Factory/.python-quantities.new.29461/python-quantities.changes 2026-02-26 18:52:24.510914399 +0100 @@ -1,0 +2,19 @@ +Thu Feb 26 01:52:20 UTC 2026 - Steve Kowalik <[email protected]> + +- Update to 0.16.4: + * deepcopy was not copying all necessary attributes of UnitQuantity; + in-place arithmetic didn't handle multiplying by scalars + * Fix broken `deepcopy` behaviour when using quantities with NumPy 2.x + * Fixes for assorted breakages that appear with recent NumPy versions + * Revert to previous behaviour where spaces around units were allowed + * Fix broken in-place arithmetic when using quantities with NumPy 2.x + * Add CI testing for Python 3.13 and 3.14, drop support for Python 3.9 + * Add CI testing for NumPy versions 2.1 to 2.4, drop support for NumPy 1.22 + and 1.23. + * Added a property `dimensionless_magnitude` to the Quantity class + * Implemented an alternative approach to avoiding arbitrary evaluation of + code when parsing strings as units, which fixes some bugs introduced in + v0.16.1 + * Added the kilonewton + +------------------------------------------------------------------- Old: ---- quantities-0.16.1.tar.gz New: ---- quantities-0.16.4.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-quantities.spec ++++++ --- /var/tmp/diff_new_pack.kiCJly/_old 2026-02-26 18:52:25.358949698 +0100 +++ /var/tmp/diff_new_pack.kiCJly/_new 2026-02-26 18:52:25.358949698 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-quantities # -# Copyright (c) 2024 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 @@ -17,15 +17,15 @@ Name: python-quantities -Version: 0.16.1 +Version: 0.16.4 Release: 0 Summary: Package for physical quantities with units License: BSD-3-Clause URL: https://github.com/python-quantities/python-quantities/ Source: https://files.pythonhosted.org/packages/source/q/quantities/quantities-%{version}.tar.gz Patch0: reproducible.patch -BuildRequires: %{python_module base >= 3.9} -BuildRequires: %{python_module numpy >= 1.22} +BuildRequires: %{python_module base >= 3.10} +BuildRequires: %{python_module numpy >= 1.24} BuildRequires: %{python_module pip} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools_scm} @@ -33,7 +33,7 @@ BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: python-numpy >= 1.22 +Requires: python-numpy >= 1.24 BuildArch: noarch %python_subpackages ++++++ quantities-0.16.1.tar.gz -> quantities-0.16.4.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/.github/workflows/test.yml new/quantities-0.16.4/.github/workflows/test.yml --- old/quantities-0.16.1/.github/workflows/test.yml 2024-08-27 11:37:05.000000000 +0200 +++ new/quantities-0.16.4/.github/workflows/test.yml 2026-01-16 11:42:01.000000000 +0100 @@ -12,14 +12,17 @@ fail-fast: false matrix: os: [ ubuntu-latest ] - python-version: [ "3.9", "3.10", "3.11", "3.12" ] - numpy-version: [ "1.22", "1.23", "1.24", "1.25", "1.26", "2.0" ] + python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14" ] + numpy-version: [ "1.24", "1.25", "1.26", "2.0", "2.1", "2.2", "2.3", "2.4" ] exclude: - - python-version: "3.12" - numpy-version: "1.22" + - python-version: "3.10" + numpy-version: "2.3" os: ubuntu-latest - - python-version: "3.12" - numpy-version: "1.23" + - python-version: "3.10" + numpy-version: "2.4" + os: ubuntu-latest + - python-version: "3.11" + numpy-version: "2.4" os: ubuntu-latest - python-version: "3.12" numpy-version: "1.24" @@ -27,24 +30,39 @@ - python-version: "3.12" numpy-version: "1.25" os: ubuntu-latest - - python-version: "3.12" - numpy-version: "2.0" + - python-version: "3.13" + numpy-version: "1.24" + os: ubuntu-latest + - python-version: "3.13" + numpy-version: "1.25" + os: ubuntu-latest + - python-version: "3.13" + numpy-version: "1.26" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.24" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.25" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.26" os: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - name: Get pip cache dir id: pip-cache run: | - echo "::set-output name=dir::$(pip cache dir)" + echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT - name: Cache - uses: actions/cache@v2 + uses: actions/cache@v4 with: path: ${{ steps.pip-cache.outputs.dir }} key: @@ -75,14 +93,17 @@ fail-fast: false matrix: os: [ ubuntu-latest ] - python-version: [ "3.9", "3.10", "3.11", "3.12" ] - numpy-version: [ "1.22", "1.23", "1.24", "1.25", "1.26", "2.0" ] + python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14" ] + numpy-version: [ "1.24", "1.25", "1.26", "2.0", "2.1", "2.2", "2.3", "2.4" ] exclude: - - python-version: "3.12" - numpy-version: "1.22" + - python-version: "3.10" + numpy-version: "2.3" os: ubuntu-latest - - python-version: "3.12" - numpy-version: "1.23" + - python-version: "3.10" + numpy-version: "2.4" + os: ubuntu-latest + - python-version: "3.11" + numpy-version: "2.4" os: ubuntu-latest - python-version: "3.12" numpy-version: "1.24" @@ -90,21 +111,39 @@ - python-version: "3.12" numpy-version: "1.25" os: ubuntu-latest + - python-version: "3.13" + numpy-version: "1.24" + os: ubuntu-latest + - python-version: "3.13" + numpy-version: "1.25" + os: ubuntu-latest + - python-version: "3.13" + numpy-version: "1.26" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.24" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.25" + os: ubuntu-latest + - python-version: "3.14" + numpy-version: "1.26" + os: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - name: Get pip cache dir id: pip-cache run: | - echo "::set-output name=dir::$(pip cache dir)" + echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT - name: Cache - uses: actions/cache@v2 + uses: actions/cache@v4 with: path: ${{ steps.pip-cache.outputs.dir }} key: @@ -118,6 +157,7 @@ python -m pip install -U setuptools python -m pip install -U wheel python -m pip install "numpy==${{ matrix.numpy-version }}" + python -m pip install -U pytest python -m pip install -U mypy - name: Install diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/CHANGES.txt new/quantities-0.16.4/CHANGES.txt --- old/quantities-0.16.1/CHANGES.txt 2024-10-16 16:56:02.000000000 +0200 +++ new/quantities-0.16.4/CHANGES.txt 2026-01-16 11:42:01.000000000 +0100 @@ -3,6 +3,31 @@ ======= ------ +0.16.4 +------ + +- Fix problems with v0.16.3: deepcopy was not copying all necessary attributes of UnitQuantity; in-place arithmetic didn't handle multiplying by scalars + +------ +0.16.3 +------ + +- Fix broken `deepcopy` behaviour when using quantities with NumPy 2.x (`PR#257 <https://github.com/python-quantities/python-quantities/pull/257>`_) +- Fixes for assorted breakages that appear with recent NumPy versions (`PR#262 <https://github.com/python-quantities/python-quantities/pull/262>`_, `PR#267 <<https://github.com/python-quantities/python-quantities/pull/267>`_) +- Revert to previous behaviour where spaces around units were allowed (`PR#270 <https://github.com/python-quantities/python-quantities/pull/270>`_) +- Fix broken in-place arithmetic when using quantities with NumPy 2.x (`PR#271 <https://github.com/python-quantities/python-quantities/pull/271>`_) +- Add CI testing for Python 3.13 and 3.14, drop support for Python 3.9 +- Add CI testing for NumPy versions 2.1 to 2.4, drop support for NumPy 1.22 and 1.23. + +------ +0.16.2 +------ + +- Added a property `dimensionless_magnitude` to the Quantity class ([`PR#248 <https://github.com/python-quantities/python-quantities/pull/248>`_]) +- Implemented an alternative approach to avoiding arbitrary evaluation of code when parsing strings as units, which fixes some bugs introduced in v0.16.1 ([`PR#251 <https://github.com/python-quantities/python-quantities/pull/251>`_]) +- Added the kilonewton + +------ 0.16.1 ------ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/PKG-INFO new/quantities-0.16.4/PKG-INFO --- old/quantities-0.16.1/PKG-INFO 2024-10-16 17:00:07.231928800 +0200 +++ new/quantities-0.16.4/PKG-INFO 2026-01-16 11:42:09.587728000 +0100 @@ -1,83 +1,9 @@ -Metadata-Version: 2.1 +Metadata-Version: 2.4 Name: quantities -Version: 0.16.1 +Version: 0.16.4 Summary: Support for physical quantities with units, based on numpy Author-email: Darren Dale <[email protected]> Maintainer-email: Andrew Davison <[email protected]> -License: .. _license: - - *********************************************** - License - *********************************************** - - - Quantities only uses BSD compatible code. See the Open Source - Initiative `licenses page <http://www.opensource.org/licenses>`_ - for details on individual licenses. - - License Agreement for Quantities - ================================ - - Copyright (c) 2012, Darren Dale <[email protected]> - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - 3. Neither the name of the University nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - SUCH DAMAGE. - - - License Agreement for Scimath - ============================= - - This software is OSI Certified Open Source Software. - OSI Certified is a certification mark of the Open Source Initiative. - - Copyright (c) 2006, Enthought, Inc. - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - - * Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - * Neither the name of Enthought, Inc. nor the names of its contributors may - be used to endorse or promote products derived from this software without - specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR - ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - Project-URL: documentation, http://python-quantities.readthedocs.io/ Project-URL: repository, https://github.com/python-quantities/python-quantities Project-URL: changelog, https://github.com/python-quantities/python-quantities/blob/master/CHANGES.txt @@ -89,19 +15,22 @@ Classifier: Intended Audience :: Education Classifier: Intended Audience :: End Users/Desktop Classifier: Intended Audience :: Science/Research -Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python Classifier: Topic :: Education Classifier: Topic :: Scientific/Engineering -Requires-Python: >=3.9 +Requires-Python: >=3.10 Description-Content-Type: text/x-rst -Requires-Dist: numpy>=1.20 +License-File: doc/user/license.rst +Requires-Dist: numpy>=1.24 Provides-Extra: test Requires-Dist: pytest; extra == "test" Requires-Dist: wheel; extra == "test" Provides-Extra: doc Requires-Dist: sphinx; extra == "doc" +Provides-Extra: scipy +Requires-Dist: scipy; extra == "scipy" +Dynamic: license-file ========== quantities @@ -163,12 +92,8 @@ Installation ------------ -quantities has a hard dependency on the `NumPy <http://www.numpy.org>`_ library. -You should install it first, please refer to the NumPy installation guide: -http://docs.scipy.org/doc/numpy/user/install.html - -To install quantities itself, then simply run:: +To install quantities itself, simply run:: $ pip install quantities diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/README.rst new/quantities-0.16.4/README.rst --- old/quantities-0.16.1/README.rst 2023-02-17 09:54:51.000000000 +0100 +++ new/quantities-0.16.4/README.rst 2026-01-16 11:42:01.000000000 +0100 @@ -58,12 +58,8 @@ Installation ------------ -quantities has a hard dependency on the `NumPy <http://www.numpy.org>`_ library. -You should install it first, please refer to the NumPy installation guide: -http://docs.scipy.org/doc/numpy/user/install.html - -To install quantities itself, then simply run:: +To install quantities itself, simply run:: $ pip install quantities diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/codemeta.json new/quantities-0.16.4/codemeta.json --- old/quantities-0.16.1/codemeta.json 1970-01-01 01:00:00.000000000 +0100 +++ new/quantities-0.16.4/codemeta.json 2026-01-16 11:42:01.000000000 +0100 @@ -0,0 +1,178 @@ +{ + "@context": "https://w3id.org/codemeta/3.0", + "type": "SoftwareSourceCode", + "author": [ + { + "type": "Person", + "familyName": "Dale", + "givenName": "Darren" + }, + { + "id": "http://orcid.org/0000-0002-4793-7541", + "type": "Person", + "email": "[email protected]", + "familyName": "Davison", + "givenName": "Andrew P." + }, + { + "type": "Person", + "givenName": "Bjorn", + "alternateName": "@bjodah" + }, + { + "type": "Person", + "familyName": "McKenzie", + "givenName": "Zach" + }, + { + "type": "Person", + "familyName": "Mankoff", + "givenName": "Ken" + }, + { + "type": "Person", + "familyName": "Wimmer", + "givenName": "Thomas" + }, + { + "type": "Person", + "familyName": "Salvatier", + "givenName": "John" + }, + { + "type": "Person", + "familyName": "N.", + "givenName": "Takumasa", + "alternateName": "@n-takumasa" + }, + { + "type": "Person", + "familyName": "Falck", + "givenName": "Rob" + }, + { + "type": "Person", + "familyName": "Delley", + "givenName": "Yves" + }, + { + "type": "Person", + "familyName": "van Kemenade", + "givenName": "Hugo" + }, + { + "type": "Person", + "familyName": "Gerkin", + "givenName": "Richard C." + }, + { + "type": "Person", + "familyName": "Wagenaar", + "givenName": "Daniel" + }, + { + "type": "Person", + "familyName": "Konradi", + "givenName": "Peter" + }, + { + "type": "Person", + "familyName": "May", + "givenName": "Ryan" + }, + { + "type": "Person", + "familyName": "Scheltienne", + "givenName": "Mathieu" + }, + { + "type": "Person", + "familyName": "McCloy", + "givenName": "Daniel" + }, + { + "type": "Person", + "familyName": "Wilson", + "givenName": "Andy" + }, + { + "type": "Person", + "alternateName": "@dotlambda" + }, + { + "type": "Person", + "familyName": "Pfabe", + "givenName": "Johannes" + }, + { + "type": "Person", + "familyName": "Senkbeil", + "givenName": "Ryan" + }, + { + "type": "Person", + "familyName": "Gates", + "givenName": "Tim" + }, + { + "type": "Person", + "familyName": "Górny", + "givenName": "Michał" + }, + { + "type": "Person", + "alternateName": "@jadoro" + }, + { + "type": "Person", + "familyName": "Kemetmüller", + "givenName": "Josef" + }, + { + "type": "Person", + "familyName": "Sechet", + "givenName": "Olivier" + }, + { + "type": "Person", + "alternateName": "@lumbric" + }, + { + "type": "Person", + "familyName": "Yoshikawa", + "givenName": "Takashi" + }, + { + "type": "Person", + "familyName": "Jones", + "givenName": "Peter" + }, + { + "type": "Person", + "familyName": "Nelson", + "givenName": "Mark" + }, + { + "type": "Person", + "familyName": "Kaiser", + "givenName": "Jakob" + } + ], + "codeRepository": "https://github.com/python-quantities/python-quantities", + "dateCreated": "2008-12-01", + "dateModified": "2026-01-16", + "datePublished": "2009-10-13", + "description": "A Python package for handling physical quantities.\n\nQuantities is designed to handle arithmetic and conversions of physical quantities, which have a magnitude, dimensionality specified by various units, and possibly an uncertainty. Quantities builds on the popular NumPy library and is designed to work with NumPy ufuncs, many of which are already supported.", + "downloadUrl": "https://files.pythonhosted.org/packages/f2/1f/04a5078af52b1587842eccd57e805f776919ab68d9a295efa061eb8c2f58/quantities-0.16.3.tar.gz", + "license": "https://spdx.org/licenses/BSD-3-Clause", + "name": "quantities", + "operatingSystem": ["Linux", "Windows", "macOS"], + "programmingLanguage": "Python 3", + "relatedLink": "https://python-quantities.readthedocs.io/", + "releaseNotes": "https://github.com/python-quantities/python-quantities/blob/master/CHANGES.txt", + "softwareRequirements": "https://pypi.org/project/numpy/", + "version": "0.16.3", + "continuousIntegration": "https://github.com/python-quantities/python-quantities/actions", + "developmentStatus": "active", + "issueTracker": "https://github.com/python-quantities/python-quantities/issues" +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/pyproject.toml new/quantities-0.16.4/pyproject.toml --- old/quantities-0.16.1/pyproject.toml 2024-10-16 16:49:46.000000000 +0200 +++ new/quantities-0.16.4/pyproject.toml 2026-01-16 11:42:01.000000000 +0100 @@ -2,8 +2,8 @@ name = "quantities" description = "Support for physical quantities with units, based on numpy" readme = "README.rst" -requires-python = ">=3.9" -license = {file = "doc/user/license.rst"} +requires-python = ">=3.10" +license-files = ["doc/user/license.rst"] authors = [ {name = "Darren Dale", email = "[email protected]"} ] @@ -18,14 +18,13 @@ "Intended Audience :: Education", "Intended Audience :: End Users/Desktop", "Intended Audience :: Science/Research", - "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Education", "Topic :: Scientific/Engineering" ] dependencies = [ - "numpy>=1.20" + "numpy>=1.24" ] dynamic = ["version"] @@ -37,6 +36,11 @@ doc = [ "sphinx" ] +scipy = [ + # use the SciPy implementation of the trapezoidal rule + # for numerical integration, + "scipy" +] [project.urls] documentation = "http://python-quantities.readthedocs.io/" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/_version.py new/quantities-0.16.4/quantities/_version.py --- old/quantities-0.16.1/quantities/_version.py 2024-10-16 17:00:06.000000000 +0200 +++ new/quantities-0.16.4/quantities/_version.py 2026-01-16 11:42:09.000000000 +0100 @@ -1,16 +1,34 @@ -# file generated by setuptools_scm +# file generated by setuptools-scm # don't change, don't track in version control + +__all__ = [ + "__version__", + "__version_tuple__", + "version", + "version_tuple", + "__commit_id__", + "commit_id", +] + TYPE_CHECKING = False if TYPE_CHECKING: - from typing import Tuple, Union + from typing import Tuple + from typing import Union + VERSION_TUPLE = Tuple[Union[int, str], ...] + COMMIT_ID = Union[str, None] else: VERSION_TUPLE = object + COMMIT_ID = object version: str __version__: str __version_tuple__: VERSION_TUPLE version_tuple: VERSION_TUPLE +commit_id: COMMIT_ID +__commit_id__: COMMIT_ID + +__version__ = version = '0.16.4' +__version_tuple__ = version_tuple = (0, 16, 4) -__version__ = version = '0.16.1' -__version_tuple__ = version_tuple = (0, 16, 1) +__commit_id__ = commit_id = 'g66762fd38' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/constants/_codata.py new/quantities-0.16.4/quantities/constants/_codata.py --- old/quantities-0.16.1/quantities/constants/_codata.py 2024-10-16 17:00:07.000000000 +0200 +++ new/quantities-0.16.4/quantities/constants/_codata.py 2026-01-16 11:42:09.000000000 +0100 @@ -1,6 +1,6 @@ # THIS FILE IS AUTOMATICALLY GENERATED # ANY CHANGES MADE HERE WILL BE LOST -# LAST GENERATED: 2024-10-16 17:00:07.014073 +# LAST GENERATED: 2026-01-16 11:42:09.427330 physical_constants = {} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/dimensionality.py new/quantities-0.16.4/quantities/dimensionality.py --- old/quantities-0.16.1/quantities/dimensionality.py 2024-10-16 16:49:46.000000000 +0200 +++ new/quantities-0.16.4/quantities/dimensionality.py 2026-01-16 11:42:01.000000000 +0100 @@ -331,6 +331,7 @@ p_dict[np.floor] = _d_copy p_dict[np.fix] = _d_copy p_dict[np.ceil] = _d_copy +p_dict[np.trunc] = _d_copy def _d_clip(a1, a2, a3, q): return q.dimensionality diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/quantity.py new/quantities-0.16.4/quantities/quantity.py --- old/quantities-0.16.1/quantities/quantity.py 2024-10-16 16:49:46.000000000 +0200 +++ new/quantities-0.16.4/quantities/quantity.py 2026-01-16 11:42:01.000000000 +0100 @@ -16,6 +16,9 @@ # e.g. PREFERRED = [pq.mV, pq.pA, pq.UnitQuantity('femtocoulomb', 1e-15*pq.C, 'fC')] # Intended to be overwritten in down-stream packages +_np_version = tuple(map(int, np.__version__.split(".dev")[0].split("."))) + + def validate_unit_quantity(value): try: assert isinstance(value, Quantity) @@ -145,6 +148,16 @@ @property def magnitude(self): + """ + Returns a view onto the numerical value of the quantity, stripping + away the associated units. For example: + ``` + import quantities as pq + t = 2 * pq.millisecond + n = t.magnitude # n will be 2 (not 0.002) + ``` + See also: dimensionless_magnitude. + """ return self.view(type=np.ndarray) @property @@ -250,6 +263,23 @@ raise Exception("Preferred units for '%s' (or equivalent) not specified in " "quantites.quantity.PREFERRED." % self.dimensionality) + @property + def dimensionless_magnitude(self): + """ + Returns the numerical value of a dimensionless quantity in the form of + a numpy array. Any decimal prefixes are normalized away first. + For example: + ``` + import quantities as pq + t = 2 * pq.ms + f = 3 * pq.MHz + n = (t*f).dimensionless_magnitude # n will be 6000 (not 6) + ``` + If the quantity is not dimensionless, a conversion error is raised. + See also: magnitude. + """ + return self.rescale(unit_registry['dimensionless']).magnitude + @with_doc(np.ndarray.astype) def astype(self, dtype=None, **kwargs): '''Scalars are returned as scalar Quantity arrays.''' @@ -291,7 +321,7 @@ return res def __array_wrap__(self, obj, context=None, return_scalar=False): - _np_version = tuple(map(int, np.__version__.split(".dev")[0].split("."))) + # For NumPy < 2.0 we do old behavior if _np_version < (2, 0, 0): if not isinstance(obj, Quantity): @@ -315,7 +345,6 @@ @scale_other_units def __radd__(self, other): return np.add(other, self) - return super().__radd__(other) @with_doc(np.ndarray.__iadd__) @scale_other_units @@ -331,7 +360,6 @@ @scale_other_units def __rsub__(self, other): return np.subtract(other, self) - return super().__rsub__(other) @with_doc(np.ndarray.__isub__) @scale_other_units @@ -351,22 +379,46 @@ @with_doc(np.ndarray.__imul__) @protected_multiplication def __imul__(self, other): - return super().__imul__(other) + # the following is an inelegant fix for the removal of __array_prepare__ in NumPy 2.x + # the longer-term solution is probably to implement __array_ufunc__ + # See: + # - https://numpy.org/devdocs/release/2.0.0-notes.html#array-prepare-is-removed + # - https://numpy.org/neps/nep-0013-ufunc-overrides.html + if _np_version < (2, 0, 0): + return super().__imul__(other) + else: + cself = self.copy() + if hasattr(other, "copy"): + cother = other.copy() + else: + cother = other + res = super().__imul__(other) + context = (np.multiply, (cself, cother, cself), 0) + return self.__array_prepare__(res, context=context) @with_doc(np.ndarray.__rmul__) def __rmul__(self, other): return np.multiply(other, self) - return super().__rmul__(other) @with_doc(np.ndarray.__itruediv__) @protected_multiplication def __itruediv__(self, other): - return super().__itruediv__(other) + # see comment above on __imul__ + if _np_version < (2, 0, 0): + return super().__itruediv__(other) + else: + cself = self.copy() + if hasattr(other, "copy"): + cother = other.copy() + else: + cother = other + res = super().__itruediv__(other) + context = (np.true_divide, (cself, cother, cself), 0) + return self.__array_prepare__(res, context=context) @with_doc(np.ndarray.__rtruediv__) def __rtruediv__(self, other): return np.true_divide(other, self) - return super().__rtruediv__(other) @with_doc(np.ndarray.__pow__) @check_uniform @@ -377,7 +429,18 @@ @check_uniform @protected_power def __ipow__(self, other): - return super().__ipow__(other) + # see comment above on __imul__ + if _np_version < (2, 0, 0): + return super().__ipow__(other) + else: + cself = self.copy() + if hasattr(other, "copy"): + cother = other.copy() + else: + cother = other + res = super().__ipow__(other) + context = (np.power, (cself, cother, cself), 0) + return self.__array_prepare__(res, context=context) def __round__(self, decimals=0): return np.around(self, decimals) @@ -501,7 +564,6 @@ @with_doc(np.nansum) def nansum(self, axis=None, dtype=None, out=None): - import numpy as np return Quantity( np.nansum(self.magnitude, axis, dtype, out), self.dimensionality @@ -602,7 +664,7 @@ def nanargmax(self,axis=None, out=None): return np.nanargmax(self.magnitude) - @with_doc(np.ndarray.ptp) + @with_doc(np.ptp) def ptp(self, axis=None, out=None): ret = np.ptp(self.magnitude, axis, None if out is None else out.magnitude) dim = self.dimensionality @@ -682,7 +744,6 @@ @with_doc(np.nanmean) def nanmean(self, axis=None, dtype=None, out=None): - import numpy as np return Quantity( np.nanmean(self.magnitude, axis, dtype, out), self.dimensionality) @@ -777,10 +838,11 @@ (self.__class__, np.ndarray, (0, ), 'b', ), state) - def __deepcopy__(self, memo_dict): - # constructor copies by default - return Quantity(self.magnitude, self.dimensionality) - + def __deepcopy__(self, memo): + new_obj = super().__deepcopy__(memo).view(self.__class__) + new_obj.__dict__.update(self.__dict__) + memo[id(self)] = new_obj + return new_obj def _reconstruct_quantity(subtype, baseclass, baseshape, basetype,): """Internal function that builds a new MaskedArray from the diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/quantity.pyi new/quantities-0.16.4/quantities/quantity.pyi --- old/quantities-0.16.1/quantities/quantity.pyi 2023-12-08 16:56:56.000000000 +0100 +++ new/quantities-0.16.4/quantities/quantity.pyi 2026-01-16 11:42:01.000000000 +0100 @@ -86,9 +86,9 @@ # NOTE divmod is not supported - def __pow__(self, power) -> Quantity: ... - def __rpow__(self, power) -> Quantity: ... - def __ipow__(self, power) -> Quantity: ... + def __pow__(self, power) -> Quantity: ... # type: ignore[override] + def __rpow__(self, power) -> Quantity: ... # type: ignore[override] + def __ipow__(self, power) -> Quantity: ... # type: ignore[override] # shift and bitwise are not supported @@ -110,5 +110,5 @@ def __getitem__(self, item: Any) -> Quantity: ... - def __setitem__(self, key: int, value: QuantityData) -> None: + def __setitem__(self, key: int, value: QuantityData) -> None: # type: ignore ... diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/registry.py new/quantities-0.16.4/quantities/registry.py --- old/quantities-0.16.1/quantities/registry.py 2024-10-16 16:49:46.000000000 +0200 +++ new/quantities-0.16.4/quantities/registry.py 2026-01-16 11:42:01.000000000 +0100 @@ -1,41 +1,51 @@ """ """ +import ast import re -import builtins class UnitRegistry: + # Note that this structure ensures that UnitRegistry behaves as a singleton class __Registry: __shared_state = {} + whitelist = ( + ast.Expression, + ast.Constant, + ast.Name, + ast.Load, + ast.BinOp, + ast.UnaryOp, + ast.operator, + ast.unaryop, + ) def __init__(self): self.__dict__ = self.__shared_state self.__context = {} def __getitem__(self, string): - - # easy hack to prevent arbitrary evaluation of code - all_builtins = dir(builtins) - # because we have kilobytes, other bytes we have to remove bytes - all_builtins.remove("bytes") - # have to deal with octet as well - all_builtins.remove("oct") - # have to remove min which is short for minute - all_builtins.remove("min") - for builtin in all_builtins: - if builtin in string: - raise RuntimeError(f"String parsing error for `{string}`. Enter a string accepted by quantities") - - try: - return eval(string, self.__context) - except NameError: + # This approach to avoiding arbitrary evaluation of code is based on https://stackoverflow.com/a/11952618 + # by https://stackoverflow.com/users/567292/ecatmur + stripped_string = string.strip() # discard leading or trailing spaces before parsing + tree = ast.parse(stripped_string, mode="eval") + valid = all(isinstance(node, self.whitelist) for node in ast.walk(tree)) + if valid: + try: + item = eval( + compile(tree, filename="", mode="eval"), + {"__builtins__": {}}, + self.__context, + ) + except NameError: + raise LookupError('Unable to parse units: "%s"' % string) + else: + return item + else: # could return self['UnitQuantity'](string) - raise LookupError( - 'Unable to parse units: "%s"'%string - ) + raise LookupError('Unable to parse units: "%s"' % string) def __setitem__(self, string, val): assert isinstance(string, str) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/tests/test_arithmetic.py new/quantities-0.16.4/quantities/tests/test_arithmetic.py --- old/quantities-0.16.1/quantities/tests/test_arithmetic.py 2024-10-16 16:49:46.000000000 +0200 +++ new/quantities-0.16.4/quantities/tests/test_arithmetic.py 2026-01-16 11:42:01.000000000 +0100 @@ -367,12 +367,46 @@ self.assertRaises(ValueError, op.isub, [1, 2, 3]*pq.m, pq.J) self.assertRaises(ValueError, op.isub, [1, 2, 3]*pq.m, 5*pq.J) + def test_in_place_multiplication(self): + velocity = 3 * pq.m/pq.s + time = 2 * pq.s + + self.assertQuantityEqual(velocity * time, 6 * pq.m) + + distance = velocity.copy() + distance *= time + self.assertQuantityEqual(distance, 6 * pq.m) + + velocity *= 2 + self.assertQuantityEqual(velocity, 6 * pq.m/pq.s) + def test_division(self): molar = pq.UnitQuantity('M', 1000 * pq.mole/pq.m**3, u_symbol='M') for subtr in [1, 1.0]: q = 1*molar/(1000*pq.mole/pq.m**3) self.assertQuantityEqual((q - subtr).simplified, 0) + a = np.array([5, 10, 15]) * pq.s + b = np.array([2, 4, 6]) * pq.kg + + c = a / b + self.assertQuantityEqual(c, np.array([2.5, 2.5, 2.5]) * pq.s / pq.kg) + + def test_in_place_division(self): + a = np.array([5, 10, 15]) * pq.s + b = np.array([2, 4, 6]) * pq.kg + + a /= b + self.assertQuantityEqual(a, np.array([2.5, 2.5, 2.5]) * pq.s / pq.kg) + + b /= 2 + self.assertQuantityEqual(b, np.array([1, 2, 3]) * pq.kg) + + c = np.array([5, 10, 15]) * pq.s + d = np.array([2, 4, 6]) + c /= d + self.assertQuantityEqual(c, np.array([2.5, 2.5, 2.5]) * pq.s) + def test_powering(self): # test raising a quantity to a power self.assertQuantityEqual((5.5 * pq.cm)**5, (5.5**5) * (pq.cm**5)) @@ -403,3 +437,12 @@ def ipow(q1, q2): q1 -= q2 self.assertRaises(ValueError, ipow, 1*pq.m, [1, 2]) + + def test_inplace_powering(self): + a = 5.5 * pq.cm + a **= 5 + self.assertQuantityEqual(a, (5.5**5) * (pq.cm**5)) + + b = np.array([1, 2, 3, 4, 5]) * pq.kg + b **= 3 + self.assertQuantityEqual(b, np.array([1, 8, 27, 64, 125]) * pq.kg**3) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/tests/test_methods.py new/quantities-0.16.4/quantities/tests/test_methods.py --- old/quantities-0.16.1/quantities/tests/test_methods.py 2024-08-27 11:37:05.000000000 +0200 +++ new/quantities-0.16.4/quantities/tests/test_methods.py 2026-01-16 11:42:01.000000000 +0100 @@ -356,3 +356,10 @@ Quantity(10, pq.deg).rescale(pq.rad), np.pi/18*pq.rad ) + + def test_dimensionless_magnitude(self): + self.assertEqual((pq.kg/pq.g).dimensionless_magnitude, 1000) + self.assertQuantityEqual((self.q / pq.cm).dimensionless_magnitude, + 100 * self.q.magnitude) + self.assertRaises(ValueError, lambda x: x.dimensionless_magnitude, + self.q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/tests/test_persistence.py new/quantities-0.16.4/quantities/tests/test_persistence.py --- old/quantities-0.16.1/quantities/tests/test_persistence.py 2022-03-03 15:06:04.000000000 +0100 +++ new/quantities-0.16.4/quantities/tests/test_persistence.py 2026-01-16 11:42:01.000000000 +0100 @@ -71,6 +71,18 @@ y = copy.copy(x) self.assertQuantityEqual(x, y) + def test_deepcopy_quantity(self): + x = [1, 2, 3] * pq.m + y = copy.deepcopy(x) + self.assertQuantityEqual(x, y) + + y[0] = 100 * pq.m + self.assertQuantityEqual(x, [1, 2, 3] * pq.m) + + # deepcopy of UnitLength + metre = copy.deepcopy(pq.m) + repr(metre) # accesses the "_definition" attribute + def test_copy_uncertainquantity(self): for dtype in [float, object]: x = UncertainQuantity(20, 'm', 0.2).astype(dtype) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/tests/test_units.py new/quantities-0.16.4/quantities/tests/test_units.py --- old/quantities-0.16.1/quantities/tests/test_units.py 2022-03-03 15:06:04.000000000 +0100 +++ new/quantities-0.16.4/quantities/tests/test_units.py 2026-01-16 11:42:01.000000000 +0100 @@ -1,6 +1,9 @@ +import pytest + from .. import units as pq from .common import TestCase + class TestUnits(TestCase): def test_compound_units(self): @@ -30,3 +33,8 @@ self.assertQuantityEqual(pq.m.copy(), pq.m) pc_per_cc = pq.CompoundUnit("pc/cm**3") self.assertQuantityEqual(pc_per_cc.copy(), pc_per_cc) + + def test_code_injection(self): + with pytest.raises(LookupError) as exc_info: + pq.CompoundUnit("exec(\"print('Hello there.')\\nprint('General Wasabi!')\")") + assert "Wasabi" in str(exc_info.value) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/unitquantity.pyi new/quantities-0.16.4/quantities/unitquantity.pyi --- old/quantities-0.16.1/quantities/unitquantity.pyi 2023-12-08 16:56:56.000000000 +0100 +++ new/quantities-0.16.4/quantities/unitquantity.pyi 2026-01-16 11:42:01.000000000 +0100 @@ -86,10 +86,10 @@ def __rtruediv__(self, other) -> Any: ... - def __pow__(self, other) -> Quantity: + def __pow__(self, other) -> Quantity: # type: ignore[override] ... - def __rpow__(self, other) -> Quantity: + def __rpow__(self, other) -> Quantity: # type: ignore[override] ... diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/units/force.py new/quantities-0.16.4/quantities/units/force.py --- old/quantities-0.16.1/quantities/units/force.py 2022-03-03 15:06:04.000000000 +0100 +++ new/quantities-0.16.4/quantities/units/force.py 2026-01-16 11:42:01.000000000 +0100 @@ -14,6 +14,12 @@ symbol='N', aliases=['newtons'] ) +kN = kilonewton = UnitQuantity( + 'kilonewton', + 1000*N, + symbol='kN', + aliases=['kilonewtons'] +) dyne = UnitQuantity( 'dyne', gram*cm/s**2, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities/units/force.pyi new/quantities-0.16.4/quantities/units/force.pyi --- old/quantities-0.16.1/quantities/units/force.pyi 2023-04-05 14:23:40.000000000 +0200 +++ new/quantities-0.16.4/quantities/units/force.pyi 2026-01-16 11:42:01.000000000 +0100 @@ -2,6 +2,7 @@ N: UnitQuantity newton: UnitQuantity +kilonewton: UnitQuantity dyne: UnitQuantity pond: UnitQuantity kgf: UnitQuantity diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities.egg-info/PKG-INFO new/quantities-0.16.4/quantities.egg-info/PKG-INFO --- old/quantities-0.16.1/quantities.egg-info/PKG-INFO 2024-10-16 17:00:07.000000000 +0200 +++ new/quantities-0.16.4/quantities.egg-info/PKG-INFO 2026-01-16 11:42:09.000000000 +0100 @@ -1,83 +1,9 @@ -Metadata-Version: 2.1 +Metadata-Version: 2.4 Name: quantities -Version: 0.16.1 +Version: 0.16.4 Summary: Support for physical quantities with units, based on numpy Author-email: Darren Dale <[email protected]> Maintainer-email: Andrew Davison <[email protected]> -License: .. _license: - - *********************************************** - License - *********************************************** - - - Quantities only uses BSD compatible code. See the Open Source - Initiative `licenses page <http://www.opensource.org/licenses>`_ - for details on individual licenses. - - License Agreement for Quantities - ================================ - - Copyright (c) 2012, Darren Dale <[email protected]> - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - 3. Neither the name of the University nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - SUCH DAMAGE. - - - License Agreement for Scimath - ============================= - - This software is OSI Certified Open Source Software. - OSI Certified is a certification mark of the Open Source Initiative. - - Copyright (c) 2006, Enthought, Inc. - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - - * Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - * Neither the name of Enthought, Inc. nor the names of its contributors may - be used to endorse or promote products derived from this software without - specific prior written permission. - - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR - ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - Project-URL: documentation, http://python-quantities.readthedocs.io/ Project-URL: repository, https://github.com/python-quantities/python-quantities Project-URL: changelog, https://github.com/python-quantities/python-quantities/blob/master/CHANGES.txt @@ -89,19 +15,22 @@ Classifier: Intended Audience :: Education Classifier: Intended Audience :: End Users/Desktop Classifier: Intended Audience :: Science/Research -Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python Classifier: Topic :: Education Classifier: Topic :: Scientific/Engineering -Requires-Python: >=3.9 +Requires-Python: >=3.10 Description-Content-Type: text/x-rst -Requires-Dist: numpy>=1.20 +License-File: doc/user/license.rst +Requires-Dist: numpy>=1.24 Provides-Extra: test Requires-Dist: pytest; extra == "test" Requires-Dist: wheel; extra == "test" Provides-Extra: doc Requires-Dist: sphinx; extra == "doc" +Provides-Extra: scipy +Requires-Dist: scipy; extra == "scipy" +Dynamic: license-file ========== quantities @@ -163,12 +92,8 @@ Installation ------------ -quantities has a hard dependency on the `NumPy <http://www.numpy.org>`_ library. -You should install it first, please refer to the NumPy installation guide: -http://docs.scipy.org/doc/numpy/user/install.html - -To install quantities itself, then simply run:: +To install quantities itself, simply run:: $ pip install quantities diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities.egg-info/SOURCES.txt new/quantities-0.16.4/quantities.egg-info/SOURCES.txt --- old/quantities-0.16.1/quantities.egg-info/SOURCES.txt 2024-10-16 17:00:07.000000000 +0200 +++ new/quantities-0.16.4/quantities.egg-info/SOURCES.txt 2026-01-16 11:42:09.000000000 +0100 @@ -4,6 +4,7 @@ CHANGES.txt MANIFEST.in README.rst +codemeta.json pyproject.toml setup.py .github/workflows/test.yml diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/quantities-0.16.1/quantities.egg-info/requires.txt new/quantities-0.16.4/quantities.egg-info/requires.txt --- old/quantities-0.16.1/quantities.egg-info/requires.txt 2024-10-16 17:00:07.000000000 +0200 +++ new/quantities-0.16.4/quantities.egg-info/requires.txt 2026-01-16 11:42:09.000000000 +0100 @@ -1,8 +1,11 @@ -numpy>=1.20 +numpy>=1.24 [doc] sphinx +[scipy] +scipy + [test] pytest wheel
