Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ulmo and Pandas incompatible on JupyterHub #127

Open
aphelionz opened this issue Aug 27, 2018 · 0 comments
Open

Ulmo and Pandas incompatible on JupyterHub #127

aphelionz opened this issue Aug 27, 2018 · 0 comments

Comments

@aphelionz
Copy link

From: hydroshare/hydroshare#2877

@miguelcleon writes:

I'm trying to run a JupyterNotebook on the CUAHSI JupyterHub the resource is here . The version of Pandas and Ulmo do not work together I get a warning:

/opt/conda/envs/python2/lib/python2.7/site-packages/ulmo/twc/kbdi/core.py:20: FutureWarning: pandas.tslib is deprecated and will be removed in a future version. You can access Timestamp as pandas.Timestamp CSV_SWITCHOVER = pandas.tslib.Timestamp('2016-10-01')

and an error:


`AttributeErrorTraceback (most recent call last)
<ipython-input-4-b758f7901a7d> in <module>()
      3 # read daily mean discharge data from cache (statistics code 00003)
      4 #Rio Sabana
----> 5 data = nwis.get_site_data('50067000',start='2017-09-01', end='2017-09-30') #, parameter_code='00060:00003')['00060:00003']
      6 
      7 # print(data['value'])

/opt/conda/envs/python2/lib/python2.7/site-packages/ulmo/usgs/nwis/core.pyc in get_site_data(site_code, service, parameter_code, statistic_code, start, end, period, modified_since, input_file, methods, **kwargs)
    250         datetime_formatter = isodate.datetime_isoformat
    251     if start is not None:
--> 252         start_datetime = util.convert_datetime(start)
    253         url_params['startDT'] = datetime_formatter(start_datetime)
    254     if end is not None:

/opt/conda/envs/python2/lib/python2.7/site-packages/ulmo/util/misc.pyc in convert_datetime(datetime)
     50     datetime-like object (datetime.date, datetime.datetime, or pandas.Timestamp)
     51     """
---> 52     return pandas.Timestamp(datetime).to_datetime()
     53 
     54 

AttributeError: 'Timestamp' object has no attribute 'to_datetime'`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant