[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

New submission from Winfried Plappert winfried.plapp...@gmx.de:

When running the attached program, it will fail with above message on
Control-2 only! All other control keys work happily.

The same program under MS-Windows seems to work (I am under Linux, so I
can't switch easily). 

My version of Python:
Python 3.1 (r31:73572, Jul 18 2009, 08:33:59) 
[GCC 4.3.3] on linux2

uname -a: Linux lin-wpl 2.6.28-13-generic #45-Ubuntu SMP Tue Jun 30
19:49:51 UTC 2009 i686 GNU/Linux

Do I have to replace the line:  
self.c.bind('Control-Key-' + str(i) + '',
lambda x=str(i): self.key_control_num(x))

with something different? str-unicode, bytes???

This does not help either:
bytes(Control-Key- + str(i) + , 'utf-8')

This program has been converted via 2to3.

--
components: Tkinter
files: tkpy_70.py
messages: 90656
nosy: wplappert
severity: normal
status: open
title: UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: 
illegal encoding
versions: Python 3.1
Added file: http://bugs.python.org/file14517/tkpy_70.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Changes by Winfried Plappert winfried.plapp...@gmx.de:


Removed file: http://bugs.python.org/file14517/tkpy_70.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Changes by Winfried Plappert winfried.plapp...@gmx.de:


Added file: http://bugs.python.org/file14518/tkpy_70.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Changes by Winfried Plappert winfried.plapp...@gmx.de:


Removed file: http://bugs.python.org/file14518/tkpy_70.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Changes by Winfried Plappert winfried.plapp...@gmx.de:


Added file: http://bugs.python.org/file14519/tkpy_70.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

Can you paste the full traceback?
I tried to run the script on Windows and nothing happened when I pressed
Ctrl+[0..9].

--
nosy: +ezio.melotti
priority:  - low
type:  - behavior

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6513] Standard Library, Warnings, 28.5.4, example fails

2009-07-18 Thread Jason Tiller

New submission from Jason Tiller ja...@sonos.org:

The example provided in section 28.5.4 (warnings) of the Standard
Library documentation fails.  This example assumes that the context
manager instance ('w' in warnings.catch_warnings(record=True) as w)
supplies a list of objects, each of which has a data attribute
'.category' that is an instance.  However, the '.category' data
attribute is actually a class.

The example code fails in this way on 2.6.2:

-
Traceback (most recent call last):
  File bob.py, line 14, in module
assert isinstance(w[-1].category, DeprecationWarning)
AssertionError
-

Replacing 'isinstance' with 'issubclass' appears to satisfy the assertion.

--
assignee: georg.brandl
components: Documentation
messages: 90658
nosy: georg.brandl, jasontiller
severity: normal
status: open
title: Standard Library, Warnings, 28.5.4, example fails
versions: Python 2.6, Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6513
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6509] re.py - compiled byte-object regular expr encounter unexpected str-object

2009-07-18 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
nosy: +ezio.melotti
priority:  - normal

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6509
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Winfried Plappert winfried.plapp...@gmx.de added the comment:

As I said, it does work on Windows, but NOT on Linux!

Her is the full traceback:
wplap...@lin-wpl:~/sudoku/version3.0/tk_test/python3$ python3 tkpy_70.py
key_control_num 1  (# I pressed Control-1)
Traceback (most recent call last):
  File tkpy_70.py, line 27, in module
app.mainloop()
  File /usr/local/lib/python3.1/tkinter/__init__.py, line 1009, in
mainloop
self.tk.mainloop(n)
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1:
illegal encoding

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6513] Standard Library, Warnings, 28.5.4, example fails

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

Thanks, fixed in r74074.

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6513
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6505] Minor typos in tutorial (i/o chapter)

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

Thanks, fixed in r74075.

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6505
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6502] documentation error: missing comma between kwonlyargcount nlocals

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

Thanks, fixed in r74076.

--
resolution: accepted - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6502
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Winfried Plappert winfried.plapp...@gmx.de added the comment:

