home / github / issues

Menu
  • GraphQL API
  • Search all tables

issues: 728888328

This data as json

id node_id number title user state locked assignee milestone comments created_at updated_at closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
728888328 MDExOlB1bGxSZXF1ZXN0NTA5NTAyMjA2 4534 Add isocalendar to dt fields 5635139 closed 0     17 2020-10-24T22:13:29Z 2020-11-19T23:36:20Z 2020-11-19T08:04:16Z MEMBER   0 pydata/xarray/pulls/4534
  • [x] Tests added
  • [x] Passes isort . && black . && mypy . && flake8
  • [ ] User visible changes (including notable bug fixes) are documented in whats-new.rst
  • [x] New functions/methods are listed in api.rst

This currently fails tests — IIUC because our infra for this expects scalars rather than tuples, and isocalendar returns a tuple.

The existing week & weekofyear are going to stop working at some point, so if we can move off those that would be ideal:

``` xarray/tests/test_accessor_dt.py::TestDatetimeAccessor::test_field_access[weekofyear] xarray/tests/test_accessor_dt.py::TestDatetimeAccessor::test_field_access[week] /Users/maximilian/workspace/xarray/xarray/tests/test_accessor_dt.py:72: FutureWarning: weekofyear and week have been deprecated, please use DatetimeIndex.isocalendar().week instead, which returns a Series. To exactly reproduce the behavior of week and weekofyear and return an Index, you may call pd.Int64Index(idx.isocalendar().week) getattr(self.times, field), name=field, coords=[self.times], dims=["time"]

xarray/tests/test_accessor_dt.py::TestDatetimeAccessor::test_field_access[weekofyear] xarray/tests/test_accessor_dt.py::TestDatetimeAccessor::test_field_access[week] /Users/maximilian/workspace/xarray/xarray/core/accessor_dt.py:44: FutureWarning: Series.dt.weekofyear and Series.dt.week have been deprecated. Please use Series.dt.isocalendar().week instead. field_values = getattr(values_as_series.dt, name).values

-- Docs: https://docs.pytest.org/en/stable/warnings.html ```

I'd be very happy for someone else to take this on...

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4534/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    13221727 pull

Links from other tables

  • 0 rows from issues_id in issues_labels
  • 17 rows from issue in issue_comments
Powered by Datasette · Queries took 0.679ms · About: xarray-datasette