home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

2 rows where issue = 325470877 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

  • shoyer 2

issue 1

  • Errors on pycharm completion · 2 ✖

author_association 1

  • MEMBER 2
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
391167274 https://github.com/pydata/xarray/issues/2172#issuecomment-391167274 https://api.github.com/repos/pydata/xarray/issues/2172 MDEyOklzc3VlQ29tbWVudDM5MTE2NzI3NA== shoyer 1217238 2018-05-22T22:58:50Z 2018-05-22T22:59:12Z MEMBER

The direct cause for this issue appears to be using integers as dimension names: ```

x <xarray.Dataset> Dimensions: (2: 2, 2000: 2000, 10000: 10000) Dimensions without coordinates: 2, 2000, 10000 Data variables: sample_data (2, 2000, 10000) float64 0.8346 0.7321 0.00948 0.04605 ... ```

We do try to support arbitrary hashable values as dimensions names for most operations, but you will have better luck in general using strings.

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Errors on pycharm completion 325470877
391166924 https://github.com/pydata/xarray/issues/2172#issuecomment-391166924 https://api.github.com/repos/pydata/xarray/issues/2172 MDEyOklzc3VlQ29tbWVudDM5MTE2NjkyNA== shoyer 1217238 2018-05-22T22:56:59Z 2018-05-22T22:56:59Z MEMBER

Thanks for the report. This is definitely a bug, calling dir() on an xarray object should never raise an error: ```python import numpy as np import xarray as xr

sample_data = np.random.uniform(size=[2,2000,10000]) x = xr.Dataset({"sample_data": (sample_data.shape, sample_data)}) x2 = x["sample_data"] dir(x2) Results in:python-traceback


TypeError Traceback (most recent call last) <ipython-input-2-39db0ce27e1d> in <module>() ----> 1 dir(x2)

/usr/local/lib/python3.6/dist-packages/xarray/core/common.py in dir(self) 195 """ 196 extra_attrs = [item --> 197 for sublist in self._attr_sources 198 for item in sublist 199 if isinstance(item, basestring)]

/usr/local/lib/python3.6/dist-packages/xarray/core/dataarray.py in _attr_sources(self) 494 def _attr_sources(self): 495 """List of places to look-up items for attribute-style access""" --> 496 return self._item_sources + [self.attrs] 497 498 @property

/usr/local/lib/python3.6/dist-packages/xarray/core/dataarray.py in _item_sources(self) 499 def _item_sources(self): 500 """List of places to look-up items for key-completion""" --> 501 return [self.coords, {d: self[d] for d in self.dims}, 502 LevelCoordinatesSource(self)] 503

/usr/local/lib/python3.6/dist-packages/xarray/core/dataarray.py in <dictcomp>(.0) 499 def _item_sources(self): 500 """List of places to look-up items for key-completion""" --> 501 return [self.coords, {d: self[d] for d in self.dims}, 502 LevelCoordinatesSource(self)] 503

/usr/local/lib/python3.6/dist-packages/xarray/core/dataarray.py in getitem(self, key) 471 else: 472 # xarray-style array indexing --> 473 return self.isel(**self._item_key_to_dict(key)) 474 475 def setitem(self, key, value):

TypeError: isel() keywords must be strings ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Errors on pycharm completion 325470877

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