xarray 2024.7.0__tar.gz → 2024.10.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (386) hide show
  1. xarray-2024.10.0/.github/FUNDING.yml +2 -0
  2. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/benchmarks-last-release.yml +1 -1
  3. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/benchmarks.yml +6 -3
  4. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/ci-additional.yaml +29 -34
  5. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/ci.yaml +8 -5
  6. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/hypothesis.yaml +2 -2
  7. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/nightly-wheels.yml +2 -2
  8. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/pypi-release.yaml +2 -2
  9. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/upstream-dev-ci.yaml +3 -3
  10. {xarray-2024.7.0 → xarray-2024.10.0}/.pre-commit-config.yaml +7 -12
  11. {xarray-2024.7.0 → xarray-2024.10.0}/.readthedocs.yaml +2 -2
  12. {xarray-2024.7.0 → xarray-2024.10.0}/CORE_TEAM_GUIDE.md +1 -2
  13. xarray-2024.10.0/DATATREE_MIGRATION_GUIDE.md +63 -0
  14. {xarray-2024.7.0/xarray.egg-info → xarray-2024.10.0}/PKG-INFO +13 -8
  15. {xarray-2024.7.0 → xarray-2024.10.0}/README.md +1 -1
  16. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/__init__.py +4 -4
  17. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/accessors.py +3 -3
  18. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/dataset_io.py +6 -8
  19. xarray-2024.10.0/asv_bench/benchmarks/datatree.py +15 -0
  20. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/groupby.py +17 -2
  21. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/rolling.py +1 -1
  22. {xarray-2024.7.0 → xarray-2024.10.0}/ci/install-upstream-wheels.sh +3 -5
  23. {xarray-2024.7.0 → xarray-2024.10.0}/ci/min_deps_check.py +3 -3
  24. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/all-but-dask.yml +1 -2
  25. xarray-2024.10.0/ci/requirements/all-but-numba.yml +54 -0
  26. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/bare-minimum.yml +3 -3
  27. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/doc.yml +6 -2
  28. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/environment-windows.yml +1 -1
  29. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/environment.yml +2 -2
  30. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/min-all-deps.yml +13 -13
  31. {xarray-2024.7.0 → xarray-2024.10.0}/design_notes/flexible_indexes_notes.md +1 -1
  32. {xarray-2024.7.0 → xarray-2024.10.0}/design_notes/grouper_objects.md +1 -1
  33. {xarray-2024.7.0 → xarray-2024.10.0}/design_notes/named_array_design_doc.md +1 -1
  34. {xarray-2024.7.0 → xarray-2024.10.0}/doc/api-hidden.rst +0 -1
  35. {xarray-2024.7.0 → xarray-2024.10.0}/doc/api.rst +348 -0
  36. xarray-2024.10.0/doc/combined.json +30 -0
  37. {xarray-2024.7.0 → xarray-2024.10.0}/doc/conf.py +10 -3
  38. {xarray-2024.7.0 → xarray-2024.10.0}/doc/contributing.rst +2 -6
  39. {xarray-2024.7.0 → xarray-2024.10.0}/doc/developers-meeting.rst +1 -1
  40. {xarray-2024.7.0 → xarray-2024.10.0}/doc/ecosystem.rst +2 -1
  41. {xarray-2024.7.0 → xarray-2024.10.0}/doc/getting-started-guide/installing.rst +3 -3
  42. {xarray-2024.7.0 → xarray-2024.10.0}/doc/getting-started-guide/quick-overview.rst +112 -0
  43. {xarray-2024.7.0 → xarray-2024.10.0}/doc/howdoi.rst +1 -1
  44. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/chunked-arrays.rst +2 -1
  45. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/extending-xarray.rst +3 -2
  46. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/internal-design.rst +3 -4
  47. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/interoperability.rst +1 -1
  48. {xarray-2024.7.0 → xarray-2024.10.0}/doc/roadmap.rst +15 -11
  49. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/computation.rst +1 -1
  50. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/dask.rst +2 -2
  51. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/data-structures.rst +312 -5
  52. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/duckarrays.rst +1 -1
  53. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/groupby.rst +34 -16
  54. xarray-2024.10.0/doc/user-guide/hierarchical-data.rst +838 -0
  55. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/index.rst +1 -0
  56. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/io.rst +112 -107
  57. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/pandas.rst +3 -3
  58. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/reshaping.rst +1 -1
  59. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/terminology.rst +28 -2
  60. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/testing.rst +1 -1
  61. {xarray-2024.7.0 → xarray-2024.10.0}/doc/whats-new.rst +175 -3
  62. xarray-2024.10.0/properties/test_encode_decode.py +45 -0
  63. {xarray-2024.7.0 → xarray-2024.10.0}/properties/test_index_manipulation.py +5 -1
  64. {xarray-2024.7.0 → xarray-2024.10.0}/properties/test_pandas_roundtrip.py +10 -1
  65. {xarray-2024.7.0 → xarray-2024.10.0}/pyproject.toml +30 -41
  66. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/__init__.py +20 -0
  67. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/api.py +568 -49
  68. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/common.py +35 -9
  69. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/file_manager.py +2 -2
  70. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/h5netcdf_.py +86 -18
  71. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/lru_cache.py +2 -2
  72. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/netCDF4_.py +113 -50
  73. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/plugins.py +21 -21
  74. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/scipy_.py +5 -3
  75. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/zarr.py +474 -133
  76. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/calendar_ops.py +65 -54
  77. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/cftime_offsets.py +77 -37
  78. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/cftimeindex.py +12 -7
  79. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/frequencies.py +1 -1
  80. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/times.py +27 -18
  81. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/variables.py +149 -112
  82. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/conventions.py +3 -2
  83. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/convert.py +1 -2
  84. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/_aggregations.py +1370 -2
  85. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/_typed_ops.py +164 -1
  86. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/accessor_dt.py +43 -3
  87. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/accessor_str.py +4 -4
  88. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/alignment.py +7 -6
  89. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/array_api_compat.py +1 -1
  90. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/combine.py +11 -8
  91. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/common.py +38 -17
  92. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/computation.py +34 -38
  93. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/concat.py +8 -6
  94. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/coordinates.py +119 -15
  95. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/dataarray.py +149 -93
  96. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/dataset.py +221 -131
  97. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/datatree.py +810 -328
  98. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/datatree_io.py +3 -3
  99. xarray-2024.10.0/xarray/core/datatree_mapping.py +204 -0
  100. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/datatree_render.py +33 -22
  101. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/dtypes.py +22 -8
  102. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/duck_array_ops.py +15 -38
  103. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/extension_array.py +2 -2
  104. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/extensions.py +2 -2
  105. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/formatting.py +179 -92
  106. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/formatting_html.py +32 -8
  107. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/groupby.py +363 -201
  108. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/indexes.py +18 -13
  109. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/indexing.py +51 -40
  110. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/merge.py +9 -9
  111. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/missing.py +44 -27
  112. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/nanops.py +1 -1
  113. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/npcompat.py +4 -0
  114. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/nputils.py +1 -1
  115. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/options.py +9 -3
  116. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/parallel.py +41 -21
  117. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/resample.py +8 -4
  118. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/resample_cftime.py +5 -5
  119. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/rolling.py +9 -7
  120. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/treenode.py +214 -18
  121. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/types.py +37 -15
  122. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/utils.py +97 -53
  123. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/variable.py +72 -55
  124. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/weighted.py +5 -3
  125. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/groupers.py +96 -29
  126. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/_aggregations.py +25 -50
  127. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/_array_api.py +4 -2
  128. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/_typing.py +10 -11
  129. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/core.py +20 -14
  130. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/daskmanager.py +2 -2
  131. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/dtypes.py +1 -7
  132. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/parallelcompat.py +6 -13
  133. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/utils.py +5 -8
  134. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/dataarray_plot.py +6 -4
  135. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/dataset_plot.py +4 -4
  136. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/facetgrid.py +19 -14
  137. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/utils.py +32 -17
  138. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/static/css/style.css +7 -2
  139. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/testing/__init__.py +2 -1
  140. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/testing/assertions.py +22 -68
  141. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/testing/strategies.py +21 -17
  142. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/__init__.py +16 -4
  143. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/arrays.py +11 -5
  144. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/conftest.py +33 -11
  145. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_accessor_dt.py +58 -2
  146. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_accessor_str.py +1 -1
  147. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_array_api.py +1 -1
  148. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_assertions.py +8 -6
  149. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends.py +704 -211
  150. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends_api.py +7 -5
  151. xarray-2024.10.0/xarray/tests/test_backends_datatree.py +558 -0
  152. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends_file_manager.py +1 -1
  153. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends_lru_cache.py +1 -1
  154. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_cftime_offsets.py +91 -45
  155. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_coarsen.py +9 -5
  156. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_coding.py +2 -2
  157. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_coding_times.py +59 -26
  158. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_combine.py +9 -3
  159. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_computation.py +13 -9
  160. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_concat.py +14 -7
  161. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_conventions.py +1 -1
  162. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_coordinates.py +4 -1
  163. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_dask.py +31 -16
  164. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_dataarray.py +48 -25
  165. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_dataset.py +141 -48
  166. xarray-2024.10.0/xarray/tests/test_datatree.py +2313 -0
  167. xarray-2024.10.0/xarray/tests/test_datatree_mapping.py +232 -0
  168. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_distributed.py +2 -2
  169. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_dtypes.py +4 -0
  170. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_duck_array_ops.py +6 -2
  171. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_extensions.py +5 -8
  172. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_formatting.py +45 -47
  173. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_formatting_html.py +22 -4
  174. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_groupby.py +473 -31
  175. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_indexes.py +4 -2
  176. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_indexing.py +71 -11
  177. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_interp.py +70 -32
  178. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_missing.py +7 -4
  179. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_namedarray.py +44 -3
  180. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_parallelcompat.py +6 -0
  181. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_plot.py +107 -90
  182. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_plugins.py +7 -18
  183. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_rolling.py +1 -1
  184. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_strategies.py +4 -2
  185. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_treenode.py +202 -78
  186. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_ufuncs.py +1 -1
  187. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_units.py +19 -16
  188. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_utils.py +17 -6
  189. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_variable.py +40 -34
  190. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_weighted.py +1 -1
  191. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tutorial.py +4 -4
  192. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/util/deprecation_helpers.py +6 -3
  193. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/util/generate_aggregations.py +77 -18
  194. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/util/generate_ops.py +6 -3
  195. {xarray-2024.7.0 → xarray-2024.10.0/xarray.egg-info}/PKG-INFO +13 -8
  196. {xarray-2024.7.0 → xarray-2024.10.0}/xarray.egg-info/SOURCES.txt +5 -4
  197. {xarray-2024.7.0 → xarray-2024.10.0}/xarray.egg-info/requires.txt +11 -4
  198. xarray-2024.7.0/.github/FUNDING.yml +0 -2
  199. xarray-2024.7.0/MANIFEST.in +0 -2
  200. xarray-2024.7.0/properties/test_encode_decode.py +0 -52
  201. xarray-2024.7.0/xarray/core/datatree_mapping.py +0 -314
  202. xarray-2024.7.0/xarray/core/datatree_ops.py +0 -309
  203. xarray-2024.7.0/xarray/core/iterators.py +0 -131
  204. xarray-2024.7.0/xarray/datatree_/datatree/__init__.py +0 -7
  205. xarray-2024.7.0/xarray/tests/test_backends_datatree.py +0 -153
  206. xarray-2024.7.0/xarray/tests/test_datatree.py +0 -1195
  207. xarray-2024.7.0/xarray/tests/test_datatree_mapping.py +0 -347
  208. {xarray-2024.7.0 → xarray-2024.10.0}/.binder/environment.yml +0 -0
  209. {xarray-2024.7.0 → xarray-2024.10.0}/.codecov.yml +0 -0
  210. {xarray-2024.7.0 → xarray-2024.10.0}/.git-blame-ignore-revs +0 -0
  211. {xarray-2024.7.0 → xarray-2024.10.0}/.git_archival.txt +0 -0
  212. {xarray-2024.7.0 → xarray-2024.10.0}/.gitattributes +0 -0
  213. {xarray-2024.7.0 → xarray-2024.10.0}/.github/ISSUE_TEMPLATE/bugreport.yml +0 -0
  214. {xarray-2024.7.0 → xarray-2024.10.0}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  215. {xarray-2024.7.0 → xarray-2024.10.0}/.github/ISSUE_TEMPLATE/misc.yml +0 -0
  216. {xarray-2024.7.0 → xarray-2024.10.0}/.github/ISSUE_TEMPLATE/newfeature.yml +0 -0
  217. {xarray-2024.7.0 → xarray-2024.10.0}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
  218. {xarray-2024.7.0 → xarray-2024.10.0}/.github/config.yml +0 -0
  219. {xarray-2024.7.0 → xarray-2024.10.0}/.github/dependabot.yml +0 -0
  220. {xarray-2024.7.0 → xarray-2024.10.0}/.github/release.yml +0 -0
  221. {xarray-2024.7.0 → xarray-2024.10.0}/.github/stale.yml +0 -0
  222. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/configure-testpypi-version.py +0 -0
  223. {xarray-2024.7.0 → xarray-2024.10.0}/.github/workflows/publish-test-results.yaml +0 -0
  224. {xarray-2024.7.0 → xarray-2024.10.0}/.gitignore +0 -0
  225. {xarray-2024.7.0 → xarray-2024.10.0}/.pep8speaks.yml +0 -0
  226. {xarray-2024.7.0 → xarray-2024.10.0}/CITATION.cff +0 -0
  227. {xarray-2024.7.0 → xarray-2024.10.0}/CODE_OF_CONDUCT.md +0 -0
  228. {xarray-2024.7.0 → xarray-2024.10.0}/CONTRIBUTING.md +0 -0
  229. {xarray-2024.7.0 → xarray-2024.10.0}/HOW_TO_RELEASE.md +0 -0
  230. {xarray-2024.7.0 → xarray-2024.10.0}/LICENSE +0 -0
  231. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/asv.conf.json +0 -0
  232. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/README_CI.md +0 -0
  233. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/alignment.py +0 -0
  234. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/coding.py +0 -0
  235. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/combine.py +0 -0
  236. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/dataarray_missing.py +0 -0
  237. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/dataset.py +0 -0
  238. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/import.py +0 -0
  239. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/indexing.py +0 -0
  240. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/interp.py +0 -0
  241. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/merge.py +0 -0
  242. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/pandas.py +0 -0
  243. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/polyfit.py +0 -0
  244. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/reindexing.py +0 -0
  245. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/renaming.py +0 -0
  246. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/repr.py +0 -0
  247. {xarray-2024.7.0 → xarray-2024.10.0}/asv_bench/benchmarks/unstacking.py +0 -0
  248. {xarray-2024.7.0 → xarray-2024.10.0}/ci/release_contributors.py +0 -0
  249. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/environment-3.13.yml +0 -0
  250. {xarray-2024.7.0 → xarray-2024.10.0}/ci/requirements/environment-windows-3.13.yml +0 -0
  251. {xarray-2024.7.0 → xarray-2024.10.0}/conftest.py +0 -0
  252. {xarray-2024.7.0 → xarray-2024.10.0}/doc/Makefile +0 -0
  253. {xarray-2024.7.0 → xarray-2024.10.0}/doc/README.rst +0 -0
  254. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/.gitignore +0 -0
  255. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/advanced_selection_interpolation.svg +0 -0
  256. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/ci.png +0 -0
  257. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/dask_array.png +0 -0
  258. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/dataset-diagram.png +0 -0
  259. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/index_api.svg +0 -0
  260. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/index_contribute.svg +0 -0
  261. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/index_getting_started.svg +0 -0
  262. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/index_user_guide.svg +0 -0
  263. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Icon_Final.png +0 -0
  264. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Icon_Final.svg +0 -0
  265. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.png +0 -0
  266. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.svg +0 -0
  267. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Logo_RGB_Final.png +0 -0
  268. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/logos/Xarray_Logo_RGB_Final.svg +0 -0
  269. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/numfocus_logo.png +0 -0
  270. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/opendap-prism-tmax.png +0 -0
  271. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/style.css +0 -0
  272. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/ERA5-GRIB-example.png +0 -0
  273. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/ROMS_ocean_model.png +0 -0
  274. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/area_weighted_temperature.png +0 -0
  275. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/monthly-means.png +0 -0
  276. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/multidimensional-coords.png +0 -0
  277. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/toy-weather-data.png +0 -0
  278. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/thumbnails/visualization_gallery.png +0 -0
  279. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_static/view-docs.png +0 -0
  280. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_templates/autosummary/accessor.rst +0 -0
  281. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_templates/autosummary/accessor_attribute.rst +0 -0
  282. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_templates/autosummary/accessor_callable.rst +0 -0
  283. {xarray-2024.7.0 → xarray-2024.10.0}/doc/_templates/autosummary/accessor_method.rst +0 -0
  284. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/ERA5-GRIB-example.ipynb +0 -0
  285. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/ROMS_ocean_model.ipynb +0 -0
  286. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/_code/accessor_example.py +0 -0
  287. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/apply_ufunc_vectorize_1d.ipynb +0 -0
  288. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/area_weighted_temperature.ipynb +0 -0
  289. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/blank_template.ipynb +0 -0
  290. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/monthly-means.ipynb +0 -0
  291. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/monthly_means_output.png +0 -0
  292. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/multidimensional-coords.ipynb +0 -0
  293. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/visualization_gallery.ipynb +0 -0
  294. {xarray-2024.7.0 → xarray-2024.10.0}/doc/examples/weather-data.ipynb +0 -0
  295. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery/README.txt +0 -0
  296. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery/plot_cartopy_facetgrid.py +0 -0
  297. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery/plot_colorbar_center.py +0 -0
  298. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery/plot_control_colorbar.py +0 -0
  299. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery/plot_lines_from_2d.py +0 -0
  300. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery.rst +0 -0
  301. {xarray-2024.7.0 → xarray-2024.10.0}/doc/gallery.yml +0 -0
  302. {xarray-2024.7.0 → xarray-2024.10.0}/doc/getting-started-guide/faq.rst +0 -0
  303. {xarray-2024.7.0 → xarray-2024.10.0}/doc/getting-started-guide/index.rst +0 -0
  304. {xarray-2024.7.0 → xarray-2024.10.0}/doc/getting-started-guide/why-xarray.rst +0 -0
  305. {xarray-2024.7.0 → xarray-2024.10.0}/doc/help-diagram.rst +0 -0
  306. {xarray-2024.7.0 → xarray-2024.10.0}/doc/index.rst +0 -0
  307. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/duck-arrays-integration.rst +0 -0
  308. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/how-to-add-new-backend.rst +0 -0
  309. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/how-to-create-custom-index.rst +0 -0
  310. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/index.rst +0 -0
  311. {xarray-2024.7.0 → xarray-2024.10.0}/doc/internals/zarr-encoding-spec.rst +0 -0
  312. {xarray-2024.7.0 → xarray-2024.10.0}/doc/tutorials-and-videos.rst +0 -0
  313. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/combining.rst +0 -0
  314. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/indexing.rst +0 -0
  315. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/interpolation.rst +0 -0
  316. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/options.rst +0 -0
  317. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/plotting.rst +0 -0
  318. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/time-series.rst +0 -0
  319. {xarray-2024.7.0 → xarray-2024.10.0}/doc/user-guide/weather-climate.rst +0 -0
  320. {xarray-2024.7.0 → xarray-2024.10.0}/doc/videos.yml +0 -0
  321. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/ANYTREE_LICENSE +0 -0
  322. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/DASK_LICENSE +0 -0
  323. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/ICOMOON_LICENSE +0 -0
  324. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/NUMPY_LICENSE +0 -0
  325. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/PANDAS_LICENSE +0 -0
  326. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/PYTHON_LICENSE +0 -0
  327. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/SCIKIT_LEARN_LICENSE +0 -0
  328. {xarray-2024.7.0 → xarray-2024.10.0}/licenses/SEABORN_LICENSE +0 -0
  329. {xarray-2024.7.0 → xarray-2024.10.0}/properties/README.md +0 -0
  330. {xarray-2024.7.0 → xarray-2024.10.0}/properties/__init__.py +0 -0
  331. {xarray-2024.7.0 → xarray-2024.10.0}/properties/conftest.py +0 -0
  332. {xarray-2024.7.0 → xarray-2024.10.0}/properties/test_properties.py +0 -0
  333. {xarray-2024.7.0 → xarray-2024.10.0}/setup.cfg +0 -0
  334. {xarray-2024.7.0 → xarray-2024.10.0}/setup.py +0 -0
  335. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/__init__.py +0 -0
  336. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/locks.py +0 -0
  337. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/memory.py +0 -0
  338. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/netcdf3.py +0 -0
  339. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/pydap_.py +0 -0
  340. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/backends/store.py +0 -0
  341. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/__init__.py +0 -0
  342. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/coding/strings.py +0 -0
  343. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/__init__.py +0 -0
  344. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/arithmetic.py +0 -0
  345. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/dask_array_ops.py +0 -0
  346. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/ops.py +0 -0
  347. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/pdcompat.py +0 -0
  348. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/core/rolling_exp.py +0 -0
  349. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/indexes/__init__.py +0 -0
  350. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/__init__.py +0 -0
  351. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/namedarray/pycompat.py +0 -0
  352. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/__init__.py +0 -0
  353. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/plot/accessor.py +0 -0
  354. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/py.typed +0 -0
  355. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/static/__init__.py +0 -0
  356. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/static/css/__init__.py +0 -0
  357. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/static/html/__init__.py +0 -0
  358. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/static/html/icons-svg-inline.html +0 -0
  359. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/bears.nc +0 -0
  360. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/example.grib +0 -0
  361. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/example.ict +0 -0
  362. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/example.uamiv +0 -0
  363. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/example_1.nc +0 -0
  364. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/data/example_1.nc.gz +0 -0
  365. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends_common.py +0 -0
  366. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_backends_locks.py +0 -0
  367. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_calendar_ops.py +0 -0
  368. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_cftimeindex.py +0 -0
  369. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_cftimeindex_resample.py +0 -0
  370. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_coding_strings.py +0 -0
  371. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_cupy.py +0 -0
  372. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_deprecation_helpers.py +0 -0
  373. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_error_messages.py +0 -0
  374. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_hashable.py +0 -0
  375. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_merge.py +0 -0
  376. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_nputils.py +0 -0
  377. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_options.py +0 -0
  378. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_print_versions.py +0 -0
  379. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_sparse.py +0 -0
  380. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_tutorial.py +0 -0
  381. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/tests/test_typed_ops.py +0 -0
  382. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/util/__init__.py +0 -0
  383. {xarray-2024.7.0 → xarray-2024.10.0}/xarray/util/print_versions.py +0 -0
  384. {xarray-2024.7.0 → xarray-2024.10.0}/xarray.egg-info/dependency_links.txt +0 -0
  385. {xarray-2024.7.0 → xarray-2024.10.0}/xarray.egg-info/entry_points.txt +0 -0
  386. {xarray-2024.7.0 → xarray-2024.10.0}/xarray.egg-info/top_level.txt +0 -0
