home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

18 rows where author_association = "MEMBER" and issue = 1028110240 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: created_at (date), updated_at (date)

user 4

  • max-sixty 7
  • dcherian 6
  • Illviljan 4
  • shoyer 1

issue 1

  • Generator for groupby reductions · 18 ✖

author_association 1

  • MEMBER · 18 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
962498057 https://github.com/pydata/xarray/pull/5871#issuecomment-962498057 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X845Xo4J max-sixty 5635139 2021-11-06T19:21:46Z 2021-11-06T19:21:46Z MEMBER

Big win @dcherian ! Thanks a lot. By LoC, xarray just got 4% better in a single PR!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
962118284 https://github.com/pydata/xarray/pull/5871#issuecomment-962118284 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X845WMKM dcherian 2448579 2021-11-05T18:22:56Z 2021-11-05T18:22:56Z MEMBER

Thanks for the reviews!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
962075979 https://github.com/pydata/xarray/pull/5871#issuecomment-962075979 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X845WB1L dcherian 2448579 2021-11-05T17:20:31Z 2021-11-05T17:20:31Z MEMBER

This can be merged as is. I just think it looks a little neater with |.

:+1: I think we make this change project-wide if we want to do it (looks like pyupgrade supports it). @Illviljan can you open an issue please?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
958177932 https://github.com/pydata/xarray/pull/5871#issuecomment-958177932 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X845HKKM Illviljan 14371165 2021-11-02T21:23:34Z 2021-11-02T21:23:34Z MEMBER

from __future__ import annotations does not actually directly enable the use of | for union, it changes the semantics of type annotations to postpone evaluation. In particular, you can then put just about anything in the type annotation without having any runtime behavior

pandas uses | and from __future__ import annotations quite frequently in order to avoid the Union, for example: https://github.com/pandas-dev/pandas/blob/master/pandas/plotting/_core.py

Having typing not doing any runtime calculations sounds great to me. We usually don't need the typing variables during runtime anyway.

This can be merged as is. I just think it looks a little neater with |.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
955082380 https://github.com/pydata/xarray/pull/5871#issuecomment-955082380 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X8447WaM Illviljan 14371165 2021-10-29T22:28:59Z 2021-10-29T22:28:59Z MEMBER

This looks great, nice work!

This can be saved for a future PR but one thing I notice is that it's possible to make the unions slightly more readable using the new |-operator: python dim: Union[None, Hashable, Sequence[Hashable]] = None vs. ```python from future import annotations

