home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

8 rows where issue = 574097799 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 3

  • max-sixty 4
  • sjvrijn 3
  • seth-p 1

author_association 2

  • CONTRIBUTOR 4
  • MEMBER 4

issue 1

  • Documentation of DataArray does not warn that inferring dimension names is deprecated · 8 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
594128647 https://github.com/pydata/xarray/issues/3820#issuecomment-594128647 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5NDEyODY0Nw== seth-p 7441788 2020-03-03T19:34:39Z 2020-03-03T19:34:39Z CONTRIBUTOR

Note that inferring dimensions from coords when it is a list of tuples does still work (with no deprecation warning): ``` In [1]: import numpy as np, xarray as xr

In [2]: xr.DataArray(np.zeros((2, 2)), coords=[('x', [1, 2]), ('y', [1, 2])])
Out[2]: <xarray.DataArray (x: 2, y: 2)> array([[0., 0.], [0., 0.]]) Coordinates: * x (x) int64 1 2 * y (y) int64 1 2 ```

{
    "total_count": 2,
    "+1": 2,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
594014351 https://github.com/pydata/xarray/issues/3820#issuecomment-594014351 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5NDAxNDM1MQ== sjvrijn 8833517 2020-03-03T15:38:05Z 2020-03-03T15:38:05Z CONTRIBUTOR

Waiting a few more months until it will definitely not be a problem for anyone seems fair to me :+1:

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593969628 https://github.com/pydata/xarray/issues/3820#issuecomment-593969628 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5Mzk2OTYyOA== max-sixty 5635139 2020-03-03T14:10:35Z 2020-03-03T14:10:35Z MEMBER

I definitely agree it's better if possible. I think the tradeoff is between better for almost everyone vs the potential of a break for a small minority.

Currently we support python versions for 42 months, and Python 3.6 was released December 2016. So that means we support it until July 2020 -- given that timeframe I think we wait until then and add this back?

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593874263 https://github.com/pydata/xarray/issues/3820#issuecomment-593874263 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5Mzg3NDI2Mw== sjvrijn 8833517 2020-03-03T10:20:08Z 2020-03-03T10:20:08Z CONTRIBUTOR

I think that inferring dimension-names from the coords-dict is the most intuitive way to define a DataArray.

Passing a dictionary for coords is in my opinion the clearest way to indicate which coordinates belong to which dimension, so then why do I have to specify the same dimension names again?

An example of how I create them from my current project: values = xr.DataArray( values, coords={'n_high': n_highs, 'n_low': n_lows, 'rep': repetitions, 'model': models, 'idx': range(n_test_samples),}, dims=['n_high', 'n_low', 'rep', 'model', 'idx'], <-- repeated dim names attrs=attributes, )

If you expect almost everyone to use CPython or 3.7+ anyway, then I don't actually see any drawbacks, while it would regularly make code shorter and less repetitive.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593700805 https://github.com/pydata/xarray/issues/3820#issuecomment-593700805 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5MzcwMDgwNQ== max-sixty 5635139 2020-03-03T00:20:11Z 2020-03-03T00:20:11Z MEMBER

I guess it's still too soon to 'un-deprecate' this behavior again?

Ha! We do support 3.6. I think that almost everyone is using xarray with CPython, so it's almost certainly safe. But maybe not worth the tradeoff given the benefit is marginal, what are your thoughts?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593673608 https://github.com/pydata/xarray/issues/3820#issuecomment-593673608 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5MzY3MzYwOA== sjvrijn 8833517 2020-03-02T23:18:47Z 2020-03-02T23:18:47Z CONTRIBUTOR

@max-sixty Thanks for the tip. In the end it meant just changing the last line on dims. The paragraph on the coords argument is still valid after all.

On a related note: according to #727 (PR #993), this was deprecated since key-order in dictionaries was arbitrary at the time of that issue. However, their order is fixed since Python3.7, as noted in the documentation:

Changed in version 3.7: Dictionary order is guaranteed to be insertion order. This behavior was an implementation detail of CPython from 3.6.

I guess it's still too soon to 'un-deprecate' this behavior again? 👼

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593574548 https://github.com/pydata/xarray/issues/3820#issuecomment-593574548 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5MzU3NDU0OA== max-sixty 5635139 2020-03-02T19:26:46Z 2020-03-02T19:26:46Z MEMBER

For the PR: in general we don't need to document deprecated behavior, so you can remove than description rather than caveat it

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799
593574188 https://github.com/pydata/xarray/issues/3820#issuecomment-593574188 https://api.github.com/repos/pydata/xarray/issues/3820 MDEyOklzc3VlQ29tbWVudDU5MzU3NDE4OA== max-sixty 5635139 2020-03-02T19:26:02Z 2020-03-02T19:26:02Z MEMBER

Agree! Thanks for spotting @sjvrijn . PR is appreciated, thanks for the offer!

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Documentation of DataArray does not warn that inferring dimension names is deprecated 574097799

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 1118.75ms · About: xarray-datasette