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
Mark Summerfield added the comment:
Same applied to IDLE for Python 3.8
--
___
Python tracker
<https://bugs.python.org/issue41765>
___
___
Python-bugs-list m
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
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
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
New submission from Mark Summerfield:
This document is v. useful for Windows Python users:
https://docs.python.org/dev/using/windows.html
However, I think it could be improved as follows:
(1) Explain which Python installer to get (since there are so many)! Even a
"get the Window
Mark Summerfield added the comment:
Sorry, I didn't even know that pyw.exe existed. Naturally pyw -h produces no
output, but maybe py -h could mention it?
--
___
Python tracker
<http://bugs.python.org/is
New submission from Mark Summerfield:
The excellent py.exe launcher on Windows always uses a python.exe interpreter
(although another issue suggests it will use pythonw.exe when the python file
has a .pyw suffix which is good).
However, if one wanted to provide a .bat file like this:
@echo
New submission from Mark Summerfield:
In the docs for the array module:
https://docs.python.org/dev/library/array.html#module-array
Note 1 in the table of type codes says that the 'u' type is deprecated and will
go in Python 4.0.
Since the array.fromunicode() and array.tounicode
Mark Summerfield added the comment:
Thanks for looking at this. In my full translation dict I had some other
mistakes of case, now all fixed:-)
--
___
Python tracker
<http://bugs.python.org/issue26
New submission from Mark Summerfield:
I am using Python 3.4.3 on Xubuntu 14.04 LTS 64-bit.
I have a program that when run repeatedly sometimes what I expect, and
sometimes does not:
$ ~/tmp/normbug.py
OK ('The AEnid oevre', '==', 'The AEnid oevre')
$ ~/tmp/no
Mark Summerfield added the comment:
Thanks Davin. I have indeed moved to 3.4 which does not seem to have the bug.
(I can't move to 3.5 because I can't install 32- and 64-bit versions as I can
with 3.4 due to the new installers -- or rather I can, but this confuses the
pywin3
Mark Summerfield added the comment:
No, I'm sorry I haven't tried with 3.5; in fact, there doesn't seem to be a
cx_Freeze available for 3.5 yet.
--
___
Python tracker
<http://bugs.pyt
Mark Summerfield added the comment:
I think the str.casefold() docs are fine as far as they go, rightly covering
what it _does_ rather than _how_, yet providing a reference for the details.
But what they lack is more complete information. For example I discovered this:
>>> x =
Mark Summerfield added the comment:
I've now signed the contributor agreement.
However, with Python 3.4 I don't seem to get the same problem anymore even
though there are a few places in the code where sys.std{err,out} are used
without if ... is not N
Changes by Mark Summerfield :
--
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue20366>
___
___
Python-bugs-list mailing list
Unsubscrib
Mark Summerfield added the comment:
Nice answer Ethan (but I can't vote you up since stack overflow won't let me
vote or even comment anymore).
As for adding export_to(), it seems like a good idea. However, personally, I
think the signature should be
hoist_into(namespace, c
Changes by Mark Summerfield :
--
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue23292>
___
___
Python-bugs-list mailing list
Unsubscrib
Mark Summerfield added the comment:
Since this is a bit controversial, I've tried marking it as 'rejected' with
this comment.
I've also added a very brief explanation and link back to here on my web site:
http://www.qtrac.eu/pyenum.html
--
reso
Mark Summerfield added the comment:
Georg said to assign this to Ethan Furman but I don't seem to have that
facility.
--
___
Python tracker
<http://bugs.python.org/is
New submission from Mark Summerfield:
I think it would be worth documenting
globals().update(MyEnumeration.__members__) in the "Interesting
Examples" section of the enum docs.
I suspect that most people will find that importing enums is annoying
because they'll get
Mark Summerfield added the comment:
Since this is closed I've created a new issue as requested:
http://bugs.python.org/issue23037
--
___
Python tracker
<http://bugs.python.org/is
New submission from Mark Summerfield:
In message
http://bugs.python.org/issue17914#msg188626
Victor Stenner says
"On Windows, GetSystemInfo() is called instead of reading an environment
variable. I suppose that this function is more reliable."
>From my reading, and based on feed
Mark Summerfield added the comment:
In message
http://bugs.python.org/issue17914#msg188626
Victor Stenner says
"On Windows, GetSystemInfo() is called instead of reading an environment
variable. I suppose that this function is more reliable."
>From my reading, and based on feedbac
Mark Summerfield added the comment:
I've notified APSW's author and I'm sure he'll fix it. Thanks!
--
___
Python tracker
<http://bug
Mark Summerfield added the comment:
Here are the flags you asked for:
$ icu-config --cppflags
-D_FORTIFY_SOURCE=2 -D_REENTRANT -I/usr/include
$ icu-config --ldflags
-Wl,-z,relro -ldl -lm -L/usr/lib/x86_64-linux-gnu -licui18n -licuuc
-licudata -ldl -lm
Mark Summerfield added the comment:
The first person I asked was the author of APSW (Roger Binns). He told me:
"The ultimate cause of that is some interaction with the compilation
environment. Some sort of CFLAGS is ultimately ending up in some
Python code like above when it shou
New submission from Mark Summerfield:
When I try to build APSW (http://rogerbinns.github.io/apsw/index.html) with
Python 3.3 or 3.4 on Debian stable 64-bit I get the error output shown below.
I dug into the source and it seems that the problem is that
distutils/ccompiler.py
Mark Summerfield added the comment:
I'd be happy to draft a PEP if it is needed, if no one else has the
time/inclination.
--
___
Python tracker
<http://bugs.python.org/is
Mark Summerfield added the comment:
I changed my suggestion but did so on the mailing list instead of here:
This (importing & using types.SimpleNamespace()) is too much for children (&
beginners).
But perhaps what I should be asking for is for a new built-in that d
Mark Summerfield added the comment:
Ah, we're slightly at cross purposes. I showed them purely in terms of the
procedural API. However, I can see now that I could have begun with:
import turtle
...
jane = turtle.Turtle()
jane.fd(100)
So, to "teach" their turtle how to go in a
New submission from Mark Summerfield:
Right now object() does not accept any args and returns the lightest possible
featureless object (i.e., without even a __dict__).
This is great.
However, it is really useful sometimes to be able to create an object to hold
some editable state (so not a
New submission from Mark Summerfield:
The turtle module is aimed primarily at young beginners to Python. Making them
type turtle.this and turtle.that all over the place is tedious and unhelpful.
At the start of the turtle docs there's a nice example that begins
from turtle import *
an
New submission from Mark Summerfield:
On Windows IDLE's working directory is Python's install directory, e.g.,
C:\Python34. ISTM that this is the wrong directory for 99% of general users and
for 100% of beginners since this is _not_ the directory where people should
save their own
Mark Summerfield added the comment:
I used pip to install the win_unicode_console package on windows 7 python 3.3.
It works but wouldn't freeze with cx_freeze because there's no __init__.py file
in the win_unicode_console directory.
--
Mark Summerfield added the comment:
Just to mention that I don't need this feature anymore since I've now switched
to using APSW which includes it and also has much fuller SQLite support than
the sqlighe3 module. (I haven't closed it though since other people have
participa
Mark Summerfield added the comment:
My change to managers.py is redundant; sorry about that.
--
___
Python tracker
<http://bugs.python.org/issue20607>
___
___
New submission from Mark Summerfield:
I have a Python Windows GUI application (using PySide) that uses
multiprocessing.
When I freeze the application I get error messages, in particular that
mulitprocessing cannot call flush on a null object.
ISTM That in a Windows GUI application
New submission from Mark Summerfield:
This is a feature request that future versions of SQLite 3 that are bundled
with Python 3 in the Windows binary packages (.msi files) has been build with
the FTS4 (full text search version 4) enabled.
--
components: Extension Modules
messages
New submission from Mark Summerfield :
I tried installing CherryPy into my local Python 3.2 build. I don't know if
this is a problem with CherryPy's setup.py or with distribute but suspect the
latter since I've had similar problems before.
$ /home/mark/opt/python32/bin/p
Mark Summerfield added the comment:
I think there is a solution to this that can be applied in one's own code:
app = tkinter.Tk()
icon = tkinter.PhotoImage(file="icon.gif")
app.tk.call("wm", "iconphoto", app, "-default", icon)
According to the docs
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
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
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
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
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
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
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
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
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
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.
>>&
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
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
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
New submission from Mark Summerfield :
If you read in an XML file that specifies its encoding and then later on use
xml.etree.ElementTree.write(), it is always written using US-ASCII.
I think the behaviour should be different:
(1) If the XML that was read included an encoding, that encoding
New submission from Mark Summerfield :
If you read in an XML file using xml.etree.ElementTree.parse() and then write
it out again using xml.etree.ElementTree.write() what is written may not be the
same as what was read. In particular any XML declaration and processing
instructions are
Mark Summerfield added the comment:
I was wrong about r"(?.*)". It is valid in the new engine. And the PyPI
docs do say so immediately _following_ the example.
I've tried all the examples in "Programming in Python 3 second edition" using
"import re
Mark Summerfield added the comment:
If you do:
>>> import regex as re
>>> dir(re)
you get over 160 items, many of which begin with an underscore and so are
private. Couldn't __dir__ be reimplemented to eliminate them. (I know that the
current re module's dir(
Mark Summerfield added the comment:
On the PyPI page:
http://pypi.python.org/pypi/regex/0.1.20100706.1
in the "Subscripting for groups" bullet it gives this pattern:
r"(?.*?)(?\\d+)(?.*)"
Shouldn't this be:
r"(?P.*?)(?P\\d+)(?P.*)"
New submission from Mark Summerfield :
It appears that br"" (raw bytes) isn't documented, at least not along with
string and bytes literals:
http://docs.python.org/py3k/reference/lexical_analysis.html#literals
Yet they are supported:
http://mail.python.org/pipermail/python-
New submission from Mark Summerfield :
The argparse module's ArgumentParser class has an error() method that appears
to have the same behavior as the optparse error() method, but this method is
not mentioned in the documentation.
--
assignee: d...@python
components: Document
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
Mark Summerfield added the comment:
On Thu, Dec 31, 2009 at 1:30 PM, Amaury Forgeot d'Arc
wrote:
>
> Amaury Forgeot d'Arc added the comment:
>
> I don't understand. How is the subprocess stdout related to the main
> program output?
> Stream-specific encoding
Mark Summerfield added the comment:
I agree with Florian Mayer that the encoding handling should be
stream-specific. You could easily be reading the stdout of some third
party program that uses, say, latin1, but want to do your own output in,
say, utf-8.
One solution that builds on what Amaury
Mark Summerfield added the comment:
Glenn Linderman's fix pretty well works for me on XP Home. I can print
every Unicode character up to and including U+D7FF (although most just
come out as rectangles, at least I don't get encoding errors).
It fails at U+D800 with message:
UnicodeE
Mark Summerfield added the comment:
Hi,
I've noticed 3 differences between the re and regex engines.
I don't know if they are intended or not, but thought it best to mention
them. (I used the issue2636-20090810#3.zip version.)
Python 2.6.2 (r262:71600, Apr 20 2009, 09:25:38)
New submission from Mark Summerfield :
When I execute the following command line (Linux, Fedora 10) using
Python 2.5 or 2.6, I get a .cover file:
python2.5 -m trace --count MyModule.py
But when I do this with Python 3.0 or 3.1, no .cover file is output.
I didn't notice anything i
New submission from Mark Summerfield :
When I start a process with subprocess.Popen() and pipe the stdin and
stdout, it always seems to use the local 8-bit encoding.
I tried setting process.stdin.encoding = "utf8" and the same for stdout
(where process is the subprocess object), but t
Mark Summerfield added the comment:
I think a checkbox would be better:
[X] Blinking cursor
or
[X] Cursor blink
but if you use radio buttons you could have:
Cursor blink (*) On ( ) Off
--
___
Python tracker
<http://bugs.python.org/issue4
New submission from Mark Summerfield :
My suggestion is to add somewhere in the configuration dialog when users
can enter a block of Python code to be executed at startup and whenever
Restart Shell is executed.
Use case: for people who use IDLE for calculations/experiments they
might like to
Mark Summerfield added the comment:
I agree that control of the blink _rate_ isn't needed. I would certainly
welcome a "[X] blinking cursor" checkbox that defaulted to being checked
so that existing behaviour is unchanged, but at the same time offering
an easier solution (i.e.,
Mark Summerfield added the comment:
Yes, blinking cursors are torture for me too. Fortunately you can switch
them off globally in Windows, and in most cases on Linux (which is what
I use). But not on Mac OS X, and not it seems for Java apps. This site
has some tips: http://www.jurta.org/en/prog
Mark Summerfield added the comment:
Py2.6: idlelib/EditorWindow.py
change line 110 from: width=self.width,
to: width=self.width, insertofftime=0,
Py3.0
apply the same change to line 112
This will switch off cursor blink (and annoy people who want cursor
blink). So really instead of setting
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
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.
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
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
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
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 &
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
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
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
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
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
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
Changes by Mark Summerfield <[EMAIL PROTECTED]>:
--
nosy: +mark
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3394>
___
___
Python
Changes by Mark Summerfield <[EMAIL PROTECTED]>:
--
nosy: +mark
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2834>
___
___
Python
Changes by Mark Summerfield <[EMAIL PROTECTED]>:
--
type: -> behavior
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3000>
___
___
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
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(
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
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.
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
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
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
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
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
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
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
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
1 - 100 of 154 matches
Mail list logo