Is it possible that this issue is related to issue6144?

BTW: I have to handcomile my python 3.1 :)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

The same problems (ctrl+space and ctrl+2) were reported in #1028.
Closing this as duplicate.

--
resolution:  - duplicate
stage:  - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1028] Tkinter binding involving Control-spacebar raises unicode error

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

More users reported this problem in #6144 and #6512.

--
nosy: +ezio.melotti
priority:  - normal
type:  - behavior

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1028
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1028] Tkinter binding involving Control-spacebar raises unicode error

2009-07-18 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
superseder:  - [IDLE] UnicodeDecodeError when invoking force-open-completions

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1028
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1028] Tkinter binding involving Control-spacebar raises unicode error

2009-07-18 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
superseder: [IDLE] UnicodeDecodeError when invoking force-open-completions - 

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1028
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6144] [IDLE] UnicodeDecodeError when invoking force-open-completions

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

This was already reported in #1028.
Closing as duplicate.

--
nosy: +ezio.melotti
resolution:  - duplicate
stage:  - committed/rejected
status: open - closed
superseder:  - Tkinter binding involving Control-spacebar raises unicode error

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6144
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
superseder:  - Tkinter binding involving Control-spacebar raises unicode error

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6489] Documentation of ElementTree.Element.getiterator implies element will always be included

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

Fixed in r74077.

--
assignee: effbot - georg.brandl
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6489
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6499] Can't import xmlrpclib, DocXMLRPCServer and SimpleXMLRPCServer when zlib is not available

2009-07-18 Thread Kristján Valur Jónsson

Kristján Valur Jónsson krist...@ccpgames.com added the comment:

I thought zlib was a builtin module?  Why isn't it available?

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6499
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6504] infinite recursion from calling builtins.open()

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

First, the second bug isn't a bug since that restriction has been lifted
in Python 3.

The original issue occurs because open() for text modes imports the
locale module. This is kind of nasty, because calling open() is well
within what a find_module() implementation should be able to do. Antoine?

--
assignee:  - pitrou
nosy: +georg.brandl, pitrou

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6504
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6507] Enhance dis.dis to autocompile codestrings

2009-07-18 Thread Georg Brandl

Georg Brandl ge...@python.org added the comment:

As I explained on python-ideas, 'single' should not be tried.

--
nosy: +georg.brandl

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6507
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Winfried Plappert winfried.plapp...@gmx.de added the comment:

I have verified that the problem goes away when you switch from
tcl/tk8.4 to tcl/tk8.5 . Luckily my Ubuntu 9.04 has the 8.5-version
available for install. Thanks for the quick help!

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6509] re.py - compiled byte-object regular expr encounter unexpected str-object

2009-07-18 Thread Georg Brandl

Changes by Georg Brandl ge...@python.org:


--
priority: normal - critical

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6509
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6504] infinite recursion from calling builtins.open()

2009-07-18 Thread kai zhu

kai zhu kaizhu...@gmail.com added the comment:

current hack-around, then is to pre-import locale, which is verified to 
work:

# beg test.py
class importer(object):
  def find_module(self, mname, path = None): open(foo.txt)
import sys, locale; sys.meta_path.append(importer)
import collections # no recursion
# end test.py

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6504
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6497] Support for digital Cinema/film DPX and Kodak Cineon image file formats in imghdr module

2009-07-18 Thread Walter Arrighetti

Walter Arrighetti riemann.ch...@gmail.com added the comment:

DPX and Kodak Cineon are the two professional raster image formats used in
digital cinema/film post-production facilities to professionally store video
frames, usually using RGB, YUV or XYZ colour-spaces with 10,12,16 or 32 bits
per channel. They have two functions:

   1. They store complete colorimetry information in order to guarantee
   perfect colour reproduction across different media (monitors, projectors,
   paper and film stock). In particular they are used when conversions between
   original negative film to print film (for theatrical releases) require
   colours stored as film density, which is a nonlinear function compared to
   linear colour spaces used for video
   2. They are to cinema like RAW images are to photography: using such high
   color depths it is possible to store even the slightest lightness/colour
   differences in order for post-production to better manage color corrections
   and VFXs

