home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

5 rows where issue = 517195073 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 3

  • dcherian 2
  • keewis 2
  • shoyer 1

issue 1

  • assign_coords with mixed DataArray / array args removes coords · 5 ✖

author_association 1

  • MEMBER 5
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
550084872 https://github.com/pydata/xarray/issues/3483#issuecomment-550084872 https://api.github.com/repos/pydata/xarray/issues/3483 MDEyOklzc3VlQ29tbWVudDU1MDA4NDg3Mg== keewis 14808389 2019-11-06T00:24:19Z 2019-11-07T15:46:15Z MEMBER

agreed, my suggestion only applies to assign_coords, and even in that function it might make sense to keep the old behaviour unless the coord was explicitly set.

Edit: this could be fixed by changing how merge_coords and _get_priority_vars_and_indexes work, but they look like magic to me

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  assign_coords with mixed DataArray / array args removes coords 517195073
549525501 https://github.com/pydata/xarray/issues/3483#issuecomment-549525501 https://api.github.com/repos/pydata/xarray/issues/3483 MDEyOklzc3VlQ29tbWVudDU0OTUyNTUwMQ== shoyer 1217238 2019-11-04T20:08:27Z 2019-11-04T20:08:27Z MEMBER

would it not be possible to always convert DataArray args using .variable? Unless I'm missing something, this should keep the information on the dimensions while also allowing to change the data independently:

It might make sense to change how assign_coords/ds.coords[k] = v] works, but in general we do want assign/ds[k] = v to add in coordinates from assigned DataArray objects rather than dropping them silently.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  assign_coords with mixed DataArray / array args removes coords 517195073
549456096 https://github.com/pydata/xarray/issues/3483#issuecomment-549456096 https://api.github.com/repos/pydata/xarray/issues/3483 MDEyOklzc3VlQ29tbWVudDU0OTQ1NjA5Ng== dcherian 2448579 2019-11-04T17:15:44Z 2019-11-04T17:15:44Z MEMBER

That is a good point. Let's see what @shoyer thinks.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  assign_coords with mixed DataArray / array args removes coords 517195073
549436798 https://github.com/pydata/xarray/issues/3483#issuecomment-549436798 https://api.github.com/repos/pydata/xarray/issues/3483 MDEyOklzc3VlQ29tbWVudDU0OTQzNjc5OA== keewis 14808389 2019-11-04T16:33:40Z 2019-11-04T16:33:40Z MEMBER

would it not be possible to always convert DataArray args using .variable? Unless I'm missing something, this should keep the information on the dimensions while also allowing to change the data independently: python obj.assign_coords(x=obj.x.copy(data=list("efgh")).variable, y=(obj.y * 2).variable) obj.assign_coords(x=list("efgh"), y=(obj.y * 2).variable) both work

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  assign_coords with mixed DataArray / array args removes coords 517195073
549429956 https://github.com/pydata/xarray/issues/3483#issuecomment-549429956 https://api.github.com/repos/pydata/xarray/issues/3483 MDEyOklzc3VlQ29tbWVudDU0OTQyOTk1Ng== dcherian 2448579 2019-11-04T16:19:37Z 2019-11-04T16:19:37Z MEMBER

The x=DataArray example looks like a bug.

The last example raises a MergeError regardless of the order of x, y which is good I think. It's pretty ambiguous to change both the index x and the y=function(x) at the same time. It will only work if xarray uses magic and infers that everything but x must be assigned before assigning x.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  assign_coords with mixed DataArray / array args removes coords 517195073

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