[issue9951] introduce bytes.hex method

2013-12-09 Thread HCT
HCT added the comment: would be good if we can specify a optional flag to get all cap hex. currently, I have to do hexlify( some_bytes ).decode( 'UTF-8' ).upper(). would be good to be able to do some_bytes.hex( upper=1 ) -- nosy: +hct ___ Python tra

[issue19915] int.bit_at(n) - Accessing a single bit in O(1)

2013-12-09 Thread Tim Peters
Tim Peters added the comment: @HCT, see http://bugs.python.org/issue19915#msg205713 for what's "semantically wrong". Ints are not arrays - slicing is unnatural. The point about error checking is that if this were supported via slicing notation, then the _helpful_ exceptions of the form, e.g.,

[issue18576] Rename and document test.script_helper as test.support.script_helper

2013-12-09 Thread Nick Coghlan
Nick Coghlan added the comment: Note that the test.* namespace has long been declared as unstable, so we don't worry about breaking third party code when rearranging the test suite (as far as I am aware, most Linux distros don't even include the test suite in their Python packages). I'll see how

[issue19846] Python 3 raises Unicode errors with the C locale

2013-12-09 Thread Nick Coghlan
Nick Coghlan added the comment: There's a wrong assumption here: glib applications on Linux use UTF-8 regardless of locale. That's the part I have a problem with: the assumption that the locale will correctly specify the encoding to use for OS APIs on modern Linux systems. It's simply not always

[issue19846] Python 3 raises Unicode errors with the C locale

2013-12-09 Thread Martin v . Löwis
Martin v. Löwis added the comment: Nick: which glib functions are you specifically referring to? Many of them don't deal with strings at all, and of those that do, many are encoding-agnostic (i.e. it is correct to claim that they operate on UTF-8, but likewise also correct that they operate on

[issue19846] Python 3 raises Unicode errors with the C locale

2013-12-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: > It's simply not always true: some Linux distros would be better handled > like OS X, where we always use UTF-8, regardless of what the locale says. Perhaps by the 3.5 timeframe we can default to utf-8 on all Unix systems? -- _

[issue19846] Python 3 raises Unicode errors with the C locale

2013-12-09 Thread Nick Coghlan
Nick Coghlan added the comment: I confess I didn't independently verify the glib claim in the Stack Overflow post. However, Toshio's post covers the specific error case we were discussing at Flock (and I had misremembered), where the standard streams are classed as "OS APIs" for the purpose of d

[issue19938] Re-enable test_bug_1333982 on 3.x

2013-12-09 Thread Zachary Ware
Changes by Zachary Ware : Added file: http://bugs.python.org/file33070/test_dis_1333982-3.4.diff ___ Python tracker ___ ___ Python-bugs-list m

[issue19938] Re-enable test_bug_1333982 on 3.x

2013-12-09 Thread Zachary Ware
New submission from Zachary Ware: Here's a pair of patches which re-enable test_bug_1333982 in test_dis on 3.3 and 3.4; the major changes in 3.4 necessitate separate patches. The patches also replace test_main with unittest.main which made trying to get the test to work much less annoying. -

[issue19928] Implement cell repr test

2013-12-09 Thread Zachary Ware
Zachary Ware added the comment: Left a comment on Rietveld; mostly LGTM. -- ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue19932] Missing spaces in import.h?

2013-12-09 Thread Ziyuan Lin
Ziyuan Lin added the comment: Yes, although I left out the space after the third PyAPI_FUNC(). -- ___ Python tracker ___ ___ Python-bu

[issue19932] Missing spaces in import.h?

2013-12-09 Thread Roundup Robot
Roundup Robot added the comment: New changeset 7b077c691fef by Victor Stinner in branch '3.3': Issue #19932: Fix typo in import.h, missing whitespaces in function prototypes. http://hg.python.org/cpython/rev/7b077c691fef New changeset e017cd46009a by Victor Stinner in branch 'default': (Merge 3.

