Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
612a7d26
Commit
612a7d26
authored
Nov 06, 2016
by
Steve Dower
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Closes #27781: Removes special cases for the experimental aspect of PEP 529
parent
45abd955
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
24 deletions
+5
-24
Doc/whatsnew/3.6.rst
Doc/whatsnew/3.6.rst
+0
-5
Lib/test/test_os.py
Lib/test/test_os.py
+2
-7
Misc/NEWS
Misc/NEWS
+2
-2
Objects/unicodeobject.c
Objects/unicodeobject.c
+1
-10
No files found.
Doc/whatsnew/3.6.rst
View file @
612a7d26
...
...
@@ -355,11 +355,6 @@ correctly encoded. To revert to the previous behaviour, set
See :pep:`529` for more information and discussion of code modifications that
may be required.
.. note::
This change is considered experimental for 3.6.0 beta releases. The default
encoding may change before the final release.
.. _whatsnew-pep487:
PEP 487: Simpler customization of class creation
...
...
Lib/test/test_os.py
View file @
612a7d26
...
...
@@ -2860,13 +2860,8 @@ class OSErrorTests(unittest.TestCase):
func
(
name
,
*
func_args
)
except
OSError
as
err
:
self
.
assertIs
(
err
.
filename
,
name
,
str
(
func
))
except
RuntimeError
as
err
:
if
sys
.
platform
!=
'win32'
:
raise
# issue27781: undecodable bytes currently raise RuntimeError
# by 3.6.0b4 this will become UnicodeDecodeError or nothing
self
.
assertIsInstance
(
err
.
__context__
,
UnicodeDecodeError
)
except
UnicodeDecodeError
:
pass
else
:
self
.
fail
(
"No exception thrown by {}"
.
format
(
func
))
...
...
Misc/NEWS
View file @
612a7d26
...
...
@@ -3270,7 +3270,7 @@ Library
-
Issue
#
24774
:
Fix
docstring
in
http
.
server
.
test
.
Patch
from
Chiu
-
Hsiang
Hsu
.
-
Issue
#
21159
:
Improve
message
in
configparser
.
InterpolationMissingOptionError
.
Patch
from
�
?
ukasz
Langa
.
Patch
from
Ł
ukasz
Langa
.
-
Issue
#
20362
:
Honour
TestCase
.
longMessage
correctly
in
assertRegex
.
Patch
from
Ilia
Kurenkov
.
...
...
@@ -5198,7 +5198,7 @@ Library
Based on patch by Martin Panter.
- Issue #17293: uuid.getnode() now determines MAC address on AIX using netstat.
Based on patch by Aivars Kalv
�?
ns.
Based on patch by Aivars Kalv
ā
ns.
- Issue #22769: Fixed ttk.Treeview.tag_has() when called without arguments.
...
...
Objects/unicodeobject.c
View file @
612a7d26
...
...
@@ -3843,18 +3843,9 @@ PyUnicode_DecodeFSDefaultAndSize(const char *s, Py_ssize_t size)
cannot only rely on it: check also interp->fscodec_initialized for
subinterpreters. */
if
(
Py_FileSystemDefaultEncoding
&&
interp
->
fscodec_initialized
)
{
PyObject
*
res
=
PyUnicode_Decode
(
s
,
size
,
return
PyUnicode_Decode
(
s
,
size
,
Py_FileSystemDefaultEncoding
,
Py_FileSystemDefaultEncodeErrors
);
#ifdef MS_WINDOWS
if
(
!
res
&&
PyErr_ExceptionMatches
(
PyExc_UnicodeDecodeError
))
{
_PyErr_FormatFromCause
(
PyExc_RuntimeError
,
"filesystem path bytes were not correctly encoded with '%s'. "
"Please report this at http://bugs.python.org/issue27781"
,
Py_FileSystemDefaultEncoding
);
}
#endif
return
res
;
}
else
{
return
PyUnicode_DecodeLocaleAndSize
(
s
,
size
,
Py_FileSystemDefaultEncodeErrors
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment