-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Deprecated twisted.internet.defer.TimeoutError in favor of twisted.internet.error.TimeoutError #261
Conversation
Remove reference in docstring to Deferred.setTimeout, which was removed in 0d2674c
…net.error.TimeoutError
Use deprecatedModuleAttribute()
| @@ -25,10 +25,12 @@ | |||
| from functools import wraps | |||
|
|
|||
| # Twisted imports | |||
| import twisted.internet.error | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to have shorter named in the rest of the code I think that we should just do
from twisted.internet import error
| @@ -2357,7 +2357,7 @@ def test_waitUntilLockedWithTimeoutUnlocked(self): | |||
| but the lock is unlocked before our timeout. | |||
| """ | |||
| def onTimeout(f): | |||
| f.trap(defer.TimeoutError) | |||
| f.trap(error.TimeoutError) | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here is a missing coverage which will block the merge :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do I test that? That code is inside a test that is supposed to be testing a condition that is never supposed to happen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question :)
I would say that we should have a # pragma: no-cover comment to let coverage know that this line should be ignored
... but first, let's talk about it over the mailing list. I will start the conversation :)
Thanks!
|
Closing, as per feedback in |
See:
http://twistedmatrix.com/trac/ticket/8533