Commit Graph

18 Commits

Author SHA1 Message Date
Victor Stinner 85310a50a9 Issue #20505: Remove resolution and _granularity from selectors and asyncio
* Remove selectors.BaseSelector.resolution attribute
* Remove asyncio.BaseEventLoop._granularity attribute
2014-02-07 23:34:58 +01:00
Victor Stinner 6b0fa70547 test_selectors: remove unused imports 2014-01-25 15:04:22 +01:00
Victor Stinner 635fca9704 Issue #20311: selectors: Add a resolution attribute to BaseSelector. 2014-01-25 14:56:48 +01:00
Victor Stinner 2041859f27 Issue #20311: Revert e042ea77a152 and 7ce7295393c2, PollSelector.select() and
EpollSelector.select() round again the timeout towards zero
2014-01-25 14:43:45 +01:00
Victor Stinner da94b9ebeb Issue #20311: add debug help in test_selectors 2014-01-23 15:07:26 +01:00
Victor Stinner 11da8e24ba Issue #20311: selector.PollSelector.select() now rounds the timeout away from
zero, instead of rounding towards zero. For example, a timeout of one
microsecond is now rounded to one millisecond, instead of being rounded to
zero.

Move also a test in test_epoll which was moved by my previous merge.
2014-01-21 01:48:28 +01:00
Victor Stinner 383bff4d74 Backed out changeset c4c1c4bc8086 2013-12-09 01:59:07 +01:00
Victor Stinner 1adc2371b8 Issue #19876: Run also test_selectors.test_unregister_after_fd_close_and_reuse() on Windows
os.dup2() is available on Windows.
2013-12-09 01:57:14 +01:00
Charles-François Natali ead8d0858b Fix test_selectors failure introduced by 39e7995f9ad1. 2013-12-08 10:06:04 +01:00
Guido van Rossum 9710ff04ac Silently ignore unregistering closed files. Fixes issue 19876. With docs and slight test refactor. 2013-12-07 15:57:01 -08:00
Victor Stinner 1a048f93bb test_selectors: test_timeout fails sometimes on busy (slow) buildbots, relax
the unit test on max time (but be more strict on mon time). Example of failure:

http://buildbot.python.org/all/builders/x86%20OpenIndiana%203.x/builds/6978/steps/test/logs/stdio

======================================================================
FAIL: test_timeout (test.test_selectors.PollSelectorTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/export/home/buildbot/32bits/3.x.cea-indiana-x86/build/Lib/test/test_selectors.py", line 316, in test_timeout
    self.assertTrue(0.5 < t1 - t0 < 1.5, t1 - t0)
AssertionError: False is not true : 1.5033390671014786
2013-11-17 23:46:34 +01:00
Guido van Rossum d0786a1a50 Optimize BaseSelector.modify(). Patch by Arnaud Faure. 2013-11-07 08:39:28 -08:00
Charles-François Natali 4574b49703 Issue #19172: Add a get_map() method to selectors. 2013-10-30 20:31:04 +01:00
Charles-François Natali c60dd5b0d4 test_selectors: make timeout-related errors report the actual elapsed timeout. 2013-10-25 17:56:00 +02:00
Charles-François Natali 052058fa14 test_selectors: rename test_interrupted_retry() (since it doesn't actually
retry on EINTR).
2013-10-25 17:49:47 +02:00
Charles-François Natali 807ba8552a Issue #18963: skip test_selectors.test_above_fd_setsize on older OS X versions. 2013-09-08 12:31:32 +02:00
Charles-François Natali 9437d7a7fe Issue #18963: Fix test_selectors.test_above_fd_setsize on OS X, where the
default RLIMIT_NOFILE hard limit can be RLIMIT_INFINITY.
2013-09-08 11:34:42 +02:00
Charles-François Natali 243d8d85de Issue #16853: Add new selectors module. 2013-09-04 19:02:49 +02:00