Thanks for the support: it is my first post here. I'll read the patches
section and send a diff file for the original imghdr.py module.

I apologize for mixed tab/space indents: I checked for them (I use \t's) but
apparently missed some. As far as h and f they are pretty useless names for
me too, but was just adapting to the names in the core imghdr.py module
(which also imports modules within the functions).

--
Added file: http://bugs.python.org/file14520/unnamed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6497
___DPX and Kodak Cineon are the two professional raster image formats used in 
digital cinema/film post-production facilities to professionally store video 
frames, usually using RGB, YUV or XYZ colour-spaces with 10,12,16 or 32 bits 
per channel. They have two functions:br
olliThey store complete colorimetry information in order to guarantee 
perfect colour reproduction across different media (monitors, projectors, paper 
and film stock). In particular they are used when conversions between original 
negative
film to print film (for theatrical releases) require colours stored as
film density, which is a nonlinear function compared to linear colour
spaces used for video/liliThey are to cinema like RAW images are to 
photography: using such high color depths it is possible to store even the 
slightest lightness/colour differences in order for post-production to better 
manage color corrections and VFXsbr
/li/olbrThanks for the support: it is my first post here. I#39;ll read 
the patches section and send a diff file for the original imghdr.py 
module.brbrI apologize for mixed tab/space indents: I checked for them (I 
use \t#39;s) but apparently missed some. As far as h and f they are pretty 
useless names for me too, but was just adapting to the names in the core 
imghdr.py module (which also imports modules within the functions).br
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Winfried Plappert

Winfried Plappert winfried.plapp...@gmx.de added the comment:

wplap...@lin-wpl:~/sudoku/version3.0/tk_test/python3$ python3
Python 3.1 (r31:73572, Jul 18 2009, 11:13:40) 
[GCC 4.3.3] on linux2
Type help, copyright, credits or license for more information.
 import tkinter
 print(tkinter.Tcl().tk.call('info', 'patchlevel'))
8.5.6

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6507] Enhance dis.dis to autocompile codestrings

2009-07-18 Thread Nick Coghlan

Nick Coghlan ncogh...@gmail.com added the comment:

As per Georg's suggestion, a better approach would look like:

from dis import dis
def dis_str(source):
  try:
c = compile(source, '', 'eval')
  except SyntaxError:
c = compile(source, '', 'exec')
  return dis(c)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6507
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5752] xml.dom.minidom does not escape CR, LF and TAB characters within attribute values

2009-07-18 Thread Tomalak

Tomalak m8r-t1tu...@mailinator.com added the comment:

@devon: Thanks for pointing  linking back here.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5752
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1578269] Add os.link() and os.symlink() and os.path.islink() support for Windows

2009-07-18 Thread Jason R. Coombs

Jason R. Coombs jar...@jaraco.com added the comment:

Now that Python 3.1 is released, can we talk about integrating this into
the 3.1.1 release?

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1578269
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6499] Can't import xmlrpclib, DocXMLRPCServer and SimpleXMLRPCServer when zlib is not available

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

I don't know why it's not installed here, but I didn't remove it
intentionally.
here is a Linux machine with Ubuntu 8.04.3 (hardy) LTS.
One reason might be that I just have a limited number of program
installed and zlib is probably a dependency of some popular packages and
hence it's found in most of the machines.

When I compiled Python I got this message, so I think that Python
expects zlib to be already there:
Python build finished, but the necessary bits to build these modules
were not found: _dbm _gdbm _hashlib _sqlite3 _ssl _tkinter bz2 zlib

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6499
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1578269] Add os.link() and os.symlink() and os.path.islink() support for Windows

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

Standard policy is that new features only go into the next version (3.2
in this case).  3.1 will only get bug fixes now that it has been released.

--
nosy: +r.david.murray

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1578269
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6431] Fraction fails equality test with a user-defined type

