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

bpo-34263 Cap timeout submitted to epoll/select etc. to one day. #8532

Merged
merged 3 commits into from
Jul 31, 2018

Conversation

MartinAltmayer
Copy link
Contributor

@MartinAltmayer MartinAltmayer commented Jul 28, 2018

"Timeouts (relative delay or absolute when) should not exceed one day."

Shall we update the doc? With this PR there is no reason anymore to disallow timeouts greater than one day in asyncio.

https://bugs.python.org/issue34263

@the-knights-who-say-ni
Copy link

Hello, and thanks for your contribution!

I'm a bot set up to make sure that the project can legally accept your contribution by verifying you have signed the PSF contributor agreement (CLA).

Unfortunately our records indicate you have not signed the CLA. For legal reasons we need you to sign this before we can look at your contribution. Please follow the steps outlined in the CPython devguide to rectify this issue.

When your account is ready, please add a comment in this pull request
and a Python core developer will remove the CLA not signed label
to make the bot check again.

You can check yourself
to see if the CLA has been received.

Thanks again for your contribution, we look forward to reviewing it!

@1st1
Copy link
Member

1st1 commented Jul 28, 2018

Shall we update the doc?

Yes, let's just drop that sentence from docs in 3.8.

Copy link
Member

@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to write a test? Maybe modify the constant during the test?

@@ -63,6 +63,9 @@

_HAS_IPv6 = hasattr(socket, 'AF_INET6')

# Maximum timeout passed to select to avoid OS limitations
MAXIMUM_SELECT_TIMEOUT = 24 * 3600
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hum, maybe it's better to make the constant private. What do you think @1st1?

@1st1
Copy link
Member

1st1 commented Jul 30, 2018

Is it possible to write a test? Maybe modify the constant during the test?

Yeah, I discussed this with @MartinAltmayer and we ultimately decided that this test would be too fragile and complex. I don't this we need it.

Hum, maybe it's better to make the constant private. What do you think @1st1?

Absolutely all constants in asyncio are already private and it's not recommended to modify them.

@1st1 1st1 merged commit 944451c into python:master Jul 31, 2018
@miss-islington
Copy link
Contributor

Thanks @MartinAltmayer for the PR, and @1st1 for merging it 🌮🎉.. I'm working now to backport this PR to: 3.6, 3.7.
🐍🍒⛏🤖

@bedevere-bot
Copy link

GH-8586 is a backport of this pull request to the 3.7 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 31, 2018
…honGH-8532)

(cherry picked from commit 944451c)

Co-authored-by: MartinAltmayer <martin.altmayer@web.de>
@bedevere-bot
Copy link

GH-8587 is a backport of this pull request to the 3.6 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 31, 2018
…honGH-8532)

(cherry picked from commit 944451c)

Co-authored-by: MartinAltmayer <martin.altmayer@web.de>
@vstinner
Copy link
Member

Absolutely all constants in asyncio are already private and it's not recommended to modify them.

My proposal was to add "_" prefix: _MAXIMUM_SELECT_TIMEOUT.

I'm fine with the merged PR.

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

Successfully merging this pull request may close these issues.

6 participants