[issue19447] py_compile.compile raises if a file has bad encoding

2014-09-01 Thread Roundup Robot
Roundup Robot added the comment: New changeset 2d0bcb653085 by Berker Peksag in branch '3.4': Issue #19447: Suppress output of py_compile.compile(). http://hg.python.org/cpython/rev/2d0bcb653085 New changeset a8ef9d7c4d20 by Berker Peksag in branch 'default': Issue #19447: Suppress output of

[issue19447] py_compile.compile raises if a file has bad encoding

2014-09-01 Thread Berker Peksag
Changes by Berker Peksag berker.pek...@gmail.com: -- resolution: - fixed stage: - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19447 ___

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-31 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis added the comment: I noticed this output of full test suite: ... [361/388] test_bisect [362/388] test_py_compile File /tmp/cpython/Lib/test/bad_coding2.py, line 0 SyntaxError: encoding problem: utf8 with BOM [363/388] test_netrc [364/388] test_sys ... I

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-22 Thread Roundup Robot
Roundup Robot added the comment: New changeset 38688f0a0e04 by Berker Peksag in branch '3.4': Issue #19447: Add a test case to py_compile.compile() to make sure http://hg.python.org/cpython/rev/38688f0a0e04 New changeset efb0a3eb4e06 by Berker Peksag in branch 'default': Issue #19447: Add a

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-22 Thread Berker Peksag
Berker Peksag added the comment: 3.3 is in security-only mode and this issue has been fixed in 3.4. I've just committed your test case to 3.4 and default. Thanks for the patch, Bohuslav. -- assignee: - berker.peksag components: +Library (Lib) -Build nosy: +berker.peksag resolution: -

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-22 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis added the comment: You should use importlib.util.cache_from_source(bad_coding) instead of bad_coding + 'c'. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19447

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-22 Thread Berker Peksag
Berker Peksag added the comment: Good point. Thank you Arfrever. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19447 ___ ___ Python-bugs-list

[issue19447] py_compile.compile raises if a file has bad encoding

2014-08-22 Thread Roundup Robot
Roundup Robot added the comment: New changeset d99014320220 by Berker Peksag in branch '3.4': Issue #19447: Use importlib.util.cache_from_source() instead of ``bad_coding + 'c'``. http://hg.python.org/cpython/rev/d99014320220 New changeset 78fff5310206 by Berker Peksag in branch 'default':

[issue19447] py_compile.compile raises if a file has bad encoding

2013-10-31 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19447 ___

[issue19447] py_compile.compile raises if a file has bad encoding

2013-10-30 Thread Bohuslav Slavek Kabrda
New submission from Bohuslav Slavek Kabrda: If py_compile.compile is used on a file with bad encoding (e.g. Lib/test/bad_coding2.py), the function raises even if doraise=False is passed. I'm attaching a patch that fixes this in 3.3 - I haven't tried on 3.4 yet and the code has changed, so I'm

[issue19447] py_compile.compile raises if a file has bad encoding

2013-10-30 Thread STINNER Victor
STINNER Victor added the comment: py_compile.compile() has been modified in Python 3.4. The encoding is now detected in the try/except block. You should write a unit test for your patch. http://docs.python.org/devguide/runtests.html#writing -- nosy: +haypo

[issue19447] py_compile.compile raises if a file has bad encoding

2013-10-30 Thread Bohuslav Slavek Kabrda
Bohuslav Slavek Kabrda added the comment: Ok, I'm attaching a patch for 3.3 with a test case included. -- Added file: http://bugs.python.org/file32424/dont-raise-from-py_compile-test-included.patch ___ Python tracker rep...@bugs.python.org