html_url,issue_url,id,node_id,user,created_at,updated_at,author_association,body,reactions,performed_via_github_app,issue
https://github.com/pydata/xarray/issues/2097#issuecomment-484259391,https://api.github.com/repos/pydata/xarray/issues/2097,484259391,MDEyOklzc3VlQ29tbWVudDQ4NDI1OTM5MQ==,1217238,2019-04-17T21:00:00Z,2019-04-17T21:00:00Z,MEMBER,"Yes, we would still welcome a fix here.
We could probably change that line to something like:
```
if isinstance(data, (pd.Series, pd.Index, pd.DataFrame)):
data = data.values
```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,319329850
https://github.com/pydata/xarray/issues/2097#issuecomment-484255028,https://api.github.com/repos/pydata/xarray/issues/2097,484255028,MDEyOklzc3VlQ29tbWVudDQ4NDI1NTAyOA==,1700203,2019-04-17T20:46:55Z,2019-04-17T20:46:55Z,CONTRIBUTOR,"I was wondering if this is still up for consideration?
> Thank you for your help! If I can be brought to better understand any constraints to adjacent issues, I can consider drafting a fix for this.
Same here.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,319329850
https://github.com/pydata/xarray/issues/2097#issuecomment-385839554,https://api.github.com/repos/pydata/xarray/issues/2097,385839554,MDEyOklzc3VlQ29tbWVudDM4NTgzOTU1NA==,1217238,2018-05-02T01:36:34Z,2018-05-02T01:36:34Z,MEMBER,"> We internally use many inhouse array-like classes and this line is used to avoid multiple nesting.
I think we can change this line to more explicit type checking.
Agreed, we should do more explicit type checking. It's a little silly to assume that every object with a `.values` attribute is an xarray.DataArray, xarray.Variable, pandas.Series or pandas.DataFrame.","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,319329850
https://github.com/pydata/xarray/issues/2097#issuecomment-385830499,https://api.github.com/repos/pydata/xarray/issues/2097,385830499,MDEyOklzc3VlQ29tbWVudDM4NTgzMDQ5OQ==,6815844,2018-05-02T00:33:17Z,2018-05-02T00:33:17Z,MEMBER,"Thanks for the report.
We did not consider to store an object type array other than string, but it should be supported.
I think we should improve this line,
https://github.com/pydata/xarray/blob/39b2a37207fc8e6c5199ba9386831ba7eb06d82b/xarray/core/variable.py#L171-L172
We internally use many inhouse array-like classes and this line is used to avoid multiple nesting.
I think we can change this line to more explicit type checking.
Currently, the following does not work either
```python
In [11]: xr.DataArray(HasValues, dims=[])
Out[11]:
array(5)
```
For your perticular purpose, the following will be working
```
bad_indexed.loc[{'dim_0': 0}] = np.array(HasValues(), dtype=object)
```","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,319329850