2009-07-18 Thread Mark Dickinson

Mark Dickinson dicki...@gmail.com added the comment:

Applied in r74078 (py3k), r74079 (release31-maint).  I'll backport to 2.x.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6431
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6514] python -m unittest testmodule does not run any tests

2009-07-18 Thread Jean-Paul Calderone

New submission from Jean-Paul Calderone exar...@divmod.com:

exar...@boson:~$ cat  test_foo.py
from unittest import TestCase

class SomeTests(TestCase):
def test_foo(self):
pass
exar...@boson:~$ python -m unittest test_foo

--
Ran 0 tests in 0.000s

OK
exar...@boson:~$ python -m unittest test_foo.SomeTests
Traceback (most recent call last):
  File /usr/lib/python2.5/runpy.py, line 95, in run_module
filename, loader, alter_sys)
  File /usr/lib/python2.5/runpy.py, line 52, in _run_module_code
mod_name, mod_fname, mod_loader)
  File /usr/lib/python2.5/runpy.py, line 32, in _run_code
exec code in run_globals
  File /usr/lib/python2.5/unittest.py, line 816, in module
main(module=None)
  File /usr/lib/python2.5/unittest.py, line 767, in __init__
self.parseArgs(argv)
  File /usr/lib/python2.5/unittest.py, line 794, in parseArgs
self.createTests()
  File /usr/lib/python2.5/unittest.py, line 800, in createTests
self.module)
  File /usr/lib/python2.5/unittest.py, line 565, in loadTestsFromNames
suites = [self.loadTestsFromName(name, module) for name in names]
  File /usr/lib/python2.5/unittest.py, line 553, in loadTestsFromName
test = obj()
  File /usr/lib/python2.5/unittest.py, line 209, in __init__
(self.__class__, methodName)
ValueError: no such test method in class 'test_foo.SomeTests': runTest
exar...@boson:~$ python -m unittest test_foo.SomeTests.test_foo
.
--
Ran 1 test in 0.000s

OK
exar...@boson:~$ 

I don't really know what's happening in the middle case.  The first case
seems to fail because the test loader goes around looking for subclasses
of __main__.TestCase.  It only finds subclasses of unittest.TestCase,
though, which it rejects.

--
components: Library (Lib)
messages: 90681
nosy: exarkun
severity: normal
status: open
title: python -m unittest testmodule does not run any tests
type: behavior
versions: Python 2.4, Python 2.5, Python 2.6

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6514
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6515] http://docs.python.org/dev/library/unittest.html#load-tests-protocol doesn't make it clear when load_tests support was introduced

2009-07-18 Thread Jean-Paul Calderone

New submission from Jean-Paul Calderone exar...@divmod.com:

The load_tests feature will be new in 2.7.  Earlier in the unittest
documentation, there's a mention that loadTestsFromModule was changed in
2.7 to add support for load_tests.  However, the main documentation for
load_tests doesn't say anything about this.  It would be good to have a
note in section 26.3.7.3.1 saying load_tests was introduced in 2.7.

--
assignee: georg.brandl
components: Documentation
messages: 90682
nosy: exarkun, georg.brandl
severity: normal
status: open
title: http://docs.python.org/dev/library/unittest.html#load-tests-protocol 
doesn't make it clear when load_tests support was introduced
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6515
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6431] Fraction fails equality test with a user-defined type

2009-07-18 Thread Mark Dickinson

Mark Dickinson dicki...@gmail.com added the comment:

Backported to trunk in r74080.  I don't think it's worth fixing this in 
2.6:  it seems unlikely that the changed comparison behaviour would cause 
breakage, but I don't want to take the chance.

Thanks Case for the report and patches!

--
resolution:  - fixed
stage: patch review - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6431
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6515] http://docs.python.org/dev/library/unittest.html#load-tests-protocol doesn't make it clear when load_tests support was introduced

2009-07-18 Thread Georg Brandl

Changes by Georg Brandl ge...@python.org:


