home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

3 rows where issue = 679575175 and user = 14371165 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 1

  • Illviljan · 3 ✖

issue 1

  • Improve Dataset documentation · 3 ✖

author_association 1

  • MEMBER 3
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
674583004 https://github.com/pydata/xarray/issues/4345#issuecomment-674583004 https://api.github.com/repos/pydata/xarray/issues/4345 MDEyOklzc3VlQ29tbWVudDY3NDU4MzAwNA== Illviljan 14371165 2020-08-16T21:57:36Z 2020-08-16T22:02:34Z MEMBER

Creating a decorator for this sounds a bit too fancy compared to just moving the init docstring to the class docstring in my opinion.

Is xarray following the numpy docstring guidelines? Reading up on the numpy guidelines they recommend that the constructor (init) should be documented at the class docstring. https://numpydoc.readthedocs.io/en/latest/format.html#class-docstring

And after looking around some more the modules that prefers having init parameters at the class docstring are: * numpy - https://github.com/numpy/numpy/blob/master/numpy/core/records.py#L98 * scipy - https://github.com/scipy/scipy/blob/v1.5.2/scipy/interpolate/interpolate.py * pandas - https://github.com/pandas-dev/pandas/blob/v1.1.0/pandas/core/frame.py#L339-L9257 * dask - https://github.com/dask/dask/blob/master/dask/blockwise.py#L135

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Improve Dataset documentation 679575175
674575204 https://github.com/pydata/xarray/issues/4345#issuecomment-674575204 https://api.github.com/repos/pydata/xarray/issues/4345 MDEyOklzc3VlQ29tbWVudDY3NDU3NTIwNA== Illviljan 14371165 2020-08-16T20:40:16Z 2020-08-16T20:40:16Z MEMBER

My opinion is that it is a general issue but maybe that's because I prefer Spyder? Jupyterlab is the other IDE I know that has this functionality it seems to print class and init information. Are there any others?

Checking pd.DataFrame() in JupyterLab:

Checking xr.Dataset() in JupyterLab:

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Improve Dataset documentation 679575175
674491988 https://github.com/pydata/xarray/issues/4345#issuecomment-674491988 https://api.github.com/repos/pydata/xarray/issues/4345 MDEyOklzc3VlQ29tbWVudDY3NDQ5MTk4OA== Illviljan 14371165 2020-08-16T07:30:14Z 2020-08-16T07:30:14Z MEMBER

Yeah, I've read the same thing that either __init__ or the class can be used. I liked adding it in __init__ too when I've developed classes because it's consistent with other functions and methods. But now that I'm on the user side I think the class docstring is the way to go. Pandas and scipy seems to be pretty consistent with this as well: * Series - https://github.com/pandas-dev/pandas/blob/v1.1.0/pandas/core/series.py#L139-L4979 * Interpolate- https://github.com/scipy/scipy/blob/v1.5.2/scipy/interpolate/interpolate.py

The Spyder help pane simply reads xr.Dataset.__doc__ and it would correctly read the __init__ doc if I I typed out xr.Dataset.__init__ too, but which users prefers to do that?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Improve Dataset documentation 679575175

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