@@ -0,0 +1,2 @@
1
+ github: numfocus
2
+ custom: https://numfocus.org/donate-to-xarray
@@ -22,7 +22,7 @@ jobs:
22
22
  fetch-depth: 0
23
23
 
24
24
  - name: Set up conda environment
25
- uses: mamba-org/setup-micromamba@v1
25
+ uses: mamba-org/setup-micromamba@v2
26
26
  with:
27
27
  environment-file: ${{env.CONDA_ENV_FILE}}
28
28
  environment-name: xarray-tests
@@ -5,6 +5,9 @@ on:
5
5
  types: [opened, reopened, synchronize, labeled]
6
6
  workflow_dispatch:
7
7
 
8
+ env:
9
+ PR_HEAD_LABEL: ${{ github.event.pull_request.head.label }}
10
+
8
11
  jobs:
9
12
  benchmark:
10
13
  if: ${{ contains( github.event.pull_request.labels.*.name, 'run-benchmark') && github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' }}
@@ -22,7 +25,7 @@ jobs:
22
25
  fetch-depth: 0
23
26
 
24
27
  - name: Set up conda environment
25
- uses: mamba-org/setup-micromamba@v1
28
+ uses: mamba-org/setup-micromamba@v2
26
29
  with:
27
30
  environment-file: ${{env.CONDA_ENV_FILE}}
28
31
  environment-name: xarray-tests
@@ -31,7 +34,7 @@ jobs:
31
34
  # add "build" because of https://github.com/airspeed-velocity/asv/issues/1385
32
35
  create-args: >-
33
36
  asv
34
- build
37
+ python-build
35
38
  mamba
36
39
 
37
40
 
@@ -49,7 +52,7 @@ jobs:
49
52
  # ID this runner
50
53
  asv machine --yes
51
54
  echo "Baseline: ${{ github.event.pull_request.base.sha }} (${{ github.event.pull_request.base.label }})"
52
- echo "Contender: ${GITHUB_SHA} (${{ github.event.pull_request.head.label }})"
55
+ echo "Contender: ${GITHUB_SHA} ($PR_HEAD_LABEL)"
53
56
  # Run benchmarks for current commit against base
54
57
  ASV_OPTIONS="--split --show-stderr --factor $ASV_FACTOR"
55
58
  asv continuous $ASV_OPTIONS ${{ github.event.pull_request.base.sha }} ${GITHUB_SHA} \
@@ -55,7 +55,7 @@ jobs:
55
55
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
56
56
 
57
57
  - name: Setup micromamba
58
- uses: mamba-org/setup-micromamba@v1
58
+ uses: mamba-org/setup-micromamba@v2
59
59
  with:
60
60
  environment-file: ${{env.CONDA_ENV_FILE}}
61
61
  environment-name: xarray-tests
@@ -81,8 +81,7 @@ jobs:
81
81
  #
82
82
  # If dependencies emit warnings we can't do anything about, add ignores to
83
83
  # `xarray/tests/__init__.py`.
84
- # [MHS, 01/25/2024] Skip datatree_ documentation remove after #8572
85
- python -m pytest --doctest-modules xarray --ignore xarray/tests --ignore xarray/datatree_ -Werror
84
+ python -m pytest --doctest-modules xarray --ignore xarray/tests -Werror
86
85
 
87
86
  mypy:
88
87
  name: Mypy
@@ -104,7 +103,7 @@ jobs:
104
103
  run: |
105
104
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
106
105
  - name: Setup micromamba
107
- uses: mamba-org/setup-micromamba@v1
106
+ uses: mamba-org/setup-micromamba@v2
108
107
  with:
109
108
  environment-file: ${{env.CONDA_ENV_FILE}}
110
109
  environment-name: xarray-tests
@@ -123,14 +122,14 @@ jobs:
123
122
  python xarray/util/print_versions.py
124
123
  - name: Install mypy
125
124
  run: |
126
- python -m pip install "mypy<1.9" --force-reinstall
125
+ python -m pip install "mypy==1.11.2" --force-reinstall
127
126
 
128
127
  - name: Run mypy
129
128
  run: |
130
- python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report xarray/
129
+ python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
131
130
 
132
131
  - name: Upload mypy coverage to Codecov
133
- uses: codecov/codecov-action@v4.5.0
132
+ uses: codecov/codecov-action@v4.6.0
134
133
  with:
135
134
  file: mypy_report/cobertura.xml
136
135
  flags: mypy
@@ -138,8 +137,8 @@ jobs:
138
137
  name: codecov-umbrella
139
138
  fail_ci_if_error: false
140
139
 
141
- mypy39:
142
- name: Mypy 3.9
140
+ mypy-min:
141
+ name: Mypy 3.10
143
142
  runs-on: "ubuntu-latest"
144
143
  needs: detect-ci-trigger
145
144
  defaults:
@@ -147,7 +146,7 @@ jobs:
147
146
  shell: bash -l {0}
148
147
  env:
149
148
  CONDA_ENV_FILE: ci/requirements/environment.yml
150
- PYTHON_VERSION: "3.9"
149
+ PYTHON_VERSION: "3.10"
151
150
 
152
151
  steps:
153
152
  - uses: actions/checkout@v4
@@ -158,7 +157,7 @@ jobs:
158
157
  run: |
159
158
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
160
159
  - name: Setup micromamba
161
- uses: mamba-org/setup-micromamba@v1
160
+ uses: mamba-org/setup-micromamba@v2
162
161
  with:
163
162
  environment-file: ${{env.CONDA_ENV_FILE}}
164
163
  environment-name: xarray-tests
@@ -177,32 +176,30 @@ jobs:
177
176
  python xarray/util/print_versions.py
178
177
  - name: Install mypy
179
178
  run: |
180
- python -m pip install "mypy<1.9" --force-reinstall
179
+ python -m pip install "mypy==1.11.2" --force-reinstall
181
180
 
182
181
  - name: Run mypy
183
182
  run: |
184
- python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report xarray/
183
+ python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
185
184
 
186
185
  - name: Upload mypy coverage to Codecov
187
- uses: codecov/codecov-action@v4.5.0
186
+ uses: codecov/codecov-action@v4.6.0
188
187
  with:
189
188
  file: mypy_report/cobertura.xml
190
- flags: mypy39
189
+ flags: mypy-min
191
190
  env_vars: PYTHON_VERSION
192
191
  name: codecov-umbrella
193
192
  fail_ci_if_error: false
194
193
 
195
-
196
-
197
194
  pyright:
198
195
  name: Pyright
199
196
  runs-on: "ubuntu-latest"
200
197
  needs: detect-ci-trigger
201
198
  if: |
202
- always()
203
- && (
204
- contains( github.event.pull_request.labels.*.name, 'run-pyright')
205
- )
199
+ always()
200
+ && (
201
+ contains( github.event.pull_request.labels.*.name, 'run-pyright')
202
+ )
206
203
  defaults:
207
204
  run:
208
205
  shell: bash -l {0}
@@ -219,7 +216,7 @@ jobs:
219
216
  run: |
220
217
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
221
218
  - name: Setup micromamba
222
- uses: mamba-org/setup-micromamba@v1
219
+ uses: mamba-org/setup-micromamba@v2
223
220
  with:
224
221
  environment-file: ${{env.CONDA_ENV_FILE}}
225
222
  environment-name: xarray-tests
@@ -245,7 +242,7 @@ jobs:
245
242
  python -m pyright xarray/
246
243
 
247
244
  - name: Upload pyright coverage to Codecov
248
- uses: codecov/codecov-action@v4.5.0
245
+ uses: codecov/codecov-action@v4.6.0
249
246
  with:
250
247
  file: pyright_report/cobertura.xml
251
248
  flags: pyright
@@ -254,20 +251,20 @@ jobs:
254
251
  fail_ci_if_error: false
255
252
 
256
253
  pyright39:
257
- name: Pyright 3.9
254
+ name: Pyright 3.10
258
255
  runs-on: "ubuntu-latest"
259
256
  needs: detect-ci-trigger
260
257
  if: |
261
- always()
262
- && (
263
- contains( github.event.pull_request.labels.*.name, 'run-pyright')
264
- )
258
+ always()
259
+ && (
260
+ contains( github.event.pull_request.labels.*.name, 'run-pyright')
261
+ )
265
262
  defaults:
266
263
  run:
267
264
  shell: bash -l {0}
268
265
  env:
269
266
  CONDA_ENV_FILE: ci/requirements/environment.yml
270
- PYTHON_VERSION: "3.9"
267
+ PYTHON_VERSION: "3.10"
271
268
 
272
269
  steps:
273
270
  - uses: actions/checkout@v4
@@ -278,7 +275,7 @@ jobs:
278
275
  run: |
279
276
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
280
277
  - name: Setup micromamba
281
- uses: mamba-org/setup-micromamba@v1
278
+ uses: mamba-org/setup-micromamba@v2
282
279
  with:
283
280
  environment-file: ${{env.CONDA_ENV_FILE}}
284
281
  environment-name: xarray-tests
@@ -304,7 +301,7 @@ jobs:
304
301
  python -m pyright xarray/
305
302
 
306
303
  - name: Upload pyright coverage to Codecov
307
- uses: codecov/codecov-action@v4.5.0
304
+ uses: codecov/codecov-action@v4.6.0
308
305
  with:
309
306
  file: pyright_report/cobertura.xml
310
307
  flags: pyright39
@@ -312,8 +309,6 @@ jobs:
312
309
  name: codecov-umbrella
313
310
  fail_ci_if_error: false
314
311
 
315
-
316
-
317
312
  min-version-policy:
318
313
  name: Minimum Version Policy
319
314
  runs-on: "ubuntu-latest"
@@ -329,7 +324,7 @@ jobs:
329
324
  fetch-depth: 0 # Fetch all history for all branches and tags.
330
325
 
331
326
  - name: Setup micromamba
332
- uses: mamba-org/setup-micromamba@v1
327
+ uses: mamba-org/setup-micromamba@v2
333
328
  with:
334
329
  environment-name: xarray-tests
335
330
  create-args: >-
@@ -47,17 +47,20 @@ jobs:
47
47
  matrix:
48
48
  os: ["ubuntu-latest", "macos-latest", "windows-latest"]
49
49
  # Bookend python versions
50
- python-version: ["3.9", "3.12"]
50
+ python-version: ["3.10", "3.12"]
51
51
  env: [""]
52
52
  include:
53
53
  # Minimum python version:
54
54
  - env: "bare-minimum"
55
- python-version: "3.9"
55
+ python-version: "3.10"
56
56
  os: ubuntu-latest
57
57
  - env: "min-all-deps"
58
- python-version: "3.9"
58
+ python-version: "3.10"
59
59
  os: ubuntu-latest
60
60
  # Latest python version:
61
+ - env: "all-but-numba"
62
+ python-version: "3.12"
63
+ os: ubuntu-latest
61
64
  - env: "all-but-dask"
62
65
  # Not 3.12 because of pint
63
66
  python-version: "3.11"
@@ -105,7 +108,7 @@ jobs:
105
108
  echo "PYTHON_VERSION=${{ matrix.python-version }}" >> $GITHUB_ENV
106
109
 
107
110
  - name: Setup micromamba
108
- uses: mamba-org/setup-micromamba@v1
111
+ uses: mamba-org/setup-micromamba@v2
109
112
  with:
110
113
  environment-file: ${{ env.CONDA_ENV_FILE }}
111
114
  environment-name: xarray-tests
@@ -159,7 +162,7 @@ jobs:
159
162
  path: pytest.xml
160
163
 
161
164
  - name: Upload code coverage to Codecov
162
- uses: codecov/codecov-action@v4.5.0
165
+ uses: codecov/codecov-action@v4.6.0
163
166
  with:
164
167
  file: ./coverage.xml
165
168
  flags: unittests
@@ -20,7 +20,7 @@ jobs:
20
20
  runs-on: ubuntu-latest
21
21
  if: |
22
22
  github.repository == 'pydata/xarray'
23
- && (github.event_name == 'push' || github.event_name == 'pull_request')
23
+ && (github.event_name == 'push' || github.event_name == 'pull_request' || github.event_name == 'schedule')
24
24
  outputs:
25
25
  triggered: ${{ steps.detect-trigger.outputs.trigger-found }}
26
26
  steps:
@@ -61,7 +61,7 @@ jobs:
61
61
  echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
62
62
 
63
63
  - name: Setup micromamba
64
- uses: mamba-org/setup-micromamba@v1
64
+ uses: mamba-org/setup-micromamba@v2
65
65
  with:
66
66
  environment-file: ci/requirements/environment.yml
67
67
  environment-name: xarray-tests
@@ -13,7 +13,7 @@ jobs:
13
13
  fetch-depth: 0
14
14
  - uses: actions/setup-python@v5
15
15
  with:
16
- python-version: "3.11"
16
+ python-version: "3.12"
17
17
 
18
18
  - name: Install dependencies
19
19
  run: |
@@ -38,7 +38,7 @@ jobs:
38
38
  fi
39
39
 
40
40
  - name: Upload wheel
41
- uses: scientific-python/upload-nightly-action@b67d7fcc0396e1128a474d1ab2b48aa94680f9fc # 0.5.0
41
+ uses: scientific-python/upload-nightly-action@82396a2ed4269ba06c6b2988bb4fd568ef3c3d6b # 0.6.1
42
42
  with:
43
43
  anaconda_nightly_upload_token: ${{ secrets.ANACONDA_NIGHTLY }}
44
44
  artifacts_path: dist
@@ -88,7 +88,7 @@ jobs:
88
88
  path: dist
89
89
  - name: Publish package to TestPyPI
90
90
  if: github.event_name == 'push'
91
- uses: pypa/gh-action-pypi-publish@v1.9.0
91
+ uses: pypa/gh-action-pypi-publish@v1.10.3
92
92
  with:
93
93
  repository_url: https://test.pypi.org/legacy/
94
94
  verbose: true
@@ -111,6 +111,6 @@ jobs:
111
111
  name: releases
112
112
  path: dist
113
113
  - name: Publish package to PyPI
114
- uses: pypa/gh-action-pypi-publish@v1.9.0
114
+ uses: pypa/gh-action-pypi-publish@v1.10.3
115
115
  with:
116
116
  verbose: true
@@ -61,7 +61,7 @@ jobs:
61
61
  with:
62
62
  fetch-depth: 0 # Fetch all history for all branches and tags.
63
63
  - name: Set up conda environment
64
- uses: mamba-org/setup-micromamba@v1
64
+ uses: mamba-org/setup-micromamba@v2
65
65
  with:
66
66
  environment-file: ci/requirements/environment.yml
67
67
  environment-name: xarray-tests
@@ -120,7 +120,7 @@ jobs:
120
120
  with:
121
121
  fetch-depth: 0 # Fetch all history for all branches and tags.
122
122
  - name: Set up conda environment
123
- uses: mamba-org/setup-micromamba@v1
123
+ uses: mamba-org/setup-micromamba@v2
124
124
  with:
125
125
  environment-file: ci/requirements/environment.yml
126
126
  environment-name: xarray-tests
@@ -146,7 +146,7 @@ jobs:
146
146
  run: |
147
147
  python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
148
148
  - name: Upload mypy coverage to Codecov
149
- uses: codecov/codecov-action@v4.5.0
149
+ uses: codecov/codecov-action@v4.6.0
150
150
  with:
151
151
  file: mypy_report/cobertura.xml
152
152
  flags: mypy
@@ -1,10 +1,10 @@
1
1
  # https://pre-commit.com/
2
2
  ci:
3
3
  autoupdate_schedule: monthly
4
- exclude: 'xarray/datatree_.*'
4
+ autoupdate_commit_msg: 'Update pre-commit hooks'
5
5
  repos:
6
6
  - repo: https://github.com/pre-commit/pre-commit-hooks
7
- rev: v4.6.0
7
+ rev: v5.0.0
8
8
  hooks:
9
9
  - id: trailing-whitespace
10
10
  - id: end-of-file-fixer
@@ -13,24 +13,19 @@ repos:
13
13
  - id: mixed-line-ending
14
14
  - repo: https://github.com/astral-sh/ruff-pre-commit
15
15
  # Ruff version.
16
- rev: 'v0.5.0'
16
+ rev: 'v0.6.9'
17
17
  hooks:
18
+ - id: ruff-format
18
19
  - id: ruff
19
20
  args: ["--fix", "--show-fixes"]
20
- # https://github.com/python/black#version-control-integration
21
- - repo: https://github.com/psf/black-pre-commit-mirror
22
- rev: 24.4.2
23
- hooks:
24
- - id: black-jupyter
25
21
  - repo: https://github.com/keewis/blackdoc
26
22
  rev: v0.3.9
27
23
  hooks:
28
24
  - id: blackdoc
29
25
  exclude: "generate_aggregations.py"
30
- additional_dependencies: ["black==24.4.2"]
31
- - id: blackdoc-autoupdate-black
26
+ additional_dependencies: ["black==24.8.0"]
32
27
  - repo: https://github.com/pre-commit/mirrors-mypy
33
- rev: v1.10.1
28
+ rev: v1.11.2
34
29
  hooks:
35
30
  - id: mypy
36
31
  # Copied from setup.cfg
@@ -41,7 +36,7 @@ repos:
41
36
  additional_dependencies: [
42
37
  # Type stubs
43
38
  types-python-dateutil,
44
- types-pkg_resources,
39
+ types-setuptools,
45
40
  types-PyYAML,
46
41
  types-pytz,
47
42
  typing-extensions>=4.1.0,
@@ -1,9 +1,9 @@
1
1
  version: 2
2
2
 
3
3
  build:
4
- os: ubuntu-22.04
4
+ os: ubuntu-lts-latest
5
5
  tools:
6
- python: mambaforge-4.10
6
+ python: mambaforge-latest
7
7
  jobs:
8
8
  post_checkout:
9
9
  - (git --no-pager log --pretty="tformat:%s" -1 | grep -vqF "[skip-rtd]") || exit 183
@@ -271,8 +271,7 @@ resources such as:
271
271
  [NumPy documentation guide](https://numpy.org/devdocs/dev/howto-docs.html#documentation-style)
272
272
  for docstring conventions.
273
273
  - [`pre-commit`](https://pre-commit.com) hooks for autoformatting.
274
- - [`black`](https://github.com/psf/black) autoformatting.
275
- - [`flake8`](https://github.com/PyCQA/flake8) linting.
274
+ - [`ruff`](https://github.com/astral-sh/ruff) autoformatting and linting.
276
275
  - [python-xarray](https://stackoverflow.com/questions/tagged/python-xarray) on Stack Overflow.
277
276
  - [@xarray_dev](https://twitter.com/xarray_dev) on Twitter.
278
277
  - [xarray-dev](https://discord.gg/bsSGdwBn) discord community (normally only used for remote synchronous chat during sprints).
@@ -0,0 +1,63 @@
1
+ # Migration guide for users of `xarray-contrib/datatree`
2
+
3
+ _15th October 2024_
4
+
5
+ This guide is for previous users of the prototype `datatree.DataTree` class in the `xarray-contrib/datatree repository`. That repository has now been archived, and will not be maintained. This guide is intended to help smooth your transition to using the new, updated `xarray.DataTree` class.
6
+
7
+ > [!IMPORTANT]
8
+ > There are breaking changes! You should not expect that code written with `xarray-contrib/datatree` will work without any modifications. At the absolute minimum you will need to change the top-level import statement, but there are other changes too.
9
+
10
+ We have made various changes compared to the prototype version. These can be split into three categories: data model changes, which affect the hierarchal structure itself; integration with xarray's IO backends; and minor API changes, which mostly consist of renaming methods to be more self-consistent.
11
+
12
+ ### Data model changes
13
+
14
+ The most important changes made are to the data model of `DataTree`. Whilst previously data in different nodes was unrelated and therefore unconstrained, now trees have "internal alignment" - meaning that dimensions and indexes in child nodes must exactly align with those in their parents.
15
+
16
+ These alignment checks happen at tree construction time, meaning there are some netCDF4 files and zarr stores that could previously be opened as `datatree.DataTree` objects using `datatree.open_datatree`, but now cannot be opened as `xr.DataTree` objects using `xr.open_datatree`. For these cases we added a new opener function `xr.open_groups`, which returns a `dict[str, Dataset]`. This is intended as a fallback for tricky cases, where the idea is that you can still open the entire contents of the file using `open_groups`, edit the `Dataset` objects, then construct a valid tree from the edited dictionary using `DataTree.from_dict`.
17
+
18
+ The alignment checks allowed us to add "Coordinate Inheritance", a much-requested feature where indexed coordinate variables are now "inherited" down to child nodes. This allows you to define common coordinates in a parent group that are then automatically available on every child node. The distinction between a locally-defined coordinate variables and an inherited coordinate that was defined on a parent node is reflected in the `DataTree.__repr__`. Generally if you prefer not to have these variables be inherited you can get more similar behaviour to the old `datatree` package by removing indexes from coordinates, as this prevents inheritance.
19
+
20
+ Tree structure checks between multiple trees (i.e., `DataTree.isomorophic`) and pairing of nodes in arithmetic has also changed. Nodes are now matched (with `xarray.group_subtrees`) based on their relative paths, without regard to the order in which child nodes are defined.
21
+
22
+ For further documentation see the page in the user guide on Hierarchical Data.
23
+
24
+ ### Integrated backends
25
+
26
+ Previously `datatree.open_datatree` used a different codepath from `xarray.open_dataset`, and was hard-coded to only support opening netCDF files and Zarr stores.
27
+ Now xarray's backend entrypoint system has been generalized to include `open_datatree` and the new `open_groups`.
28
+ This means we can now extend other xarray backends to support `open_datatree`! If you are the maintainer of an xarray backend we encourage you to add support for `open_datatree` and `open_groups`!
29
+
30
+ Additionally:
31
+ - A `group` kwarg has been added to `open_datatree` for choosing which group in the file should become the root group of the created tree.
32
+ - Various performance improvements have been made, which should help when opening netCDF files and Zarr stores with large numbers of groups.
33
+ - We anticipate further performance improvements being possible for datatree IO.
34
+
35
+ ### API changes
36
+
37
+ A number of other API changes have been made, which should only require minor modifications to your code:
38
+ - The top-level import has changed, from `from datatree import DataTree, open_datatree` to `from xarray import DataTree, open_datatree`. Alternatively you can now just use the `import xarray as xr` namespace convention for everything datatree-related.
39
+ - The `DataTree.ds` property has been changed to `DataTree.dataset`, though `DataTree.ds` remains as an alias for `DataTree.dataset`.
40
+ - Similarly the `ds` kwarg in the `DataTree.__init__` constructor has been replaced by `dataset`, i.e. use `DataTree(dataset=)` instead of `DataTree(ds=...)`.
41
+ - The method `DataTree.to_dataset()` still exists but now has different options for controlling which variables are present on the resulting `Dataset`, e.g. `inherit=True/False`.
42
+ - `DataTree.copy()` also has a new `inherit` keyword argument for controlling whether or not coordinates defined on parents are copied (only relevant when copying a non-root node).
43
+ - The `DataTree.parent` property is now read-only. To assign a ancestral relationships directly you must instead use the `.children` property on the parent node, which remains settable.
44
+ - Similarly the `parent` kwarg has been removed from the `DataTree.__init__` constuctor.
45
+ - DataTree objects passed to the `children` kwarg in `DataTree.__init__` are now shallow-copied.
46
+ - `DataTree.as_array` has been replaced by `DataTree.to_dataarray`.
47
+ - A number of methods which were not well tested have been (temporarily) disabled. In general we have tried to only keep things that are known to work, with the plan to increase API surface incrementally after release.
48
+
49
+ ## Thank you!
50
+
51
+ Thank you for trying out `xarray-contrib/datatree`!
52
+
53
+ We welcome contributions of any kind, including good ideas that never quite made it into the original datatree repository. Please also let us know if we have forgotten to mention a change that should have been listed in this guide.
54
+
55
+ Sincerely, the datatree team:
56
+
57
+ Tom Nicholas,
58
+ Owen Littlejohns,
59
+ Matt Savoie,
60
+ Eni Awowale,
61
+ Alfonso Ladino,
62
+ Justus Magin,
63
+ Stephan Hoyer
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: xarray
3
- Version: 2024.7.0
3
+ Version: 2024.10.0
4
4
  Summary: N-D labeled arrays and datasets in Python
5
5
  Author-email: xarray Developers <xarray@googlegroups.com>
6
6
  License: Apache-2.0
@@ -15,25 +15,25 @@ Classifier: Operating System :: OS Independent
15
15
  Classifier: Intended Audience :: Science/Research
16
16
  Classifier: Programming Language :: Python
17
17
  Classifier: Programming Language :: Python :: 3
18
- Classifier: Programming Language :: Python :: 3.9
19
18
  Classifier: Programming Language :: Python :: 3.10
20
19
  Classifier: Programming Language :: Python :: 3.11
21
20
  Classifier: Programming Language :: Python :: 3.12
22
21
  Classifier: Topic :: Scientific/Engineering
23
- Requires-Python: >=3.9
22
+ Requires-Python: >=3.10
24
23
  Description-Content-Type: text/markdown
25
24
  License-File: LICENSE
26
- Requires-Dist: numpy>=1.23
25
+ Requires-Dist: numpy>=1.24
27
26
  Requires-Dist: packaging>=23.1
28
- Requires-Dist: pandas>=2.0
27
+ Requires-Dist: pandas>=2.1
29
28
  Provides-Extra: accel
30
29
  Requires-Dist: scipy; extra == "accel"
31
30
  Requires-Dist: bottleneck; extra == "accel"
32
31
  Requires-Dist: numbagg; extra == "accel"
32
+ Requires-Dist: numba>=0.54; extra == "accel"
33
33
  Requires-Dist: flox; extra == "accel"
34
34
  Requires-Dist: opt_einsum; extra == "accel"
35
35
  Provides-Extra: complete
36
- Requires-Dist: xarray[accel,dev,io,parallel,viz]; extra == "complete"
36
+ Requires-Dist: xarray[accel,etc,io,parallel,viz]; extra == "complete"
37
37
  Provides-Extra: dev
38
38
  Requires-Dist: hypothesis; extra == "dev"
39
39
  Requires-Dist: mypy; extra == "dev"
@@ -44,6 +44,8 @@ Requires-Dist: pytest-env; extra == "dev"
44
44
  Requires-Dist: pytest-xdist; extra == "dev"
45
45
  Requires-Dist: pytest-timeout; extra == "dev"
46
46
  Requires-Dist: ruff; extra == "dev"
47
+ Requires-Dist: sphinx; extra == "dev"
48
+ Requires-Dist: sphinx_autosummary_accessors; extra == "dev"
47
49
  Requires-Dist: xarray[complete]; extra == "dev"
48
50
  Provides-Extra: io
49
51
  Requires-Dist: netCDF4; extra == "io"
@@ -54,12 +56,15 @@ Requires-Dist: zarr; extra == "io"
54
56
  Requires-Dist: fsspec; extra == "io"
55
57
  Requires-Dist: cftime; extra == "io"
56
58
  Requires-Dist: pooch; extra == "io"
59
+ Provides-Extra: etc
60
+ Requires-Dist: sparse; extra == "etc"
57
61
  Provides-Extra: parallel
58
62
  Requires-Dist: dask[complete]; extra == "parallel"
59
63
  Provides-Extra: viz
64
+ Requires-Dist: cartopy; extra == "viz"
60
65
  Requires-Dist: matplotlib; extra == "viz"
61
- Requires-Dist: seaborn; extra == "viz"
62
66
  Requires-Dist: nc-time-axis; extra == "viz"
67
+ Requires-Dist: seaborn; extra == "viz"
63
68
 
64
69
  # xarray: N-D labeled arrays and datasets
65
70
 
@@ -151,7 +156,7 @@ Xarray is a fiscally sponsored project of
151
156
  [NumFOCUS](https://numfocus.org), a nonprofit dedicated to supporting
152
157
  the open source scientific computing community. If you like Xarray and
153
158
  want to support our mission, please consider making a
154
- [donation](https://numfocus.salsalabs.org/donate-to-xarray/) to support
159
+ [donation](https://numfocus.org/donate-to-xarray) to support
155
160
  our efforts.
156
161
 
157
162
  ## History
@@ -88,7 +88,7 @@ Xarray is a fiscally sponsored project of
88
88
  [NumFOCUS](https://numfocus.org), a nonprofit dedicated to supporting
89
89
  the open source scientific computing community. If you like Xarray and
90
90
  want to support our mission, please consider making a
91
- [donation](https://numfocus.salsalabs.org/donate-to-xarray/) to support
91
+ [donation](https://numfocus.org/donate-to-xarray) to support
92
92
  our efforts.
93
93
 
94
94
  ## History
@@ -18,15 +18,15 @@ def parameterized(names, params):
18
18
  def requires_dask():
19
19
  try:
20
20
  import dask # noqa: F401
21
- except ImportError:
22
- raise NotImplementedError()
21
+ except ImportError as err:
22
+ raise NotImplementedError() from err
23
23
 
24
24
 
25
25
  def requires_sparse():
26
26
  try:
27
27
  import sparse # noqa: F401
28
- except ImportError:
29
- raise NotImplementedError()
28
+ except ImportError as err:
29
+ raise NotImplementedError() from err
30
30
 
31
31
 
32
32
  def randn(shape, frac_nan=None, chunks=None, seed=0):
@@ -16,10 +16,10 @@ class DateTimeAccessor:
16
16
  self.da = xr.DataArray(data, dims="time", coords={"time": time})
17
17
 
18
18
  def time_dayofyear(self, calendar):
19
- self.da.time.dt.dayofyear
19
+ _ = self.da.time.dt.dayofyear
20
20
 
21
21
  def time_year(self, calendar):
22
- self.da.time.dt.year
22
+ _ = self.da.time.dt.year
23
23
 
24
24
  def time_floor(self, calendar):
25
- self.da.time.dt.floor("D")
25
+ _ = self.da.time.dt.floor("D")