--
assignee: georg.brandl - michael.foord
nosy: +michael.foord

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6515
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6512] UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

2009-07-18 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

Do you know what 8.5.x version were you running before?
You should report it to #1028, apparently they were trying to find out
the affected versions there.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1886] Permit to easily use distutils --formats=tar, gztar, bztar on all systems

2009-07-18 Thread Till Maas

Changes by Till Maas opensou...@till.name:


--
nosy: +till

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1886
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6516] reset owner/group to root for distutils tarballs

2009-07-18 Thread Till Maas

New submission from Till Maas opensou...@till.name:

Please allow to create tarballs with owner/group of files be set to root.

One possible fix is to change cmd in distutils/archive_util.py to this:

cmd = [tar, -cf, archive_name, --owner=root, --group=root, base_dir]

--
assignee: tarek
components: Distutils
messages: 90685
nosy: tarek, till
severity: normal
status: open
title: reset owner/group to root for distutils tarballs
type: feature request
versions: Python 2.6

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6516
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1578269] Add os.link() and os.symlink() and os.path.islink() support for Windows

2009-07-18 Thread Jason R. Coombs

Jason R. Coombs jar...@jaraco.com added the comment:

In many ways, this is a bug fix and not a new feature.  os.islink is
already in the ntpath module, but simply doesn't perform its intended
purpose. Similarly, os.symlink exists and is defined for unix platforms,
but is just absent on the Windows platform.  In other words, this patch
doesn't implement new features, but simply expands the platform support
for existing features.  Therefore, I believe this is a strong candidate
for a 3.1.1 target.

That said, if the maintainers would prefer to defer this capability to
3.2, then I would like to move forward with that effort.

Whatever the recommended approach, this effort is ready to move onto the
next step.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1578269
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1578269] Add os.link() and os.symlink() and os.path.islink() support for Windows

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

I'm inclined to agree with you.

--
stage:  - patch review

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1578269
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue4753] Faster opcode dispatch on gcc

2009-07-18 Thread Michele Dionisio

Michele Dionisio michele.dioni...@gmail.com added the comment:

I have patch the code of python3.1 to use computed goto tecnique also
with Visual Studio. The performance result is not good (I really don't
know why). But it is a good work-araound for use the computed goto also
on windows.
The only diffentes is that the opcode_targets vector is filled at run-time.

--
nosy: +mdionisio
versions: +Python 3.1 -Python 2.7
Added file: http://bugs.python.org/file14521/newfile.zip

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue4753
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6517] configparser: add possibility to escape formatstrings

2009-07-18 Thread Till Maas

New submission from Till Maas opensou...@till.name:

There seems to be no way to add a config item with a value containing a
formatstring without this formatstring beeing handled by configparser.

A possible way to escape the formatstrings could be to double the
%-sign, e.g.:

[foo]
bar = %%(string)s

The value of the bar item should then be %(string)s.

--
components: Library (Lib)
messages: 90689
nosy: till
severity: normal
status: open
title: configparser: add possibility to escape formatstrings
versions: Python 2.6

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6517
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6461] multiprocessing: freezing apps on Windows

2009-07-18 Thread Stuart Mentzer

Stuart Mentzer s...@objexx.com added the comment:

Thanks Jesse. If you make broader changes that my patch I am happy to
test on Windows and with py2exe if that is helpful.

I will try to get the py2exe folks to look at the broader
multiprocessing issues I describe as well. If multiprocessing supports
freezing on Windows then it would be nice if its docs had a short primer
on what you'll actually need to do to get that working with freeze tools.

Stuart

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6461
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6461] multiprocessing: freezing apps on Windows

2009-07-18 Thread Jesse Noller

Jesse Noller jnol...@gmail.com added the comment:

Sounds good - I've personally never used freeze on windows, so having some 
docs and a patch to help make it better for those that do is a definite 
plus

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6461
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6415] warnings.warn segfaults on bad formatted string

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

The backport to 2.6 needs adjustment.  The test fails:

Traceback (most recent call last):
  File
