summaryrefslogtreecommitdiffstats
path: root/Lib/asyncio/base_events.py
Commit message (Collapse)AuthorAgeFilesLines
...
* asyncio: Enable the debug mode of event loops when the PYTHONASYNCIODEBUGVictor Stinner2014-06-221-1/+2
| | | | environment variable is set
* asyncio: BaseEventLoop._assert_is_current_event_loop() now only raises anVictor Stinner2014-06-221-1/+2
| | | | | | | | | | | | exception if the current loop is not None. Guido van Rossum wrote: "The behavior that you can set the loop to None (and keep track of it explicitly) is part of the spec, and this should still be supported even in debug mode. The behavior that we raise an error if you are caught having multiple active loops per thread is just a debugging heuristic, and it shouldn't break code that follows the spec."
* asyncio, Tulip issue 105: in debug mode, log callbacks taking more than 100 msVictor Stinner2014-06-201-5/+27
| | | | to be executed.
* Tulip issue 83: document more asyncio functions in docstringsVictor Stinner2014-06-191-3/+18
|
* Issue #21326: Add a new is_closed() method to asyncio.BaseEventLoopVictor Stinner2014-06-101-0/+19
| | | | | | | | | | | Add BaseEventLoop._closed attribute and use it to check if the event loop was closed or not, instead of checking different attributes in each subclass of BaseEventLoop. run_forever() and run_until_complete() methods now raise a RuntimeError('Event loop is closed') exception if the event loop was closed. BaseProactorEventLoop.close() now also cancels "accept futures".
* Issue #21119: asyncio now closes sockets on errorsVictor Stinner2014-06-031-0/+8
| | | | | | Fix ResourceWarning: create_connection(), create_datagram_endpoint() and create_unix_server() methods of event loop now close the newly created socket on error.
* asyncio: Upstream issue #167: remove dead code, by Marc Schlaich.Guido van Rossum2014-05-101-5/+1
|
* asyncio: Ensure call_soon(), call_later() and call_at() are invoked on currentVictor Stinner2014-03-211-1/+22
| | | | | | loop in debug mode. Raise a RuntimeError if the event loop of the current thread is different. The check should help to debug thread-safetly issue. Patch written by David Foster.
* asyncio: _check_resolved_address() must also accept IPv6 without flow_info andVictor Stinner2014-02-201-1/+1
| | | | scope_id: (host, port).
* asyncio: Fix _check_resolved_address() for IPv6 addressVictor Stinner2014-02-201-2/+5
|
* asyncio, Tulip issue #136: Add get/set_debug() methods to BaseEventLoopTests.Victor Stinner2014-02-191-0/+7
| | | | | | Add also a PYTHONASYNCIODEBUG environment variable to debug coroutines since Python startup, to be able to debug coroutines defined directly in the asyncio module.
* asyncio: pep8-ify the code.Yury Selivanov2014-02-191-5/+6
|
* asyncio: New error handling API. Issue #20681.Yury Selivanov2014-02-181-2/+94
|
* asyncio: Add support for UNIX Domain Sockets.Yury Selivanov2014-02-181-0/+7
|
* ayncio, Tulip issue 129: BaseEventLoop.sock_connect() now raises an error ifVictor Stinner2014-02-131-0/+25
| | | | | the address is not resolved (hostname instead of an IP address) for AF_INET and AF_INET6 address families.
* Issue #20505: Remove debug codeVictor Stinner2014-02-111-20/+0
|
* asyncio, Tulip issue 130: Add more checks on subprocess_exec/subprocess_shellVictor Stinner2014-02-111-3/+9
| | | | parameters
* asyncio, Tulip issue 126: call_soon(), call_soon_threadsafe(), call_later(),Victor Stinner2014-02-111-0/+6
| | | | | call_at() and run_in_executor() now raise a TypeError if the callback is a coroutine function.
* Issue #20505: use also the monotonic time to decide if asyncio debug tracesVictor Stinner2014-02-111-3/+4
| | | | should be printed
* Issue #20505: Oops, only print debug info if selector.select(timeout) took lessVictor Stinner2014-02-111-1/+1
| | | | than timeout
* Issue #20505: Improve debug info in asyncio event loopVictor Stinner2014-02-111-5/+18
|
* Issue #20505: BaseEventLoop uses again the resolution of the clock to decide ifVictor Stinner2014-02-101-2/+3
| | | | scheduled tasks should be executed or not.
* Issue #20505: Add debug info to analyze sporaric failures ofVictor Stinner2014-02-101-0/+6
| | | | test_timeout_rounding() on Windows XP buildbots.
* asyncio: Tulip issue 112: Inline make_handle() into Handle constructorVictor Stinner2014-02-091-1/+1
|
* Issue #20505: Remove resolution and _granularity from selectors and asyncioVictor Stinner2014-02-071-12/+1
| | | | | * Remove selectors.BaseSelector.resolution attribute * Remove asyncio.BaseEventLoop._granularity attribute
* Issue #20505: add debug infoVictor Stinner2014-02-071-0/+10
|
* Issue #20452: Remove debug code, no more neededVictor Stinner2014-01-311-9/+1
|
* asyncio: Fix error message in BaseEventLoop.subprocess_shell(). Patch writtenVictor Stinner2014-01-311-1/+1
| | | | by Vajrasky Kok.
* Issue #20452: select and selectors round (again) timeout away from zero forVictor Stinner2014-01-311-10/+5
| | | | | | poll and epoll Improve also debug info to analyze the issue
* Issue #20452: Oops, fix debug code :-/Victor Stinner2014-01-311-5/+10
| | | | Add also event more debug info
* Issue #20452: add more info in case of test_asyncio failure to try to debug theVictor Stinner2014-01-311-1/+9
| | | | failure on buildbot "x86 Ubuntu Shared 3.x"
* asyncio: subprocess_shell() and subprocess_exec() now raise ValueError ↵Victor Stinner2014-01-291-5/+14
| | | | | | instead of assert. Moreover, bufsize different than 0 is now considered as an error.
* Merge latest Tulip into asyncioVictor Stinner2014-01-251-7/+2
| | | | | | - Make the new granularity attribute private - Simplify BaseEventLoop._run_once(): avoid math.ceil(), use simple arithmetic instead
* Issue #20311: asyncio: Add a granularity attribute to BaseEventLoop: maximumVictor Stinner2014-01-251-0/+6
| | | | | | between the resolution of the BaseEventLoop.time() method and the resolution of the selector. The granuarility is used in the scheduler to round time and deadline.
* asyncio: Cleanup logging in BaseEventLoop._run_once()Victor Stinner2014-01-221-2/+5
| | | | | | logger.log() is now responsible to format the timeout. It might be faster if the log is disabled for DEBUG level, but it's also more readable and fix an issue with Python 2.6 in the Trollius project.
* Close #20275: Optimize BaseEventLoop._run_once()Victor Stinner2014-01-201-8/+11
| | | | | | Logger.log() is "slow", logger.isEnabledFor() is faster and the logger is disabled in most cases. A microbenchmark executing 100,000 dummy tasks is 22% faster with this change.
* asyncio: Fix space in log message about poll time.Guido van Rossum2013-12-211-1/+1
|
* asyncio: Better-looking errors when ssl module cannot be imported. In part ↵Guido van Rossum2013-11-011-0/+2
| | | | by Arnaud Faure.
* asyncio: Various style nits.Guido van Rossum2013-11-011-1/+1
|
* asyncio: Document EventLoop.close().Guido van Rossum2013-11-011-0/+5
|
* asyncio: Add server_hostname as create_connection() argument, with secure ↵Guido van Rossum2013-11-011-2/+21
| | | | default.
* (Hopefully) proper fix for gentoo buildbot failure due to lacking AF_INET6 ↵Guido van Rossum2013-10-201-1/+5
| | | | | | support. This should supersede revision e3ec6b17260c (but please test before removing that).
* Issue #19299: fix refleak test failures in test_asyncioAntoine Pitrou2013-10-191-0/+8
|
* Rename the logger to plain "logger".Guido van Rossum2013-10-171-2/+2
|
* Initial checkin of asyncio package (== Tulip, == PEP 3156).Guido van Rossum2013-10-171-0/+606