[issue1109] Warning required when calling register() on an ABCMeta subclass

2007-09-05 Thread Mark Summerfield
New submission from Mark Summerfield: GvR asked me to add this to the bug tracker. If you do this: class A(ABCMeta): pass A.register(list) you get this error message: Traceback (most recent call last): File "", line 1, in RuntimeError: maximum recursion depth e

[issue9522] xml.etree.ElementTree forgets the encoding

2010-08-12 Thread Mark Summerfield
Mark Summerfield added the comment: Perhaps a useful compromise would be to add an "encoding" attribute that is set to the encoding of the XML file that's read in (and with a default of "ascii"). That way it would be possible to preserve the encoding, e.g.: import

[issue9522] xml.etree.ElementTree forgets the encoding

2010-08-12 Thread Mark Summerfield
Mark Summerfield added the comment: I don't see how lxml is relevant here? lxml is a third party library, whereas etree is part of the standard library. And according to the 3.1.2 docs etree doesn't have a docinfo (or any other

[issue10926] Some Invalid Relative Imports succeed in Py 3.0 & 3.1 [& correctly fail in 3.2rc1]

2011-01-17 Thread Mark Summerfield
New submission from Mark Summerfield : I'm reporting this at Georg Brandl's suggestion. If you unpack the attached (tiny) tarball you get this directory structure: Graphics/ Graphics/Xpm.py Graphics/Vector/ Graphics/Vector/__init__.py Graphics/Vector/Svg.py Graphics/__init__.py

[issue10926] Some Invalid Relative Imports succeed in Py 3.0 & 3.1 [& correctly fail in 3.2rc1]

2011-01-17 Thread Mark Summerfield
Mark Summerfield added the comment: I just installed 3.1.3 and it does indeed give the import error: Python 3.1.3 (r313:86834, Jan 17 2011, 16:29:46) [GCC 4.4.5] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>&

[issue2851] Eliminate Perl legacy in re flag names

2008-05-14 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: The re module has the following flags (amongst others): re.X == re.VERBOSE re.S == re.DOTALL The short forms of both these flags are clearly taken from Perl, but they don't seem necessary for Python and are confusing since al

[issue2806] Py30a5: Tk Menu Alt-f behaves differently Linux vs Windows

2008-05-15 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: This bug can be worked around by using the more modern style of menu creation. If the program that exhibits the bug has its __init__() replaced as follows it works correctly on both Linux and Windows: def __init__(self,

[issue2913] idlelib/EditorWindow.py uses xrange()

2008-05-19 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: In Py30a5 idlelib/EditorWindow.py line 292 uses xrange() when it should use range(). -- components: IDLE messages: 67060 nosy: mark severity: normal status: open title: idlelib/EditorWindow.py uses xrange() versions: Pyth

[issue2636] Regexp 2.6 (modifications to current re 2.2.2)

2008-05-28 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: AFAIK if you have a regex with named capture groups there is no direct way to relate them to the capture group numbers. You could do (untested; Python 3 syntax): d = {v: k for k, v in match.groupdict()} for i in

[issue2999] Py30a5: str.replace() tiny doc error

2008-05-29 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: >>> help(str.replace) Help on method_descriptor: replace(...) S.replace (old, new[, maxsplit]) -> unicode Return a copy of S with all occurrences of substring old replaced by new. If the optional ar

[issue3000] 2to3 doesn't handle print(whatever); print nor string.* functions

2008-05-29 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Py30a5 2to3 currently does not cope correctly with this: print whatever; print which it converts to: print(whatever); print This is a subtle error since "print" on its own is valid. Nor does it replace the d

[issue2636] Regexp 2.6 (modifications to current re 2.2.2)

2008-06-18 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: [snip] > 13) Implement a grouptuples(...) method as per Mark Summerfield's > suggest on 2008-05-28 09:38. grouptuples would take the same filtering > parameters as the other group* functions, and would return a list of

[issue3140] str.format("{0:n}") poss. bug with setlocale()

2008-06-19 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Python 30b1 >>> import locale >>> locale.setlocale(locale.LC_ALL, "en_US.UTF-8") 'en_US.UTF-8' >>> for x in (1234,12345,123456,1234567,12345678,123456789,1234567

[issue3141] Linux build requires Mac module _gestalt

2008-06-19 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: When you build 30b1 on Linux (I tried Fedora 8 and Xubuntu 8) you get a message that make failed to find the bits to build "_gestalt", which I think is a Mac-thing not a Linux thing. Anyway, Barry asked me to a

[issue3142] urllib docs don't match the new modules

2008-06-19 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Py30b1 The module renaming of urllib's modules (and the getting rid of urllib2) has been done---but this isn't reflected in the docs. -- assignee: georg.brandl components: Documentation messages: 68406 nosy: ge

[issue2636] Regexp 2.6 (modifications to current re 2.2.2)

2008-06-19 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: [snip] It seems to me that both using a special prefix or adding an option are adding a lot of baggage and will increase the learning curve. The nice thing about (3) (even without slicing) is that it seems a v. natural extension.

[issue3175] multiprocessing build fails on Fedora 8 and Xubuntu 8 + solution

2008-06-23 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: I built Python 30b1 from the tarball on Fedora 8 and Xubuntu 8. My only configure switch was --prefix to get a local build. On both systems the only build error I got was: Failed to find the necessary bits to build these m

[issue3198] strings don't seem to roundtrip with repr()

2008-06-25 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: With 2.5.2 and 30b1 strings don't round trip like numbers do. I guess it has been like this a long time so isn't a bug, but it does seem inconsistent. Both 2.5.2 and 30b1: >>> x = 5 >>> x == int(repr(

[issue3252] str.tobytes() and bytes/bytearray.tostr()

2008-07-01 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: I know it is almost certainly too late, but I think a lot of people will be confused by str.decode() and bytes.encode() (or was that the other way around)? Calling the methods str.tobytes() and bytes.tostr() (or nicer, str.to_bytes

[issue3000] 2to3 doesn't handle print(whatever); print nor string.* functions

2008-07-01 Thread Mark Summerfield
Changes by Mark Summerfield <[EMAIL PROTECTED]>: -- type: -> behavior ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3000> ___ ___

[issue2834] re.IGNORECASE not Unicode-ready

2008-07-24 Thread Mark Summerfield
Changes by Mark Summerfield <[EMAIL PROTECTED]>: -- nosy: +mark ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2834> ___ ___ Python

[issue3394] zipfile.writestr doesn't set external attributes, so files are extracted mode 000 on Unix

2008-07-25 Thread Mark Summerfield
Changes by Mark Summerfield <[EMAIL PROTECTED]>: -- nosy: +mark ___ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3394> ___ ___ Python

[issue3598] multiprocessing.Pool windows/linux behaviour difference

2008-08-18 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: When the attached program is run on Linux it runs "instantly" and outputs one line, e.g.: $ python3 mtest.py 100 files, 1702627142 bytes (The number of bytes will vary depending on the system.) When run on Windows XP th

[issue3598] multiprocessing.Pool windows/linux behaviour difference

2008-08-19 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-08-19, Antoine Pitrou wrote: > Antoine Pitrou <[EMAIL PROTECTED]> added the comment: > > For what it's worth, this is documented in > http://docs.python.org/dev/library/multiprocessing.html#windows

[issue2834] re.IGNORECASE not Unicode-ready

2008-08-20 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-08-19, Antoine Pitrou wrote: > Antoine Pitrou <[EMAIL PROTECTED]> added the comment: > > Fixed in r65860. Someone should check the docs though (at least try to > generate them, and review my changes a bi

[issue2834] re.IGNORECASE not Unicode-ready

2008-08-20 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-08-19, Antoine Pitrou wrote: > Antoine Pitrou <[EMAIL PROTECTED]> added the comment: > > Fixed in r65860. Someone should check the docs though (at least try to > generate them, and review my changes a bi

[issue3628] IDLE does not run with Py30b3

2008-08-21 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: When I try to run IDLE in Py30b3 I get a traceback, then the main window appears with an error message box and an OK button; once I click OK, IDLE goes away. $ ~/opt/python30b3/bin/idle Traceback (most recent call last): File &q

[issue3629] Py30b3 won't compile a regex that compiles with 2.5.2 and 30b2

2008-08-21 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Here are the results of running the same tiny program against 2.5.2, 30b2, and 30b3. The program creates a regex and tries to match 3 strings. For 2.5.2 and 30b2 this works fine; for 30b3 the regex won't even compile: $ pytho

[issue3628] IDLE does not run with Py30b3

2008-08-21 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: Just realised how to fix this. Change line 76 in idlelib/run.py: # change this: sockthread.set_daemon(True) # to this: sockthread.daemon = True and IDLE runs fine. ___ Python tracker &

[issue3930] urllib.request.urlopen() different on Windows than Linux

2008-09-22 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Py30rc1 On Windows the file object returned by urllib.request.urlopen() appears to be in binary mode, so .read() returns a bytes object. But on Linux it appears to be in text mode, so .read() returns a str object. It seeems to m

[issue3930] urllib.request.urlopen() different on Windows than Linux

2008-09-22 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: Sorry, I now can't reproduce it. I made a tiny test script and it worked fine on both Windows and Linux. Now when I run the real test that works fine too. So could you close/remove this "bug" for me please? #!/usr/b

[issue3955] maybe doctest doesn't understand unicode_literals?

2008-09-24 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: # This program works fine with Python 2.5 and 2.6: def f(): """ >>> f() 'xyz' """ return "xyz" if __name__ == "__main__": import doctest

[issue8557] subprocess portability issue

2010-04-28 Thread Mark Summerfield
Mark Summerfield added the comment: IMO there's another problem with subprocess portablity---the lack of control over encodings: see issue 6135. -- nosy: +mark ___ Python tracker <http://bugs.python.org/i

[issue1109] Warning required when calling register() on an ABCMeta subclass

2007-11-30 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-11-30, Christian Heimes wrote: > Christian Heimes added the comment: > > Fixed in r59233. Please adjust the error message if you don't like it. > > TypeError: register() cannot be called on an ABCMeta subclass, use class > Exampl

[issue1585] IDLE uses non-existent xrange() function (Py30a2)

2007-12-11 Thread Mark Summerfield
New submission from Mark Summerfield: When I start IDLE I get this: Python 3.0a2 (r30a2:59382, Dec 10 2007, 14:21:37) [GCC 4.1.2 20070626 (Red Hat 4.1.2-13)] on linux2 Type "copyright", "credits" or "licens

[issue1585] IDLE uses non-existent xrange() function (Py30a2)

2007-12-11 Thread Mark Summerfield
Mark Summerfield added the comment: Amaury Forgeot d'Arc says he's fixed this in change 59456 (but I don't know how---or if---I can change its status). __ Tracker <[EMAIL PROTECTED]> <http://b

[issue1586] IDLE no longer shows colour syntax highlighting in the Shell (Py30a2)

2007-12-11 Thread Mark Summerfield
New submission from Mark Summerfield: When I do: import sys; dir(sys) everything is shown in plain black & white, but in the IDLE that came with Py30a1 color syntax highlighting is used. -- components: IDLE messages: 58423 nosy: mark severity: minor status: open title: IDL

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2007-12-11 Thread Mark Summerfield
New submission from Mark Summerfield: >>> x = complex(1, 2/3) >>> "{0} {0:.5}".format(x) '(1+0.6667j) (1+0.' The complex number is being formatted as if it were a string and simply truncated to 5 characters. I would expect each part of the complex n

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2007-12-11 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-11, Guido van Rossum wrote: > Guido van Rossum added the comment: > > This really is a feature request -- in Python 2.x there is no formatting > code for complex numbers at all, and "%.5s" % complex(...) does the same > t

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2007-12-12 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-11, Guido van Rossum wrote: > Guido van Rossum added the comment: > > This really is a feature request -- in Python 2.x there is no formatting > code for complex numbers at all, and "%.5s" % complex(...) does the same > th

[issue1601] IDLE not working correctly on Windows (Py30a2/IDLE30a1)

2007-12-12 Thread Mark Summerfield
New submission from Mark Summerfield: (1) IDLE starts up on Windows OK, but if I press Alt+F the file menu comes up giant sized (i.e., each menu entry is almost as tall as the screen). (2) If I open a file using Ctrl+O, the Open dialog pops up fine, but when I select a file and click Open, IDLE

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-12 Thread Mark Summerfield
New submission from Mark Summerfield: I don't know if this is a bug, but it is certainly a difference in behavior between platforms: Python 3.0a2 on linux2: >>> "{0:.3e}".format(123.45678901) '1.235e+02' Python 3.0a2 on win32: >>> "{0:.3e}&qu

[issue1602] windows console doesn't print utf8 (Py30a2)

2007-12-12 Thread Mark Summerfield
New submission from Mark Summerfield: I am not sure if this is a Python bug or simply a limitation of cmd.exe. I am using Windows XP Home. I run cmd.exe with the /u option and I have set my console font to "Lucida Console" (the only TrueType font offered), and I run chcp 65001 to se

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-12 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-12, Guido van Rossum wrote: > Guido van Rossum added the comment: > > Again, a (not unreasonable) feature request. AFAIK %e behaves the same > way. I'm sure if you submitted a patch it would be accepted happily. Unfortunately, I

[issue1612] infinite recursion when using collections.Sequence in a recursive function (Py30a2)

2007-12-13 Thread Mark Summerfield
New submission from Mark Summerfield: In the attached file there are two tiny functions, flatten1() and flatten2(). There is only one difference between them: flatten1() has the line: if isinstance(x, list): and flatten2() has this line instead: if isinstance(x, collections.Sequence

[issue1602] windows console doesn't print utf8 (Py30a2)

2007-12-14 Thread Mark Summerfield
Mark Summerfield added the comment: I've looked into this a bit more, and from what I can see, code page 65001 just doesn't work---so it is a Windows problem not a Python problem. A possible solution might be to read/write UTF16 which "managed" Windows

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-15 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-15, Christian Heimes wrote: > Christian Heimes added the comment: > > Guido is right. On Linux the system's sprintf() family prints %e, %g and > %f with two or three digits while Windows always uses three digits: > >

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-16 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-15, Christian Heimes wrote: > Christian Heimes added the comment: > > Mark Summerfield wrote: > > It seems to me that Python should provide consistent results across > > platforms wherever possible and that this is a gra

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-16 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-15, Christian Heimes wrote: > Christian Heimes added the comment: > > Mark Summerfield wrote: > > It seems to me that Python should provide consistent results across > > platforms wherever possible and that this is a gra

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-17 Thread Mark Summerfield
Mark Summerfield added the comment: Attached is new version of test_float.py with a few tests to check str.format() with exponents formats, plus a diff. They test that the exponent is always 3 digits and that the case of the e in the format is respected. Added file: http://bugs.python.org

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-17 Thread Mark Summerfield
Mark Summerfield added the comment: My C is rusty! Attached is new pystrtod.c & diff, this time using memset() instead of looping to padd with zeros. Added file: http://bugs.python.org/file8971/pystrtod.c Added file: http://bugs.python.org/file8972/pystrtod.

[issue1600] str.format() produces different output on different platforms (Py30a2)

2007-12-18 Thread Mark Summerfield
Mark Summerfield added the comment: On 2007-12-17, Christian Heimes wrote: > Christian Heimes added the comment: > > Hi Mark! > > In general the patch is fine but it has some small issues. > > * Your patches are all reversed. They remove (-) the new lines instead > of add

[issue1920] while else loop seems to behave incorrectly

2008-01-24 Thread Mark Summerfield
New submission from Mark Summerfield: I am using: Python 3.0a2 (r30a2:59382, Dec 17 2007, 08:47:22) [GCC 4.1.2 20070626 (Red Hat 4.1.2-13)] on linux2 IDLE 3.0a1 This seems wrong: >>> while False: print("no") else: print("yes") >

[issue1600] str.format() produces different output on different platforms (Py30a2)

2008-02-18 Thread Mark Summerfield
Mark Summerfield added the comment: On 2008-02-18, Mark Dickinson wrote: > Mark Dickinson added the comment: > > I know I'm coming a bit late to this discussion, but I wanted to point > out that the C99 standard does actually specify how many digits should > be in t

[issue2219] Py30a3: Possibly confusing message when module detection fails

2008-03-03 Thread Mark Summerfield
New submission from Mark Summerfield: On Fedora 8 I get this message: Failed to find the necessary bits to build these modules: _bsddb To find the necessary bits, look in setup.py in detect_modules() for the module's name. On Kubuntu 6.06 LTS I get the same message, but about different mo

[issue2219] Py30a3: Possibly confusing message when module detection fails

2008-03-03 Thread Mark Summerfield
Mark Summerfield added the comment: On 2008-03-03, Martin v. Löwis wrote: > Martin v. Löwis added the comment: > > Modules/Setup is out of date; _bsddb supports anything between 3.3 and 4.5. > FYI, only now I've just realised that Fedora 8's db version is 4.6.21, but I tho

[issue2219] Py30a3: Possibly confusing message when module detection fails

2008-03-03 Thread Mark Summerfield
Mark Summerfield added the comment: On 2008-03-03, Martin v. Löwis wrote: > Martin v. Löwis added the comment: > > Rereading your report, I cannot quite understand what issue specifically > you are reporting. What error message do you find confusing, and what do > you think should

[issue2221] Py30a3: calltip produces error output to stderr

2008-03-03 Thread Mark Summerfield
New submission from Mark Summerfield: In IDLE for Py30a3 if you enter: >>> class A( as soon as you type the ( you get the following output to stderr (on Fedora 8 with Tcl/Tk 8.4): : *** Internal Error: rpc.py:SocketIO.localcall() Object: exec Method: > Args: ('A',)

[issue2219] Py30a3: Possibly confusing message when module detection fails

2008-03-03 Thread Mark Summerfield
Mark Summerfield added the comment: On 2008-03-03, Martin v. Löwis wrote: > Martin v. Löwis added the comment: > > What I find confusing is: > > > > Failed to find the necessary bits to build these modules: > > > > To find the necessary bits, look in set

[issue2278] [Py30a3] xml.parsers.expat recognizes encoding="utf-8" but not encoding="utf8"

2008-03-12 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: Here is how to reproduce the bug: from xml.etree.ElementTree import parse import io xml1 = """ text""" xml2 = """ text""" f1 = io.StringIO(xml1) f2 = io.StringIO(xml2) tre

[issue2283] lambda *a, **k: a, k # does not work

2008-03-13 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: According to the docs lambda can handle the same parameter list as can def. But this does not appear to be the case as the following (both 2.5.1 and 30a3) shows: >>> def f(*a, **kw): return a, kw >>> f(1,2,a=3,b

[issue2283] lambda *a, **k: a, k # does not work

2008-03-13 Thread Mark Summerfield
Changes by Mark Summerfield <[EMAIL PROTECTED]>: -- type: -> behavior __ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2283> __ ___ Python-b

[issue2278] [Py30a3] xml.parsers.expat recognizes encoding="utf-8" but not encoding="utf8"

2008-03-13 Thread Mark Summerfield
Changes by Mark Summerfield <[EMAIL PROTECTED]>: -- components: +Library (Lib), XML type: -> behavior __ Tracker <[EMAIL PROTECTED]> <http://bugs.py

[issue2283] lambda *a, **k: a, k # does not work

2008-03-13 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-03-13, Imri Goldberg wrote: > Imri Goldberg <[EMAIL PROTECTED]> added the comment: > > This is not a bug, just missing parenthesis. > > >>> lambda x: x,x > > Traceback (most recent call l

[issue2278] [Py30a3] xml.parsers.expat recognizes encoding="utf-8" but not encoding="utf8"

2008-03-15 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: You're right that the parser should not recognise "utf8" since it isn't correct XML (as per the references you gave). I made the mistake because I used the etree module and wrote an XML file with encoding "u

[issue2219] Py30a3: Possibly confusing message when module detection fails

2008-03-20 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-03-20, Sean Reifschneider wrote: > Sean Reifschneider <[EMAIL PROTECTED]> added the comment: > > Don't modify Modules/Setup*, do as the message says and modify setup.py. > Search for "4, 5&quo

[issue2494] Can't round-trip datetimes<->timestamps prior to 1970 on Windows

2008-03-27 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: # If you run the code below on Py30a3 you get the output shown at the end import calendar, datetime, time pastdate = datetime.datetime(1969, 12, 31) print(pastdate) timestamp = calendar.timegm(pastdate.utctimetuple()) print(tim

[issue2501] xml.sax.parser() doesn't terminate when given a filename

2008-03-28 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: The tiny program at the end of this message runs under Python 2.5 & 30a3. Under 2 it gives the following output: : python sax.py test.xml ('+', u'document') ('+', u'outer') ('+'

[issue2526] str.format() :n format does not appear to work

2008-04-01 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: >>> # Py30a3 >>> import locale >>> locale.setlocale(locale.LC_ALL, "en_US.UTF8") 'en_US.UTF8' >>> locale.format("%d", 12345, True) '12,345' >>>

[issue2547] Py30a4 RELNOTES only cover 30a1 and 30a2

2008-04-03 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: The 30a4 RELNOTES file doesn't cover 30a3 or 30a4. -- assignee: georg.brandl components: Documentation messages: 64918 nosy: georg.brandl, mark severity: normal status: open title: Py30a4 RELNOTES only cover 30a1 an

[issue2606] trace module crashes due to using wrong sort idiom

2008-04-10 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: In Py30a4's trace.py there is this: calls = self.calledfuncs.keys() calls.sort() which causes: AttributeError: 'dict_keys' object has no attribute 'sort' There are two other occurrences

[issue2613] inconsistency with bare * in parameter list

2008-04-11 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: A bare * in a parameter list behaves differently depending on what follows it: Py30a4: >>> def f(*, a=1, b=2): return 1 >>> def g(*, **kwargs): return 1 SyntaxError: named arguments must follow bare * (, line

[issue2649] poss. patch for fnmatch.py to add {.htm, html} style globbing

2008-04-17 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: At the moment fnmatch.py (and therefore glob.py) support: * . [chars] [!chars] The attached version of fnmatch.py extends this to: * . [chars] [!chars] {one,two,...} There are 2 changes from the original fnmatch.py file: (

[issue2801] Py30a5 float.is_integer() raises ValueError

2008-05-09 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: The new method float.is_integer() introduced in Py30a5 behaves unexpectedly: >>> x = 5.0 >>> x.as_integer_ratio() (5, 1) >>> x.is_integer() Traceback (most recent call last): File "", lin

[issue2802] str.format() :n integer output

2008-05-09 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: In Py30a5 the 'n' format option is not v. useful for integers: >>> for x in range(8): print("{0:n} ".format(10**x), end="") 1 10 100 1,000 10,000 100,000 1e+06 1e+07 This is

[issue2801] Py30a5 float.is_integer() raises ValueError

2008-05-09 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-05-09, Mark Dickinson wrote: > Mark Dickinson <[EMAIL PROTECTED]> added the comment: > > Is this on Windows? I can't reproduce it on OS X 10.5.2: > > Python 3.0a5+ (py3k:62937M, May 9 2008, 09:32:27

[issue2802] str.format() :n integer output

2008-05-09 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-05-09, Mark Dickinson wrote: > Mark Dickinson <[EMAIL PROTECTED]> added the comment: > > I think that n should stay the same for floats, but for integers should > > never switch to g, but just use as many

[issue2801] Py30a5 float.is_integer() raises ValueError

2008-05-09 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: OK, I've just built against your fix and it works fine now! Python 3.0a5+ (py3k:60668:62940, May 9 2008, 15:48:15) [GCC 4.1.2 20070925 (Red Hat 4.1.2-33)] on linux2 Type "help", "copyright", "credit

[issue2802] str.format() :n integer output

2008-05-09 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-05-09, Eric Smith wrote: > Eric Smith <[EMAIL PROTECTED]> added the comment: > > The reason for this is that 'n' is defined in PEP 3101 as being a float > format only, and the rule is that if

[issue1733134] sqlite3.dll cannot be relocated

2008-05-09 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: Unfortunately, this bug appears to affect Py30a5 too (at least on Win XP Home): Python 3.0a5 (py3k:62932M, May 9 2008, 16:23:11) [MSC v.1500 32 bit (Intel)] on win32 IDLE 3.0a5 >>> import sqlite3 Traceback (most r

[issue2806] Py30a5: Tk Menu Alt-f behaves differently Linux vs Windows

2008-05-09 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: #Python 3.0a5 (py3k:62932M, May 9 2008, 16:23:11) [MSC v.1500 32 bit #(Intel)] on win32 # # If you run this tiny program on Linux and press Alt+F (Alt-f in Tk # terminology) the File menu pops up as expected. But run it on # W

[issue2835] Py30a5: webbrowser.open() inf recursion

2008-05-12 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: There appears to be an infinite recursion in Py30a5 (doing the same thing in Py2.5.1 works fine): Python 3.0a5 (r30a5:62856, May 9 2008, 11:23:06) [GCC 4.1.2 20070925 (Red Hat 4.1.2-33)] on linux2 Type "copyright&quo

[issue2835] Py30a5: webbrowser.open() inf recursion

2008-05-12 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: I get the same bug on Fedora 8 (Python build 63161) and Kubuntu 8 (official Py30a5 release)---but not on Windows XP Home where the URL is opened correctly. Python 3.0a5+ (py3k:60668:63161, May 12 2008, 14:46:40) [GCC 4.1.2 2007092

[issue2835] Py30a5: webbrowser.open() inf recursion

2008-05-12 Thread Mark Summerfield
Mark Summerfield <[EMAIL PROTECTED]> added the comment: On 2008-05-12, Amaury Forgeot d'Arc wrote: > Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: > > The traceback suggest a problem when using KDE: a call to file() was > renamed to open(),

[issue4630] IDLE no longer respects .Xdefaults insertOffTime

2008-12-11 Thread Mark Summerfield
New submission from Mark Summerfield <[EMAIL PROTECTED]>: IDLE's cursor blinks with Python 3.0 on Linux. But it shouldn't (and doesn't for prior versions) because in my .Xdefaults file I have the line: *insertOffTime: 0 Now I have to manually edit idlelib/EditorWindow.

[issue4630] IDLE no longer respects .Xdefaults insertOffTime

2008-12-13 Thread Mark Summerfield
Mark Summerfield added the comment: Although I stand by my criticism of IDLE not offering the option of switching off cursor blink, I've now discovered that the problem was with Fedora 10 no longer executing xrdb .Xdefaults; once I added that line to my .bash_profile the cursor blinking st

[issue45480] Missing link(s) to the "Python Module Index" page

2021-10-15 Thread Mark Summerfield
New submission from Mark Summerfield : I mostly use the Python 3.8 docs since that's the Python I use. However, when I tried using the 3.9 and 3.10 docs I found that the top of each page has a long search bar (presumably for mobile devices?) but _no_ link to the python module index. I

[issue41765] XFCE task switcher shows 'Tk' insteadl of Window title

2020-09-11 Thread Mark Summerfield
New submission from Mark Summerfield : This tiny test application illustrates the problem: ```python #!/usr/bin/env python3 import tkinter as tk app = tk.Tk() app.withdraw() app.title('Test App') app.deiconify() app.mainloop() ``` When run on Linux with XFCE the task bar entry show

[issue41765] XFCE task switcher shows 'Tk' insteadl of Window title

2020-09-12 Thread Mark Summerfield
Mark Summerfield added the comment: I just ran IDLE and it seems to have the same problem. Although the taskbar entry is 'Python 3.6.9 Shell' (ought really to be 'IDLE'), when context switching the switcher shows the correct icon but

[issue41765] XFCE task switcher shows 'Tk' insteadl of Window title

2020-09-12 Thread Mark Summerfield
Mark Summerfield added the comment: Same applied to IDLE for Python 3.8 -- ___ Python tracker <https://bugs.python.org/issue41765> ___ ___ Python-bugs-list m

[issue4198] os.path.normcase gets fooled on windows with mapped linux network drive

2019-06-17 Thread Mark Summerfield
Mark Summerfield added the comment: When running a VirtualBox Windows 7 guest on Linux I have found that os.path.samefile() returns False when the filenames are the same, e.g., f = r'V:\pdfs\boson1.pdf' same = os.path.samefile(f, f) print(same) # expected True; got False I menti

[issue15133] tkinter.BooleanVar.get() docstring is wrong

2012-06-22 Thread Mark Summerfield
New submission from Mark Summerfield : Python 3.2.2 (default, Jun 4 2012, 11:15:16) [GCC 4.4.5] on linux2 Type "copyright", "credits" or "license()" for more information. >>> from tkinter import * >>> help(BooleanVar.get) Help on function get in

[issue15133] tkinter.BooleanVar.get() behavior and docstring disagree

2012-06-23 Thread Mark Summerfield
Mark Summerfield added the comment: Did you mean formal test code? Or just an example like this: from tkinter import * tk = Tk() bv = BooleanVar() print(bv.get(), type(bv.get())) bv.set(True) print(bv.get(), type(bv.get())) bv.set(False) print(bv.get(), type(bv.get())) ### output ### 0 1 0

[issue15133] tkinter.BooleanVar.get() behavior and docstring disagree

2012-06-24 Thread Mark Summerfield
Mark Summerfield added the comment: I think that BooleanVar.set(x) should do bool(x) on its argument (and raise an exception if this isn't valid) and BooleanVar.get() should return a bool. Similarly I think that IntVar.set(x) should do int(x) and IntVar.get() should return an int, and

[issue15133] tkinter.BooleanVar.get() behavior and docstring disagree

2012-06-24 Thread Mark Summerfield
Mark Summerfield added the comment: Oh, and I forgot to say that I think StringVar.set(x) should do str(x) and StringVar.get() should return a str. -- ___ Python tracker <http://bugs.python.org/issue15

[issue15133] tkinter.BooleanVar.get() behavior and docstring disagree

2012-06-24 Thread Mark Summerfield
Mark Summerfield added the comment: How about a compromise? Deprecate (but keep BooleanVar) and add BoolVar with proper True/False behavior to match the other *Vars? -- ___ Python tracker <http://bugs.python.org/issue15

[issue15189] tkinter.messagebox does not use the application's icon

2012-06-26 Thread Mark Summerfield
New submission from Mark Summerfield : The tkinter.messagebox functions, e.g., askyesno(), do not use the application's icon (if it has one). Nor do they accept a bitmapicon option, so ISTM that it is "impossible" to set one. The same is true of tkinter.dialog, but for that it

[issue15191] tkinter convenience dialogs don't use themed widgets

2012-06-26 Thread Mark Summerfield
New submission from Mark Summerfield : Some of the tkinter convenience dialogs, e.g., tkinter.filedialog.FileDialog, tkinter.scrolledtext.ScrolledText, tkinter.simpledialog.SimpleDialog, tkinter.simpledialog.Dialog, and tkinter.simpledialog._QueryDialog. Ideally they should use ttk.Frame

[issue15189] tkinter.messagebox does not use the application's icon

2012-07-09 Thread Mark Summerfield
Mark Summerfield added the comment: On Linux & Windows every top-level window (including dialogs) normally has an icon at the left of the title bar. Typically this icon is the application's icon. But tkinter doesn't provide such an icon and so a system default icon is used inst

[issue3405] Add support for the new data option supported by event generate (Tk 8.5)

2012-07-11 Thread Mark Summerfield
Mark Summerfield added the comment: According to the Tcl/Tk docs the 'data' field is a string (i.e., for any user data) and the 'detail' field contains some internal data (so shouldn't be messed with); see http://www.tcl.tk/man/tcl8.5/TkCmd/event.htm#M16 Anyway, I

  1   2   >