/home/rdmurray/python/release26-maint/Lib/test/test_warnings.py, line
350, in test_bad_str
with self.assertRaises(ValueError):
TypeError: failUnlessRaises() takes at least 3 arguments (2 given)

assertRaises can't be used as a context manager in 2.6.

--
nosy: +r.david.murray
status: closed - open

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6415
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6517] configparser: add possibility to escape formatstrings

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

The formatstring is a Python % formatting code, and doubling the %% is
the way to escape one, so what you suggest is in fact the way it works.
 Do you have a test case demonstrating that it doesn't work as
documented (it works for me)?

--
nosy: +r.david.murray
resolution:  - works for me
stage:  - committed/rejected
status: open - pending
type:  - behavior

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6517
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6517] configparser: add possibility to escape formatstrings

2009-07-18 Thread Till Maas

Till Maas opensou...@till.name added the comment:

Afacs it is not documented to work. Here is the testcase:

#!/usr/bin/python
# vim: fileencoding=utf8

import ConfigParser
import tempfile

file = tempfile.TemporaryFile(mode='rw+b')
file.write([s]\nf=%%(b)s\n)
file.seek(0)
config = ConfigParser.ConfigParser()

config.readfp(file)

print config.get(s, f)

file.close()

--
status: pending - open
Added file: http://bugs.python.org/file14522/test-configparse.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6517
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6517] configparser: add possibility to escape formatstrings

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

Ah, that's because you aren't using SafeConfigParser (which the docs
recommend that you do unless you have to use ConfigParser for backward
compatibility reasons).  Your test case works with SafeConfigParser.

You are correct that it is not explicitly documented in the ConfigParser
docs.  It is implied by the fact that the magic substitution is
documented to be a standard format string, and by the recommendation to
use SafeConfigParser because ConfigParser's handling of formatstrings is
broken.

To make this all explicit, I've attached a doc patch to make the
motivation for using SafeConfigParser clearer, using this as the
example.  Let me know what you think.

Georg, Raymond, I added you as nosy to ask for a style/content opinion.
 Should we instead rewrite the section to put SafeConfigParser first,
and perhaps even deprecate ConfigParser?

--
assignee:  - r.david.murray
components: +Documentation -Library (Lib)
keywords: +patch
nosy: +georg.brandl, rhettinger
priority:  - normal
resolution: works for me - 
stage: committed/rejected - patch review
versions: +Python 2.7, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file14523/issue6517.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6517
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6517] configparser: add possibility to escape formatstrings

2009-07-18 Thread Till Maas

Till Maas opensou...@till.name added the comment:

It would be nice if you could expand the patch to also use only one name
for the support of format strings.

In the beginning it is introduced as reference expansion, but later in
the document, several variatons of interpolation are used: magical
interpolation, string interpolation, % interpolation is used.
Therefore I guess it should also be introduced as interpolation.

Another nice improvement would also be to move the ConfigParser to a
deprecated classes section at the end like it is done for some methods
in the string module.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6517
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6518] Enable 'with' statement in ossaudiodev module

2009-07-18 Thread Jerzy Jalocha N

New submission from Jerzy Jalocha N jjalo...@gmail.com:

Actually, it is not possible to use the 'with' statement in the
ossaudiodev module:

 import ossaudiodev
 with ossaudiodev.open('/dev/dsp', 'r') as device:
... pass
...
Traceback (most recent call last):
  File stdin, line 1 in module
AttributeError: 'ossaudodev.oss_audio_device' object has no attribute
'__exit__'

In order to provide a similar interface as standard Python files, and
encourage safe coding practices, the 'with' statement should be
supported in the ossaudiodev module.

Thanks.

--
components: Extension Modules
messages: 90697
nosy: jjalocha
severity: normal
status: open
title: Enable 'with' statement in ossaudiodev module
type: feature request
versions: Python 2.6, Python 2.7, Python 3.0, Python 3.1, Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6518
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6519] Reorder 'with' statement for files in Python Tutorial

