[issue21934] OpenBSD has no /dev/full device
Daniel Dickman added the comment: We will merge any fix decided by the python team when it's committed. In the meantime may commit our fix on OpenBSD to solve the problem in the short term as it seems no one has time to go further right now. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21934 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21323] CGI HTTP server not running scripts from subdirectories
Ned Deily added the comment: The fix and test look good to me. I'll apply it after Zach submits the contributor agreement. -- stage: needs patch - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21323 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21939] IDLE - Test Percolator
Tal Einat added the comment: I've reviewed the patch and made my remarks in the review tool. These tests don't test the central functionality of Percolator nearly enough. We should test, at least: 1) That the text actually went through the filter (and not directly to the Text widget). 2) That if a filter modifies the text, the modified text appears in the Text widget. 3) That a filter can stop the event from continuing through the following filters. 4) That having more than one filter modify the arguments works. 5) That not having any filters works. 6) That this doesn't only work on a Text widget's insert and delete events. There are probably more things we should test. Take a look at what this is used for in practice in the code for ideas. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21939 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21955] ceval.c: implement fast path for integers with a single digit
New submission from STINNER Victor: Python 2 has fast path in ceval.c for operations (a+b, a-b, etc.) on small integers (int type) if the operation does not overflow. We loose these fast-path in Python 3 when we dropped the int type in favor of the long type. Antoine Pitrou proposed a fast-path, but only for int singletons (integers in the range [-5; 255]): issue #10044. His patch was rejected because it introduces undefined behaviour. I propose to reimplemenet Python 2 optimization for long with a single digit, which are the most common numbers. Pseudo-code for BINARY_ADD: --- if (PyLong_CheckExact(x) Py_ABS(Py_SIZE(x)) == 1 PyLong_CheckExact(y) Py_ABS(Py_SIZE(y)) == 1) { stwodigits a = ..., b = ...; stwodigits c; if (... a+b will not overflow ...) { c = a + b; return PyLong_FromLongLong(c); } } /* fall back to PyNumber_Add() */ --- The code can be copied from longobject.c, there are already fast-path for single digit numbers. See for example long_mul(): --- /* fast path for single-digit multiplication */ if (Py_ABS(Py_SIZE(a)) = 1 Py_ABS(Py_SIZE(b)) = 1) { } --- As any other optimization, it should be proved to be faster with benchmarks. -- messages: 222731 nosy: haypo, mark.dickinson priority: normal severity: normal status: open title: ceval.c: implement fast path for integers with a single digit type: performance versions: Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21955 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog
Tal Einat added the comment: I don't think this is a major issue. Most users only use one version of IDLE with one version of Python. IDLE's user config is indeed shared between all versions. This is an unfortunate design mistake, and could perhaps be fixed in 3.5. Regarding this issue, we could skip 3.4 and include it only in 3.5. I think telling users fix your IDLE config when switching from 3.4 to 3.5 as so is reasonable. If we don't allow ourselves this, then without switching to having separate configs for each version of Python, we'll never be able to change anything in IDLE's configuration! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20577 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
David added the comment: Hi, I've the same problem. I've already tested (from source, Python-3.4.1.tgz) under OpenSUSE 12.3 and Debian 7.5 with the same issue. I've compiled it in standard way (./configure; make; make install) although the output (error) is the same, after import sqlite3: #python3 -c import sqlite3 Traceback (most recent call last): File string, line 1, in module File /usr/lib/python3.4/sqlite3/__init__.py, line 23, in module from sqlite3.dbapi2 import * File /usr/lib/python3.4/sqlite3/dbapi2.py, line 26, in module from _sqlite3 import * ImportError: No module named '_sqlite3' However, if I install it using specific distro packages it works properly. -- nosy: +dpatino ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
Berker Peksag added the comment: Works for me on Ubuntu 12.04 LTS: $ sudo apt-get install sqlite3 libsqlite3-dev $ ./configure $ make -j3 $ sudo make install $ sqlite3 -version 3.7.9 2011-11-01 00:52:41 c7c6050ef060877ebe77b41d959e9df13f8c9b5e $ python3.4 -V 3.4.1 $ python3.4 -c import sqlite3; print(sqlite3.sqlite_version) 3.7.9 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19806] smtpd crashes when a multi-byte UTF-8 sequence is split between consecutive data packets
Walter Dörwald added the comment: I don't know anything about SMTP, but would it make sense to use an incremental decoder for decoding UTF-8? -- nosy: +doerwalter ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19806 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
Alejandro added the comment: I've downloaded UBUNTU 12.04. I've compiled python3 and I got the same error. Seleccionando el paquete sqlite3 previamente no seleccionado. Desempaquetando sqlite3 (de .../sqlite3_3.7.9-2ubuntu1.1_i386.deb) ... Procesando disparadores para man-db ... Configurando libsqlite3-dev (3.7.9-2ubuntu1.1) ... Configurando sqlite3 (3.7.9-2ubuntu1.1) ... ubuntu@ubuntu:~$ python3.4 -c import sqlite3 Traceback (most recent call last): File string, line 1, in module File /usr/local/lib/python3.4/sqlite3/__init__.py, line 23, in module from sqlite3.dbapi2 import * File /usr/local/lib/python3.4/sqlite3/dbapi2.py, line 26, in module from _sqlite3 import * ImportError: No module named '_sqlite3' -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
Ismail Donmez added the comment: Chiming in here as a SUSE guy; Can you make sure /usr/local/lib/python3.4/lib-dynload/_sqlite3.cpython-34m.so does exist. If yes run ldd on it ldd /usr/local/lib/python3.4/lib-dynload/_sqlite3.cpython-34m.so And also give output of which python3.4 to make sure you are running the right python instance. -- nosy: +cartman ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15722] PEP 3121, 384 Refactoring applied to decimal module
Stefan Krah added the comment: Sorry Robin, I was wrong about the context -- it should be fine since it's thread-local. So the slowdown is back to 25%. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15722 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
Changes by STINNER Victor victor.stin...@gmail.com: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21765] Idle: make 3.x HyperParser work with non-ascii identifiers.
Tal Einat added the comment: If you think ColorDelegator and UndoDelegator should be fixed as well, I'd be happy to take a look, but we should open a separate tracker issue for it. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21765 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21927] BOM appears in stdin when using Powershell
Jason R. Coombs added the comment: I've tested it and setting PYTHONIOENCODING='utf-8-sig' starts to get there. It causes Python to consume the BOM on stdin, but it also causes stdout to print a spurious non-printable character in the output: C:\Users\jaraco echo foo | ./print-input foo There is a non-printable character before foo. I've included it in this message. In Powershell, it's rendered with a square before foo: □foo Using PowerShell under ConEmu, it appears as a space: foo In cmd.exe, I see this: C:\Users\jaracopython -c print('foo') ∩╗┐foo The space before the 'foo' apparently isn't a space at all. Indeed, the input is being processed as desired, but the output now is not. C:\Users\jaraco python -c print('bar') bar (the non-printable character appears there too) If I copy that text to the clipboard, I find that character is actually a \ufeff (zero-width no-break space, aka byte order mark). So by setting the environment variable to use utf-8-sig for input, it simultaneously changes the output to also use utf-8-sig. So it appears as if setting the environment variable would work for my purposes except that I only want to alter the input encoding and not the output encoding. I think my goal is pretty basic - read text from standard input and write text to standard output on the primary shell included with the most popular operating system. I contend that goal should be easily achieved and straightforward on Python out of the box. What does everyone think of the proposal that Python should simply default to utf-8-sig instead of utf-8 for stdin encoding? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21927 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12067] Doc: remove errors about mixed-type comparisons.
Changes by Andy Maier andreas.r.ma...@gmx.de: -- nosy: +benjamin.peterson, steven.daprano ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12067 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Deleted document should not appear in 3.4 docs
New submission from Brandon Rhodes: There was an old document in the howto folder whose advice was in many cases flat-out wrong, so Raymond Hettinger performed a wonderful public service by deleting it back in 2011: http://hg.python.org/cpython/rev/80ff78425419 Unfortunately it looks like the process for publishing Python documentation only adds documents, but never deletes them, so a copy of the documentation is still available under the 3.4 document tree: https://docs.python.org/3.4/howto/doanddont.html It should be deleted as soon as possible. Because it is presumed that only the most accurate and up-to-date documentation lives under the URL 3.4, people are reading and debating this document's bad advice as though it is official guidance as to how to use the language. (The only hint that something is wrong, alas, is the tiny detail that the top-left of the page says “Python v3.3a0 documentation”). The advice is currently being debated on Twitter and people are sad that they are supposed to stop using “from foo import bar” in Python. -- messages: 222741 nosy: brandon-rhodes priority: normal severity: normal status: open title: Deleted document should not appear in 3.4 docs ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12067] Doc: remove errors about mixed-type comparisons.
Changes by Andy Maier andreas.r.ma...@gmx.de: -- nosy: +ethan.furman ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12067 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Deleted document should not appear in 3.4 docs
Changes by Brandon Rhodes bran...@rhodesmill.org: -- assignee: - docs@python components: +Documentation nosy: +docs@python versions: +Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14714] PEP 414 tokenizing hook does not preserve tabs
Mark Lawrence added the comment: What are the Python core developers meant to do with this issue? How does a piece of code on github relate to the core Python code in Mercurial? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14714 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21927] BOM appears in stdin when using Powershell
STINNER Victor added the comment: The BOM (byte order mark) appears in the standard input stream. When using cmd.exe, the BOM is not present. This behavior occurs in CP1252 as well as CP65001. How you do change the console encoding? Using the chcp command? I'm surprised that you get a UTF-8 BOM when the code page 1252 is used. Can you please check that sys.stdin.encoding is cp1252? I tested PowerShell with Python 3.5 on Windows 7 with an OEM code page 850 and ANSI code page 1252: - by default, the stdin encoding is cp850 (OEM code page) and os.device_encoding(0) returns cp850. sys.stdin.readline() does not contain a BOM. - when stdin is a pipe (ex: echo abc|python ...), the stdin encoding becomes cp1252 (ANSI code page) because os.device_encoding(0) returns None; cp1252 is the result of locale.getpreferredencoding(False) (ANSI code page). sys.stdin.readline() does not contain a BOM. If I change the console encoding using the command chcp 65001: - by default, the stdin encoding = os.device_encoding(0) = cp65001. sys.stdin.readline() does not contain a BOM. - when stdin is a pipe, stdin encoding = locale.getpreferredencoding(False) = cp1252 and sys.stdin.readline() *contains* the UTF-8 BOM Note: The UTF-8 BOM is only written once, before the first character. So the UTF-8 BOM is only written in one case under these conditions: - Python is running in PowerShell (The UTF-8 BOM is not written in cmd.exe, even with chcp 65001) - sys.stdin is a pipe - the console encoding was set manually to cp65001 -- It looks like PowerShell decodes the output of the producer program (echo, type, ...) and then encodes the output to the consumer program (ex: python). It's possible to change the encoding of the encoder by setting $OutputEncoding variable. Example to encode to UTF-8 without the BOM: $OutputEncoding = New-Object System.Text.UTF8Encoding($False) Example to encode to UTF-8 without the BOM: $OutputEncoding = [System.Text.Encoding]::UTF8 Using [System.Text.Encoding]::UTF8, sys.stdin.readline() starts with a BOM even if the console encoding is cp850. If you set the console encoding to 65001 (chcp 65001) and $OutputEncoding to [System.Text.Encoding]::UTF8, you get... two UTF-8 BOMs... yeah! I tried different producer programs: [MS-DOS] echo abc, [PowerShell] write-output abc, [MS-DOS] type document.txt, [PowerShell] Get-Content document.txt, python -c print('abc'). It doesn't like like using a different program changes anything. The UTF-8 BOM is added somewhere by PowerShell between by producer and the consumer programs. To show the console input and output encodings in PowerShell, type [console]::InputEncoding and [console]::OutputEncoding. See also: http://stackoverflow.com/questions/22349139/utf8-output-from-powershell -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21927 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
Alejandro added the comment: we have /usr/local/lib/python3.4/lib-dynload/_sqlite3.cpython-34m.so but we didn't have it in /soft/pyt341/lib/python3.4/lib-dynload/ After copying it into /sofy/pyt341 the problem was solved!! ;) /soft/pyt341/bin/python3 -c import sqlite3;print(sqlite3.sqlite_version) 3.7.6.3 In my opinion running ./configure should check if sqlite libs are properly satisfied and break compilation if they aren't installed. :) I don't know if this issue could be considered a bug. So I will close it as works for me Thanks for all! -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21950] import sqlite3 not running
David added the comment: You're absolute right that file is not in path. However, in my view this a bug, due to the fact libsqlite3-dev package must be installed before Python3.4.1 is compiled (or install it and recompile python) because there is no errors, no warnings... nothing. In any case, thanks a lot for your help. This solution works for me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21950 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20065] Python-3.3.3/Modules/socketmodule.c:1660:14: error: 'CAN_RAW' undeclared (first use in this function)
Igor Franchuk added the comment: Confirmed as fixed at least in Python 3.3.5 Successfully compiled at Linux gw 2.6.33-gentoo #1 SMP Mon Mar 8 23:29:59 MSK 2010 i686 Intel(R) Pentium(R) D CPU 3.00GHz GenuineIntel GNU/Linux -- versions: -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20065 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12067] Doc: remove errors about mixed-type comparisons.
Andy Maier added the comment: Uploaded v8 of the patch for 3.4 and default. It reflects hopefully everything that was said in this issue thread, and on the python-dev mailing list (subject: == on object tests identity in 3.x), at least to the extent it was related to comparisons. Besides the doc changes it contained previously, it now also contains improvements for the test suite for comparisons (lib/test/test_compare.py). - Please review both. Andy -- Added file: http://bugs.python.org/file35924/issue12067-expressions-py34_v8.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12067 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21957] ASCII Formfeed (FF) ASCII Vertical Tab (VT) Have Hexadecimal Representation
New submission from Stephen Paul Chappell: In the string module, the definition of whitespace is ' \t\n\r\v\f'. However, the representation of string.whitespace is ' \t\n\r\x0b\x0c'. Would it be terribly inconvenient to change the representation of '\x0b\x0c' to '\v\f'? The documentation at https://docs.python.org/3.4/reference/lexical_analysis.html#string-and-bytes-literals lists recognized escape sequences, but string represetations seem to diverge slightly from what is recognized. The same problem exists with the representation of bytes. -- messages: 222749 nosy: Zero priority: normal severity: normal status: open title: ASCII Formfeed (FF) ASCII Vertical Tab (VT) Have Hexadecimal Representation type: enhancement versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4, Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21957 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21927] BOM appears in stdin when using Powershell
STINNER Victor added the comment: See also issues #1602 (Windows console) and #16587 (stdin, _setmode() and wprintf). I tried msvcrt.setmode(0, 0x4): set stdin mode to _O_U8TEXT. In this mode, echo abc|python -c import sys; print(ascii(sys.stdin.read())) displays \xff\xfea\x00b\x00c\x00\n\x00 which is abc encoded to UTF-16 (little endian with the BOM), b'\xff\xfe' is the Unicode BOM U+FEFF (u'\uFEFF') encoded to UTF-16-LE. U+FEFF encoded to UTF-8 gives b'\xef\xbb\xbf'. So it looks like it's not an issue of the stdin mode. I tried all modes and I always get the Unicode BOM. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21927 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21953] pythonrun.c does not check std streams the same as fileio.c
STINNER Victor added the comment: See also issues: - issue #17797: Visual C++ 11.0 reports fileno(stdin) == 0 for non-console program - issue #18804: I proposed a similar change for other reasons. -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21953 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21936] test_future_exception_never_retrieved() of test_asyncio fails on AMD64 Debian root 3.x
Changes by STINNER Victor victor.stin...@gmail.com: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21936 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13081] Crash in Windows with unknown cause
STINNER Victor added the comment: Serhiy implemented the FileIO class in pure Python: see the issue #21859 (patch under review). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13081 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13081] Crash in Windows with unknown cause
Changes by STINNER Victor victor.stin...@gmail.com: -- Removed message: http://bugs.python.org/msg222751 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13081 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue17984] io and _pyio modules require the _io module
STINNER Victor added the comment: Serhiy implemented the FileIO class in pure Python: see the issue #21859 (patch under review). -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17984 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11455] issue a warning when populating a CPython type dict with non-string keys
Mark Lawrence added the comment: The patch is short and sweet. Assuming it is acceptable do we commit or don't we? See also the reference to #11470 in msg132032. -- nosy: +BreamoreBoy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11455 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21732] SubprocessTestsMixin.test_subprocess_terminate() hangs on AMD64 Snow Leop 3.x buildbot
STINNER Victor added the comment: It looks like the bug is gone... I don't know why :-/ But at least, it didn't occur recently. -- resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21732 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Deleted document should not appear in 3.4 docs
Steven D'Aprano added the comment: in many cases flat-out wrong What advice is flat-out wrong? All the advice seems excellent to me: * avoid from spam import * (with a very few exceptions) * be cautious about from spam import eggs * avoid bare except clauses * watch out for time from check to time to use race conditions (e.g. prefer EAFP over LBYL when opening files) * don't reinvent the wheel poorly when the std lib already solves your problem * avoid backslash as line continuation It should be deleted as soon as possible. Why delete it rather than fix any (alleged) problems with it? The advice is currently being debated on Twitter and people are sad that they are supposed to stop using “from foo import bar” Debated on Twitter. Why am I not surprised that they've misunderstood it? The document explains why from foo import bar can *sometimes* be harmful. The wording could be improved, and isn't as clear as it should be, but the advice is broadly correct: from foo import bar injects the object bar into the current namespace, not the name, which means that if foo rebinds bar, that change will not be seen in the current namespace. If foo never rebinds bar, then there is no problem, but if bar is a *variable* rather than a (pseudo-)constant, you may run into subtle and tricky problems. -1 on deleting. If the consensus is to keep it, I'll look at rewording and improving some of the weaker descriptions. -- nosy: +steven.daprano ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21932] os.read() must use Py_ssize_t for the size parameter
Roundup Robot added the comment: New changeset e9b401d46e20 by Victor Stinner in branch 'default': Issue #21932: os.read() now uses a :c:func:`Py_ssize_t` type instead of http://hg.python.org/cpython/rev/e9b401d46e20 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21932 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21932] os.read() must use Py_ssize_t for the size parameter
STINNER Victor added the comment: Patch LGTM. Thanks for the review. Here is a test for it. Your test does not pass because Linux truncates the read() size to 2GB - 4096. I tested with /dev/zero device and with a regular file. I wrote a simplified test to just check that size larger than INT_MAX does not emit an OverflowError. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21932 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Deleted document should not appear in 3.4 docs
Brandon Rhodes added the comment: The question of whether the document ought to be removed is not at issue here. The document was already deleted, in 2011, by Raymond Hettinger, with the consent of its author. I told that story merely as background. The issue here is that the Python web site is out of date with the documentation in the Mercurial source repository, which is clear because what is clearly marked as an old 3.3-alpha document is being served out of the /3.4/ directory. This is probably because the documentation “push” script does not remove documents from the site, and can be corrected through a simple rm by anyone with access to the server. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Doc files deleted from repo are not deleted from docs.python.org.
R. David Murray added the comment: The file no longer exists in the 3.5 tree on the server. Since it isn't linked from the 3.4 index, it may be more effort than it is worth to get someone to delete the file from the 3.4 tree on the server. On the other hand, fixing the publication process to delete files is something the doc team should probably tackle (note: it might be a sphinx issue, but as Brandon says is more likely an issue with the script that publishes the pages to the server). As for revising the howto and re-adding it, that is a separate issue and should be discussed on the original issue 7391, where the possibility was already raised and got some support. -- nosy: +r.david.murray title: Deleted document should not appear in 3.4 docs - Doc files deleted from repo are not deleted from docs.python.org. versions: +Python 2.7, Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21932] os.read() must use Py_ssize_t for the size parameter
Roundup Robot added the comment: New changeset 4a7fcd5273ce by Victor Stinner in branch 'default': Issue #21932: Ooops, os.read(fd, size) allocates a buffer of size bytes, even http://hg.python.org/cpython/rev/4a7fcd5273ce -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21932 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21927] BOM appears in stdin when using Powershell
Jason R. Coombs added the comment: I get different results that @haypo when testing Powershell on Windows 8.1 with Python 3.4.1: C:\Users\jaraco chcp 1252 Active code page: 1252 C:\Users\jaraco $env:PYTHONIOENCODING='' How you do change the console encoding? Using the chcp command? Yes. I recently discovered that if I use chcp 65001 in my Powershell profile, I can finally see Unicode characters output from my Python programs! I'm surprised that you get a UTF-8 BOM when the code page 1252 is used. Can you please check that sys.stdin.encoding is cp1252? C:\Users\jaraco echo foo | python -c import sys; print(sys.stdin.readline()) foo C:\Users\jaraco python -c import sys; print(sys.stdin.encoding) cp1252 C:\Users\jaraco chcp 65001 C:\Users\jaraco echo foo | python -c import locale, os; print(os.device_encoding(0), locale.getpreferredencoding(False)) None cp1252 It seems as if something may have changed in Powershell between Windows 7 and 8.1, because my results are inconsistent with your findings. There's a lot more to digest from your response, so I'll going to have to revisit this later. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21927 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog
Terry J. Reedy added the comment: The awkwardness of the config design is that idlelib/config-xyz.def files are separate for each version and shared across users (and systems) while .idlerc/config-xyz.def files are separate for each user (account) and shared across versions on the same machine. #20580 is about at least using the existing system-specific sections. Ned also suggested the possibility of version-specific systems. Version specific files are also possible: config-xyz-34.def. I am willing to also tell users in 2.8.9 and 3.4.2 to reset any custom formatwidth setting. But we need a way to *tell* users that, even for 3.5. I would like to replace the useless Type copyright, credits or license() for more information. with See HELP/NEWS for information about changes in each release. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20577 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16382] Better warnings exception for bad category
Roundup Robot added the comment: New changeset c4a86fe52006 by Berker Peksag in branch 'default': Issue #16382: Improve exception message of warnings.warn() for bad category. http://hg.python.org/cpython/rev/c4a86fe52006 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16382 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21958] Allow python 2.7 to compile with Visual Studio 2013
New submission from Zachary Turner: VS2013 and beyond implement C99 math functions. Of interest to Python is the function round(). Python conditionally provides its own implementation of round() based on whether or not HAVE_ROUND is defined, but in no case is HAVE_ROUND ever defined. This leads to a huge spew of warnings when compiling with VS2013, and presumably it also leads to undefined behavior. The attached patch conditionally defines HAVE_ROUND based on _MSC_VER, and additionally provides a VS2013 port in the form of a set of native VS2013 solution and project files. This patch is based against tip of 2.7 release branch. The same fix may or may not still be needed in 3.x -- components: Windows files: python.patch keywords: patch messages: 222766 nosy: Zachary.Turner, steve.dower priority: normal severity: normal status: open title: Allow python 2.7 to compile with Visual Studio 2013 type: compile error versions: Python 2.7 Added file: http://bugs.python.org/file35925/python.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21958 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog
Tal Einat added the comment: So is that a go-ahead to commit to the 2.7 and 3.4 branches (as well as default)? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20577 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21765] Idle: make 3.x HyperParser work with non-ascii identifiers.
Terry J. Reedy added the comment: I did not open another issue yet because I did not want to split the general discussion of parsing 3.x unicode-based python. We might also need another issue for idlelib/PyParse, and that might need to come first. What I think is that Idle should have at 1 definition of 'identifier' and not a least 3, in 3 separate places ;-). Hyperparser seems like the most appropriate place if there is to be more than str.isidentifier. That is not to say that equivalents versions might be needed for different uses. ColorDelegator, as it is, needs an re version to be combined with other regexes. I have not looked yet at what UndoDelegator does with its character classification function and whether str.isidentifier could be used. Hyperparsar seems the hardest since it parses backwards. I do not consider this issue to be the highest priority, at the moment, but we have collected enough info with help from Ezio and Martin to do some experiments. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21765 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21906] Tools\Scripts\md5sum.py doesn't work in Python 3.x
Roundup Robot added the comment: New changeset eafe4007c999 by Berker Peksag in branch '3.4': Issue #21906: Make Tools/scripts/md5sum.py work in Python 3. http://hg.python.org/cpython/rev/eafe4007c999 New changeset e1913d2780d7 by Berker Peksag in branch 'default': Issue #21906: Merge from 3.4. http://hg.python.org/cpython/rev/e1913d2780d7 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21906 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Doc files deleted from repo are not deleted from docs.python.org.
Audrey Roy added the comment: Since it isn't linked from the 3.4 index, it may be more effort than it is worth to get someone to delete the file from the 3.4 tree on the server. It would be worthwhile to delete or fix it in the 2.7 and 3.4 tree. It accidentally gets linked, still causing confusion to 2.7 and 3.4 users: https://twitter.com/audreyr/status/487446878837944320 -- nosy: +audreyr ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16382] Better warnings exception for bad category
Berker Peksag added the comment: Thanks for the patch, Phil. -- assignee: - berker.peksag nosy: +r.david.murray resolution: - fixed stage: patch review - resolved status: open - closed type: behavior - enhancement ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16382 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21959] msi product code for 2.7.8150 not in Tools/msi/uuids.py
Changes by Anselm Kruis a.kr...@science-computing.de: -- title: msi product code for 2.7.5150 not in Tools/msi/uuids.py - msi product code for 2.7.8150 not in Tools/msi/uuids.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21959 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1074333] On linux, numeric pad input is ignored when numlock off
Terry J. Reedy added the comment: I verified that this issue does not affect Windows. What about Mac? A patch might best be system-specific in only being active on systems that need it. The lack of complaints other than by one person suggests that it is not a high priority among linux users -- or that they are all resigned to flakey behavior, or that some other linux apps also do not recognize numlock-off keypad keys. -- assignee: kbk - nosy: +terry.reedy priority: normal - low title: input from numeric pad always dropped when numlock off - On linux, numeric pad input is ignored when numlock off type: behavior - enhancement versions: +Python 3.4, Python 3.5 -Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1074333 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21906] Tools\Scripts\md5sum.py doesn't work in Python 3.x
Berker Peksag added the comment: Thanks for the patch, Zachary. -- resolution: - fixed stage: patch review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21906 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13574] refresh example in doc for Extending and Embedding
Mark Lawrence added the comment: https://docs.python.org/3/extending/newtypes.html still refers to PyInstanceObject, I'm sorry but I've no idea what the replacement is called, so I'll leave this to someone in the know. -- nosy: +BreamoreBoy versions: +Python 3.5 -Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13574 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15577] Real argc and argv in embedded interpreter
Mark Lawrence added the comment: Without a patch this issue will go nowhere. I'm assuming that this limitation must have been overcome by other projects using embedded Python. Has anybody got any ideas as to how, I certainly haven't? -- nosy: +BreamoreBoy type: crash - enhancement versions: +Python 3.5 -Python 2.7, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15577 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1856] shutdown (exit) can hang or segfault with daemon threads running
Matthias Klose added the comment: http://tracker.ceph.com/issues/8797 reports that the backport to 2.7 causes a regression in ceph. -- nosy: +benjamin.peterson, doko status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1856 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10175] vs version for win32 compilation of extension modules is undocumented.
Mark Lawrence added the comment: There's a table here https://docs.python.org/X/using/windows.html#compiling-python-on-windows which shows what versions you need, where X can be 2 or 3. -- nosy: +BreamoreBoy versions: +Python 3.4, Python 3.5 -Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10175 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Doc files deleted from repo are not deleted from docs.python.org.
Mark Lawrence added the comment: The docs state 'from module import name1, name2. - This is a “don’t” which is much weaker than the previous “don’t”s but is still something you should not do if you don’t have good reasons to do that.' How does that translate into 'The Python docs say that from module import name1, name2 is an anti-idiom' ? -- nosy: +BreamoreBoy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12217] Cross-link docs for faulthandler, traceback and pdb
Mark Lawrence added the comment: Who has the technical knowledge to write a patch for this? -- nosy: +BreamoreBoy versions: +Python 3.5 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12217 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12067] Doc: remove errors about mixed-type comparisons.
Mark Dickinson added the comment: + In other words, the following expressions should have the same result: + +``x == y`` and ``not x != y`` + +``x y`` and ``not x = y`` + +``x y`` and ``not x = y`` I think the second and third items here go too far: sets don't obey these rules, for example. Not all uses of comparisons need to force a total ordering. OTOH, you leave out a more fundamental relation, namely that `x y` and `y x` should ordinarily give the same result, as should `x = y` and `y = x`. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12067 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16516] argparse types (and actions) must be hashable
Mark Lawrence added the comment: @Paul can you take a look at this please. -- nosy: +BreamoreBoy, paul.j3 versions: +Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16516 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21959] msi product code for 2.7.8150 not in Tools/msi/uuids.py
Changes by Zachary Ware zachary.w...@gmail.com: -- nosy: +steve.dower ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21959 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21959] msi product code for 2.7.5150 not in Tools/msi/uuids.py
New submission from Anselm Kruis: The file Tools/msi/uuids.py contains the product codes for all recently released Python 2.x versions except 2.7.8. Without this code it is not possible to recreate the MSI installer using Tools\msi\msi.py. The product code of https://www.python.org/ftp/python/2.7.8/python-2.7.8.msi is '{61121B12-88BD-4261-A6EE-AB32610A56DD}'. By the way. We had exactly the same issue with 2.7.5: #18023 -- components: Windows messages: 222774 nosy: anselm.kruis, loewis, zach.ware priority: normal severity: normal status: open title: msi product code for 2.7.5150 not in Tools/msi/uuids.py type: behavior versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21959 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21957] ASCII Formfeed (FF) ASCII Vertical Tab (VT) Have Hexadecimal Representation
Ned Deily added the comment: I am not sure why the string reprs for FF and VT are not special-cased to \f and \v but they are not alone: \a (BEL) and \b (BS) are also not special-cased. My guess is that it was for performance reasons but perhaps someone with a longer memory can comment. As now implemented, supporting these special cases would add checks for each for every character being encoded, a critical path for many applications, and in most cases, CR, LF, and HT are much more likely to be encountered. I also don't see where this behavior is documented anywhere but it goes back a long way, probably to the earliest days of Python and, in general, Python does not make any promises about which of any valid representations for particular characters will be used. While, on the one hand, it would make some string reprs look cleaner, on the other hand there are downsides: the risks of breaking existing code that might depend on the long-standing behavior, the potential performance impact that would need to be measured and mitigated, and the cost to develop and test. In balance, I think the risks outweigh any benefit so I think we should not pursue this change. If others feel differently, feel free to reopen. In any case, thanks for the suggestion. -- nosy: +ned.deily resolution: - rejected stage: - resolved status: open - closed versions: -Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21957 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6092] IDLE: Changed Shortcuts don't show up in menu
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6092 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20135] FAQ need list mutation answers
R. David Murray added the comment: I think the example would be clarified by speaking about mutation operations versus non-mutation operations. After all: x = [1] y = x x = x + [2] x [1, 2] y [1] At that point including a list += operation would also be beneficial. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20135 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21960] Better path handling in Idle find in files
New submission from Terry J. Reedy: I propose two interrelated changes for path handling in Idle's Find in Files feature (Alt-F3). 1. If I hit Alt-F3 in an editor window, the 'In files:' entry box displays a full path, such as C:\Programs\Python34\Lib\idlelib\*.py. If I do the same in the shell, the display is *.py with the prefix, the starting directory containing pythonx.exe, suppressed. (In a repository build, the box is blank, perhaps because the executable is not in the directory containing Assuming 2, I would prefer the full path (in a wider dialog box). 1a. In a repository build, the box is blank, perhaps because the executable is not in the directory containing Lib. Starting with the patch to that directory, rather than pcbuild (on Windows) would be more useful than nothing. 2. FiF uses a generic Output Window. It first displays something like Searching 'Func' in lib/idlelib/idle_test/*.py ... where the path is copied from the 'In file:' path. This common prefix is displayed with all hits lib/idlelib/idle_test\htest.py: 15: or a wrapper function also work... lib/idlelib/idle_test\htest.py: 40: 'msg': Test editor ... lib/idlelib/idle_test\mock_tk.py: 18: class Mbox_func: If one starts from the editor window, the common prefix is even longer and more noisy and obnoxious. (It is also slightly worse in my repository setup.) C:\Programs\Python34\lib/idlelib/idle_test\htest.py: 15: or a wrapper function also work... C:\Programs\Python34\lib/idlelib/idle_test\htest.py: 40: 'msg': Test editor ... C:\Programs\Python34\lib/idlelib/idle_test\mock_tk.py: 18: class Mbox_func: which is why I do not especially want change 1 without change 2: delete the common prefix from the listing. htest.py: 15: or a wrapper function also work. The name of wrapper functions, like htest.py: 40: 'msg': Test editor functions of interest mock_tk.py: 18: class Mbox_func: The path prefix would have to be an attribute of the window, which should perhaps be an FiF subclass of OutputWindow anyway. The Go to file/line function would append the prefix. -- messages: 222779 nosy: terry.reedy priority: normal severity: normal status: open title: Better path handling in Idle find in files type: enhancement versions: Python 2.7, Python 3.4, Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21960 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14929] IDLE crashes on *Edit / Find in files ...* command
Changes by Terry J. Reedy tjre...@udel.edu: -- stage: needs patch - test needed versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14929 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog
Terry J. Reedy added the comment: What I meant was 'wait until we have an new announcement mechanism', which we very much need anyway, and then apply to all three. And that should have been 'Help/What's New' in the splash announcement. I opened #21961 for this and will try to have a minimal document is a day or so. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20577 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14929] IDLE crashes on *Edit / Find in files ...* command
Terry J. Reedy added the comment: The 'In files:' field specifies the search directory. I opened #21960 about it being more informative when using Find in Files from the Shell window. Perfect encoding detection is a fantasy; decent encoding detection by heuristics is slow and not something to do when searchings 100s, 1000s, or more files. What would be reasonable is to check for an encoding cookie. Idle already does this when opening a .py file in the editor. That code should be encapsulated if it is not and reused. An encoding field for non-python files would be possible, but is a lesser priority to me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14929 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21961] Add What's New for Idle.
New submission from Terry J. Reedy: For the stdlib in general, What's New in x.y.0 is sufficient because there is not supposed to be anything new in bugfix releases except for bugfixes. 2.7 has a security enhancement exemption, and a corresponding section in the 2.7 What's New for security enhancements in maintenance releases. A similar section for Idle could be added to What's New for each Python version. But thinking about it, I would rather have a separate document listed in the Idle help menu and advertised in the Idle sign-on message. In particular, I would replace the useless Type copyright, credits or license() for more information. with See HELP/WHAT'S NEW for information about changes in each release. -- assignee: terry.reedy components: IDLE messages: 222785 nosy: terry.reedy priority: normal severity: normal stage: needs patch status: open title: Add What's New for Idle. type: enhancement versions: Python 2.7, Python 3.4, Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21961 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Doc files deleted from repo are not deleted from docs.python.org.
Brandon Rhodes added the comment: I do not find it unreasonable, on a page of Python idioms, the we would call an example that explicitly says Don't in its title an anti-idiom. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21960] Better path handling in Idle find in files
Changes by Terry J. Reedy tjre...@udel.edu: -- stage: - test needed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21960 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21323] CGI HTTP server not running scripts from subdirectories
Zach Byrne added the comment: Done and done. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21323 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16494] Add a method on importlib.SourceLoader for creating bytecode file format/container
Mark Lawrence added the comment: @Brett as #15627 is in would you like to follow up on this. -- nosy: +BreamoreBoy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16494 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21956] Doc files deleted from repo are not deleted from docs.python.org.
Audrey Roy added the comment: Mark, I and a number of others simply misinterpreted the text in that section. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21956 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21962] No timeout for asyncio.Event.wait() or asyncio.Condition.wait() ?
New submission from Alexandre JABORSKA: Hi, Nor asyncio.Event.wait() neither asyncio.Condition.wait() (or .wait_for()) has a timeout parameter, while threading.Event.wait() has one. A timeout can be specified for the whole task using asyncio.wait_for() but it's tricky. I guess asyncio implementation could allow a timeout parameter (but I've not looked at the code yet). Maybe is this a feature ? -- components: asyncio messages: 222791 nosy: ajaborsk, gvanrossum, haypo, yselivanov priority: normal severity: normal status: open title: No timeout for asyncio.Event.wait() or asyncio.Condition.wait() ? type: enhancement versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21962 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21962] No timeout for asyncio.Event.wait() or asyncio.Condition.wait() ?
STINNER Victor added the comment: A timeout can be specified for the whole task using asyncio.wait_for() but it's tricky. Exactly, you can use wait_for() on any async operation. Why would you like to add a timeout on each async operation, while wait_for() is available? Replace event.wait(timeout=60) with wait_for(event.wait(), 60). Maybe we should put more examples using wait_for() on operations commonly used with a timeout? Guido proposed to add a timeout for some operations, but with a different meaning: maximum time without getting new events, each new event resets the timeout. It was maybe on StreamReader.readline() which uses multiple async read until it gets a full line. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21962 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21937] IDLE interactive window doesn't display unsaved-indicator
Terry J. Reedy added the comment: In installed 3.4.1 on Win 7, I *do* get the unsaved * back when typing. It disappears again when I hit return. So on this system, the meaning seems to be 'unsubmitted code'. Saving in the middle of a line inserts '\n' before saving (but does not submit for execution) and also removes *. -- nosy: +terry.reedy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21937 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14714] PEP 414 tokenizing hook does not preserve tabs
Vinay Sajip added the comment: How does a piece of code on github relate to the core Python code in Mercurial? Tangentially. Armin Ronacher is the developer of both the GitHub code and the PEP 414 implementation, and it's referenced in the PEP. It doesn't make sense for any other Python core developer to worry about it. If Armin wants to close the issue, it's up to him. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14714 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21963] 2.7.8 backport of Issue1856 (avoid daemon thread problems at shutdown) breaks ceph
New submission from Ned Deily: doko in msg222768 of Issue1856: http://tracker.ceph.com/issues/8797 reports that the backport to 2.7 causes a regression in ceph. -- messages: 222795 nosy: benjamin.peterson, doko, ned.deily priority: release blocker severity: normal stage: needs patch status: open title: 2.7.8 backport of Issue1856 (avoid daemon thread problems at shutdown) breaks ceph versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21963 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14714] PEP 414 tokenizing hook does not preserve tabs
Armin Ronacher added the comment: I hereby close this issue which is two years old. The only point of the tokenizer thing was to support Python 3.2 which many libraries already have stopped supporting anyways. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14714 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14143] test_ntpath failure on Windows
Mark Lawrence added the comment: I've just taken a look at the Windows buildbots and can't find anything relevant to this so can we close it. -- nosy: +BreamoreBoy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14143 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1856] shutdown (exit) can hang or segfault with daemon threads running
Ned Deily added the comment: I've opened Issue21963 to track the 2.7.8 regression. Please continue any discussion there. -- nosy: +ned.deily status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1856 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21963] 2.7.8 backport of Issue1856 (avoid daemon thread problems at shutdown) breaks ceph
Changes by Ned Deily n...@acm.org: -- nosy: -ned.deily ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21963 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14714] PEP 414 tokenizing hook does not preserve tabs
Changes by Armin Ronacher armin.ronac...@active-4.com: -- resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14714 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12669] test_curses skipped on buildbots
Changes by Mark Lawrence breamore...@yahoo.co.uk: -- versions: +Python 3.5 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12669 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21963] 2.7.8 backport of Issue1856 (avoid daemon thread problems at shutdown) breaks ceph
STINNER Victor added the comment: Does anyone have a *simple* script to reproduce the regression? The changeset 7741d0dd66ca looks good to me, Python 3 does the same thing since Python 3.2 (the new GIL). Anyway, daemon threads are evil :-( Expecting them to exit cleanly automatically is not good. Last time I tried to improve code to cleanup Python at exit in Python 3.4, I also had a regression (just before the release of Python 3.4.0): see the issue #21788. -- nosy: +haypo, neologix ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21963 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21963] 2.7.8 backport of Issue1856 (avoid daemon thread problems at shutdown) breaks ceph
STINNER Victor added the comment: The changeset 7741d0dd66ca looks good to me, Python 3 does the same thing since Python 3.2 (the new GIL). Oh, I forgot to say that the simplest way to fix the regression is to revert this commit... As I wrote modifying the code to cleanup Python at exit is risky, and it's maybe too late to do that in Python 2.7? The risk of regression caused by 7741d0dd66ca is maybe higher than the benefit of the enhancement? :-( -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21963 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21958] Allow python 2.7 to compile with Visual Studio 2013
Steve Dower added the comment: The fix is certainly needed in default, though I already have it in my fork for porting to VC14. I'm okay with the HAVE_ROUND change, but I think the VS2013 project files are better off kept separate. We won't be rebuilding 2.x with a newer compiler, so they don't belong in hg.python.org. -- nosy: +tim.golden, zach.ware ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21958 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7063] Memory errors in array.array
Mark Lawrence added the comment: I've tested the reworked patch on Windows 7, ran 718 tests with 1 skipped both before and after applying the patch. -- nosy: +BreamoreBoy Added file: http://bugs.python.org/file35926/Issue7063.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7063 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21955] ceval.c: implement fast path for integers with a single digit
Josh Rosenberg added the comment: On: if (... a+b will not overflow ...) { Since you limited the optimization for addition to single digit numbers, at least for addition and subtraction, overflow is impossible. The signed twodigit you use for the result is guaranteed to be able to store far larger numbers than addition of single digits can produce. In fact, due to the extra wasted bit on large (30 bit) digits, if you used a fixed width 32 bit type for addition/subtraction, and a fixed width 64 bit type for multiplication, overflow would be impossible regardless of whether you used 15 or 30 bit digits. On a related note: Presumably you should check if the abs(size) = 1 like in longobject.c, not == 1, or you omit the fast path for 0. Doesn't come up much, not worth paying extra to optimize, but it costs nothing to handle it. -- nosy: +josh.rosenberg ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21955 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21959] msi product code for 2.7.8150 not in Tools/msi/uuids.py
Steve Dower added the comment: Yeah, I patched my msi.py to get the build going but haven't checked it in (it was already after the tag...). I'll fill out the next few minor versions and check it in. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21959 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21953] pythonrun.c does not check std streams the same as fileio.c
Steve Dower added the comment: This is definitely the same as #17797, so I'll close this as a dup. Over on that issue, it's confirmed as fixed in VC14 (and it is - I've checked). -- resolution: - duplicate status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21953 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21953] pythonrun.c does not check std streams the same as fileio.c
Changes by Zachary Ware zachary.w...@gmail.com: -- stage: - resolved ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21953 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21958] Allow python 2.7 to compile with Visual Studio 2013
Zachary Ware added the comment: Agreed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21958 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21959] msi product code for 2.7.8150 not in Tools/msi/uuids.py
Roundup Robot added the comment: New changeset cc8849331528 by Steve Dower in branch '2.7': #21959: Adds 2.7.8 product code to Tools/msi/uuids.py http://hg.python.org/cpython/rev/cc8849331528 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21959 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10213] tests shouldn't fail with unset timezone
Mark Lawrence added the comment: Given the extended EOL I'd assume that this is worth doing for 2.7. -- nosy: +BreamoreBoy versions: -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10213 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21868] Tbuffer in turtle allows negative size
Lita Cho added the comment: Hi Raymond! Just wanted to check if you had time to test this yet. I ran the tests through the Turtle tests I wrote (issue21914), but those are still pending approval. This is off topic, but I also didn't realize till now that you gave a talk about Transforming Code into Beautiful, Idiomatic Python, which is super awesome! Getting a patch reviewed by you is super exciting! :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21868 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21964] inconsistency in list-generator comprehension with yield(-from)
New submission from hakril: Will playing with generators and `yield from` I found some inconsistency. list comprehension with yield(-from) would return a generator. generator comprehension would yield some None in the middle of the expected values. Examples: l = [abc, range(3)] g1 = [(yield from i) for i in l] print(g) generator object listcomp at 0x7f5ebd58b690 print(list(g)) ['a', 'b', 'c', 0, 1, 2] # this result is super cool ! g2 = ((yield from i) for i in l) print(g2) generator object genexpr at 0x7f5ebd58b6e0 print(list(g2)) ['a', 'b', 'c', None, 0, 1, 2, None] For `g1`: it returns a generator because the listcomp contains a `yield from`. For `g2` it append None because it yield the return value of `yield from i`. It could be rewritten as: def comp(x): for i in x: yield (yield from i) -- components: Interpreter Core messages: 222811 nosy: hakril priority: normal severity: normal status: open title: inconsistency in list-generator comprehension with yield(-from) type: behavior versions: Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21964 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20135] FAQ need list mutation answers
Ezio Melotti added the comment: Good point, I'll try to add that to the FAQ. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20135 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3015] tkinter with wantobjects=False has been broken for some time
Lita Cho added the comment: That's perfect. I agree that this issue is closed! :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3015 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com