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

Add some documentation on gotchas related to pytz updates #7620 #7672

Merged
merged 1 commit into from
Jul 6, 2014

Conversation

rockg
Copy link
Contributor

@rockg rockg commented Jul 5, 2014

closes #7620

@jreback
Copy link
Contributor

jreback commented Jul 5, 2014

can u make this pytz/dateutil (or just say tz library)

as this is a function. of the time zone definitions and not the tz library itself

@rockg
Copy link
Contributor Author

rockg commented Jul 6, 2014

Done.

Also, the ipython slowness was actually due to how completion is implemented in PyDev. It does dir(object) and then iterates through the attributes calling getattr in order to call inspect.getdoc. With a large DatetimeIndex, getattr for properties evaluates the property and some of those take 15 seconds. Trying to work out a solution to that on the PyDev side.

@immerrr
Copy link
Contributor

immerrr commented Jul 6, 2014

@rockg, if that's of any help, I've recently pushed a fix into ipython introspection utilities to avoid evaluating properties in the last step of the lookup when doing question-mark queries, e.g. obj.this_is_evaluated.this_is_not? It ended up pretty simple, maybe you can borrow some inspiration from there.

@jreback jreback added the Docs label Jul 6, 2014
@jreback
Copy link
Contributor

jreback commented Jul 6, 2014

@jorisvandenbossche ?

@jreback jreback added this to the 0.14.1 milestone Jul 6, 2014
@jorisvandenbossche
Copy link
Member

looks ok. Does this close #7620 ?

jreback added a commit that referenced this pull request Jul 6, 2014
Add some documentation on gotchas related to pytz updates #7620
@jreback jreback merged commit 0876947 into pandas-dev:master Jul 6, 2014
@rockg
Copy link
Contributor Author

rockg commented Jul 6, 2014

@immerrr Thank you for the reference. I was doing something similar. I simply did:

try:
   obj = getattr(type(parent_obj), attr)
except AttributeError:
   obj = getattr(parent_obj, attr)
except:
   continue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Timezones are not comparable between different pytz versions
4 participants