Your message dated Wed, 22 Nov 2023 07:21:58 +0000
with message-id <e1r5hyc-000u2n...@fasolo.debian.org>
and subject line Bug#1050854: fixed in python-xarray 2023.11.0-1
has caused the Debian Bug report #1050854,
regarding python-xarray: autopkgtest failures
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
1050854: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1050854
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Source: python-xarray
Version: 2023.08.0-1
Severity: serious
Tags: patch
Justification: autopkgtest failures

Dear Maintainer,

The autopkgtest for your package is failing:

 230s =================================== FAILURES 
===================================
 230s ____________ test_open_mfdataset_manyfiles[netcdf4-20-True-None-5] 
_____________
 230s 
 230s self = CachingFileManager(<class 'netCDF4._netCDF4.Dataset'>, 
'/tmp/tmp4hr6i68_/temp-1120.nc', mode='r', kwargs={'clobber': True, 'diskless': 
False, 'persist': False, 'format': 'NETCDF4'}, 
manager_id='abdbaa71-0b5f-4544-982d-afa923d39953')
 230s needs_lock = True
 230s 
 230s     def _acquire_with_cache_info(self, needs_lock=True):
 230s         """Acquire a file, returning the file and whether it was 
cached."""
 230s         with self._optional_lock(needs_lock):
 230s             try:
 230s >               file = self._cache[self._key]
 230s 
 230s /usr/lib/python3/dist-packages/xarray/backends/file_manager.py:211: 
 230s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ _ 
 230s 
 230s self = <xarray.backends.lru_cache.LRUCache object at 0x7fe48b508b00>
 230s key = [<class 'netCDF4._netCDF4.Dataset'>, 
('/tmp/tmp4hr6i68_/temp-1120.nc',), 'r', (('clobber', True), ('diskless', 
False), ('format', 'NETCDF4'), ('persist', False)), 
'abdbaa71-0b5f-4544-982d-afa923d39953']
 230s 
 230s     def __getitem__(self, key: K) -> V:
 230s         # record recent use of the key by moving it to the front of the 
list
 230s         with self._lock:
 230s >           value = self._cache[key]
 230s E           KeyError: [<class 'netCDF4._netCDF4.Dataset'>, 
('/tmp/tmp4hr6i68_/temp-1120.nc',), 'r', (('clobber', True), ('diskless', 
False), ('format', 'NETCDF4'), ('persist', False)), 
'abdbaa71-0b5f-4544-982d-afa923d39953']
 230s 
 230s /usr/lib/python3/dist-packages/xarray/backends/lru_cache.py:56: KeyError
 230s 
 230s During handling of the above exception, another exception occurred:
 230s 
 230s readengine = 'netcdf4', nfiles = 20, parallel = True, chunks = None
 230s file_cache_maxsize = 5
 230s 
 230s     @requires_dask
 230s     @pytest.mark.filterwarnings("ignore:use make_scale(name) instead")
 230s     def test_open_mfdataset_manyfiles(
 230s         readengine, nfiles, parallel, chunks, file_cache_maxsize
 230s     ):
 230s         # skip certain combinations
 230s         skip_if_not_engine(readengine)
 230s     
 230s         if ON_WINDOWS:
 230s             pytest.skip("Skipping on Windows")
 230s     
 230s         randdata = np.random.randn(nfiles)
 230s         original = Dataset({"foo": ("x", randdata)})
 230s         # test standard open_mfdataset approach with too many files
 230s         with create_tmp_files(nfiles) as tmpfiles:
 230s             writeengine = readengine if readengine != "pynio" else 
"netcdf4"
 230s             # split into multiple sets of temp files
 230s             for ii in original.x.values:
 230s                 subds = original.isel(x=slice(ii, ii + 1))
 230s                 if writeengine != "zarr":
 230s                     subds.to_netcdf(tmpfiles[ii], engine=writeengine)
 230s                 else:  # if writeengine == "zarr":
 230s                     subds.to_zarr(store=tmpfiles[ii])
 230s     
 230s             # check that calculation on opened datasets works properly
 230s >           with open_mfdataset(
 230s                 tmpfiles,
 230s                 combine="nested",
 230s                 concat_dim="x",
 230s                 engine=readengine,
 230s                 parallel=parallel,
 230s                 chunks=chunks if (not chunks and readengine != "zarr") 
else "auto",
 230s             ) as actual:
 230s 
 230s /usr/lib/python3/dist-packages/xarray/tests/test_backends.py:3407: 
 230s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ _ 
 230s /usr/lib/python3/dist-packages/xarray/backends/api.py:1020: in 
