home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

4 rows where issue = 153640301 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 2

  • shoyer 2
  • max-sixty 2

issue 1

  • Inconsistent handling of .item with PeriodIndex · 4 ✖

author_association 1

  • MEMBER 4
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
218362743 https://github.com/pydata/xarray/issues/846#issuecomment-218362743 https://api.github.com/repos/pydata/xarray/issues/846 MDEyOklzc3VlQ29tbWVudDIxODM2Mjc0Mw== max-sixty 5635139 2016-05-11T05:05:36Z 2016-05-11T05:05:36Z MEMBER

OK great. Closing this. Cheers

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Inconsistent handling of .item with PeriodIndex 153640301
218360165 https://github.com/pydata/xarray/issues/846#issuecomment-218360165 https://api.github.com/repos/pydata/xarray/issues/846 MDEyOklzc3VlQ29tbWVudDIxODM2MDE2NQ== shoyer 1217238 2016-05-11T04:40:58Z 2016-05-11T04:40:58Z MEMBER

I see, because all numpy dtypes have .item(), and Period is trying to be a dtype? I haven't come across .item() before but I generally don't work much with numpy directly

Yes, that would be the argument here. It's not clear how closely pandas should be mimicking NumPy here, though, given that we are looking to eventually make the backend flexible enough that it doesn't need to be built on NumPy.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Inconsistent handling of .item with PeriodIndex 153640301
218357921 https://github.com/pydata/xarray/issues/846#issuecomment-218357921 https://api.github.com/repos/pydata/xarray/issues/846 MDEyOklzc3VlQ29tbWVudDIxODM1NzkyMQ== max-sixty 5635139 2016-05-11T04:19:50Z 2016-05-11T04:19:50Z MEMBER

So I think one reasonable approach would be to implement .item() for pandas.Period, too.

I see, because all numpy dtypes have .item(), and Period is trying to be a dtype? I haven't come across .item() before but I generally don't work much with numpy directly

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Inconsistent handling of .item with PeriodIndex 153640301
218355316 https://github.com/pydata/xarray/issues/846#issuecomment-218355316 https://api.github.com/repos/pydata/xarray/issues/846 MDEyOklzc3VlQ29tbWVudDIxODM1NTMxNg== shoyer 1217238 2016-05-11T03:53:50Z 2016-05-11T03:53:50Z MEMBER

Actually, p.values in your first example is a datetime64 scalar. NumPy scalars support .item(), though.

So I think one reasonable approach would be to implement .item() for pandas.Period, too. One difference is that there is no native Python scalar for periods, so I would probably just make .item() a no-op.

Side note: that the behavior you show for DatetimeIndex/datetime64[ns] is actually a bug in NumPy related to nanosecond precision:

``` In [4]: np.array(np.datetime64('2000-01-01', 'us')).item() Out[4]: datetime.datetime(2000, 1, 1, 0, 0)

In [5]: np.array(np.datetime64('2000-01-01', 's')).item() Out[5]: datetime.datetime(2000, 1, 1, 0, 0)

In [6]: np.array(np.datetime64('2000-01-01', 'ns')).item() Out[6]: 946684800000000000 ```

It's probably worth filing on bug report, if one doesn't already exist...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Inconsistent handling of .item with PeriodIndex 153640301

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