[issue16099] robotparser doesn't support request rate and crawl delay parameters

2013-12-09 Thread Nikolay Bogoychev
Nikolay Bogoychev added the comment: Thank you for the review! I have addressed your comments and release a v2 of the patch: Highlights: No longer crashes when provided with malformed crawl-delay/robots.txt parameter. Returns None when parameter is missing or syntax is invalid. Simplified sev

[issue19932] Missing spaces in import.h?

2013-12-09 Thread STINNER Victor
STINNER Victor added the comment: @Ziyuan Lin: The issue should now be fixed, can you please confirm? -- ___ Python tracker ___ ___ Py

[issue19932] Missing spaces in import.h?

2013-12-09 Thread Roundup Robot
Roundup Robot added the comment: New changeset eb1039fe090c by Victor Stinner in branch '2.7': Issue #19932: Fix typo in import.h, missing whitespaces in function prototypes. http://hg.python.org/cpython/rev/eb1039fe090c -- ___ Python tracker

[issue14621] Hash function is not randomized properly

2013-12-09 Thread Nick Coghlan
Nick Coghlan added the comment: This issue has belatedly had a CVE assigned: CVE-2013-7040 ("CPython hash secret can be recovered remotely") 3.4 is not affected (due to PEP 456), but 3.3 and 2.7 are still affected. -- nosy: +bkabrda status: pending -> open versions: +Python 2.7, Python

[issue14621] Hash function is not randomized properly

2013-12-09 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think that's just WONTFIX at this point. -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___

[issue19915] int.bit_at(n) - Accessing a single bit in O(1)

2013-12-09 Thread anon
anon added the comment: Tim, I'm sorry to hear you can't accept my patch. I am afraid I want to stay anonymous. You have my word that I wrote the two code segments above (based on code already in CPython) and that I put them in the public domain. But I appreciate that the word of `anon` may b

[issue16099] robotparser doesn't support request rate and crawl delay parameters

2013-12-09 Thread Nikolay Bogoychev
Nikolay Bogoychev added the comment: Oh... Sorry for the spam, could you please verify my documentation link syntax. I'm not entirely sure I got it right. -- ___ Python tracker

[issue19915] int.bit_at(n) - Accessing a single bit in O(1)

2013-12-09 Thread Tim Peters
Tim Peters added the comment: @anon, not to worry: someone else will write the code. Maybe even me ;-) BTW, "public domain" is not a license. It's the absence of a license. Our lawyers would not accept that even if you had a real name ;-) -- ___

[issue19904] Add 128-bit integer support to struct

2013-12-09 Thread Fil Mackay
Fil Mackay added the comment: So where do we go from here - is there enough support for this to proceed, or vote the idea off the island :) -- ___ Python tracker ___ ___

[issue19932] Missing spaces in import.h?

2013-12-09 Thread Ziyuan Lin
Ziyuan Lin added the comment: I can't build the cpython with Visual Studio 2012 because of the following errors: "D:\Repository\cpython\PCbuild\pcbuild.sln" (default target) (1) -> "D:\Repository\cpython\PCbuild\_msi.vcxproj" (default target) (13) -> (Link target) -> LINK : fatal error LNK11

[issue6143] IDLE - an extension to clear the shell window

2013-12-09 Thread Martin Panter
Changes by Martin Panter : -- nosy: +vadmium ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue19904] Add 128-bit integer support to struct

2013-12-09 Thread Gregory P. Smith
Gregory P. Smith added the comment: Pick two suitable letters for the int128 and uint128 cases and create a patch for an implementation with tests (targeting Python 3.5). The implementation needs to compile and work even when the platform C compiler Python is compiled with does not have a 128

[issue19914] help([object]) returns "Not enough memory." on standard Python types, object and object functions

