home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

6 rows where author_association = "MEMBER" and issue = 270677100 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 2

  • shoyer 5
  • max-sixty 1

issue 1

  • Add option “engine” · 6 ✖

author_association 1

  • MEMBER · 6 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
365842057 https://github.com/pydata/xarray/pull/1682#issuecomment-365842057 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM2NTg0MjA1Nw== shoyer 1217238 2018-02-15T07:04:56Z 2018-02-15T07:04:56Z MEMBER

@ajelenak-thg thanks for your patience here. I need to think a little bit harder about what the right API for controlling the default engine is, but this work is definitely appreciated (and will probably make it in for the next release).

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100
348155004 https://github.com/pydata/xarray/pull/1682#issuecomment-348155004 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM0ODE1NTAwNA== shoyer 1217238 2017-11-30T10:58:20Z 2017-11-30T10:58:20Z MEMBER

One more minor complexity is that there are two version of netCDF, not all of which are supported by all tools:

  • netcdf4 support netcdf3 and netcdf4
  • scipy only supports netcdf3
  • h5netcdf only supports netcdf4.
  • pynio supports both netcdf3 and netcdf4.

So will need to distinguish between URLs (opendap) and these two types of netCDF files. To do this, we'll need to look at the first few bytes of each file: - netCDF4/HDF5 starts with the 8-byte signature b'\x89HDF\r\n\x1a\n' - netCDF4 starts with b'CDF\x00' or b'CDF\x01'

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100
341795047 https://github.com/pydata/xarray/pull/1682#issuecomment-341795047 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM0MTc5NTA0Nw== shoyer 1217238 2017-11-03T18:51:49Z 2017-11-03T18:51:49Z MEMBER

Maybe it would make more sense to set a list of engines to try in order? e.g., io_engines=['pydap', 'h5netcdf', 'scipy'] could use pydap for web requests, h5netcdf for netCDF4 and scipy for netCDF3. The default would be something like ['netcdf4', 'pydap', 'scipy', 'h5netcdf']

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100
341613287 https://github.com/pydata/xarray/pull/1682#issuecomment-341613287 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM0MTYxMzI4Nw== shoyer 1217238 2017-11-03T03:04:17Z 2017-11-03T03:04:17Z MEMBER

We should probably have separate options for opendap/netcdf. It would not be so useful to try to use pydap to read a netcdf file.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100
341586491 https://github.com/pydata/xarray/pull/1682#issuecomment-341586491 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM0MTU4NjQ5MQ== shoyer 1217238 2017-11-02T23:19:55Z 2017-11-02T23:19:55Z MEMBER

I like the direction this is going in, but as @MaximilianR notes it won't work to set this in default function arguments.

Also, I would probably pick a more descriptive name for the option, e.g., netcdf_engine.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100
341577210 https://github.com/pydata/xarray/pull/1682#issuecomment-341577210 https://api.github.com/repos/pydata/xarray/issues/1682 MDEyOklzc3VlQ29tbWVudDM0MTU3NzIxMA== max-sixty 5635139 2017-11-02T22:29:45Z 2017-11-02T22:29:45Z MEMBER

This looks great so far!

But have you tested this? I have a suspicion that putting OPTIONS['engine'] as a default arg won't work: whenever the relevant function is imported, the default will be set to the value at that time, and won't change if the options dictionary is later modified.

You could have a default arg of None and then look up the option within the function, if my suspicions are right

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add option “engine” 270677100

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