open_mfdataset
 230s     datasets, closers = dask.compute(datasets, closers)
 230s /usr/lib/python3/dist-packages/dask/base.py:600: in compute
 230s     results = schedule(dsk, keys, **kwargs)
 230s /usr/lib/python3/dist-packages/dask/threaded.py:89: in get
 230s     results = get_async(
 230s /usr/lib/python3/dist-packages/dask/local.py:511: in get_async
 230s     raise_exception(exc, tb)
 230s /usr/lib/python3/dist-packages/dask/local.py:319: in reraise
 230s     raise exc
 230s /usr/lib/python3/dist-packages/dask/local.py:224: in execute_task
 230s     result = _execute_task(task, data)
 230s /usr/lib/python3/dist-packages/dask/core.py:119: in _execute_task
 230s     return func(*(_execute_task(a, cache) for a in args))
 230s /usr/lib/python3/dist-packages/dask/utils.py:71: in apply
 230s     return func(*args, **kwargs)
 230s /usr/lib/python3/dist-packages/xarray/backends/api.py:570: in open_dataset
 230s     backend_ds = backend.open_dataset(
 230s /usr/lib/python3/dist-packages/xarray/backends/netCDF4_.py:602: in 
open_dataset
 230s     store = NetCDF4DataStore.open(
 230s /usr/lib/python3/dist-packages/xarray/backends/netCDF4_.py:400: in open
 230s     return cls(manager, group=group, mode=mode, lock=lock, 
autoclose=autoclose)
 230s /usr/lib/python3/dist-packages/xarray/backends/netCDF4_.py:347: in 
__init__
 230s     self.format = self.ds.data_model
 230s /usr/lib/python3/dist-packages/xarray/backends/netCDF4_.py:409: in ds
 230s     return self._acquire()
 230s /usr/lib/python3/dist-packages/xarray/backends/netCDF4_.py:403: in 
_acquire
 230s     with self._manager.acquire_context(needs_lock) as root:
 230s /usr/lib/python3.11/contextlib.py:137: in __enter__
 230s     return next(self.gen)
 230s /usr/lib/python3/dist-packages/xarray/backends/file_manager.py:199: in 
acquire_context
 230s     file, cached = self._acquire_with_cache_info(needs_lock)
 230s /usr/lib/python3/dist-packages/xarray/backends/file_manager.py:217: in 
_acquire_with_cache_info
 230s     file = self._opener(*self._args, **kwargs)
 230s src/netCDF4/_netCDF4.pyx:2490: in netCDF4._netCDF4.Dataset.__init__
 230s     ???
 230s src/netCDF4/_netCDF4.pyx:1879: in netCDF4._netCDF4._get_grps
 230s     ???
 230s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
_ _ _ 
 230s 
 230s >   ???
 230s E   RuntimeError: NetCDF: Not a valid ID
 230s 
 230s src/netCDF4/_netCDF4.pyx:2029: RuntimeError

https://ci.debian.net/data/autopkgtest/testing/amd64/p/python-xarray/37237465/log.gz

You would have caught this if you hadn't disabled the tests during the build.

The attached patch resolves the issue skipping the failing test.

Kind Regards,

Bas
diff -Nru python-xarray-2023.08.0/debian/changelog 
python-xarray-2023.08.0/debian/changelog
--- python-xarray-2023.08.0/debian/changelog    2023-08-28 17:28:23.000000000 
+0200
+++ python-xarray-2023.08.0/debian/changelog    2023-08-30 10:40:43.000000000 
+0200
@@ -1,3 +1,12 @@
+python-xarray (2023.08.0-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Don't override dh_auto_test.
+  * Use autopkgtest-pkg-pybuild testsuite.
+  * Skip test_open_mfdataset_manyfiles, causes FTBFS.
+
+ -- Bas Couwenberg <sebas...@debian.org>  Wed, 30 Aug 2023 10:40:43 +0200
+
 python-xarray (2023.08.0-1) unstable; urgency=medium
 
   * New upstream release
diff -Nru python-xarray-2023.08.0/debian/control 
python-xarray-2023.08.0/debian/control
--- python-xarray-2023.08.0/debian/control      2023-08-28 17:28:23.000000000 
+0200
+++ python-xarray-2023.08.0/debian/control      2023-08-30 10:40:43.000000000 
+0200
@@ -50,6 +50,7 @@
 Vcs-Browser: https://salsa.debian.org/science-team/python-xarray
 Vcs-Git: https://salsa.debian.org/science-team/python-xarray.git
 Homepage: http://xarray.pydata.org/
+Testsuite: autopkgtest-pkg-pybuild
 
 Package: python3-xarray
 Architecture: all
diff -Nru python-xarray-2023.08.0/debian/rules 
python-xarray-2023.08.0/debian/rules
--- python-xarray-2023.08.0/debian/rules        2023-08-28 17:28:23.000000000 
+0200
+++ python-xarray-2023.08.0/debian/rules        2023-08-30 10:40:43.000000000 
+0200
@@ -4,10 +4,10 @@
 export DH_VERBOSE=1
 
 export PYBUILD_NAME=xarray
-PY3VERS:= $(shell py3versions -s)
+export PYBUILD_TEST_ARGS=-vv -k 'not test_open_mfdataset_manyfiles'
 
-# Disable checking for this release:
-DEB_BUILD_OPTIONS += nocheck nodoc
+# Disable docs for this release:
+DEB_BUILD_OPTIONS += nodoc
 
 export PYDEVD_DISABLE_FILE_VALIDATION=1
 
@@ -33,14 +33,6 @@
        PYTHONPATH=$(CURDIR) $(MAKE) -C doc html
 endif
 
-override_dh_auto_test:
-ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
-       for p in $(PY3VERS); do \
-               PY3VERNUM=`echo $$p | sed -e 's/python//' `; \
-               pybuild --test --test-pytest -i $$p -p $$PY3VERNUM  ;  \
-               done
-endif
-
 ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS)))
 override_dh_sphinxdoc:
        dh_sphinxdoc --exclude=MathJax.js
diff -Nru python-xarray-2023.08.0/debian/tests/control 
python-xarray-2023.08.0/debian/tests/control
--- python-xarray-2023.08.0/debian/tests/control        2023-08-28 
17:28:23.000000000 +0200
+++ python-xarray-2023.08.0/debian/tests/control        1970-01-01 
01:00:00.000000000 +0100
@@ -1,18 +0,0 @@
-Test-Command: set -e
- ; for py in $(py3versions -r 2>/dev/null)
- ; do cd "$AUTOPKGTEST_TMP"
- ; echo "Testing with $py:"
- ; $py -m pytest -v --pyargs xarray
- ; done
-Depends: python3-all,
-         python3-pytest (>= 2.7.1),
-         python3-xarray,
-        python3-bottleneck,
-         python3-dask (>= 2.8.1+dfsg),
-         python3-netcdf4,
-         python3-scipy,
-         python3-matplotlib,
-        python3-cftime,
-         python3-rasterio
-
-         

--- End Message ---
--- Begin Message ---
Source: python-xarray
Source-Version: 2023.11.0-1
Done: Andreas Tille <ti...@debian.org>

We believe that the bug you reported is fixed in the latest version of
python-xarray, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1050...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Andreas Tille <ti...@debian.org> (supplier of updated python-xarray package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Wed, 22 Nov 2023 07:37:01 +0100
Source: python-xarray
Architecture: source
Version: 2023.11.0-1
Distribution: unstable
Urgency: medium
Maintainer: Debian Science Maintainers 
<debian-science-maintain...@lists.alioth.debian.org>
Changed-By: Andreas Tille <ti...@debian.org>
Closes: 1004869 1050854 1053700
Changes:
 python-xarray (2023.11.0-1) unstable; urgency=medium
 .
   [ Andreas Tille ]
   * Team upload.
   * New upstream version. Closes: #1050854
   * Remove trailing whitespace in debian/changelog (routine-update)
   * Remove trailing whitespace in debian/control (routine-update)
   * Remove trailing whitespace in debian/rules (routine-update)
   * Add salsa-ci file (routine-update)
   * Rules-Requires-Root: no (routine-update)
   * Use secure URI in Homepage field.
   * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository-Browse.
   * Re-enable docs which do not segfault but do nothing else.  Upstream might
     provide docs in future - otherwise the python-xarray-doc package could be
     dropped completely.
 .
   [ Rebecca N. Palmer ]
   * Tests: ignore rounding differences on i386.  Closes: #1004869.
   * Tests: don't fail on big-endian systems.  Closes: #1053700.
Checksums-Sha1:
 46cd1e80b628c1c8220debd7fb07d74400bffa38 3419 python-xarray_2023.11.0-1.dsc
 6b4c2f5006a19b50881b11e68783ed7e2ac2364f 3792320 
python-xarray_2023.11.0.orig.tar.gz
 6761e80419733d73f3dff7520daf8d5c1c7fd65f 15572 
python-xarray_2023.11.0-1.debian.tar.xz
 a2714dd75978ce5b829f6bbdfe7bf217a9643ff0 21702 
python-xarray_2023.11.0-1_amd64.buildinfo
Checksums-Sha256:
 88a9850cad505ca206a4a7b3a60e7ad184461b205e530cbe54a840b40ac57e47 3419 
python-xarray_2023.11.0-1.dsc
 f6e0978d4d61d5abe7997ccc56cf8eba5fb7a2921d9feadd6e168f5b7659cb9d 3792320 
python-xarray_2023.11.0.orig.tar.gz
 f7e55afa25c8f036e64bc3018bed3eee5dd1bf667ad03a6898f9c5b83de40fa1 15572 
python-xarray_2023.11.0-1.debian.tar.xz
 e06602d68a1ff9caec4bf9967ed656f4d9aae016ffef4c969a8cb7118d4c1781 21702 
python-xarray_2023.11.0-1_amd64.buildinfo
Files:
 3cfde394f6552c416a588402d4ba7bbf 3419 python optional 
python-xarray_2023.11.0-1.dsc
 9fff3f98b634b833ecb5def2381e526f 3792320 python optional 
python-xarray_2023.11.0.orig.tar.gz
 11f880c8fde977a86c90d650a6a215ad 15572 python optional 
python-xarray_2023.11.0-1.debian.tar.xz
 72ad6b6cf4ccadaa7452f3d0a67558e3 21702 python optional 
python-xarray_2023.11.0-1_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQJFBAEBCgAvFiEE8fAHMgoDVUHwpmPKV4oElNHGRtEFAmVdpH0RHHRpbGxlQGRl
Ymlhbi5vcmcACgkQV4oElNHGRtHGWA//arOykpflKELUN02WYDarWvh0Q3zMmV5e
C4+B2PBWazWI7f9VFu9RavJvWrtKsscY0SfgI8oj8WMzAOf7C+zSz453U9Iz0jap
B3GpdTMXb17VHWG80QAwE8RioYMDhpVW8YAwAZ7E4MKgee9TO8VbaNVESu3nDX5I
DOdHlWhlbj+j/fLRHA8YXYvlIOQ3LwLCAj93joPF3lFYXEpBF5LzjpL7Po71fZx6
BTVf2YwMN5jb3lRNvfbcCsgYsa3q9nu+DuAtyCYCXQfFji0xtf6CKNEchP1BqOgG
0zp/GPqBeRzBJgV4gdDRS1F1V/+1S0ydrsMGe56xfs3KWjYAONhh3UYflH+SiC++
0eHmZfSQWkCLYXWywPsmltlqb7liwhJFioKFh4FszP/d2rTHOMgCiNHujLKmLv4H
Pe768ao3YY6SDHFcEQ6ingiWXhY0NKMDhE7YmSdMntOYMNhvyElZZE3pqK7DiNC3
jSjbPKsLCuz0uytvRwXE4F5uk78SfXTtfq8Tk0m5UoIQabWMuKQn+bfTjoq6Ggoa
ahKghMatT8arTsCsugAsoh6qoQNyhxLpN91lefEswLaNF4emYR2dVIlfLX1enuxN
ShqqKXsjH6J71dmYvetbO60aEcJS4Tj8Jjyv2w8t3mDoEQuV2Rlsf03rJKuxE9SQ
o8JZf94iC0Y=
=gIZk
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to