[issue10657] os.lstat/os.stat/os.fstat don't set st_dev (st_rdev) on Windows
New submission from Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp: I noticed st_dev is not set yet. Attached patch fill this value, but sometimes it becomes negative value because dwVolumeSerialNumber is large enough. Maybe st_dev should be declared as unsigned int. # I think this is not new feature. Just bug. So I think # this can go into python3.2. -- components: Windows files: py3k_add_st_dev_and_st_rdev.patch keywords: patch messages: 123673 nosy: ocean-city priority: normal severity: normal status: open title: os.lstat/os.stat/os.fstat don't set st_dev (st_rdev) on Windows versions: Python 3.2, Python 3.3 Added file: http://bugs.python.org/file19984/py3k_add_st_dev_and_st_rdev.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10657 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1571170] Some numeric characters are still not recognized
Anders Chrigström ander...@users.sourceforge.net added the comment: This is indeed a duplicate of #1571184 -- resolution: - duplicate status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1571170 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9927] Leak around GetFinalPathNameByHandle (Windows)
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: This is updated version. Can you test this? (I only fixed leak, deferred other fixes to future) -- Added file: http://bugs.python.org/file19985/py3k_fix_leak_around_GetFinalPathNameByHandle_v2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9927 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9927] Leak around GetFinalPathNameByHandle (Windows)
Changes by Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp: Removed file: http://bugs.python.org/file18979/py3k_fix_leak_around_GetFinalPathNameByHandle.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9927 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10653] test_time test_strptime fails on windows
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: 1. Decoding the output of wcsftime(). Python expects mbcs (which I believe is an UTF16-like wide char encoding) while Windows apparently puts cp932 there in your locale. I don't have expertise to address this issue. No, mbcs is not wide character sets (wchar_t*) but ANSI character sets (char*). In my environment, mbcs == cp932. And python expects UTF-16. 2. strptime() cannot parse strftime() output when strftime('%Z') is different from time.tzname[dst]. (snip) I attached test program to test behavior of strftime and wcsftime on locale. On VC6, strftime doesn't depend on locale, wheres wcsftime changed the value depends on locale. (I tested only C locale and System locale because I could not find other locales working on my environment, so ) If strftime doesn't depend on locale and equals to tzname for every locale, maybe strftime is preferred on windows. # Can somebody test this on VS9? And other locales? -- Added file: http://bugs.python.org/file19986/main.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10653 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10658] Link to source code is broken
New submission from anatoly techtonik techto...@gmail.com: http://docs.python.org/library/queue.html -- assignee: d...@python components: Documentation messages: 123677 nosy: d...@python, techtonik priority: normal severity: normal status: open title: Link to source code is broken versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10658 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10658] Link to source code is broken
Georg Brandl ge...@python.org added the comment: Fixed in r87143. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10658 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10655] Wrong powerpc define in Python/ceval.c
adrian adr...@lisas.de added the comment: Here is a patch that I had to include in my Linux PowerPC build of 2.7 and 3.2 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -31,10 +31,12 @@ typedef unsigned long long uint64; -#if defined(__ppc__) /* - Don't know if this is the correct symbol; this +#if defined(__ppc__) || defined (__powerpc__) /* - Don't know if + this is the correct symbol; this section should work for GCC on any PowerPC platform, irrespective of OS. - POWER? Who knows :-) */ + POWER? Who knows :-) + __powerpc__ is necessary for Linux */ #define READ_TIMESTAMP(var) ppc_getcounter(var) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10655 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10659] Hook scripts for immediate doc build system
New submission from anatoly techtonik techto...@gmail.com: When a new revision is committed to documentation, it will be nice to have hook scripts that start documentation build process on development server. Another hook script may also analyze commit message, extract ticket number, branch and revision from it. Then post a comment with a link to development version of documentation and close the ticket. See how it works on Google Code http://code.google.com/p/support/wiki/IssueTracker#Integration_with_version_control -- assignee: d...@python components: Documentation messages: 123680 nosy: d...@python, techtonik priority: normal severity: normal status: open title: Hook scripts for immediate doc build system ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10659 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9523] Improve dbm modules
Ray.Allen ysj@gmail.com added the comment: Here is the updated patch, which fixed: 1. remove get() method of gdbm since issue6045 has already add it. 2. method keys() and items() of dbm object return set instead of list. Since pep3119 said keys() and items() should return collections.Set and set is a collections.Set. 3. add update() method to dbm object, which follows implementation in collections.MutableMapping.update(). -- Added file: http://bugs.python.org/file19987/issue_9523.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9523 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10516] Add list.clear() and list.copy()
Ray.Allen ysj@gmail.com added the comment: eli, you should also add New in version 3.3 to the doc of the tow new list methods. -- nosy: +ysj.ray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10516 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10659] Hook scripts for immediate doc build system
Georg Brandl ge...@python.org added the comment: The development docs are rebuilt twice a day; that should be enough. As for tracker integration with version control, that is already an issue for the meta tracker at http://psf.upfronthosting.co.za/roundup/meta/issue20 (which you should know, since you commented there.) -- nosy: +georg.brandl resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10659 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10660] format() to lower and uppercase
New submission from Hervé Cauwelier he...@itaapy.com: Hexadecimals can be formatted to lower and uppercase: '{0:x}'.format(123) '7b' '{0:X}'.format(123) '7B' I would like the same thing for strings: '{0.lastname:u} {0.firstname}'.format(user) 'DOE John' I first thought using S for uppercase, but s is not available for lowercase. So I thought about u and l. The alternative is to write: '{0} {1}'.format(user.lastname.upper(), user.firstname) 'DOE John' But I find it less compact and elegant. -- components: Interpreter Core messages: 123684 nosy: Hervé Cauwelier priority: normal severity: normal status: open title: format() to lower and uppercase type: feature request versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10660 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10660] format() to lower and uppercase
R. David Murray rdmur...@bitdance.com added the comment: The format support is written specifically so that it is extensible. You can write your own string subclass that extends the formatting mini-language with whatever features you find useful. There are too many variations on what might be useful with regards to case transformations for this to be a sensible addition to the language itself. Much better that an application create use-case tailored facilities. (Note, by the way, that new features can only go in to 3.3 at this point.) -- nosy: +r.david.murray resolution: - rejected stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10660 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6422] timeit called from within Python should allow autoranging
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10660] format() to lower and uppercase
Eric Smith e...@trueblade.com added the comment: I agree with David. Here's an example of using such a subclass. It extends the format string for strings to begin with an optional 'u' or 'l': --- class U(str): def __format__(self, fmt): if fmt[0] == 'u': s = self.upper() fmt = fmt[1:] elif fmt[0] == 'l': s = self.lower() fmt = fmt[1:] else: s = str(self) return s.__format__(fmt) name = 'Hervé Cauwelier' print('{0:u*^20} {0:l*^20} {0:*^20}'.format(U(name))) --- It produces: **HERVÉ CAUWELIER*** **hervé cauwelier*** **Hervé Cauwelier*** -- nosy: +eric.smith ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10660 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10661] ElementTree QName has a very uninformative repr()
New submission from Jean-Paul Calderone inva...@example.invalid: This is somewhat unfortunate behavior: from xml.etree.ElementTree import QName QName('foo') xml.etree.ElementTree.QName instance at 0x10049c830 It becomes even more apparent when encountered in a situation like this: print {QName('foo'): 'bar', QName('baz'): 'quux'} {xml.etree.ElementTree.QName instance at 0x10049cb90: 'bar', xml.etree.ElementTree.QName instance at 0x10049c248: 'quux'} I would like to see QName.__repr__ return something like 'QName %r' % (text,) -- messages: 123687 nosy: exarkun priority: normal severity: normal status: open title: ElementTree QName has a very uninformative repr() type: behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10661 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10662] Typo in concurrent.futures, seperate
New submission from Christian Oudard christian.oud...@gmail.com: Found the misspelling seperate in two places in the concurrent.futures library module. Patch attached, correcting the spelling to separate. -- files: seperate.patch keywords: patch messages: 123688 nosy: Christian.Oudard priority: normal severity: normal status: open title: Typo in concurrent.futures, seperate versions: Python 3.2 Added file: http://bugs.python.org/file19988/seperate.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10662 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10662] Typo in concurrent.futures, seperate
Georg Brandl ge...@python.org added the comment: Fixed in r87146. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10662 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10661] ElementTree QName has a very uninformative repr()
Georg Brandl ge...@python.org added the comment: Added in r87147. -- nosy: +georg.brandl resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10661 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10661] ElementTree QName has a very uninformative repr()
Eric Smith e...@trueblade.com added the comment: This should be either: 'QName %r' % (self.text,) or: 'QName {!r}'.format(self.text) If self.text is a tuple (which granted is its own error), then the version checked in will raise an exception. -- nosy: +eric.smith resolution: fixed - status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10661 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10661] ElementTree QName has a very uninformative repr()
Georg Brandl ge...@python.org added the comment: Granted. Since the rest of the file uses old-style format, I've kept to it, r87148. -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10661 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7475] codecs missing: base64 bz2 hex zlib hex_codec ...
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: With Georg's approval, I am reopening this issue until a decision is made on whether {str,bytes,bytearray}.{transform,untransform} methods should go into 3.2. I am adding Guido to nosy because the decision may turn on the interpretation of his post. [1] I also started a python-dev thread on this issue. [2] [1] http://mail.python.org/pipermail/python-dev/2010-December/106374.html [2] http://mail.python.org/pipermail/python-dev/2010-December/106617.html -- components: +Unicode nosy: +gvanrossum resolution: fixed - stage: - commit review status: closed - open type: - feature request ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7475 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10453] Add -h/--help option to compileall
R. David Murray rdmur...@bitdance.com added the comment: OK, here is what I hope is a comprehensive set of CLI tests, and fixes for the bugs revealed thereby. Except for the new test added by Georg after the original patch here was committed, all of the tests either pass using the old compileall module or fail only because stderr has resource warnings in it. I did some refactoring on the tests, and since there were few enough original tests I went through and refactored them all. Hopefully that won't make the review more difficult. Note that I have not tested this patch on windows :) -- Added file: http://bugs.python.org/file19989/compileall_cli_revisited.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10453 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10663] configure shouldn't set a default OPT
New submission from Antoine Pitrou pit...@free.fr: The configure.in sets a default OPT of -O if none was set by the user, but I think that's wrong. The user could simply pass optimization flags as part of CFLAGS instead, and then the contents of OPT could conflict with that of CFLAGS (which is annoying to debug when you don't know what is happening exactly). Besides, -O is hardly an useful default value for any compiler. I would advocate trimming down the magic and letting OPT empty/undefined if that's what the user asks for (and expects). What do you think? -- components: Build messages: 123695 nosy: barry, dmalcolm, laca, pitrou priority: normal severity: normal status: open title: configure shouldn't set a default OPT type: behavior versions: Python 2.7, Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10663 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
R. David Murray rdmur...@bitdance.com added the comment: for what it is worth, I am +1 on having completion and history file work by default. The sqlite3 command line does this, for example. I think it is what unix user expect nowadays, and I think it is reasonable. Looking at my home directory, it would appear that the de-facto standard history file name would be .python_history. This is based on .mysql_history, .psql_history, and .sqlite_history, none of which I configured explicitly to support history saving. -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Éric Araujo mer...@netwok.org added the comment: Okay, that’s one question answered. Still to solve: How to bind the right key? (“But perhaps tab isn’t the right key to bind. I think inputrc could set it to something different, perhaps shell rc files too. Is there an API to get this setting, does readline.so already do the right thing, or does it have to be added?”) -- versions: +Python 3.3 -Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Antoine Pitrou pit...@free.fr added the comment: I think TAB is the key expected by most people, so let's make it the default. As for the location, site.py is an adequate one IMO. -- components: +Library (Lib) -Interpreter Core versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10664] xml.sax.expatreader should support namespace prefixes
New submission from Fred L. Drake, Jr. fdr...@acm.org: The xml.sax.expatreader module pre-dates prefix reporting from Expat, and should be modified to support the feature_namespace_prefixes feature instead of complaining that Expat doesn't support prefixes. -- assignee: fdrake components: XML messages: 123699 nosy: fdrake priority: normal severity: normal stage: needs patch status: open title: xml.sax.expatreader should support namespace prefixes type: feature request versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10664 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Update and expand unicodedata module documentation
New submission from Alexander Belopolsky belopol...@users.sourceforge.net: unicodedata module documentation has not been updated to reflect transition to 6.0. Attached patch fixes the version and unicode.org links and starts making the documentation rely less on the unicode.org pages for basic understanding of the provided functionality. I am posting work in progress to solicit feedback on how much of the Unicode Standard information we would want to present here. On of the goals of this patch is to provide a standard reference that can be used throughout the library manual for basic Unicode concepts without sending the reader over to unicode.org. -- assignee: d...@python components: Documentation files: unicodedata-doc.diff keywords: patch messages: 123700 nosy: belopolsky, d...@python priority: normal severity: normal status: open title: Update and expand unicodedata module documentation versions: Python 3.2 Added file: http://bugs.python.org/file19990/unicodedata-doc.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Update and expand unicodedata module documentation
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: -- components: +Unicode ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10666] OS X installer variants have confusing readline differences
New submission from Ned Deily n...@acm.org: 32-bit-only OS X installers build and link to a copy of the GNU readline library for use by the readline module in the standard library. But, the newer 64-bit/32-bit installer variants for 2.7 and 3.2 link to the OS X supplied BSD editline (libedit) library using its GNU readline compatibility interface. This creates a confusing situation for users: depending on which installer variant is used for 2.7 or 3.2, the commands needed to enable things like tab completion. Here's a snippet of what I have in my startup file: import readline import rlcompleter if 'libedit' in readline.__doc__: readline.parse_and_bind(bind ^I rl_complete) else: readline.parse_and_bind(tab: complete) While obviously this can be handled, it seems like an unnecessary burden on users. I think the primary reason for adding the editline support was to make it simpler for developers building their own Pythons. That's not a concern for the installer build. Another concern may have been to avoid shipping a copy of GNU readline which is GPL-licensed. (The installer currently, to the best of my knowledge, does not document in a README or elsewhere that GNU readline is included.) That seems a problem. This disparity also could cause problems elsewhere (see Issue5845). I see two solutions: 1. (trivial) Change the installer to always build and include GNU readline regardless of SDK (today, editline is used with builds using SDK 10.5 or higher). 2. (TBD) Build and link with the open-source version of editline for all installers. In either case, the installer should include license info on included 3rd-party libraries somewhere in the installer README and/or installed files. -- assignee: ronaldoussoren components: Build, Macintosh messages: 123701 nosy: ned.deily, ronaldoussoren priority: high severity: normal stage: needs patch status: open title: OS X installer variants have confusing readline differences type: behavior versions: Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10666 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Ned Deily n...@acm.org added the comment: Keep in bind that there the Python readline module may be linked to either GNU readline or the BSD editline (libedit) library and they have different command strings. Note the warning here: http://docs.python.org/dev/py3k/library/readline.html Here's a snippet of what I have today in my startup file: import rlcompleter if 'libedit' in readline.__doc__: readline.parse_and_bind(bind ^I rl_complete) else: readline.parse_and_bind(tab: complete) See Issue10666 for more details and some possible changes. -- nosy: +ned.deily, ronaldoussoren ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Ned Deily n...@acm.org added the comment: Keep in mind that the Python readline module may be linked to either GNU readline or the BSD editline (libedit) library and they have different command strings. Note the warning here: http://docs.python.org/dev/py3k/library/readline.html Here's a snippet of what I have today in my startup file: import rlcompleter if 'libedit' in readline.__doc__: readline.parse_and_bind(bind ^I rl_complete) else: readline.parse_and_bind(tab: complete) See Issue10666 for more details and some possible changes. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Changes by Ned Deily n...@acm.org: -- Removed message: http://bugs.python.org/msg123702 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Update and expand unicodedata module documentation
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: Added more tables semi-automatically produced from http://www.unicode.org/Public/UNIDATA/PropertyValueAliases.txt -- Added file: http://bugs.python.org/file19991/unicodedata-doc.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Update and expand unicodedata module documentation
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: Removed file: http://bugs.python.org/file19990/unicodedata-doc.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Ned Deily n...@acm.org added the comment: Nosying Martin: any Windows installer concerns? -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10667] collections.Counter object in C
New submission from Justin Peel pee...@gmail.com: I put the Counter's update and __missing__ methods into C code. The rest of the existing methods remain the same. The new Counter is at least 2x-10x (or more) faster for updating depending on the input. I also added a new method, update_fromsubs, which is documented below the timings for updating a Counter. Here are a few examples to demonstrate the speed of the new update function: Counting list(range(100))*100 - Old Counter: 18.6 msec New Counter: 1.43 13x speed-up Counting range(1) - Old Counter: 21.5 msec New Counter: 3.84 msec 5.6x speed-up Counter generator i % 100 for i in range(1) - Old Counter: 36.7 msec New Counter: 17.5 msec 2.1x speed-up and the __missing__ method being in C makes getting missing keys about twice as fast. Also, I added a new method, update_fromsubs, which counts subarrays/substrings of a sequence. This method only works with immutable sequences like tuples, bytes, and unicode objects. The method is of the form update_fromsubs(seq, frame[, step[, lo[, hi]]]) where frame is the size of the subarrays, step is how far to move forward after each subarray, and lo and hi are the respective starting and ending indices to count subarrays within the sequence. For instance, c = Counter() c.update_fromsubs('abcd', 2) yields Counter({'cd': 1, 'ab': 1, 'bc': 1}) and d = Counter() d.update_fromsubs('abcd', 2, 2) yields Counter({'ab': 1, 'cd: 1}) These sorts of operations could be done with generators in a manner like Counter(s[i:i+2] for i in range(0, len(s)-1)) but it can be about twice as fast by using update_fromsubs. Here's an example Counting subarrays of length 2 of ab*1: update_fromsubs:30.8 ms New Counter w/ generator: 54.3 ms Old Counter w/ generator: 98.8 ms This method would probably be most useful in processing strings, but there may be other uses. If it is accepted, please feel to change the method name and parameters. I especially wasn't sure what to call this method (update_fromsubsequences seemed rather long). -- components: Extension Modules, Library (Lib) files: counterpatch.diff keywords: patch messages: 123706 nosy: jpeel, rhettinger priority: normal severity: normal status: open title: collections.Counter object in C type: performance versions: Python 3.3 Added file: http://bugs.python.org/file19992/counterpatch.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10667 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10667] collections.Counter object in C
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Thanks for the patch. FWIW, I'm attaching some timing code that I've used in the past. -- assignee: - rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10667 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10667] collections.Counter object in C
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Added file: http://bugs.python.org/file19993/time_counter.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10667 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Update and expand unicodedata module documentation
Martin v. Löwis mar...@v.loewis.de added the comment: Please, one issue per report and checkin, and no work-in-progress on the tracker. The issue of factually correcting claims about the unicodedata module and elaborations on how it works are unrelated issues. -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5845] rlcompleter should be enabled automatically
Martin v. Löwis mar...@v.loewis.de added the comment: There is no readline support on Windows at all, so I don't think the Windows installer can be affected. I'm uncertain what the proposed change to Python is at this point, though. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5845 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10667] collections.Counter object in C
Antoine Pitrou pit...@free.fr added the comment: When adding some C accelerations, we often try to keep a pure Python alternative in the stdlib, since it can then benefit other Python implementations (and easy prototyping). If you move some of the methods inside a mixin and use multiple inheritance with the base C impl, this should be easy. Also, the unit tests should then test both the C impl and the pure Python impl. -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10667 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6422] timeit called from within Python should allow autoranging
Antoine Pitrou pit...@free.fr added the comment: Not sure why you chose 0.11 here. It should probably be 0.2 as in the command-line code. As for applying the patch, this can't be done before 3.2 is released. -- nosy: +pitrou stage: unit test needed - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10242] unittest's assertItemsEqual() method makes too many assumptions about its input
Gregory P. Smith g...@krypto.org added the comment: I have to agree that the name assertCountEqual does not work well for me as something I can read and really comprehend what it is going to do without searching for the docs or implementation to double check. (not that assertItemsEqual did either). 'Count' does not strongly imply to me that it is expecting sequences or really tell me what it will be testing. Brainstorming based on other suggestions i've seen and some i've made up: assertCountEqual [in 3.2beta1] assertCountsEqual assertElementCountEqual [michael.foord] assertElementCountsEqual assertItemCountEqual assertItemCountsEqual assertItemsEqual [old, agreed to replace this] When it comes down to Item vs Element I do like the sound of Element even though it is longer to type. Should it be singular 'Count' (Dracula?) or plural/possessive 'Counts'? To me assertCountEqual makes me think of the other assertFooEqual methods and wonder what data structure type a Count is. You could argue that calling it assertCounterEqual would make sense in reference to collections.Counter but I do not think that actually ready any more explanatory when reading. I'm sorry that this is a bikeshed. But if we're gonna change the paint color, during the beta is a good time. my problem with assertElementCountEqual is that being singular I could read a statement such as self.assertElementCountEqual(listA, setB) and assume that it is the same as self.assertEqual(len(listA), len(setB)) assertElementCountsEqual by virtue of the mere 's' implies to me that it is not doing a len(listA) but is instead counting up the individual elementS and comparing those counts. So after all this rambling, I think that's my vote. Agree/disagree/indifferent? -- nosy: +gregory.p.smith ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10242 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10273] Clean-up Unittest API
Gregory P. Smith g...@krypto.org added the comment: fyi - since I didn't chime in earlier on this: I think you made the right choice with what was decided in msg122413 and implemented in the renaming done in r86910 and the work done in issue10242. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10273 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10668] Array tests have nonsense in them
New submission from Alex alex.gay...@gmail.com: In ArraySubclassWithKwargs, when __init__ is called it doesn't actually pass self to `array.array.__init__`, this doesn't actually cause errors because the contents of the array isn't tested anywhere. -- components: Library (Lib) messages: 123714 nosy: alex priority: normal severity: normal status: open title: Array tests have nonsense in them versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10668 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10668] Array tests have nonsense in them
R. David Murray rdmur...@bitdance.com added the comment: This class was added by the fix for issue 1486663 in r53509. Adding Georg as nosy since he committed it, but it seems like it would be worth fixing it in case someone else uses the class in an additional test in the future. -- nosy: +georg.brandl, r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10668 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10668] Array tests have nonsense in them
Changes by R. David Murray rdmur...@bitdance.com: -- versions: +Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10668 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10669] Remove Deprecation Warnings
New submission from Rusi rustompm...@gmail.com: I am trying to port some app from 2.x to 3.x Terry Reedy suggested using 2.7 I get deprecation warnings (with -3 flag) I would be good to have a place to check all such and have suggested solutions -- components: 2to3 (2.x to 3.0 conversion tool) messages: 123716 nosy: RusiMody priority: normal severity: normal status: open title: Remove Deprecation Warnings type: feature request versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10669 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10611] sys.exit() in a test causes a test run to die
Ray.Allen ysj@gmail.com added the comment: Agreed. I think the except Exception in TestCase.run() should be except BaseException, since BaseException could catch Exception, SystemExit, GeneratorExit, KeyboardInterrupt. The KeyboardInterrupt should be caught first. The remaining three is exactly what is needed. Here is a patch I worked, with unittest. -- keywords: +patch nosy: +ysj.ray Added file: http://bugs.python.org/file19994/issue_10611.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10611 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10611] sys.exit() in a test causes a test run to die
Éric Araujo mer...@netwok.org added the comment: LGTM. -- stage: unit test needed - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10611 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com