summary refs log tree commit diff
path: root/pkgs/development/python-modules/astroquery
diff options
context:
space:
mode:
authorSébastien Maret <sebastien.maret@icloud.com>2019-11-28 13:02:52 +0100
committerSébastien Maret <sebastien.maret@icloud.com>2019-11-28 13:02:52 +0100
commiteb16eb51f250ff49a4e402e2af922327c3515991 (patch)
treeff38ab0c47f3db2e8a69cfd18374ee143f223565 /pkgs/development/python-modules/astroquery
parentd7b18bcb3718c87767619e117e363e830c81913f (diff)
downloadnixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar.gz
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar.bz2
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar.lz
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar.xz
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.tar.zst
nixpkgs-eb16eb51f250ff49a4e402e2af922327c3515991.zip
pythonPackages.astroquery: fix build
The patch from upstream repository has been included in the latest
release (0.3.10), so we don't need it anymore.
Diffstat (limited to 'pkgs/development/python-modules/astroquery')
-rw-r--r--pkgs/development/python-modules/astroquery/conftest-astropy-3-fix.patch54
-rw-r--r--pkgs/development/python-modules/astroquery/default.nix4
2 files changed, 0 insertions, 58 deletions
diff --git a/pkgs/development/python-modules/astroquery/conftest-astropy-3-fix.patch b/pkgs/development/python-modules/astroquery/conftest-astropy-3-fix.patch
deleted file mode 100644
index 0b1c7973b59..00000000000
--- a/pkgs/development/python-modules/astroquery/conftest-astropy-3-fix.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-diff -ruN astroquery-0.3.9.orig/astroquery/conftest.py astroquery-0.3.9/astroquery/conftest.py
---- astroquery-0.3.9.orig/astroquery/conftest.py	2018-11-27 14:51:16.000000000 +0100
-+++ astroquery-0.3.9/astroquery/conftest.py	2019-07-23 18:19:17.000000000 +0200
-@@ -5,15 +5,20 @@
- # by importing them here in conftest.py they are discoverable by py.test
- # no matter how it is invoked within the source tree.
- 
--from astropy.tests.pytest_plugins import (PYTEST_HEADER_MODULES,
--                                          enable_deprecations_as_exceptions,
--                                          TESTED_VERSIONS)
-+from astropy.version import version as astropy_version
- 
--try:
--    packagename = os.path.basename(os.path.dirname(__file__))
--    TESTED_VERSIONS[packagename] = version.version
--except NameError:
--    pass
-+if astropy_version < '3.0':
-+    # With older versions of Astropy, we actually need to import the pytest
-+    # plugins themselves in order to make them discoverable by pytest.
-+    from astropy.tests.pytest_plugins import *
-+else:
-+    # As of Astropy 3.0, the pytest plugins provided by Astropy are
-+    # automatically made available when Astropy is installed. This means it's
-+    # not necessary to import them here, but we still need to import global
-+    # variables that are used for configuration.
-+    from astropy.tests.plugins.display import PYTEST_HEADER_MODULES, TESTED_VERSIONS
-+
-+from astropy.tests.helper import enable_deprecations_as_exceptions
- 
- # Add astropy to test header information and remove unused packages.
- # Pytest header customisation was introduced in astropy 1.0.
-@@ -36,12 +41,17 @@
-     # The warnings_to_ignore_by_pyver parameter was added in astropy 2.0
-     enable_deprecations_as_exceptions(modules_to_ignore_on_import=['requests'])
- 
-+# add '_testrun' to the version name so that the user-agent indicates that
-+# it's being run in a test
-+from . import version
-+version.version += '_testrun'
-+
-+
- # This is to figure out the affiliated package version, rather than
- # using Astropy's
--try:
--    from .version import version
--except ImportError:
--    version = 'dev'
-+from .version import version, astropy_helpers_version
-+
- 
- packagename = os.path.basename(os.path.dirname(__file__))
- TESTED_VERSIONS[packagename] = version
-+TESTED_VERSIONS['astropy_helpers'] = astropy_helpers_version
diff --git a/pkgs/development/python-modules/astroquery/default.nix b/pkgs/development/python-modules/astroquery/default.nix
index e1f36ffa8cf..461d8801e60 100644
--- a/pkgs/development/python-modules/astroquery/default.nix
+++ b/pkgs/development/python-modules/astroquery/default.nix
@@ -20,10 +20,6 @@ buildPythonPackage rec {
     sha256 = "1ce57a8792c7d5d74206d797d379de6da35d56be433ea5840c41a49f202e2fab";
   };
 
-  # Fix tests using conftest.py from HEAD in the upstream GitHub
-  # repository.
-  patches = [ ./conftest-astropy-3-fix.patch ];
-
   propagatedBuildInputs = [ astropy requests keyring beautifulsoup4 html5lib ];
 
   nativeBuildInputs = [ astropy-helpers ];