2009-07-18 Thread Jerzy Jalocha N

New submission from Jerzy Jalocha N jjalo...@gmail.com:

Actually, the Python Tutorial recommends the use of the 'with' statement
in Section 7.2.1. Methods of File Objects:

 It is good practice to use the with keyword when dealing with file
 objects. [etc.]

But the example and description are at the very bottom of this very
large section, and are easily missed by new Python users.

If this suggestion is to be taken seriously, I suggest putting this
information at a more prominent place, somewhere at the top of the short
section 7.2. Reading and Writing Files.

--
assignee: georg.brandl
components: Documentation
messages: 90698
nosy: georg.brandl, jjalocha
severity: normal
status: open
title: Reorder 'with' statement for files in Python Tutorial
type: feature request
versions: Python 2.6, Python 2.7, Python 3.0, Python 3.1, Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6519
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6070] Python 2.6 makes .pyc/.pyo bytecode files executable

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

Committed to 2.6 in r74085, py3k in r74058 (by alexandre vassalotti),
and 3.1 in r74086.

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6070
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5230] pydoc reports misleading failure if target module raises an ImportError

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

Benjamin merged this to py3k/3.1 as part of r73623/r73625.

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5230
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5102] urllib2.py timeouts do not propagate across redirects for 2.6.1 (and 3.x?)

2009-07-18 Thread Senthil

Senthil orsent...@gmail.com added the comment:

Fixed and committed in revision 74089 and revision 74090.
Should this be backported?

--
resolution:  - fixed
versions: +Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5102
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5102] urllib2.py timeouts do not propagate across redirects for 2.6.1 (and 3.x?)

2009-07-18 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

It's hard to imagine anyone depending on the broken behavior, so I'd
vote yes.

--
nosy: +r.david.murray

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5102
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6520] urllib.urlopen does not have timeout parameter where as urllib2.urlopen has

2009-07-18 Thread Senthil

New submission from Senthil orsent...@gmail.com:

Just noticed this while fixing another bug issue5102. 
Need to figure out why urllib.urlopen does not have timeout in the first
account and if it was due to some overlook, then:

1) add timeout parameter to urllib.urlopen
2) propage it across redirects.

It may not have high implications in Py2.x, but might lead us to
problems in future in Py3.x where urlopen is a combined function.

--
assignee: orsenthil
components: Library (Lib)
keywords: easy
messages: 90703
nosy: orsenthil
priority: normal
severity: normal
status: open
title: urllib.urlopen does not have timeout parameter where as urllib2.urlopen 
has
versions: Python 2.7, Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6520
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5102] urllib2.py timeouts do not propagate across redirects for 2.6.1 (and 3.x?)

2009-07-18 Thread Senthil

Changes by Senthil orsent...@gmail.com:


--
versions: +Python 2.7 -Python 2.6

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5102
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6415] warnings.warn segfaults on bad formatted string

2009-07-18 Thread Hirokazu Yamamoto

Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment:

Thank you, I've fixed it in r74091. I should have checked test results 
on all branches.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6415
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5102] urllib2.py timeouts do not propagate across redirects for 2.6.1 (and 3.x?)

2009-07-18 Thread Senthil

Senthil orsent...@gmail.com added the comment:

backported to release26-maint in the revision 74093
and release31-maint in the revision 74092
Closing this issue.

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5102
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5102] urllib2.py timeouts do not propagate across redirects for 2.6.1 (and 3.x?)

2009-07-18 Thread Senthil

Changes by Senthil orsent...@gmail.com:


--
versions: +Python 2.6, Python 3.1

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5102
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1006238] cross compile patch

2009-07-18 Thread Garrett Cooper

Garrett Cooper yaneg...@gmail.com added the comment:

Coming back to this issue, I really want to resolve it on TRUNK and for
it to make its way into 2.6.3 and 2.x trunk, as well as 3.0.2 and 3.x
trunk. I am more than happy to sign a contributor agreement if this will
push things along quicker.

Thanks,
-Garrett

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1006238
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com