dim: None | Hashable | Sequence[Hashable] = None ``` I'm unsure about the compatibility but I think it should be fine.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
954959122 https://github.com/pydata/xarray/pull/5871#issuecomment-954959122 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X84464US dcherian 2448579 2021-10-29T18:26:19Z 2021-10-29T18:26:19Z MEMBER

All green! This should be good to go.

Here are a couple of examples: https://xray--5871.org.readthedocs.build/en/5871/generated/xarray.core.groupby.DataArrayGroupBy.sum.html

https://xray--5871.org.readthedocs.build/en/5871/generated/xarray.core.resample.DataArrayResample.sum.html

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
951128744 https://github.com/pydata/xarray/pull/5871#issuecomment-951128744 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844sRKo shoyer 1217238 2021-10-25T17:08:17Z 2021-10-25T17:08:17Z MEMBER

Unless @shoyer has any objections — I think we were primarily delayed by Apache Beam, and they have unlocked that dependency, so I would vote to add it as a required dependency. The only realistic way this could be bad is if there's another package that is commonly installed with xarray that a) requires typing_extensions, b) forbids a recent version, c) won't remove that pin soon.

+1 for adding a requirement on typing_extensions. It seems a little early to be dropping Python 3.7.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
951117633 https://github.com/pydata/xarray/pull/5871#issuecomment-951117633 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844sOdB max-sixty 5635139 2021-10-25T16:54:48Z 2021-10-25T16:54:48Z MEMBER

Unless @shoyer has any objections — I think we were primarily delayed by Apache Beam, and they have unlocked that dependency, so I would vote to add it as a required dependency. The only realistic way this could be bad is if there's another package that is commonly installed with xarray that a) requires typing_extensions, b) forbids a recent version, c) won't remove that pin soon.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950316866 https://github.com/pydata/xarray/pull/5871#issuecomment-950316866 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844pK9C dcherian 2448579 2021-10-24T12:30:40Z 2021-10-24T12:30:40Z MEMBER

It's ok to me. My hesitation is because we only need in a very small number of places IIUC.

Happy to defer to the opinions of more experienced typers

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950304347 https://github.com/pydata/xarray/pull/5871#issuecomment-950304347 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844pH5b max-sixty 5635139 2021-10-24T11:06:56Z 2021-10-24T11:06:56Z MEMBER

I think @keewis mentioned we could drop 3.7 in December which is not that far away. Can we type self as Any for now and update later?

What are your thoughts re adding the typing_extensions dependency?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950295790 https://github.com/pydata/xarray/pull/5871#issuecomment-950295790 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844pFzu dcherian 2448579 2021-10-24T10:04:34Z 2021-10-24T10:04:34Z MEMBER

I think @keewis mentioned we could drop 3.7 in December which is not that far away. Can we type self as Any for now and update later?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950268614 https://github.com/pydata/xarray/pull/5871#issuecomment-950268614 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844o_LG max-sixty 5635139 2021-10-24T06:26:24Z 2021-10-24T06:26:24Z MEMBER

I just checked Apache beam (the library that prevented us upgrading last time), and they now support typing-extensions<4, so I would vote to add that dependency, rather than drop 3.7.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950262008 https://github.com/pydata/xarray/pull/5871#issuecomment-950262008 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844o9j4 Illviljan 14371165 2021-10-24T05:14:38Z 2021-10-24T05:44:19Z MEMBER

We can probably do the workaround way like in #5624: https://github.com/pydata/xarray/blob/b79155862e154db45dff3b526c2f9e8ef303808f/xarray/core/options.py#L7-L72

But I find typing_extensions getting rather important, most of the time when you google for the typing issue the proper solutions often uses these new typing additions.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950237563 https://github.com/pydata/xarray/pull/5871#issuecomment-950237563 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844o3l7 max-sixty 5635139 2021-10-24T00:27:31Z 2021-10-24T00:27:31Z MEMBER

Bah, Protocol isn't supported in 3.7! We could either revisit mandating typing_extensions or drop 3.7 (which is overdue since our change to only allow 24 months for python releases).

Is it possible to mandate typing_extensions for only 3.7?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950236575 https://github.com/pydata/xarray/pull/5871#issuecomment-950236575 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844o3Wf max-sixty 5635139 2021-10-24T00:17:15Z 2021-10-24T00:17:15Z MEMBER

I fixed mypy! @Illviljan thanks for the Protocol suggestion. I had to make a different one per class, because the return type for reduce couldn't be generic (I think, unless there's a way...)

Actually much more tedious was fixing black given line-breaks etc.

Great work @dcherian !

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950229311 https://github.com/pydata/xarray/pull/5871#issuecomment-950229311 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844o1k_ max-sixty 5635139 2021-10-23T23:01:18Z 2021-10-23T23:01:18Z MEMBER

I'm having trouble with mypy though. Please help!

I tried for a while. I'm still trying!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950201382 https://github.com/pydata/xarray/pull/5871#issuecomment-950201382 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844ouwm Illviljan 14371165 2021-10-23T19:28:17Z 2021-10-23T19:28:17Z MEMBER

For the typing issues you can try out using Protocol: https://stackoverflow.com/questions/51930339/how-do-i-correctly-add-type-hints-to-mixin-classes

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240
950181408 https://github.com/pydata/xarray/pull/5871#issuecomment-950181408 https://api.github.com/repos/pydata/xarray/issues/5871 IC_kwDOAMm_X844op4g dcherian 2448579 2021-10-23T17:01:02Z 2021-10-23T17:01:02Z MEMBER

Updated to generate resample reductions separately. This allows us to have nice examples in the docstring.

I'm having trouble with mypy though. Please help! xarray/core/_reductions.py:2662: error: "DataArrayResampleReductions" has no attribute "reduce" [attr-defined] xarray/core/_reductions.py:2737: error: "DataArrayResampleReductions" has no attribute "reduce" [attr-defined] xarray/core/_reductions.py:2805: error: "DataArrayResampleReductions" has no attribute "reduce" [attr-defined] xarray/core/_reductions.py:2872: error: "DataArrayResampleReductions" has no attribute "reduce" [attr-defined] xarray/core/_reductions.py:2939: error: "DataArrayResampleReductions" has no attribute "reduce" [attr-defined]

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Generator for groupby reductions 1028110240

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
);
CREATE INDEX [idx_issue_comments_issue]
    ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
    ON [issue_comments] ([user]);
Powered by Datasette · Queries took 14.894ms · About: xarray-datasette