2013-12-09 Thread HCT
HCT added the comment: verified issue is due to code page was set to 65001, but I set PYTHONIOENCODING to utf-8 (tried UTF-8, utf8, utf-8...etc), so I'm not sure why there is problem with code page 65001 setting code page back to ascii (non-Unicode) fixed the issue. -- __

[issue19851] reload problem with submodule

2013-12-09 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1d67eb1df5a9 by Eric Snow in branch 'default': Issue 19851: Fix a regression in reloading submodules. http://hg.python.org/cpython/rev/1d67eb1df5a9 -- nosy: +python-dev ___ Python tracker

[issue19851] reload problem with submodule

2013-12-09 Thread Eric Snow
Changes by Eric Snow : -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker ___ __

[issue19927] Path-based loaders lack a meaningful __eq__() implementation.

2013-12-09 Thread Eric Snow
Eric Snow added the comment: Good point, Nick. Here's a patch that follows your recommendation on both points. -- Added file: http://bugs.python.org/file33072/issue19927-loader-eq.diff ___ Python tracker

[issue19927] Path-based loaders lack a meaningful __eq__() implementation.

2013-12-09 Thread Eric Snow
Changes by Eric Snow : Removed file: http://bugs.python.org/file33038/issue19927-loader-eq.diff ___ Python tracker ___ ___ Python-bugs-list ma

[issue18864] Implementation for PEP 451 (importlib.machinery.ModuleSpec)

2013-12-09 Thread Eric Snow
Eric Snow added the comment: Here's a patch for adding a setter for ModuleSpec.has_location. -- Added file: http://bugs.python.org/file33073/issue18864-has-location-setter.diff ___ Python tracker __

[issue19933] Round default argument for "ndigits"

2013-12-09 Thread Vajrasky Kok
Vajrasky Kok added the comment: In case we want to add consistency with None ndigits, here is the patch adding support for None value for ndigits parameter. This one looks like a low-risk addition but since Python 3.4 is in beta phase -- Added file: http://bugs.python.org/file330

[issue19939] Deprecate portions or all of pkgutil module.

2013-12-09 Thread Eric Snow
New submission from Eric Snow: In the last Python releases, particularly 3.3 and 3.4, we've made improvements to the import machinery that render (at least) portions of pkgutil obsolete. Here's a breakdown of the public API of pkgutil: get_importer() - duplicate of PathFinder._path_importer_c

[issue19846] Python 3 raises Unicode errors with the C locale

2013-12-09 Thread Martin v . Löwis
Martin v. Löwis added the comment: >From what I read, it appears that the SO posting is plain wrong. Consider, for >example, https://developer.gnome.org/glib/stable/glib-Character-Set-Conversion.html#g-filename-to-utf8 # Converts a string which is in the encoding used by GLib for filenames #

[issue17762] platform.linux_distribution() should honor /etc/os-release

2013-12-09 Thread Vajrasky Kok
Vajrasky Kok added the comment: This patch needs to be updated to tip since this commit: http://hg.python.org/cpython/rev/4580976c07cb -- ___ Python tracker ___

[issue19940] ssl.cert_time_to_seconds() returns wrong results if local timezone is not UTC

2013-12-09 Thread akira
New submission from akira: cert_time_to_seconds() uses `time.mktime()` [1] to convert utc time tuple to seconds since epoch. `mktime()` works with local time. It should use `calendar.timegm()` analog instead. Example from the docs [2] is seven hours off (it shows utc offset of the local timez

[issue19914] help([object]) returns "Not enough memory." on standard Python types, object and object functions

2013-12-09 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- components: +Windows nosy: +brian.curtin, haypo, tim.golden ___ Python tracker ___ ___ Python-bugs-li

[issue19939] Deprecate portions or all of pkgutil module.

2013-12-09 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- nosy: +Arfrever ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue9951] introduce bytes.hex method

2013-12-09 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- nosy: +Arfrever ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

<    1   2