d9b1c61d80
- Update to 4.0.1.post1 * astropy.config [gh#astropy/astropy#9975] Fixed a bug where importing a development version of a package that uses ``astropy`` configuration system can result in a ``~/.astropy/config/package..cfg`` file. * astropy.coordinates [gh#astropy/astropy#9815] Fixed a bug where a vestigal trace of a frame class could persist in the transformation graph even after the removal of all transformations involving that frame class. [gh#astropy/astropy#9815] Fixed a bug with ``TransformGraph.remove_transform()`` when the "from" and "to" frame classes are not explicitly specified. [gh#astropy/astropy#9900] Read-only longitudes can now be passed in to ``EarthLocation`` even if they include angles outside of the range of -180 to 180 degrees. [gh#astropy/astropy#9980] ```SkyCoord.radial_velocity_correction``` no longer raises an Exception when space motion information is present on the SkyCoord. * astropy.io [gh#astropy/astropy#9866] Fixed a bug that prevented the unified I/O infrastructure from working with datasets that are represented by directories rather than files. * astropy.io.ascii [gh#astropy/astropy#9918] Fixed a bug in the ``fast_reader`` C parsers incorrectly returning entries of isolated positive/negative signs as ``float`` instead of ``str``. [gh#astropy/astropy#9923] Fixed a segmentation fault in the ``fast_reader`` C parsers when parsing an invalid file with ``guess=True`` and the file contains inconsistent column numbers in combination with a quoted field; e.g., ``"1 2\n 3 4 '5'"``. [gh#astropy/astropy#9933] Magnitude, decibel, and dex can now be stored in ``ecsv`` files. * astropy.io.misc [gh#astropy/astropy#9933] Magnitude, decibel, and dex can now be stored in ``hdf5`` files. [gh#astropy/astropy#9956, gh#astropy/astropy#9961] Fixed serialization of polynomial models to include non default values of domain and window values. [gh#astropy/astropy#9950] Fixed a bug which affected overwriting tables within ``hdf5`` files. Overwriting an existing path with associated column meta data now also overwrites the meta data associated with the table. [gh#astropy/astropy#9983] Fixed serialization of Time objects with location under time-1.0.0 ASDF schema. * astropy.io.fits [gh#astropy/astropy#9711, gh#astropy/astropy#9934] Fix regression with ``GroupsHDU`` which needs to modify the header to handle invalid headers, and fix accesing ``.data`` for empty HDU. [gh#astropy/astropy#9711] Fix ``fitsdiff`` when its arguments are directories that contain other directories. [gh#astropy/astropy#9958] Fix writing noncontiguous data to a compressed HDU. [gh#astropy/astropy#9978] Added verification of ``disp`` (``TDISP``) keyword to ``fits.Column`` and extended tests for ``TFORM`` and ``TDISP`` validation. [gh#astropy/astropy#10012] Fix checksum verification to process all HDUs instead of only the first one because of the lazy loading feature. [gh#astropy/astropy#10030] Allow passing ``output_verify`` to ``.close`` when using the context manager. [gh#astropy/astropy#10041] Prevent instantiation of ``PrimaryHDU`` and ``ImageHDU`` with a scalar. [gh#astropy/astropy#10069] Fix column access by attribute with FITS_rec: columns with scaling or columns from ASCII tables where not properly converted when accessed by attribute name. * astropy.io.misc [gh#astropy/astropy#9933] Magnitude, decibel, and dex can now be stored in ``hdf5`` files. [gh#astropy/astropy#9956, gh#astropy/astropy#9961] Fixed serialization of polynomial models to include non default values of domain and window values. [gh#astropy/astropy#9950] Fixed a bug which affected overwriting tables within ``hdf5`` files. Overwriting an existing path with associated column meta data now also overwrites the meta data associated with the table. [gh#astropy/astropy#9983] Fixed serialization of Time objects with location under time-1.0.0 ASDF schema. * astropy.modeling [gh#astropy/astropy#9987] Fixed a bug in setting default values of parameters of orthonormal polynomials when constructing a model set. * astropy.table [gh#astropy/astropy#9839] Fixed bug in ``Table.reverse`` for tables that contain non-mutable mixin columns (like ``SkyCoord``) for which in-place item update is not allowed. [gh#astropy/astropy#9933] Tables containing Magnitude, decibel, and dex columns can now be saved to ``ecsv`` files. [gh#astropy/astropy#10027] Fixed bug where adding or inserting a row fails on a table with an index defined on a column that is not the first one. [gh#astropy/astropy#10068] Ensured that ``table.show_in_browser`` also worked for mixin columns like ``Time`` and ``SkyCoord``. * astropy.time [gh#astropy/astropy#9679] Fix inaccuracy when converting between TimeDelta and datetime.timedelta. [gh#astropy/astropy#9812] Fixed exception when changing ``format`` in the case when ``out_subfmt`` is defined and is incompatible with the new format. [gh#astropy/astropy#9812] Fixed exceptions in ``Time.to_value()``: when supplying any ``subfmt`` argument for string-based formats like 'iso', and for ``subfmt='long'`` for the formats 'byear', 'jyear', and 'decimalyear'. [gh#astropy/astropy#9969] Fixed bug where the location attribute was lost when creating a new ``Time`` object from an existing ``Time`` or list of ``Time`` objects. [gh#astropy/astropy#10034] Fixed a bug where an exception occurred when creating a ``Time`` object if the ``val1`` argument was a regular double and the ``val2`` argument was a ``longdouble``. * astropy.timeseries [gh#astropy/astropy#10013] Fixed issue with reference time for the ``transit_time`` parameter returned by the ``BoxLeastSquares`` periodogram. Now, the ``transit_time`` will be within the range of the input data and arbitrary time offsets/zero points no longer affect results. * astropy.units [gh#astropy/astropy#9948] Fix for ``quantity_input`` annotation raising an exception on iterable types that don't define a general ``__contains__`` for checking if ``None`` is contained (e.g. Enum as of python3.8), by instead checking for instance of Sequence. [gh#astropy/astropy#10066] Fix for ``u.Quantity`` not taking into account ``ndmin`` if constructed from another ``u.Quantity`` instance with different but convertible unit * astropy.utils [gh#astropy/astropy#9981] Fixed ``deprecated_renamed_argument`` not passing in user value to deprecated keyword when the keyword has no new name. [gh#astropy/astropy#9985] Fixed ``deprecated_renamed_argument`` not issuing a deprecation warning when deprecated keyword without new name is passed in as positional argument. [gh#astropy/astropy#10007] Fixed detection of read-only filesystems in the caching code. * astropy.visualization [gh#astropy/astropy#9848] Fixed bug from matplotlib >=3.1 where an empty Quantity array is sent for unit conversion as an empty list. [gh#astropy/astropy#9913] Fix bug in ``ZScaleInterval`` to return the array minimum and maximum when there are less then ``min_npixels`` in the input array. [gh#astropy/astropy#8004, gh#astropy/astropy#9991] Fix a bug in simplifying axis labels that affected non-rectangular frames. * Increase minimum asdf version to 2.5.2. [gh#astropy/astropy#9996, gh#astropy/astropy#9819] * Updated wcslib to v7.2. [gh#astropy/astropy#10021] - updated test requirements and recommends - run pytest directly OBS-URL: https://build.opensuse.org/request/show/795557 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-astropy?expand=0&rev=23
164 lines
6.4 KiB
RPMSpec
164 lines
6.4 KiB
RPMSpec
#
|
|
# spec file for package python-astropy
|
|
#
|
|
# Copyright (c) 2020 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
%define skip_python2 1
|
|
Name: python-astropy
|
|
Version: 4.0.1.post1
|
|
Release: 0
|
|
Summary: Community-developed python astronomy tools
|
|
License: BSD-3-Clause
|
|
URL: https://astropy.org
|
|
Source: https://files.pythonhosted.org/packages/source/a/astropy/astropy-%{version}.tar.gz
|
|
# Mark wcs headers as false positives for devel-file-in-non-devel-package
|
|
# These are used by the python files so they must be available.
|
|
Source100: python-astropy-rpmlintrc
|
|
BuildRequires: %{python_module Cython >= 0.21}
|
|
BuildRequires: %{python_module astropy-helpers}
|
|
BuildRequires: %{python_module devel}
|
|
BuildRequires: %{python_module numpy-devel >= 1.16}
|
|
BuildRequires: %{python_module ply}
|
|
BuildRequires: %{python_module setuptools}
|
|
BuildRequires: fdupes
|
|
BuildRequires: hdf5-devel
|
|
BuildRequires: libxml2-tools
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: python-rpm-macros
|
|
BuildRequires: pkgconfig(cfitsio)
|
|
BuildRequires: pkgconfig(erfa) >= 1.7.0
|
|
BuildRequires: pkgconfig(expat)
|
|
BuildRequires: pkgconfig(wcslib)
|
|
Requires: hdf5
|
|
Requires: liberfa1 >= 1.7.0
|
|
Requires: python-dbm
|
|
Requires: python-matplotlib >= 2.1
|
|
Requires: python-numpy >= 1.7.0
|
|
Recommends: libxml2-tools
|
|
Recommends: python-Jinja2
|
|
Recommends: python-PyYAML
|
|
Recommends: python-asdf >= 2.5
|
|
Recommends: python-beautifulsoup4
|
|
Recommends: python-Bottleneck
|
|
Recommends: python-bleach
|
|
Recommends: python-h5py
|
|
Recommends: python-ipython
|
|
Recommends: python-jplephem
|
|
Recommends: python-matplotlib >= 2.1
|
|
Recommends: python-pandas
|
|
Recommends: python-scikit-image
|
|
Recommends: python-scipy >= 0.18
|
|
Conflicts: perl-Data-ShowTable
|
|
# SECTION Optional requirements
|
|
BuildRequires: %{python_module Bottleneck}
|
|
BuildRequires: %{python_module Jinja2}
|
|
BuildRequires: %{python_module PyYAML}
|
|
BuildRequires: %{python_module asdf >= 2.5}
|
|
BuildRequires: %{python_module beautifulsoup4}
|
|
BuildRequires: %{python_module bleach}
|
|
BuildRequires: %{python_module h5py}
|
|
BuildRequires: %{python_module ipython}
|
|
BuildRequires: %{python_module jplephem}
|
|
BuildRequires: %{python_module matplotlib >= 2.1}
|
|
BuildRequires: %{python_module pandas}
|
|
BuildRequires: %{python_module scikit-image}
|
|
BuildRequires: %{python_module scipy >= 0.18}
|
|
# /SECTION
|
|
# SECTION test requirements
|
|
BuildRequires: %{python_module mpmath}
|
|
BuildRequires: %{python_module objgraph}
|
|
BuildRequires: %{python_module pytest >= 3.1}
|
|
BuildRequires: %{python_module pytest-astropy}
|
|
BuildRequires: %{python_module pytest-doctestplus}
|
|
BuildRequires: %{python_module pytest-mpl}
|
|
# /SECTION
|
|
%python_subpackages
|
|
|
|
%description
|
|
Astropy is a package intended to contain core functionality and some
|
|
common tools needed for performing astronomy and astrophysics research with
|
|
Python. It also provides an index for other astronomy packages and tools for
|
|
managing them.
|
|
|
|
%prep
|
|
%setup -q -n astropy-%{version}
|
|
|
|
# Make sure bundled libs are not used
|
|
rm -rf cextern/expat
|
|
rm -rf cextern/erfa
|
|
rm -rf cextern/cfitsio
|
|
rm -rf cextern/wcslib
|
|
|
|
echo "[build]" >> setup.cfg
|
|
echo "use_system_libraries=1" >> setup.cfg
|
|
|
|
%build
|
|
%python_build --use-system-libraries --offline
|
|
|
|
%install
|
|
%python_install --use-system-libraries --offline
|
|
|
|
chmod a-x %{buildroot}%{python_sitearch}/astropy/wcs/tests/data/header_with_time.fits
|
|
|
|
# Deduplicating files can generate a RPMLINT warning for pyc mtime
|
|
%{python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
rm -rf %{buildroot}%{$python_sitearch}/astropy/io/misc/tests/__pycache__/__init__.*.pyc
|
|
rm -rf %{buildroot}%{$python_sitearch}/astropy/io/votable/tests/__pycache__/*_test.*.pyc
|
|
rm -rf %{buildroot}%{$python_sitearch}/astropy/io/votable/tests/__pycache__/__init__.*.pyc
|
|
rm -rf %{buildroot}%{$python_sitearch}/astropy/wcs/tests/__pycache__/__init__.*.pyc
|
|
rm -rf %{buildroot}%{$python_sitearch}/astropy/wcs/tests/extension/__pycache__/__init__.*.pyc
|
|
$python -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/io/misc/tests/
|
|
$python -O -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/io/misc/tests/
|
|
$python -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/io/votable/tests/
|
|
$python -O -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/io/votable/tests/
|
|
$python -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/stats/bls/tests/
|
|
$python -O -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/stats/bls/tests/
|
|
$python -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/wcs/tests/
|
|
$python -O -m compileall -d %{$python_sitearch} %{buildroot}%{$python_sitearch}/astropy/wcs/tests/
|
|
%fdupes %{buildroot}%{$python_sitearch}
|
|
}
|
|
|
|
%check
|
|
export PYTHONDONTWRITEBYTECODE=1
|
|
# http://docs.astropy.org/en/latest/development/testguide.html#running-tests
|
|
%python_exec setup.py build_ext --inplace --offline
|
|
%ifarch aarch64
|
|
# doctest failure because of precision errors
|
|
%define skippytest -k 'not bayesian_info_criterion_lsq'
|
|
%endif
|
|
%{pytest_arch -W "ignore:the imp module is deprecated:DeprecationWarning" \
|
|
-W "ignore:Unknown pytest.mark.openfiles_ignore:pytest.PytestUnknownMarkWarning" \
|
|
--ignore "docs/whatsnew" %{?skippytest}
|
|
}
|
|
|
|
%files %{python_files}
|
|
%doc CHANGES.rst README.rst
|
|
%license licenses/*
|
|
%python3_only %{_bindir}/fitsdiff
|
|
%python3_only %{_bindir}/fitsheader
|
|
%python3_only %{_bindir}/fitscheck
|
|
%python3_only %{_bindir}/fitsinfo
|
|
%python3_only %{_bindir}/fits2bitmap
|
|
%python3_only %{_bindir}/samp_hub
|
|
%python3_only %{_bindir}/showtable
|
|
%python3_only %{_bindir}/volint
|
|
%python3_only %{_bindir}/wcslint
|
|
%{python_sitearch}/astropy/
|
|
%{python_sitearch}/astropy-%{version}-py*.egg-info
|
|
|
|
%changelog
|