summaryrefslogtreecommitdiffstats
path: root/Lib
Commit message (Collapse)AuthorAgeFilesLines
* bpo-30822: Deduplicate ZoneInfoTest classes in test_datetime. (#2534)Serhiy Storchaka2017-07-021-0/+1
|
* bpo-30822: Fix testing of datetime module. (#2530)Utkarsh Upadhyay2017-07-023-9/+14
| | | | Only C implementation was tested.
* bpo-30441: Fix bug when modifying os.environ while iterating over it (#2409)Osvaldo Santana Neto2017-07-012-1/+27
|
* bpo-30695: Add set_nomemory(start, stop) to _testcapi (GH-2406)xdegaye2017-07-011-1/+33
|
* bpo-30804: fix macOS build with framework enabled. (#2516)INADA Naoki2017-06-301-2/+2
|
* bpo-30818: test_ftplib calls asyncore.close_all() (#2514)Victor Stinner2017-06-301-0/+3
| | | | | | | | | | Always clear asyncore socket map using asyncore.close_all(ignore_all=True) in tearDown() method. This change should fix this warning: Warning -- asyncore.socket_map was modified by test_ftplib Before: {} After: {4: <test.test_ftplib.DummyTLS_FTPServer 127.0.0.1:0 at 0x805feccf0>}
* test_urllib2_localnet: clear server variable (#2510)Victor Stinner2017-06-301-4/+13
| | | | Set the server attribute to None in cleanup to avoid dangling threads.
* bpo-30812: Fix test_warnings, restore _showwarnmsg (#2504)Victor Stinner2017-06-301-4/+9
| | | | bpo-26568, bpo-30812: Fix test_showwarnmsg_missing(): restore the attribute after removing it.
* bpo-30813: Fix unittest when hunting refleaks (#2502)Victor Stinner2017-06-301-0/+6
| | | | | | bpo-11798, bpo-16662, bpo-16935, bpo-30813: Skip test_discover_with_module_that_raises_SkipTest_on_import() and test_discover_with_init_module_that_raises_SkipTest_on_import() of test_unittest when hunting reference leaks using regrtest.
* bpo-30280: Cleanup threads in ayncio tests (#2501)Victor Stinner2017-06-302-5/+9
| | | | | | | | | | | | | | | | * bpo-30280: asyncio now cleans up threads asyncio base TestCase now uses threading_setup() and threading_cleanup() of test.support to cleanup threads. * asyncio: Fix TestBaseSelectorEventLoop cleanup bpo-30280: TestBaseSelectorEventLoop of test.test_asyncio.test_selector_events now correctly closes the event loop: cleanup its executor to not leak threads. Don't override the close() method of the event loop, only override the_close_self_pipe() method.
* threading_cleanup() failure marks test as ENV_CHANGED (#2500)Victor Stinner2017-06-303-1/+22
| | | | | | | If threading_cleanup() fails to cleanup threads, set a a new support.environment_altered flag to true, flag uses by save_env which is used by regrtest to check if a test altered the environment. At the end, the test file fails with ENV_CHANGED instead of SUCCESS, to report that it altered the environment.
* bpo-30807: signal.setitimer() may disable the timer by mistake (#2493)Antoine Pitrou2017-06-301-0/+9
| | | | | | * bpo-30807: signal.setitimer() may disable the timer by mistake * Add NEWS blurb
* bpo-30495: IDLE: improve textview with docstrings, PEP8 names, more tests. ↵csabella2017-06-295-100/+139
| | | | | | | (#2283) Split TextViewer class into ViewWindow, ViewFrame, and TextFrame classes so that instances of the latter two can be placed with other widgets within a multiframe window. Patch by Cheryl Sabella.
* bpo-30647: Check nl_langinfo(CODESET) in locale coercion (GH-2374)Nick Coghlan2017-06-291-7/+18
| | | | | | | | | | | | | - On some versions of FreeBSD, setting the "UTF-8" locale succeeds, but a subsequent "nl_langinfo(CODESET)" fails - adding a check for this in the coercion logic means that coercion will happen on systems where this check succeeds, and will be skipped otherwise - that way CPython should automatically adapt to changes in platform behaviour, rather than needing a new release to enable coercion at build time - this also allows UTF-8 to be re-enabled as a coercion target, restoring the locale coercion behaviour on Mac OS X
* bpo-30796: Fix failures in signal delivery stress test (#2488)Antoine Pitrou2017-06-291-15/+50
| | | | | | | | | | * bpo-30796: Fix failures in signal delivery stress test setitimer() can have a poor minimum resolution on some machines, this would make the test reach its deadline (and a stray signal could then kill a subsequent test). * Make sure to clear the itimer after the test
* bpo-30776: regrtest: reduce memleak false positive (#2484)Victor Stinner2017-06-291-10/+3
| | | Only report a leak if each run leaks at least one memory block.
* bpo-30703: Improve signal delivery (#2415)Antoine Pitrou2017-06-281-0/+96
| | | | | | | | | | | | | | | | | | | | * Improve signal delivery Avoid using Py_AddPendingCall from signal handler, to avoid calling signal-unsafe functions. * Remove unused function * Improve comments * Add stress test * Adapt for --without-threads * Add second stress test * Add NEWS blurb * Address comments @haypo
* bpo-29585: Define PYTHONFRAMEWORK in PC/pyconfig.h (#2477)Victor Stinner2017-06-281-1/+1
| | | | | | | | | | * bpo-29585: Fix PC/pyconfig.h whitespaces Run "make patchcheck". * bpo-29585: Define PYTHONFRAMEWORK in PC/pyconfig.h * site: Fix path separator in _get_path() on Windows
* bpo-29585: optimize site.py startup time (GH-136)INADA Naoki2017-06-283-42/+69
| | | | Avoid importing `sysconfig` from `site` by copying minimum code. Python startup is 5% faster on Linux and 30% faster on macOS
* Clear potential ref cycle between Process and Process target (#2470)Antoine Pitrou2017-06-282-0/+21
| | | | | | | | | * Clear potential ref cycle between Process and Process target Besides Process.join() not being called, this was an indirect cause of bpo-30775. The threading module already does this. * Add issue reference
* bpo-30775: Fix refleaks in test_multiprocessing (#2467)Antoine Pitrou2017-06-281-2/+17
| | | Forgetting to call Process.join() can keep some resources alive.
* [security] bpo-13617: Reject embedded null characters in wchar* strings. (#2302)Serhiy Storchaka2017-06-288-1/+35
| | | | | | | Based on patch by Victor Stinner. Add private C API function _PyUnicode_AsUnicode() which is similar to PyUnicode_AsUnicode(), but checks for null characters.
* bpo-24813: IDLE tagline is Integrated Development and Learning Environment ↵Mark Roseman2017-06-281-1/+1
| | | | | (#2451) Patch by Mark Roseman
* bpo-30723: IDLE -- Enhance parenmatch; add style, flash, and help (#2306)wohlganger2017-06-283-72/+91
| | | | | | | | | * Add 'parens' style to highlight both opener and closer. * Make 'default' style, which is not default, a synonym for 'opener'. * Make time-delay work the same with all styles. * Add help for config dialog extensions tab, including parenmatch. * Add new tests. Original patch by Charles Wohlganger.
* bpo-29512: Add test.bisect, bisect failing tests (#2452)Victor Stinner2017-06-281-0/+167
| | | | | | Add a new "python3 -m test.bisect" tool to bisect failing tests. It can be used to find which test method(s) leak references, leak files, etc.
* bpo-30708: Check for null characters in PyUnicode_AsWideCharString(). (#2285)Serhiy Storchaka2017-06-271-2/+2
| | | | | Raise a ValueError if the second argument is NULL and the wchar_t\* string contains null characters.
* bpo-30674: IDLE: add docstrings to grep.py (#2213)csabella2017-06-271-12/+54
| | | Patch by Cheryl Sabella
* bpo-21519: IDLE basic custom key entry better detects duplicates. (#2428)terryjreedy2017-06-272-7/+13
|
* bpo-29910: IDLE no longer deletes a character after commenting out a region ↵Serhiy Storchaka2017-06-2710-16/+45
| | | | | | | | | | | (#825) This happened because shortcut has a class binding and 'break' was not returned. Fix other potential conflicts between IDLE and default key bindings. * Add news item * Update NEWS
* bpo-24813: IDLE: Add build bitness to About Idle title (#2380)csabella2017-06-272-6/+24
| | | Patch by Cheryl Sabella.
* bpo-30776: reduce regrtest -R false positives (#2422)Victor Stinner2017-06-272-21/+57
| | | | | | | | | | | | | | * Change the regrtest --huntrleaks checker to decide if a test file leaks or not. Require that each run leaks at least 1 reference. * Warmup runs are now completely ignored: ignored in the checker test and not used anymore to compute the sum. * Add an unit test for a reference leak. Example of reference differences previously considered a failure (leak) and now considered as success (success, no leak): [3, 0, 0] [0, 1, 0] [8, -8, 1]
* bpo-30728: IDLE: Refactor configdialog to PEP8 names (#2307)csabella2017-06-262-828/+837
| | | | Also, change '*' in the tkinter import to an explicit list of names. Patch by Cheryl Sabella.
* bpo-30532: Fix whitespace folding in certain casesJoel Hillacre2017-06-262-3/+13
| | | Leading whitespace was incorrectly dropped during folding of certain lines in the _header_value_parser's folding algorithm. This makes the whitespace handling code consistent.
* bpo-30764: regrtest: add --fail-env-changed option (#2402)Victor Stinner2017-06-263-14/+52
| | | | | | | | | | | | * bpo-30764: regrtest: change exit code on failure * Exit code 2 if failed tests ("bad") * Exit code 3 if interrupted * bpo-30764: regrtest: add --fail-env-changed option If the option is set, mark a test as failed if it alters the environment, for example if it creates a file without removing it.
* bpo-30764: test_subprocess uses SuppressCrashReport (#2405)Victor Stinner2017-06-261-19/+22
| | | | | bpo-30764, bpo-29335: test_child_terminated_in_stopped_state() of test_subprocess now uses support.SuppressCrashReport() to prevent the creation of a core dump on FreeBSD.
* bpo-30523: regrtest --list-cases --match (#2401)Victor Stinner2017-06-263-15/+32
| | | | | | | * regrtest --list-cases now supports --match and --match-file options. Example: ./python -m test --list-cases -m FileTests test_os * --list-cases now also sets support.verbose to False to prevent messages to stdout when loading test modules. * Add support._match_test() private function.
* bpo-6739: IDLE: Check for valid keybinding in config_keys (#2377)csabella2017-06-262-26/+115
| | | | | | Verify user-entered key sequences by trying to bind them with tk. Add tests for all 3 validation functions. Original patch by G Polo. Tests added by Cheryl Sabella.
* bpo-30746: Port more tests for os.spawnvpe() and os.execve() from 2.7. (#2394)Serhiy Storchaka2017-06-251-9/+36
|
* bpo-30746: Prohibited the '=' character in environment variable names (#2382)Serhiy Storchaka2017-06-252-0/+64
| | | | in `os.putenv()` and `os.spawn*()`.
* Fix bpo-30596: Add close() method to multiprocessing.Process (#2010)Antoine Pitrou2017-06-247-8/+95
| | | | | | | | | | * Fix bpo-30596: Add close() method to multiprocessing.Process * Raise ValueError if close() is called before the Process is finished running * Add docs * Add NEWS blurb
* Fix a typo in a comment in coroutines.py (GH-2267)Johan de Jager2017-06-241-1/+1
| | | defiend -> defined
* bpo-24813: IDLE: Add default title to help_about (#2366)csabella2017-06-244-9/+33
| | | Patch by Cheryl Sabella.
* bpo-30664: The description of a unittest subtest now preserves the (#2265)Serhiy Storchaka2017-06-232-7/+26
| | | | order of keyword arguments of TestCase.subTest().
* bpo-30645: don't append to an inner loop path in imp.load_package() (GH-2268)Alexandru Ardelean2017-06-231-2/+3
| | | | | Bug didn't manifest itself when importing a module with source as .py files are always the first on the search path. The issue only showed up in bytecode-only packages where the calculated file path would be ``__init__.py/__init__.pyc``. Patch by Alexandru Ardelean.
* bpo-30730: Prevent environment variables injection in subprocess on Windows. ↵Serhiy Storchaka2017-06-232-2/+46
| | | | | | (#2325) Prevent passing other invalid environment variables and command arguments.
* bpo-24813: IDLE: Add icon to help_about (#2335)csabella2017-06-232-4/+19
| | | Patch by Cheryl Sabella
* bpo-21071: struct.Struct.format type is now str (#845)Victor Stinner2017-06-231-0/+8
|
* bpo-30604: Skip CoExtra tests if ctypes is missing (#2356)Victor Stinner2017-06-231-3/+6
|
* bpo-30727: Fix a race condition in test_threading. (#2334)Serhiy Storchaka2017-06-231-5/+14
|
* bpo-30736: upgrade to Unicode 10.0 (#2344)Benjamin Peterson2017-06-231-2/+2
| | | Straightforward. While we're at it, though, strip trailing whitespace from generated tables.