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

don't rely on timedelta.total_seconds in AsyncResult #1608

Merged
merged 1 commit into from Apr 16, 2012

Conversation

@minrk
Copy link
Member

commented Apr 15, 2012

which is new in 2.7

Could result in weird errors, because the result was
an AttributeError (on timedelta) raised in a property, which triggered
the __getattr__() path, which would also fail.

don't rely on timedelta.total_seconds in AsyncResult
which is new in 2.7

Could result in weird errors, because the result was
an AttributeError raised in a property, which triggered
the `__getattr__()` path, which would also fail.
@fperez

This comment has been minimized.

Copy link
Member

commented Apr 16, 2012

Great, thanks for the fix!

@fperez

This comment has been minimized.

Copy link
Member

commented Apr 16, 2012

Merging now.

fperez added a commit that referenced this pull request Apr 16, 2012

Merge pull request #1608 from minrk/ar_sugar_2.6
don't rely on timedelta.total_seconds in AsyncResult (timedelta is new in python 2.7).  

This maintains compatibility with Python 2.6; the utility function introduced can be removed if/when we drop 2.6 support.

@fperez fperez merged commit 5750e2d into ipython:master Apr 16, 2012

mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this pull request Nov 3, 2014

Merge pull request ipython#1608 from minrk/ar_sugar_2.6
don't rely on timedelta.total_seconds in AsyncResult (timedelta is new in python 2.7).  

This maintains compatibility with Python 2.6; the utility function introduced can be removed if/when we drop 2.6 support.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.