Eric V. Smith
7389fd935c
bpo-33100: Dataclasses now handles __slots__ and default values correctly. (GH-6152)
...
If the class has a member that's a MemberDescriptorType, it's not a default value, it's from that member being in __slots__.
2018-03-19 21:07:51 -04:00
aetracht
4573820d2a
bpo-33061: Add missing 'NoReturn' to __all__ in typing.py (GH-6127)
2018-03-19 18:41:32 +00:00
Eric V. Smith
f199bc655e
bpo-32953: Dataclasses: frozen should not be inherited for non-dataclass derived classes ( #6147 )
...
If a non-dataclass derives from a frozen dataclass, allow attributes to be set.
Require either all of the dataclasses in a class hierarchy to be frozen, or all non-frozen.
Store `@dataclass` parameters on the class object under `__dataclass_params__`. This is needed to detect frozen base classes.
2018-03-18 20:40:34 -04:00
xdegaye
3fe33043ee
bpo-19417: Add test_bdb.py (GH-5217)
2018-03-18 13:02:47 -07:00
Jelle Zijlstra
f64aae46da
Revert "bpo-30406: Make async and await proper keywords ( #1669 )" (GH-6143)
...
This reverts commit ac317700ce
.
(Reverts only the lib2to3 part.)
2018-03-18 09:54:33 -07:00
Serhiy Storchaka
fe2bbb1869
bpo-32489: Allow 'continue' in 'finally' clause. (GH-5822)
2018-03-18 09:56:52 +02:00
Serhiy Storchaka
134cb01cda
bpo-32056: Improve exceptions in aifc, wave and sunau. (GH-5951)
2018-03-18 09:55:53 +02:00
Serhiy Storchaka
bc300ce205
bpo-33041: Add tests for jumps in/out of 'async with' blocks. ( #6110 )
2018-03-18 09:53:08 +02:00
Aviv Palivoda
bbf7bb7a63
bpo-27645: Fix version number in 'database in transaction' fallback (GH-6131)
...
It was actually fixed in SQLite 3.8.8, not 3.8.7.
2018-03-18 03:48:55 +03:00
Donald Stufft
7f81bb2add
Update pip to 9.0.2 and setuptools to 38.6.1 ( #6133 )
2018-03-17 11:13:48 -04:00
Marcel Plch
c2b0b12d1a
bpo-32374: m_traverse may be called with m_state=NULL (GH-5140)
...
Multi-phase initialized modules allow m_traverse to be called while the
module is still being initialized, so module authors may need to account
for that.
2018-03-17 15:41:20 +10:00
Zackery Spytz
d6e1404661
bpo-33021: Fix GCC 7 warning (-Wmaybe-uninitialized) in mmapmodule.c ( #6117 )
2018-03-14 21:08:01 +01:00
Łukasz Langa
74f56878cd
lib2to3: Add more tests ( #6101 )
2018-03-13 10:53:22 -07:00
xdegaye
b8e9d6c5cd
bpo-17288: Prevent jumps from 'return' and 'exception' trace events. (GH-6107)
...
(cherry picked from commit e32bbaf376
)
2018-03-13 19:31:31 +02:00
Miro Hrončok
5affd5c29e
bpo-32885: Tools/scripts/pathfix.py: Add -n option for no backup~ ( #5772 )
...
Creating backup files with ~ suffix can be undesirable in some environment,
such as when building RPM packages. Instead of requiring the user to remove
those files manually, option -n was added, that simply disables this feature.
-n was selected because 2to3 has the same option with this behavior.
2018-03-13 05:56:43 -04:00
Łukasz Langa
b51f5de711
bpo-33064: lib2to3: support trailing comma after *args and **kwargs ( #6096 )
...
New tests also added.
I also made the comments in line with the builtin Grammar/Grammar. PEP 306 was
withdrawn, Kees Blom's railroad program has been lost to the sands of time for
at least 16 years now (I found a python-dev post from people looking for it).
2018-03-13 00:44:49 -07:00
Ned Deily
a34510a4c5
bpo-29719: Remove Date and Release field in whatsnew/3.7 and 8 (GH-6093)
2018-03-12 21:16:08 -04:00
Ned Deily
37ed6dfbbc
Add macOS installer Conclusion file
2018-03-12 16:49:59 -04:00
Antoine Pietri
019f5b3e9e
bpo-22674: fix test_strsignal on OSX (GH-6085)
2018-03-12 20:03:14 +01:00
Andrew Svetlov
b21505e710
Fix docs markup for asyncio current_task() and all_tasks() ( #6089 )
2018-03-12 20:50:50 +02:00
Thomas Moreau
095ee415ce
bpo-33056 FIX leaking fd in concurrent.futures.ProcessPoolExecutor ( #6084 )
2018-03-12 19:18:41 +02:00
Antoine Pietri
5d2a27de62
signal: add strsignal() ( #6017 )
...
Co-authored-by: Vajrasky Kok <sky.kok@speaklikeaking.com>
2018-03-12 14:42:34 +01:00
Nir Soffer
4484f9dca9
bpo-33021: Release the GIL during fstat() calls (GH-6019)
...
fstat may block for long time if the file descriptor is on a
non-responsive NFS server, hanging all threads. Most fstat() calls are
handled by _Py_fstat(), releasing the GIL internally, but but
_Py_fstat_noraise() does not release the GIL, and most calls release the
GIL explicitly around it.
This patch fixes last 2 calls to _Py_fstat_no_raise(), avoiding hangs
when calling:
- mmap.mmap()
- os.urandom()
- random.seed()
2018-03-12 00:39:22 +01:00
Antoine Pitrou
e756f66c83
bpo-31804: Fix multiprocessing.Process with broken standard streams ( #6079 )
...
In some conditions the standard streams will be None or closed in the child process (for example if using "pythonw" instead of "python" on Windows). Avoid failing with a non-0 exit code in those conditions.
Report and initial patch by poxthegreat.
2018-03-11 19:21:38 +01:00
Siddhesh Poyarekar
9fb8415759
Drop confusing commented out code in pystrtod.c (GH-6072)
2018-03-11 17:45:10 +08:00
Serhiy Storchaka
e2732d3e66
bpo-32970: Improve disassembly of the MAKE_FUNCTION instruction. (GH-5937)
2018-03-11 11:07:06 +02:00
Serhiy Storchaka
3f7e9aa2ef
bpo-32925: Optimized iterating and containing test for literal lists (GH-5842)
...
consisting of non-constants: `x in [a, b]` and `for x in [a, b]`.
The case of all constant elements already was optimized.
2018-03-11 10:54:47 +02:00
Serhiy Storchaka
4e2442505c
bpo-32946: Speed up "from ... import ..." from non-packages. (GH-5873)
2018-03-11 10:52:37 +02:00
Serhiy Storchaka
b931bd0a2f
bpo-32338: OrderedDict import is no longer needed in re. ( #4891 )
2018-03-11 08:38:13 +02:00
Serhiy Storchaka
26c9f565d0
bpo-33026: Fix jumping out of "with" block by setting f_lineno. ( #6026 )
2018-03-11 08:32:47 +02:00
Serhiy Storchaka
51302a5fcc
bpo-32996: Improve What's New in 3.7. ( #5983 )
2018-03-11 03:48:14 +02:00
Matt Eaton
9cf8c42f32
bpo-33045: Fix typos in SSL documentation (GH-6065)
2018-03-11 04:00:04 +03:00
Berker Peksag
7280a4eef5
bpo-27645: Skip test_bad_target_in_transaction if SQLite == 3.8.7.1 (GH-6067)
2018-03-11 03:38:50 +03:00
Emanuele Gaifas
d7aed4102d
bpo-27645: Add support for native backup facility of SQLite (GH-4238)
2018-03-11 01:08:31 +03:00
Xiang Zhang
c10b288f34
bpo-30249: Improve struct.unpack_from() error messages (GH-6059)
2018-03-11 02:58:52 +08:00
Serhiy Storchaka
67ee07795b
bpo-33041: Add missed error checks when compile "async for" ( #6053 )
...
and remove redundant code.
2018-03-10 18:49:26 +02:00
Serhiy Storchaka
24d3201eb7
bpo-33041: Fixed bytecode generation for "async for" with a complex target. ( #6052 )
...
A StopAsyncIteration raised on assigning or unpacking will be now propagated
instead of stopping the iteration.
2018-03-10 18:22:34 +02:00
Andrew Svetlov
5e80a71ab6
bpo-33037: Skip sending/receiving after SSL transport closing (GH-6044)
...
* Skip write()/data_received() if sslpipe is destroyed
2018-03-10 17:48:35 +02:00
Serhiy Storchaka
496431ffb6
bpo-26701: Improve documentation for the rounding special methods. ( #6054 )
2018-03-10 17:18:32 +02:00
Eric Appelt
308eab979d
bpo-26701: Add documentation for __trunc__ (GH-6022)
...
`int` fails back to `__trunc__` is `__int__` isn't defined, so cover
that in the docs.
2018-03-10 18:44:12 +10:00
Brett Cannon
10485ebd40
Warn that dbm.dumb.open() can crash Python (GH-6047)
2018-03-09 15:58:40 -08:00
Brett Cannon
f7a6ff6fca
Warn that compile() can crash when compiling to an AST object (GH-6043)
2018-03-09 13:13:32 -08:00
Brett Cannon
7a7f100eb3
bpo-32758: Warn that ast.parse() and ast.literal_eval() can segfault the interpreter (GH-5960)
2018-03-09 12:03:22 -08:00
Steven M. Vascellaro
83d7062d2d
controlflow: Use full example for "5 through 9" (GH-5907)
...
Replace example result of "5 through 9" with complete list: "5, 6, 7, 8, 9".
This format is more consistent with the surrounding examples.
2018-03-09 11:57:21 -08:00
Alexey Izbyshev
3b20d3454e
bpo-33016: Fix potential use of uninitialized memory in nt._getfinalpathname ( #6010 )
2018-03-08 08:03:25 -08:00
Xiang Zhang
3c7ac7ea20
Add two missing error checks in hamt.c (GH-5851)
2018-03-08 13:59:46 +08:00
Xiang Zhang
e405096ea9
Fix some ipaddress documentation errors (GH-6021)
...
* fix a typo: documention -> documentation
* fix the type of IPv?Network.hostmask
* add documentation about IPv?Network.netmask
* fix IPv6Network constructor doc that extended netmasks are not supported
2018-03-08 12:24:36 +08:00
INADA Naoki
fc7df0e664
bpo-32999: Fix ABC.__subclasscheck__ crash (GH-6002)
2018-03-07 16:27:01 +09:00
Xiang Zhang
bc3f2289b9
bpo-32969: Expose some missing constants in zlib and fix the doc (GH-5988)
2018-03-07 13:05:37 +08:00
Yury Selivanov
8a387219bd
bpo-33009: Fix inspect.signature() for single-parameter partialmethods. (GH-6004)
2018-03-06 12:59:45 -05:00