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
[9660][twisted/internet/_glibbase] Fix Typeerror in simulate for py3 #1679
Conversation
ec06a1e
to
bf132b3
Compare
b26d96c
to
49cf9bd
Compare
for failing test: python 3.6 is no longer included in macos image. And not within the scope of my changes. |
Fixes TypeError in simulate call Ref: https://twistedmatrix.com/trac/ticket/9660 Ref: twisted/twisted#1679
@glyph Nice all the checks pass now, is there anything I need to change? |
Sadly, the project is suffering for a severe lack of reviewer bandwidth right now, so it's not your fault. If you have a look at https://twisted.reviews/ you might see some stuff submitted by project members that you can review, though, and that might relieve the load a little bit to get this looked at! You're under no obligation, of course, so you can just wait, but this is the reality of open source "staffing", for lack of a better word 😄 . Personally I typically work from the top of that list down when I have time to look at a few things. |
@glyph sorry for adding to the mass amount of messages I'm sure you get. Thanks! |
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.
Changes looks good. Thanks.
I left a few suggestions to improve the tests
The current testing code looks like it's not finished .
No docstring or empty docstring.
Please check my suggestions.
After that, I think that this is ready to review and merge.
Feel free to ping once ready.
Thanks again for your help!
d77dbab
to
b9ce4a3
Compare
Co-authored-by: Adi Roiban <adiroiban@gmail.com>
@adiroiban I rebased to merge some pre-commit/formating changes but I think its good now? |
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.
Looks good. Many thanks!
@@ -0,0 +1 @@ | |||
twisted.internet._glibbase.PortableGlibReactorBase.simulate no longer raises TypeError when there are no delayed called. This was a regression introduced with the migration to Python3 in which the builtin `min` function no longer accepts `None` as an argument. |
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.
The relevant public names are twisted.internet.gireactor.PortableGIReactor.simulate
and twisted.internet.gtk2reactor.PortableGtkReactor.simulate
; in general we should avoid news fragments that mention private names (those which have a single underscore directly following a dot)
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.
so....should I change something or you guys gonna figure this one out?
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.
We can go ahead and merge this as-is, my comment was more for @adiroiban than you :)
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.
(Nothing wrong with fixing up the changelog later.)
Is best to fix the release notes in the PR, when possible :) |
@adiroiban @glyph |
Fix for Windows simulate error has been merged and in 22.2.0rc Ref: twisted/twisted#1679
Scope and purpose
Fixes a Type error when calling simpulate() in a glib reactor.
Contributor Checklist:
tox -e lint
to format my patch to meet the Twisted Coding Standard#
character).review
to the keywords field in Trac, and putting a link to this PR in the comment; it shows up in https://twisted.reviews/ now.The first line is automatically generated by GitHub based on PR ID and branch name.
The other lines generated by GitHub should be replaced.