Gregory P. Smith
ad577b938b
Issue 24230: The tempfile module now accepts bytes for prefix, suffix and dir
...
parameters and returns bytes in such situations (matching the os module APIs).
2015-05-22 16:18:14 -07:00
Steve Dower
4a7fe7e397
Issue #23955 : Add pyvenv.cfg option to suppress registry/environment lookup for generating sys.path.
...
Also cleans up and secures getpathp.c
2015-05-22 15:10:10 -07:00
Steve Dower
d9ef74e3dd
Issue 24244: Prevents termination when an invalid format string is encountered on Windows.
2015-05-22 15:08:34 -07:00
Yury Selivanov
945fff44c4
Issue 20438: Add a note about deprecating old inspect APIs to whatsnew.
...
Also, deprecate formatargspec, formatargvalues, and getargvalues
functions. Since we are deprecating 'getfullargspec' function in
3.5 (documentation only, no DeprecationWarning), it makes sense
to also deprecate functions designed to be directly used with it.
In 3.6 we will remove 'getargsspec' function (was deprecated since
Python 3.0), and start raising DeprecationWarnings in other
'getarg*' family of functions. We can remove them in 3.7 or later.
Also, it is worth noting, that Signature API does not provide 100%
of functionality that deprecated APIs have. It is important to do
a soft deprecation of outdated APIs in 3.5 to gather users feedback,
and improve Signature object.
2015-05-22 16:28:05 -04:00
Yury Selivanov
c8386f78fd
Issue 20438: Adjust stacklevel of inspect.getargspec() warning.
2015-05-22 16:09:44 -04:00
Guido van Rossum
46dbb7d103
Preliminary typing.py, anticipating provisional acceptance of PEP 484.
...
There area bunch of TODOs here, but the biggest (not mentioned in the
file) is that I'm going to take out __instancecheck__ and
__subclasscheck__. However my personal schedule is such that I
probably won't have time for these before Larry tags beta 1. But I
will try -- this commit is mostly to make sure that typing.py doesn't
completely miss the train.
PS. I'm tracking issues at https://github.com/ambv/typehinting/issues .
2015-05-22 10:14:11 -07:00
Zachary Ware
569db2c9f6
Fix extraneous BOM in whatsnew.
...
That's what I get for using Notepad to make a quick edit...
2015-05-22 11:42:20 -05:00
Zachary Ware
7dc9dea778
Issue #20035 : Reimplement tkinter._fix module as a C function.
...
The new private C function makes no permanent changes to the environment
and is #ifdef'd out on non-Windows platforms.
2015-05-22 11:36:53 -05:00
Yury Selivanov
3cfec2e2fc
Issue 20438: Deprecate inspect.getargspec() and friends.
2015-05-22 11:38:38 -04:00
Yury Selivanov
8d006e75e0
docs: Mention PEP 479 in whatsnew.
...
Issue 22906.
2015-05-22 11:30:45 -04:00
Yury Selivanov
683333955a
Issue 24237: Raise PendingDeprecationWarning per PEP 479
...
Raise PendingDeprecationWarning when generator raises StopIteration
and no __future__ import is used. Fix offenders in the stdlib
and tests.
See also issue 22906.
Thanks to Nick Coghlan and Berker Peksag for reviews.
2015-05-22 11:16:47 -04:00
Serhiy Storchaka
e79ec70801
Issue #24257 : Fixed incorrect uses of PyObject_IsInstance().
...
Fixed segmentation fault in sqlite3.Row constructor with faked cursor type.
Fixed system error in the comparison of faked types.SimpleNamespace.
2015-05-22 11:13:20 +03:00
Serhiy Storchaka
08d230a540
Issue #24257 : Fixed incorrect uses of PyObject_IsInstance().
...
Fixed segmentation fault in sqlite3.Row constructor with faked cursor type.
Fixed system error in the comparison of faked types.SimpleNamespace.
2015-05-22 11:02:49 +03:00
Raymond Hettinger
5cbd8331ff
Issue #24221 : Small optimizations for heapq.
...
Replaces the PyList_GET_ITEM and PyList_SET_ITEM macros with normal array
accesses. Replace the siftup unpredicatable branch with arithmetic.
Replace the rc == -1 tests with rc < 0. Gives nicer looking assembly
with both Clang and GCC-4.9. Also gives a small performance both for both.
2015-05-22 00:41:57 -07:00
Donald Stufft
35e24a50c5
merge: Upgrade pip to 7.0 and setuptools to 16.0
2015-05-22 00:39:57 -04:00
Donald Stufft
df9ba3623a
Upgrade pip to 7.0 and setuptools to 16.0
2015-05-22 00:39:22 -04:00
Yury Selivanov
a18cad543f
Issue 24180: Fixes by Berker Peksag.
2015-05-21 17:02:31 -04:00
Berker Peksag
b560158622
Set stacklevel to 2 to get more accurate warning messages from deprecated functions.
2015-05-21 23:40:54 +03:00
Yury Selivanov
d854aacaa9
Fix a misplaced NEWS entry.
2015-05-21 15:48:59 -04:00
Yury Selivanov
095fb84fc2
Issue 23898: Fix inspect.classify_class_attrs() to work with __eq__
...
Patch by Mike Bayer.
2015-05-21 15:45:08 -04:00
Yury Selivanov
bf341fb5f6
Issue 23898: Fix inspect.classify_class_attrs() to work with __eq__
2015-05-21 15:41:57 -04:00
Serhiy Storchaka
c9745e5f7d
Fixed issue number for issue #22939 .
2015-05-21 20:54:48 +03:00
Serhiy Storchaka
0978b5cdb3
Fixed issue number for issue #22939 .
2015-05-21 20:54:36 +03:00
Serhiy Storchaka
b2f3c2357c
Issue #23985 : Fixed integer overflow in iterator object. Patch by
...
Clement Rouault.
2015-05-21 20:51:53 +03:00
Serhiy Storchaka
4faf5c5655
Issue #23985 : Fixed integer overflow in iterator object. Patch by
...
Clement Rouault.
2015-05-21 20:50:25 +03:00
Serhiy Storchaka
041dd8eef1
Issue #15836 : assertRaises(), assertRaisesRegex(), assertWarns() and
...
assertWarnsRegex() assertments now check the type of the first argument
to prevent possible user error. Based on patch by Daniel Wagner-Hall.
2015-05-21 20:15:40 +03:00
Yury Selivanov
ff54223606
Issue 24017: Use abc.Coroutine in inspect.iscoroutine() function
2015-05-21 12:03:21 -04:00
Yury Selivanov
f3e40fac10
Issue 24180: Documentation for PEP 492 changes.
2015-05-21 11:50:30 -04:00
Serhiy Storchaka
548de2b210
Issue #22955 : Fixed reference leak in attrgetter.repr().
2015-05-21 14:19:20 +03:00
Benjamin Peterson
b1cc37cfb5
improve wording
2015-05-20 22:09:43 -05:00
Yury Selivanov
57c74fca02
Issue 24248: Deprecate inspect.Signature.from_function and .from_builtin
2015-05-20 23:07:02 -04:00
Antoine Pitrou
45d6156154
Issue #9858 : Add missing method stubs to _io.RawIOBase. Patch by Laura Rupprecht.
2015-05-20 21:50:59 +02:00
Serhiy Storchaka
60335855f0
Issue #22955 : Fixed test_operator. It left Python implementation in
...
sys.modules and broke test_ipaddress.
2015-05-20 22:02:43 +03:00
Yury Selivanov
cf45f022b7
inspect.Signature: Factor out Signature.from_function to a private helper
2015-05-20 14:38:50 -04:00
Yury Selivanov
bcd4fc161a
Issue 20691: Add follow_wrapped arg to inspect.signature/from_callable.
2015-05-20 14:30:08 -04:00
Serhiy Storchaka
1f507a8140
Issue 24215: Added tests for more builtin types in test_pprint.
...
Made test_pprint and test_trace discoverable.
2015-05-20 19:38:05 +03:00
Serhiy Storchaka
cbfe07e06c
Issue 24215: Added tests for more builtin types in test_pprint.
...
Made test_pprint and test_trace discoverable.
2015-05-20 19:37:10 +03:00
Steve Dower
f54bcfb835
Updates PCBuild.sln to open with VS 2015 by default.
2015-05-20 09:30:42 -07:00
Serhiy Storchaka
3ddcfb119d
Issue #24134 : Use assertRaises() in context manager form in test_slice to
...
avoid passing the test accidently because slice.__hash__ is None.
2015-05-20 18:38:39 +03:00
Serhiy Storchaka
c0e0022f07
Issue #24134 : Use assertRaises() in context manager form in test_slice to
...
avoid passing the test accidently because slice.__hash__ is None.
2015-05-20 18:37:37 +03:00
Serhiy Storchaka
35ac5f8280
Issue #22955 : attrgetter, itemgetter and methodcaller objects in the operator
...
module now support pickling. Added readable and evaluable repr for these
objects. Based on patch by Josh Rosenberg.
2015-05-20 18:29:18 +03:00
Serhiy Storchaka
5418d0bfc4
Issue #24245 : Eliminated senseless expect clauses that have no any effect in
...
IDLE. Patch by Martin Panter.
2015-05-20 16:15:20 +03:00
Serhiy Storchaka
ef94869f4f
Issue #24245 : Eliminated senseless expect clauses that have no any effect in
...
IDLE. Patch by Martin Panter.
2015-05-20 16:15:02 +03:00
Serhiy Storchaka
e98209c2b4
Issue #24245 : Eliminated senseless expect clauses that have no any effect.
...
Patch by Martin Panter.
2015-05-20 16:10:04 +03:00
Serhiy Storchaka
ba9ac5b5c4
Issue #16261 : Converted some bare except statements to except statements
...
with specified exception type. Original patch by Ramchandra Apte.
2015-05-20 10:33:40 +03:00
Serhiy Storchaka
492f027793
Issue #22107 : tempfile.gettempdir() and tempfile.mkdtemp() now try again
...
when a directory with the chosen name already exists on Windows as well as
on Unix. tempfile.mkstemp() now fails early if parent directory is not
valid (not exists or is a file) on Windows.
2015-05-20 00:14:00 +03:00
Serhiy Storchaka
5d6b7b1cb7
Issue #22107 : tempfile.gettempdir() and tempfile.mkdtemp() now try again
...
when a directory with the chosen name already exists on Windows as well as
on Unix. tempfile.mkstemp() now fails early if parent directory is not
valid (not exists or is a file) on Windows.
2015-05-20 00:11:48 +03:00
Antoine Pitrou
873e0df946
Fix some compilation warnings when using gcc (-Wmaybe-uninitialized).
2015-05-19 21:06:04 +02:00
Antoine Pitrou
f6d1f1fa8a
Fix some compilation warnings when using gcc (-Wmaybe-uninitialized).
2015-05-19 21:04:33 +02:00
Antoine Pitrou
ef64847f71
Issue #23985 : Fix a possible buffer overrun when deleting a slice from the front of a bytearray and then appending some other bytes data.
...
Patch by Martin Panter.
2015-05-19 20:55:42 +02:00