[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: Serhiy Storchaka wrote: > Try with my last patch (pythonrun_filename_decoding_test.patch). It > fixes also fail on Linux with 8-bit locale. Unfortunately your last patch does not work on Windows. -- I'm too lazy to step through the domain specific language of test

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > For Windows I'm getting a more informative error message than from the > buildbot output if I run the test via an ssh client: Try with my last patch (pythonrun_filename_decoding_test.patch). It fixes also fail on Linux with 8-bit locale. $ LC_ALL=en_US.ISO-

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Andrew Svetlov
Andrew Svetlov added the comment: I will fix it tomorrow at Kiev Python sprint. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: That sounds good for Unix. For Windows I'm getting a more informative error message than from the buildbot output if I run the test via an ssh client: == FA

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Andrew Svetlov
Andrew Svetlov added the comment: Looking on the last message from Stefan I think we have to check cmdpath to be encoded via sys.getfilesystemencoding() first and skip test if fails. -- ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: On FreeBSD both Serhiy's original test case as well as the unit test work if the locale is ISO8859-15: >>> sys.getdefaultencoding() 'utf-8' >>> sys.getfilesystemencoding() 'iso8859-15' >>> locale.getpreferredencoding(True) 'ISO8859-15' >>> locale.getpreferredencodi

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Andrew Svetlov
Andrew Svetlov added the comment: Perhaps we have to skip tests if filesystem encoding doesn't support wide characters. Not sure about the way: should we skip if sys.getfilesystemencoding() is not utf8 or better to try encode path and skip if it fails? I think the later is better. --

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: This is it: >>> >>> sys.getdefaultencoding() 'utf-8' >>> sys.getfilesystemencoding() 'ascii' >>> locale.getpreferredencoding(True) 'US-ASCII' >>> locale.getpreferredencoding(False) 'US-ASCII' >>> $ locale LANG= LC_CTYPE="C" LC_COLLATE="C" LC_TIME="C" LC_NUMERIC=

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > Serhiy, your original example from msg173373 still fails on > FreeBSD: Thank you for a report. I have not any ideas what happened (note that error on encoding, not decoding). Can you please show me the results of sys.getdefaultencoding(), sys.getfilesystemen

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Vinay Sajip
Changes by Vinay Sajip : -- nosy: -vinay.sajip ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: Serhiy, your original example from msg173373 still fails on FreeBSD: $ name=$(printf "\xff") $ echo "print('Hello, world')" >$name $ ./python $name UnicodeEncodeError: 'ascii' codec can't encode character '\xff' in position 0: ordinal not in range(128) [41257 refs

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I was not able to reproduce this error, I got other errors. The issue not in Python interpreter, the test is broken. Here is a patch that might solve the issue on some platforms (need to test on Windows). I guess failing of all command line tests when the pa

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Brian Curtin
Changes by Brian Curtin : -- nosy: -brian.curtin ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Andrew Svetlov
Andrew Svetlov added the comment: I see. Sorry, my fault. Give me weekend to figure out why it fails. Thanks. -- assignee: -> asvetlov ___ Python tracker ___ __

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: Reopening bug. Quite a few buildbots are failing with this patch. Please, commit a new version or revert. -- resolution: fixed -> stage: committed/rejected -> commit review status: closed -> open ___ Python tracke

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue16218] Python launcher does not support non ascii characters

2012-11-02 Thread Stefan Krah
Stefan Krah added the comment: Some of the buildbots are failing with the new test: == FAIL: test_non_utf8 (test.test_cmd_line_script.CmdLineTest) -- Traceback

[issue16218] Python launcher does not support non ascii characters

2012-11-01 Thread Vinay Sajip
Vinay Sajip added the comment: > Please note "sN" format istead "sO". I see. Thanks. -- ___ Python tracker ___ ___ Python-bugs-list m

[issue16218] Python launcher does not support non ascii characters

2012-11-01 Thread Andrew Svetlov
Andrew Svetlov added the comment: Vinay, it's processed in PyObject_CallFunction(loader_type, "sN", "__main__", filename_obj) Please note "sN" format istead "sO". "N" means PyObject* is passed but unlike "sO" that object is not increfed. -- ___ Pytho

[issue16218] Python launcher does not support non ascii characters

2012-11-01 Thread Vinay Sajip
Vinay Sajip added the comment: I'm not especially familiar with this code, but just trying to understand - how come filename_obj isn't decref'd on normal exit? -- nosy: +vinay.sajip ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-11-01 Thread Andrew Svetlov
Andrew Svetlov added the comment: Fixed. Thanks, Serhiy. -- nosy: +asvetlov resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-11-01 Thread Roundup Robot
Roundup Robot added the comment: New changeset 02d25098ad57 by Andrew Svetlov in branch '3.3': Issue #16218: Support non ascii characters in python launcher. http://hg.python.org/cpython/rev/02d25098ad57 New changeset 1267d64c14b3 by Andrew Svetlov in branch 'default': Merge issue #16218: Suppor

[issue16218] Python launcher does not support non ascii characters

2012-10-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Test added. -- stage: test needed -> patch review Added file: http://bugs.python.org/file27707/pythonrun_filename_decoding_2.patch ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-10-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Where we have tests for Python launch? I can't find. runpy is not affected. -- ___ Python tracker ___

[issue16218] Python launcher does not support non ascii characters

2012-10-20 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti stage: -> test needed type: crash -> behavior ___ Python tracker ___ ___ Python-bugs

[issue16218] Python launcher does not support non ascii characters

2012-10-20 Thread STINNER Victor
STINNER Victor added the comment: The patch looks correct, but a test is missing. -- nosy: +haypo ___ Python tracker ___ ___ Python-bu

[issue16218] Python launcher does not support non ascii characters

2012-10-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch which fixes filename decoding error in PyRun_SimpleFileExFlags(). -- keywords: +patch Added file: http://bugs.python.org/file27630/pythonrun_filename_decoding.patch ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-10-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I can reproduce this on Linux (3.3+ only): $ name=$(printf "\xff") $ echo "print('Hello, world')" >$name $ ./python $name python: failed to set __main__.__loader__ The issue is in PyRun_SimpleFileExFlags() function, which gets raw char * as the file name (th

[issue16218] Python launcher does not support non ascii characters

2012-10-19 Thread Tim Golden
Tim Golden added the comment: Confirming that this doesn't happen on 2.7 py -2 £.py succeeds py -3 £.py gives: python: failed to set __main__.__loader__ -- ___ Python tracker

[issue16218] Python launcher does not support non ascii characters

2012-10-19 Thread Gertjan Klein
Changes by Gertjan Klein : -- nosy: +gklein ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue16218] Python launcher does not support non ascii characters

2012-10-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +brian.curtin, tim.golden ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue16218] Python launcher does not support non ascii characters

2012-10-13 Thread Jeremy Kloth
Changes by Jeremy Kloth : -- nosy: +jkloth ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue16218] Python launcher does not support non ascii characters

2012-10-13 Thread Turn
New submission from Turn: If there are non ASCII character in the py.exe arguments, the execution will fail. The script file name or path may contain non ASCII characters. -- components: Windows messages: 172807 nosy: turncc priority: normal severity: normal status: open title: Python l