Commit Graph

18973 Commits

Author SHA1 Message Date
Victor Stinner 9036e49ba1 Tulip issue 184: Fix test_pipe() on Windows
Pass explicitly the event loop to StreamReaderProtocol.
2015-01-13 16:13:06 +01:00
Benjamin Peterson 82f34ada45 fix instances of consecutive articles (closes #23221)
Patch by Karan Goel.
2015-01-13 09:17:24 -05:00
Victor Stinner 38dc250521 Issue #23209, #23225: selectors.BaseSelector.close() now clears its internal
reference to the selector mapping to break a reference cycle. Initial patch
written by Martin Richard.
2015-01-13 09:58:33 +01:00
Victor Stinner 70db9e428a asyncio: sync with Tulip
* Tulip issue 184: FlowControlMixin constructor now get the event loop if the
  loop parameter is not set. Add unit tests to ensure that constructor of
  StreamReader and StreamReaderProtocol classes get the event loop.
* Remove outdated TODO/XXX
2015-01-09 21:32:05 +01:00
Victor Stinner 15cc678d89 asyncio: Truncate to 80 columns 2015-01-09 00:09:10 +01:00
Nick Coghlan b9fdb7a452 Issue 19548: update codecs module documentation
- clarified the distinction between text encodings and other codecs
- clarified relationship with builtin open and the io module
- consolidated documentation of error handlers into one section
- clarified type constraints of some behaviours
- added tests for some of the new statements in the docs
2015-01-07 00:22:00 +10:00
Victor Stinner fcfed19913 Issue #21356: Make ssl.RAND_egd() optional to support LibreSSL. The
availability of the function is checked during the compilation. Patch written
by Bernard Spil.
2015-01-06 13:54:58 +01:00
Victor Stinner 212994e4e2 Issue #23140, asyncio: Simplify the unit test 2015-01-06 01:22:45 +01:00
Victor Stinner c447ba04e7 Issue #23140, asyncio: Fix cancellation of Process.wait(). Check the state of
the waiter future before setting its result.
2015-01-06 01:13:49 +01:00
Ned Deily 1418320850 Issue #22165: Skip test_undecodable_filename on OS X prior to 10.5.
10.4 systems do not allow creation of files with such filenames.
2015-01-05 01:02:30 -08:00
Gregory P. Smith 5719ef17ba fix issue23157 - time_hashlib hadn't been ported to Python 3. 2015-01-04 00:36:04 -08:00
Victor Stinner 956de691f8 Issue #22926: In debug mode, call_soon(), call_at() and call_later() methods of
asyncio.BaseEventLoop now use the identifier of the current thread to ensure
that they are called from the thread running the event loop.

Before, the get_event_loop() method was used to check the thread, and no
exception was raised when the thread had no event loop. Now the methods always
raise an exception in debug mode when called from the wrong thread. It should
help to notice misusage of the API.
2014-12-26 21:07:52 +01:00
Victor Stinner d7ff5a5375 asyncio: sync with Tulip
* Fix pyflakes warnings: remove unused imports and variables
* asyncio.test_support now uses test.support and test.script_helper if available
2014-12-26 21:16:42 +01:00
Victor Stinner fe02e39029 Issue #22585: On OpenBSD 5.6 and newer, os.urandom() now calls getentropy(),
instead of reading /dev/urandom, to get pseudo-random bytes.
2014-12-21 01:16:38 +01:00
Benjamin Peterson 94cb7a2429 fix behavior of trailing slash redirection when a query string is involved (closes #23112) 2014-12-26 10:53:43 -06:00
Benjamin Peterson 10e76b67c9 allow more operations to work on detached streams (closes #23093)
Patch by Martin Panter.
2014-12-21 20:51:50 -06:00
Serhiy Storchaka fe3dc376fa Issue #19104: pprint now produces evaluable output for wrapped strings. 2014-12-20 20:57:15 +02:00
Serhiy Storchaka f65d1d3b02 Issue #23071: "namereplace_errors" was added only in 3.5. 2014-12-20 18:53:01 +02:00
Serhiy Storchaka de3ee5b94f Issue #23071: Added missing names to codecs.__all__. Patch by Martin Panter. 2014-12-20 17:42:38 +02:00
Victor Stinner 4d825b45a0 asyncio: IocpProactor.wait_for_handle() test now also checks the result of the
future
2014-12-19 17:10:44 +01:00
Victor Stinner dc7765d12c asyncio: sync with Tulip 2014-12-18 12:29:53 +01:00
Victor Stinner 3a1c738e6c Issue #23074: asyncio.get_event_loop() now raises an exception if the thread
has no event loop even if assertions are disabled.
2014-12-18 01:20:10 +01:00
Serhiy Storchaka 5bbd231f27 Issue #15513: Added a __sizeof__ implementation for pickle classes. 2014-12-16 19:39:08 +02:00
Serhiy Storchaka 05dadcfb28 Issue #19858: pickletools.optimize() now aware of the MEMOIZE opcode, can
produce more compact result and no longer produces invalid output if input
data contains MEMOIZE opcodes together with PUT or BINPUT opcodes.
2014-12-16 18:00:56 +02:00
Benjamin Peterson 4c11c92578 remove extra ssl imports (closes #23053)
Patch from Jan Matejek.
2014-12-15 10:04:13 -05:00
Serhiy Storchaka bad1257c96 Issue #22777: Test pickling with all protocols. 2014-12-15 14:03:42 +02:00
Serhiy Storchaka 79b81738ef Issue #23015: Improved testing of the uuid module. 2014-12-15 12:03:44 +02:00
Benjamin Peterson 9566de18e6 make sure server threads get cleaned up 2014-12-13 16:13:24 -05:00
Benjamin Peterson 3cda0ed062 pop the loop block even for infinite while loops (closes #23048) 2014-12-13 16:06:19 -05:00
Victor Stinner 437ffbdcd8 test_selectors: Tolerate 2.0 seconds instead of 1.6 sec for very slow buildbots 2014-12-12 12:57:35 +01:00
Victor Stinner 3f7e064b2b Issue #22935: Fix test_ssl when the SSLv3 protocol is not supported 2014-12-12 12:27:08 +01:00
Serhiy Storchaka 4ac7ed97a8 Issue #22095: Fixed HTTPConnection.set_tunnel with default port. The port
value in the host header was set to "None".  Patch by Demian Brecht.
2014-12-12 09:29:15 +02:00
Victor Stinner 1e40f10886 asyncio, tulip issue 209: Fix subprocess for close_fds=False on Python 3.3
Mark the write end of the stdin pipe as non-inheritable.
2014-12-11 23:30:17 +01:00
Victor Stinner df75d5b402 asyncio, tulip issue 202: Add unit test of pause/resume writing for proactor
socket transport
2014-12-11 22:23:19 +01:00
Serhiy Storchaka 60599525c5 Issue #23016: A warning no longer produces AttributeError when the program
is run with pythonw.exe.
2014-12-10 22:59:55 +02:00
Berker Peksag 884afd92f5 Issue #21775: shutil.copytree(): fix crash when copying to VFAT
An exception handler assumed that that OSError objects always have a
'winerror' attribute. That is not the case, so the exception handler
itself raised AttributeError when run on Linux (and, presumably, any
other non-Windows OS).

Patch by Greg Ward.
2014-12-10 02:50:32 +02:00
Yury Selivanov 7de29687f2 inspect: Fix getsource() to load updated source of reloaded module
Issue #1218234. Initial patch by Berker Peksag.
2014-12-08 18:00:25 -05:00
Yury Selivanov d60ef4aa9d selectors: Make sure EpollSelecrtor.select() works when no FD is registered.
Closes issue #23009.
2014-12-08 12:21:58 -05:00
Benjamin Peterson a090f01bb6 HTTPSConnection: prefer the context's check_hostname attribute over the constructor parameter (#22959) 2014-12-07 13:18:25 -05:00
Benjamin Peterson e32467cf6a allow ssl module to compile if openssl doesn't support SSL 3 (closes #22935)
Patch by Kurt Roeckx.
2014-12-05 21:59:35 -05:00
Benjamin Peterson eca72d47f5 merge 3.3 (#16043) 2014-12-05 20:34:56 -05:00
Benjamin Peterson 81b7374fbe merge 3.2 (#16043) 2014-12-05 20:30:54 -05:00
Benjamin Peterson 4e9cefaf86 add a default limit for the amount of data xmlrpclib.gzip_decode will return (closes #16043) 2014-12-05 20:15:15 -05:00
Victor Stinner f3e2e09213 Closes #22429, asyncio: Fix EventLoop.run_until_complete(), don't stop the
event loop if a BaseException is raised, because the event loop is already
stopped.
2014-12-05 01:44:10 +01:00
Victor Stinner e80bf0d4a9 Closes #22922: More EventLoop methods fail if the loop is closed. Initial patch
written by Torsten Landschoff.

create_task(), call_at(), call_soon(), call_soon_threadsafe() and
run_in_executor() now raise an error if the event loop is closed.
2014-12-04 23:07:47 +01:00
Victor Stinner dd8224e6a4 Issue #22685: Fix test_pause_reading() of asyncio test_subprocess
* mock also resume_reading()
* ensure that resume_reading() is called
2014-12-04 23:06:13 +01:00
Serhiy Storchaka 1ad088f3ea Issue #14099: ZipFile.open() no longer reopen the underlying file. Objects
returned by ZipFile.open() can now operate independently of the ZipFile even
if the ZipFile was created by passing in a file-like object as the first
argument to the constructor.
2014-12-03 09:11:57 +02:00
Barry Warsaw eb2763dd43 Fix the test to use an os.sep agnostic test. Hopefully this will fix the
Windows buildbots.  Found by Jeremy Kloth.
2014-12-02 11:30:43 -05:00
Serhiy Storchaka 83cf99d733 Issue #20335: bytes constructor now raises TypeError when encoding or errors
is specified with non-string argument.  Based on patch by Renaud Blanch.
2014-12-02 09:24:06 +02:00
Barry Warsaw 9d98c9bf42 Make this change a little more robust for up-merging. 2014-12-01 18:15:26 -05:00