[issue3390] [PATCH] replace last has_key in unittest by in operator

2008-07-17 Thread engelbert gruber

New submission from engelbert gruber <[EMAIL PROTECTED]>:

take the line from python-3

--
components: Library (Lib)
files: lib_unittest-r65058
messages: 69877
nosy: grubert
severity: normal
status: open
title: [PATCH] replace last has_key in unittest by in operator
type: behavior
versions: Python 2.6
Added file: http://bugs.python.org/file10925/lib_unittest-r65058

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Selon "Gregory P. Smith" <[EMAIL PROTECTED]>:
>
> To answer Antoine Pitrou's question about using the old ident vs the new
> _get_ident().  I don't know if the forked process will have the same
> thread id.

Then wouldn't it be safer to use _get_ident() rather than re-using the old
thread ID? It doesn't make the code any more complicated as far as I know :)

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3391] Idle uses old showwarning signature

2008-07-17 Thread Robert Schuppenies

New submission from Robert Schuppenies <[EMAIL PROTECTED]>:

Idle does not use the 'line' argument for its showwarning function. This
results in the DeprecationWarning "functions overriding
warnings.showwarning() must support the 'line' argument", or, when
called from within Idle "TypeError: idle_formatwarning_subproc() takes
exactly 4 arguments (5 given)".

The error can be reproduced from within Idle as well as demonstrated
with verify.py.

The attached patch applies the behavior of the default warnings
implementation.

--
components: IDLE
files: idle.patch
keywords: patch
messages: 69879
nosy: brett.cannon, schuppenies
priority: normal
severity: normal
status: open
title: Idle uses old showwarning signature
type: behavior
versions: Python 2.6, Python 3.0
Added file: http://bugs.python.org/file10926/idle.patch

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3391] Idle uses old showwarning signature

2008-07-17 Thread Robert Schuppenies

Changes by Robert Schuppenies <[EMAIL PROTECTED]>:


Added file: http://bugs.python.org/file10927/verify.py

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3392] subprocess fails in select when descriptors are large

2008-07-17 Thread Mattias Engdegård

New submission from Mattias Engdegård <[EMAIL PROTECTED]>:

If the stdin/out file descriptors are too large to be used with
select(), subprocess will fail in .communicate(). Example:

# raise the fd limit to something like 2048 before running this
import subprocess
somefiles = [open("/etc/passwd") for i in xrange(2000)]
print subprocess.Popen(["date"], stdout=subprocess.PIPE).communicate()

The solution would be to use select.poll() in subprocess instead.

--
components: Library (Lib)
messages: 69880
nosy: yorick
severity: normal
status: open
title: subprocess fails in select when descriptors are large
versions: Python 2.5

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3377] Invalid child node access in ast.c

2008-07-17 Thread Jeremy Hylton

Changes by Jeremy Hylton <[EMAIL PROTECTED]>:


--
assignee:  -> jhylton
nosy: +jhylton

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3364] An ortographical typo in Zen of Python text

2008-07-17 Thread Chester

Chester <[EMAIL PROTECTED]> added the comment:

You're a strange man, Mr. Peters, a strange man...

On Tue, Jul 15, 2008 at 9:35 PM, Tim Peters <[EMAIL PROTECTED]> wrote:

>
> Tim Peters <[EMAIL PROTECTED]> added the comment:
>
> I'm afraid you missed the joke ;-)  While you believe spaces are
> required on both sides of an em dash, there is no consensus on this
> point.  For example, most (but not all) American authorities say /no/
> spaces should be used.  That's the joke.  In writing a line about "only
> one way to do it", I used a device (em dash) for which at least two ways
> to do it (with spaces, without spaces) are commonly used, neither of
> which is obvious -- and deliberately picked a third way just to rub it in.
>
> This will never change ;-)
>
> --
> nosy: +tim_one
>
> ___
> Python tracker <[EMAIL PROTECTED]>
> 
> ___
>

Added file: http://bugs.python.org/file10928/unnamed

___
Python tracker <[EMAIL PROTECTED]>

___You're a strange man, Mr. Peters, a strange 
man...On Tue, Jul 15, 2008 at 9:35 PM, Tim 
Peters [EMAIL PROTECTED]> 
wrote:

Tim Peters [EMAIL PROTECTED]> 
added the comment:

I'm afraid you missed the joke ;-)  While you believe spaces are
required on both sides of an em dash, there is no consensus on this
point.  For example, most (but not all) American authorities say /no/
spaces should be used.  That's the joke.  In writing a line about 
"only
one way to do it", I used a device (em dash) for which at least two 
ways
to do it (with spaces, without spaces) are commonly used, neither of
which is obvious -- and deliberately picked a third way just to rub it in.

This will never change ;-)

--
nosy: +tim_one

___
Python tracker [EMAIL 
PROTECTED]>
http://bugs.python.org/issue3364>
___

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



[issue3364] An ortographical typo in Zen of Python text

2008-07-17 Thread David Goodger

Changes by David Goodger <[EMAIL PROTECTED]>:


Removed file: http://bugs.python.org/file10928/unnamed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3375] _multiprocessing.so build problems

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

How about simply doing sys.path_importer_cache.clear() at the right
point in setup.py? I don't think the performance loss would be
overwhelming...

--
nosy: +pitrou

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3381] `./configure --enable-framework --enable-universalsdk` fails because of change in r63997

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

Ok applied in r65061.

--
nosy: +benjamin.peterson
resolution: accepted -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue2690] Precompute range length

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Has a resolution been made on this?

--
nosy: +pitrou

___
Python tracker <[EMAIL PROTECTED]>

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



[issue2523] binary buffered reading is quadratic

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

If nobody objects I'll commit Alexandre's patch in a few days (after
beta 2 though).

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3375] _multiprocessing.so build problems

2008-07-17 Thread Guido van Rossum

Guido van Rossum <[EMAIL PROTECTED]> added the comment:

I've checked in a fix (r65063) that simply clear sys.path_importer_cache
right before the attempted import of the freshly-built extension.  This
seems to work.

--
assignee: jnoller -> gvanrossum
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3369] memory leak in floatobject.c

2008-07-17 Thread Mark Dickinson

Changes by Mark Dickinson <[EMAIL PROTECTED]>:


--
assignee:  -> marketdickinson

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3377] Invalid child node access in ast.c

2008-07-17 Thread Jeremy Hylton

Jeremy Hylton <[EMAIL PROTECTED]> added the comment:

Committed revision 65064.

--
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

I've merged the change to py3k in r65065

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

test_3_join_in_forked_from_thread hangs for me in Py3k.

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Trent Mick

New submission from Trent Mick <[EMAIL PROTECTED]>:

http://svn.python.org/view?rev=63955&view=rev
"MacOS X: Enable 4-way universal builds ..."

This revision made the following change to Mac/Makefile.in:
http://svn.python.org/view/python/trunk/Mac/Makefile.in?rev=63955&view=diff&r1=63955&r2=63954&p1=python/trunk/Mac/Makefile.in&p2=/python/trunk/Mac/Makefile.in

The last hunk (part of the "installmacsubtree" target) and a bit of the
preceding hunk uses `arch` with arguments:
-
 install_BuildApplet:
-   $(RUNSHARED) $(BUILDPYTHON) $(srcdir)/scripts/BuildApplet.py \
+   $(RUNSHARED) arch -ppc -i386 $(BUILDPYTHON)
$(srcdir)/scripts/BuildApplet.py \
--destroot "$(DESTDIR)" \
-   --python $(INSTALLED_PYTHONAPP) \
+   
--python=$(prefix)/Resources/Python.app/Contents/MacOS/$(PYTHONFRAMEWORK)`test
-f
"$(DESTDIR)$(prefix)/Resources/Python.app/Contents/MacOS/$(PYTHONFRAMEWORK)-32"
&& echo "-32"`  \
--output "$(DESTDIR)$(PYTHONAPPSDIR)/Build Applet.app" \
$(srcdir)/scripts/BuildApplet.py
 
@@ -225,7 +279,7 @@
done
 
 
-   $(RUNSHARED) $(BUILDPYTHON) $(CACHERSRC) -v $(DESTDIR)$(MACLIBDEST)
$(DESTDIR)$(MACTOOLSDEST)
+   $(RUNSHARED) arch -ppc -i386 $(BUILDPYTHON) $(CACHERSRC) -v
$(DESTDIR)$(MACLIBDEST) $(DESTDIR)$(MACTOOLSDEST)
$(RUNSHARED) $(BUILDPYTHON) -Wi -tt $(compileall) -d $(MACTOOLSDEST)
-x badsyntax $(DESTDIR)$(MACTOOLSDEST)
$(RUNSHARED) $(BUILDPYTHON) -O -Wi -tt $(compileall) -d
$(MACTOOLSDEST) -x badsyntax $(DESTDIR)$(MACTOOLSDEST)
-

That form of calling `arch` is only supported on Mac OS X 10.5
(Leopard), I believe.

--
$ sw_vers
ProductName:Mac OS X
ProductVersion: 10.4.11
BuildVersion:   8S2167
$ man arch | cat

ARCH(1)   BSD General Commands Manual 
ARCH(1)

NAME
 arch -- print architecture type

SYNOPSIS
 arch

DESCRIPTION
 The arch command displays the machine's architecture type.

SEE ALSO
 machine(1)

Mac OS  August 20, 1997
Mac OS
--


Here is the current man page for arch (I had to look to try to see what
Ronald was trying to do with the Makefile change) :)
http://developer.apple.com/documentation/Darwin/Reference/ManPages/man1/arch.1.html

I don't fully understand why the "arch -ppc -i386" is necessary for
"$(BUILDPYTHON)".


I'm not sure what the easiest solution to this would be... or if
supporting "make frameworkinstallframework" (which eventually calls this
target) on Mac OS X <10.5 is considered important enough.

Perhaps a new 
  [EMAIL PROTECTED]@
could be added to Mac/Makefile.in with the associated configure support
to have that be blank unless `--with-universal-archs=all` was specified?

--
components: Build
messages: 69890
nosy: ronaldoussoren, trentm
severity: normal
status: open
title: `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of 
r63955
type: compile error
versions: Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Trent Mick

Trent Mick <[EMAIL PROTECTED]> added the comment:

Similar change in Mac/IDLE/Makefile.in:

-
--- python/trunk/Mac/IDLE/Makefile.in   (original)
+++ python/trunk/Mac/IDLE/Makefile.in   Thu Jun  5 14:58:24 2008
@@ -42,7 +42,7 @@
$(srcdir)/../Icons/PythonSource.icns \
$(srcdir)/../Icons/PythonCompiled.icns Info.plist
rm -fr IDLE.app
-   $(RUNSHARED) $(BUILDPYTHON) $(BUNDLEBULDER) \
+   $(RUNSHARED) arch -ppc -i386 $(BUILDPYTHON) $(BUNDLEBULDER) \
--builddir=. \
--name=IDLE \
--link-exec \
-

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Trent Mick

Trent Mick <[EMAIL PROTECTED]> added the comment:

Alternative potential solution: use the ARCHPREFERENCE environment
variable as described in the Mac OS X 10.5 arch man page. Ronald, if you
could test if that works for you on 10.5, then presumably setting that
environment var would be safely ignored on Mac OS X <10.5. Thoughts?

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

To add to ben's comment, under py3k the third test hangs, if you pull 
out the basic script code being executed in subprocess:

if 1:
import sys, os, time, threading

# a thread, which waits for the main program to terminate
def joiningfunc(mainthread):
mainthread.join()
print('end of thread')

if 1:
main_thread = threading.current_thread()
def worker():
childpid = os.fork()
if childpid != 0:
os.waitpid(childpid, 0)
sys.exit(0)

t = threading.Thread(target=joiningfunc,
 args=(main_thread,))
print('starting worker')
t.start()
print('joining worker')
t.join() # Should not block: main_thread is already stopped

w = threading.Thread(target=worker)
w.start()

You'll note it hangs promptly at the join()

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

Ben commented out the hanging test, lowering this from a release blocker 
as the patch is on both trunk and 3k, and minus that third new test, 
test_threading and test_multiprocessing are both passing

--
priority: release blocker -> critical

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3088] test_multiprocessing hangs intermittently on POSIX platforms

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

Issue 874900's patch seems to have resolve the hangs. I am closing this 
issue as fixed.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3379] Option to not-exit on test

2008-07-17 Thread J. Pablo Fernández

J. Pablo Fernández <[EMAIL PROTECTED]> added the comment:

Added tests.

Added file: http://bugs.python.org/file10929/add_avoid_exit_option.diff

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3382] Make '%F' and float.__format__('F') convert results to upper case.

2008-07-17 Thread Eric Smith

Eric Smith <[EMAIL PROTECTED]> added the comment:

Implemented for trunk in r65069; for py3k in r65073.

--
resolution:  -> accepted
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



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

2008-07-17 Thread Stephen Warren

New submission from Stephen Warren <[EMAIL PROTECTED]>:

Run the following Python script, on Unix/Linux:

==
import zipfile

z = zipfile.ZipFile('zipbad.zip', 'w')
z.writestr('filebad.txt', 'Some content')
z.close()

z = zipfile.ZipFile('zipgood.zip', 'w')
zi = zipfile.ZipInfo('filegood.txt')
zi.external_attr = 0660 << 16L
z.writestr(zi, 'Some content')
z.close()
==

Like this:

python testzip.py  && unzip zipbad.zip && unzip zipgood.zip && ls -l
file*.txt

You'll see:

--  1 swarren swarren   12 2008-07-17 12:54 filebad.txt
-rw-rw  1 swarren swarren   12 1980-01-01 00:00 filegood.txt

Note that filebad.txt is extracted with mode 000.

The WAR (used for filegood.txt) is to pass writestr a ZipInfo class with
external_attr pre-initialized. However, writestr should perform this
assignment itself, to be consistent with write. I haven't checked, but
there's probably a bunch of other stuff in write that writestr should do
too.

--
components: Extension Modules
messages: 69898
nosy: swarren
severity: normal
status: open
title: zipfile.writestr doesn't set external attributes, so files are extracted 
mode 000 on Unix
versions: Python 2.5

___
Python tracker <[EMAIL PROTECTED]>

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



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

2008-07-17 Thread Stephen Warren

Stephen Warren <[EMAIL PROTECTED]> added the comment:

Oops. Forgot to set "type" field.

--
type:  -> behavior

___
Python tracker <[EMAIL PROTECTED]>

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



[issue1432] Strange behavior of urlparse.urljoin

2008-07-17 Thread Roman Petrichev

Roman Petrichev <[EMAIL PROTECTED]> added the comment:

Senthil, please read the RFC3986 text, not only examples.
[Page 31] contains exact algorithm how to handle this case.
--cut--
if (R.path == "") then
   T.path = Base.path;
   if defined(R.query) then
  T.query = R.query;
   else
  T.query = Base.query;
   endif;
--cut--

I.e. instead of:
>>> urljoin('http://www.ya.ru/index.php', '?o=30&a=l')
'http://www.ya.ru/?o=30&a=l'
python SHOULD do:
>>> urljoin('http://www.ya.ru/index.php', '?o=30&a=l')
'http://www.ya.ru/index.php?o=30&a=l'

Look at any browser's handling this case.

--
nosy: +tier

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3382] Make '%F' and float.__format__('F') convert results to upper case.

2008-07-17 Thread Eric Smith

Eric Smith <[EMAIL PROTECTED]> added the comment:

Changes backed out, pending fixing on Windows.

--
resolution: accepted -> 
status: closed -> open

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3324] Broken link in online doc

2008-07-17 Thread Georg Brandl

Georg Brandl <[EMAIL PROTECTED]> added the comment:

I've backported the fix to the 2.5 branch. This will go live with the
release of 2.5.3.

For those who do not want to use the released documentation we do offer
the 2.6 documentation under development under http://docs.python.org/dev
-- it is very usable for 2.5 too, since anything new in 2.6 will be
clearly marked as such.

When 2.6 is released, handling of the docs will be different in any
case, since comments and change suggestions will be possible and handled
in a timely manner, I hope.

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3373] sys recursion limit a lot shorter on trunk?

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Here is a small script that shows various possibilities depending on how
object creation is done, and here is the output with the trunk:

rec1 stopped at 1000
rec2 stopped at 1000
rec3 stopped at 500
rec4 stopped at 334
rec5 stopped at 334
rec6 stopped at 250

With 2.5, the output is:

rec1 stopped at 1000
rec2 stopped at 1000
rec3 stopped at 500
rec4 stopped at 1000
rec5 stopped at 1000
rec6 stopped at 1000

I think we should just acknowledge that recursion count has gotten
stricter (PyObject_Call() increases it, and then PyEval_EvalFrameEx()
will increase it a second time if Python code is entered), and bump the
default recursion limit.

(the reason calling Python functions directly doesn't increase the
recursion count twice is that there are optimization shortcuts in
ceval.c to avoid calling PyObject_Call() - not the case though when
calling a type object)

Added file: http://bugs.python.org/file10930/rec.py

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3373] sys recursion limit a lot shorter on trunk?

2008-07-17 Thread Antoine Pitrou

Changes by Antoine Pitrou <[EMAIL PROTECTED]>:


--
priority:  -> high
versions: +Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3395] typo in test_multiprocessing.py: should _debugInfo be _debug_info ?

2008-07-17 Thread Mark Dickinson

New submission from Mark Dickinson <[EMAIL PROTECTED]>:

In _TestZZZNumberOfObjects in test_multiprocessing.py, at around line 1040  
(this is r65075 on the trunk), there's a line:

print self.manager._debugInfo()

Should this be

print self.manager._debug_info()

?

While running test_multiprocessing directly (./python.exe 
Lib/test/test_multiprocessing) I got the following traceback:

Macintosh-3:trunk dickinsm$ ./python.exe Lib/test/test_multiprocessing.py
test_array (__main__.WithProcessesTestArray) ... ok
test_getobj_getlock_obj (__main__.WithProcessesTestArray) ... ok
...
[snip lots of passing tests]
...
test_rawvalue (__main__.WithManagerTestValue) ... ok
test_value (__main__.WithManagerTestValue) ... ok
test_number_of_objects (__main__.WithManagerTestZZZNumberOfObjects) ... 
ERROR

==
ERROR: test_number_of_objects (__main__.WithManagerTestZZZNumberOfObjects)
--
Traceback (most recent call last):
  File "Lib/test/test_multiprocessing.py", line 1040, in 
test_number_of_objects
print self.manager._debugInfo()
AttributeError: 'SyncManager' object has no attribute '_debugInfo'

--
Ran 121 tests in 10.446s

FAILED (errors=1)
[53431 refs]

--
assignee: jnoller
keywords: easy
messages: 69904
nosy: jnoller, marketdickinson
severity: normal
status: open
title: typo in test_multiprocessing.py:  should _debugInfo be _debug_info ?
versions: Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3396] rlcompleter can't autocomplete members of callable objects

2008-07-17 Thread Antoine Pitrou

New submission from Antoine Pitrou <[EMAIL PROTECTED]>:

This is a regression caused by #449227. When typing e.g. "int." and then
pressing tab, none of the int members is proposed. It worked until just
before r64664.

--
components: Library (Lib)
messages: 69905
nosy: facundobatista, pitrou
priority: normal
severity: normal
status: open
title: rlcompleter can't autocomplete members of callable objects
type: behavior
versions: Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue449227] rlcompleter add "(" to callables feature

2008-07-17 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

This issue caused a regression in #3396.

--
nosy: +pitrou

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3395] typo in test_multiprocessing.py: should _debugInfo be _debug_info ?

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

I can not reproduce this using r65075 of python-trunk:

test_number_of_objects (__main__.WithManagerTestZZZNumberOfObjects) ... 
ok

--
Ran 121 tests in 9.165s

This is with a clean build of python against trunk it also doesn't fail 
with regrtest:

thumper:python-trunk jesse$ ./python.exe Lib/test/regrtest.py 
test_multiprocessing


This is a clean checkout

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3395] typo in test_multiprocessing.py: should _debugInfo be _debug_info ?

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

Fixed, r65077 on trunk

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3397] Mac 3.0 build cannot find cachersrc.py

2008-07-17 Thread Barry Alan Scott

New submission from Barry Alan Scott <[EMAIL PROTECTED]>:

$ sw_vers
ProductName:Mac OS X
ProductVersion: 10.4.11
BuildVersion:   8S165

./configure --enable-framework
make
...
make install
Creating directory
/Library/Frameworks/Python.framework/Versions/3.0/Mac/Tools
DYLD_FRAMEWORK_PATH=/Users/barry/Work/Python-3.0b1: ../python.exe
./scripts/cachersrc.py -v
/Library/Frameworks/Python.framework/Versions/3.0/lib/python3.0/plat-mac
/Library/Frameworks/Python.framework/Versions/3.0/Mac/Tools
../python.exe: can't open file './scripts/cachersrc.py': [Errno 2] No
such file or directory
make[1]: *** [installmacsubtree] Error 2
make: *** [frameworkinstallmaclib] Error 2

--
components: Build
messages: 69909
nosy: barry-scott
severity: normal
status: open
title: Mac 3.0 build cannot find cachersrc.py
type: compile error
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3398] mac build 3.0 no MacOS module

2008-07-17 Thread Barry Alan Scott

New submission from Barry Alan Scott <[EMAIL PROTECTED]>:

$ sw_vers 
ProductName:Mac OS X
ProductVersion: 10.4.11
BuildVersion:   8S165

./configure --enable-framework
make
...
make install
...

DYLD_FRAMEWORK_PATH=/Users/barry/Work/Python-3.0b1: ../python.exe
./scripts/BuildApplet.py \
--destroot "" \
--python
/Library/Frameworks/Python.framework/Versions/3.0/Resources/Python.app/Contents/MacOS/Python
\
--output "/Applications/Python 3.0/Build Applet.app" \
./scripts/BuildApplet.py
Traceback (most recent call last):
  File "./scripts/BuildApplet.py", line 14, in 
import MacOS
ImportError: No module named MacOS
make[1]: *** [install_BuildApplet] Error 1
make: *** [frameworkinstallapps] Error 2

--
components: Build
messages: 69910
nosy: barry-scott
severity: normal
status: open
title: mac build 3.0 no MacOS module
type: compile error
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3396] rlcompleter can't autocomplete members of callable objects

2008-07-17 Thread Guilherme Polo

Guilherme Polo <[EMAIL PROTECTED]> added the comment:

This is somewhat obscure to notice but the problem is towards that
getattr on attr_matches. For "int" specifically, it will try to get the
attribute '__abstractmethods__' (which is a member of int.__class__) and
will raise an AttributeError but then the exception is discarded by the
readline module.
A workaround is to change that getattr to:

try:
val = getattr(object, word)
except AttributeError:
continue

--
nosy: +gpolo

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3398] mac build 3.0 no MacOS module

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

I assume this is only 3.0 beta 1. This has been fixed for beta 2.

--
nosy: +benjamin.peterson
resolution:  -> out of date
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3397] Mac 3.0 build cannot find cachersrc.py

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

This is fixed in beta 2.

--
nosy: +benjamin.peterson
resolution:  -> out of date
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3398] mac build 3.0 no MacOS module

2008-07-17 Thread Barry Alan Scott

Barry Alan Scott <[EMAIL PROTECTED]> added the comment:

I don't see beta 2 on python.org or I'd have used it...

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3398] mac build 3.0 no MacOS module

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

It's supposed to be release tonight. Sorry for the confusion. :)

___
Python tracker <[EMAIL PROTECTED]>

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



[issue2234] cygwinccompiler.py fails for latest MinGW releases.

2008-07-17 Thread Jose Antonio Martin H

Jose Antonio Martin H <[EMAIL PROTECTED]> added the comment:

I have the same problem, i have patched the file and now it works ok.

--
nosy: +jamartinh

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3390] [PATCH] replace last has_key in unittest by in operator

2008-07-17 Thread Antoine Pitrou

Changes by Antoine Pitrou <[EMAIL PROTECTED]>:


--
keywords: +patch

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

New submission from Mark Dickinson <[EMAIL PROTECTED]>:

As of revision 65077 of the trunk, I'm getting errors in 
test_multiprocessing that seem to point to memory corruption in object 
allocation/deallocation.  The failures are intermittent, and of a 
similar nature to the errors I was seeing previously, outlined in issue 
3088.

The platform is OS X 10.5.4 (not a fresh install---it was an upgrade 
from OS X 10.4, in case this makes any difference), running on a MacBook 
Pro.  I'm running a freshly checked out debug build of the trunk.

Here's what I did:

(1) make a fresh svn+ssh checkout of the trunk
(2) ./configure --with-pydebug && make
(3) ./python.exe Lib/test/test_multiprocessing.py
(4) repeat step (3) until something nasty happens.

The results vary from run to run, and 80-90% of the runs of 
test_multiprocessing pass.  Here are 3 of the failures I've seen, 
occurring on three separate runs of test_multiprocessing.

Failure 1:

test_notify_all (__main__.WithManagerTestCondition) ... Assertion 
failed: (pool->ref.count > 0), function PyObject_Free, file 
Objects/obmalloc.c, line 1100.

Failure 2:

test_imap_unordered (__main__.WithManagerTestPool) ...
python.exe(32381,0xb0513000) malloc: *** error for object 0xdbdbdbdb:
pointer being reallocated was not allocated
*** set a breakpoint in malloc_error_break to debug
python.exe(32381,0xb0513000) malloc: *** error for object 0xdbdbdbdb:
Non-aligned pointer being freed
*** set a breakpoint in malloc_error_break to debug
Fatal Python error: UNREF invalid object
ERROR

Failure 3:

test_imap_unordered (__main__.WithManagerTestPool) ... Fatal Python
error: UNREF invalid object
ERROR


I have very little (i.e. no) experience of debugging this kind of 
failure, and little understanding of how the multiprocessing module 
works.  But I can and will follow instructions and suggestions about how 
to debug this.

Stupid question:  it appears from reading the comments in that file that 
obmalloc.c is (intentionally) not thread-safe.  Could this have anything 
to do with the failures above?

--
assignee: jnoller
components: Extension Modules
messages: 69917
nosy: jnoller, marketdickinson
severity: normal
status: open
title: Memory corruption in multiprocessing module, OS X 10.5.4
type: crash
versions: Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3400] dis module: undocumented new bytecodes

2008-07-17 Thread Terry J. Reedy

New submission from Terry J. Reedy <[EMAIL PROTECTED]>:

dis / Python Bytecode Instructions is missing
UNPACK_EX
STORE_LOCALS
LOAD_BUILD_CLASS
MAKE_BYTES
which appear in dis.opname (3.0 version).

Suggestion: After entry for UNPACK_SEQUENCE(count), add
UNPACK_EX(bytepair)
Used for starred assignment.  Similar to UNPACK_SEQUENCE except 1) the
lo and hi bytes of the argument are the number of unstarred targets
before and after the starred target and 2) the values between the first
lo and last hi are collected into a list for the starred target.

I deduced this because *a,b; a,*b; *a,b,c; a,*b,c; and a,b,*c as targets
produce byte pairs of 0,1; 1,0; 0,2; 1,1; and 2,0 (arguments 256, 1,
512, 257, and 2).

The other three are new since 2.5 but do not make much sense to me.  I
will ask on pydev for clarification.  I do not have 2.6 to check its
version of .opname to determine which of these belong there too.

--
assignee: georg.brandl
components: Documentation
messages: 69918
nosy: georg.brandl, tjreedy
severity: normal
status: open
title: dis module: undocumented new bytecodes
versions: Python 2.6, Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3400] dis module: undocumented new bytecodes

2008-07-17 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

LOAD_BUILD_CLASS is 3.0 only and I documented it.

--
nosy: +benjamin.peterson

___
Python tracker <[EMAIL PROTECTED]>

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



[issue2638] tkSimpleDialog Window Flashing

2008-07-17 Thread Guilherme Polo

Guilherme Polo <[EMAIL PROTECTED]> added the comment:

It would be more appropriate to properly use withdraw and deiconify
then. I'm attaching a patch that uses them.

--
keywords: +patch
Added file: http://bugs.python.org/file10931/issue_2638.diff

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

Mark Dickinson <[EMAIL PROTECTED]> added the comment:

And one more:

Failure 4:

test_make_pool (__main__.WithManagerTestPool) ... Assertion failed: (bp != 
NULL), function PyObject_Malloc, file Objects/obmalloc.c, line 746.

___
Python tracker <[EMAIL PROTECTED]>

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



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

2008-07-17 Thread Christopher Brannon

Christopher Brannon <[EMAIL PROTECTED]> added the comment:

What value should the new archive entry's external_attr attribute have?
ZipFile.write sets it to the permissions of the file being archived, but
writestr is archiving a string, not a file.  Setting it to 0600 << 16
seems reasonable.

Stephen's script exposed a second bug in writestr.  When passed a name
rather than a ZipInfo instance, the new archive member receives a timestamp
of 01/01/1980.  However, the docs say that the timestamp should correspond to
the current date and time.
ZipFile.writestr begins with the following code:

def writestr(self, zinfo_or_arcname, bytes):
"""Write a file into the archive.  The contents is the string
'bytes'.  'zinfo_or_arcname' is either a ZipInfo instance or
the name of the file in the archive."""
if not isinstance(zinfo_or_arcname, ZipInfo):
zinfo = ZipInfo(filename=zinfo_or_arcname,
date_time=time.localtime(time.time())[:6])
zinfo.compress_type = self.compression

The "date_time=" line should read:

zinfo.date_time=time.localtime(time.time())[:6])

--
nosy: +cbrannon
versions: +Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3400] dis module: undocumented new bytecodes

2008-07-17 Thread Martin v. Löwis

Martin v. Löwis <[EMAIL PROTECTED]> added the comment:

Terry, would you like to contribute a patch (even if only for the one
you understand)?

--
nosy: +loewis

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

Mark Dickinson <[EMAIL PROTECTED]> added the comment:

And another:

Failure 5:

test_notify (__main__.WithManagerTestCondition) ... Assertion failed: 
(usable_arenas->freepools == NULL), function PyObject_Malloc, file 
Objects/obmalloc.c, line 809.
ERROR

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

On Jul 17, 2008, at 6:22 PM, Mark Dickinson <[EMAIL PROTECTED]>  
wrote:

>
> New submission from Mark Dickinson <[EMAIL PROTECTED]>:
>
> As of revision 65077 of the trunk, I'm getting errors in
> test_multiprocessing that seem to point to memory corruption in object
> allocation/deallocation.  The failures are intermittent, and of a
> similar nature to the errors I was seeing previously, outlined in  
> issue
> 3088.
>
> The platform is OS X 10.5.4 (not a fresh install---it was an upgrade
> from OS X 10.4, in case this makes any difference), running on a  
> MacBook
> Pro.  I'm running a freshly checked out debug build of the trunk.
>
> Here's what I did:
>
> (1) make a fresh svn+ssh checkout of the trunk
> (2) ./configure --with-pydebug && make
> (3) ./python.exe Lib/test/test_multiprocessing.py
> (4) repeat step (3) until something nasty happens.
>
> The results vary from run to run, and 80-90% of the runs of
> test_multiprocessing pass.  Here are 3 of the failures I've seen,
> occurring on three separate runs of test_multiprocessing.
>

I am/was going to help you with this when you emailed me your last  
email - I'm disturbed none of my machines or the buildbots for that  
matter are seeing this. Can you post the output from:

Echo $LD_LIBRARY_PATH
which gcc
gcc -v

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

Mark Dickinson <[EMAIL PROTECTED]> added the comment:

LD_LIBRARY_PATH isn't set.  gcc is the system gcc from Apple:

Macintosh-3:trunk dickinsm$ echo $LD_LIBRARY_PATH

Macintosh-3:trunk dickinsm$ which gcc
/usr/bin/gcc
Macintosh-3:trunk dickinsm$ gcc -v
Using built-in specs.
Target: i686-apple-darwin9
Configured with: /var/tmp/gcc/gcc-5484~1/src/configure --disable-
checking -enable-werror --prefix=/usr --mandir=/share/man --enable-
languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-
]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --with-
slibdir=/usr/lib --build=i686-apple-darwin9 --with-arch=apple --with-
tune=generic --host=i686-apple-darwin9 --target=i686-apple-darwin9
Thread model: posix
gcc version 4.0.1 (Apple Inc. build 5484)

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3341] "Suggest a change" link

2008-07-17 Thread Georg Brandl

Georg Brandl <[EMAIL PROTECTED]> added the comment:

None yet. :(

___
Python tracker <[EMAIL PROTECTED]>

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



[issue874900] threading module can deadlock after fork

2008-07-17 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

Jesse: thanks for doing the py3k merge.

Antoine: yeah it might be safer to use _get_ident() but since the
len(_active) == 1 assert is not firing we're probably fine as is.

A change to this that I was considering making to this code has been
attached as threading-874900-improvement-gps01.diff.

-gps

Added file: 
http://bugs.python.org/file10932/threading-874900-improvement-gps01.diff

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3401] wsgiref can't handle unicode environments

2008-07-17 Thread Benjamin Peterson

New submission from Benjamin Peterson <[EMAIL PROTECTED]>:

The following errors pop up on the Windows trunk build bot because the
LIB environmental variable is unicode not str. This causes the
validation to fail.


Re-running test 'test_wsgiref' in verbose mode
testAbstractMethods (test.test_wsgiref.HandlerTests) ... ok
testBasicErrorOutput (test.test_wsgiref.HandlerTests) ... ok
testCGIEnviron (test.test_wsgiref.HandlerTests) ... ok
testContentLength (test.test_wsgiref.HandlerTests) ... ok
testEnviron (test.test_wsgiref.HandlerTests) ... ERROR
testErrorAfterOutput (test.test_wsgiref.HandlerTests) ... ok
testHeaderFormats (test.test_wsgiref.HandlerTests) ... ok
testScheme (test.test_wsgiref.HandlerTests) ... ok
testExtras (test.test_wsgiref.HeaderTests) ... ok
testMappingInterface (test.test_wsgiref.HeaderTests) ... ok
testRequireList (test.test_wsgiref.HeaderTests) ... ok
test_plain_hello (test.test_wsgiref.IntegrationTests) ... ok
test_simple_validation_error (test.test_wsgiref.IntegrationTests) ... FAIL
test_validated_hello (test.test_wsgiref.IntegrationTests) ... FAIL
testAppURIs (test.test_wsgiref.UtilityTests) ... ok
testCrossDefaults (test.test_wsgiref.UtilityTests) ... ok
testDefaults (test.test_wsgiref.UtilityTests) ... ok
testFileWrapper (test.test_wsgiref.UtilityTests) ... ok
testGuessScheme (test.test_wsgiref.UtilityTests) ... ok
testHopByHop (test.test_wsgiref.UtilityTests) ... ok
testNormalizedShifts (test.test_wsgiref.UtilityTests) ... ok
testReqURIs (test.test_wsgiref.UtilityTests) ... ok
testSimpleShifts (test.test_wsgiref.UtilityTests) ... ok

==
ERROR: testEnviron (test.test_wsgiref.HandlerTests)
--
Traceback (most recent call last):
  File
"E:\cygwin\home\db3l\buildarea\trunk.bolen-windows\build\lib\test\test_wsgiref.py",
line 437, in testEnviron
self.checkOSEnviron(h)
  File
"E:\cygwin\home\db3l\buildarea\trunk.bolen-windows\build\lib\test\test_wsgiref.py",
line 429, in checkOSEnviron
self.assertEqual(env[k],v)
KeyError: 'AUTH_TYPE'

==
FAIL: test_simple_validation_error (test.test_wsgiref.IntegrationTests)
--
Traceback (most recent call last):
  File
"E:\cygwin\home\db3l\buildarea\trunk.bolen-windows\build\lib\test\test_wsgiref.py",
line 157, in test_simple_validation_error
"AssertionError: Headers (('Content-Type', 'text/plain')) must"
AssertionError: "AssertionError: Environmental variable LIB is not a
string:  (value: u'C:Program FilesMicrosoft
Visual Studio 9.0VCLIB;C:Program FilesMicrosoft
SDKsWindowsv6.0Alib;c:program filesmicrosoft visual
studio .NET 2003vc7atlmfclib;c:program
filesmicrosoft visual studio .NET 2003vc7lib;c:program
filesmicrosoft visual studio .NET
2003vc7PlatformSDKlib;C:Program FilesMicrosoft
Visual Studio .NET 2003SDKv1.1Lib')" != "AssertionError:
Headers (('Content-Type', 'text/plain')) must be of type list: "

==
FAIL: test_validated_hello (test.test_wsgiref.IntegrationTests)
--
Traceback (most recent call last):
  File
"E:\cygwin\home\db3l\buildarea\trunk.bolen-windows\build\lib\test\test_wsgiref.py",
line 145, in test_validated_hello
self.check_hello(out, has_length=False)
  File
"E:\cygwin\home\db3l\buildarea\trunk.bolen-windows\build\lib\test\test_wsgiref.py",
line 134, in check_hello
"\r\n"
AssertionError: 'HTTP/1.0 500 Dude, this is whack!\r\nDate: Thu, 17 Jul
2008 22:45:20 GMT\r\nServer: WSGIServer/0.1
Python/2.6b1+\r\nContent-Type: text/plain\r\nContent-Length: 59\r\n\r\nA
server error occurred.  Please contact the administrator.' != 'HTTP/1.0
200 OK\r\nServer: WSGIServer/0.1 Python/2.6b1+\r\nContent-Type:
text/plain\r\nDate: Mon, 05 Jun 2006 18:49:54 GMT\r\n\r\nHello, world!'

--
messages: 69929
nosy: benjamin.peterson
severity: normal
status: open
title: wsgiref can't handle unicode environments

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3401] wsgiref can't handle unicode environments

2008-07-17 Thread Benjamin Peterson

Changes by Benjamin Peterson <[EMAIL PROTECTED]>:


--
components: +Library (Lib)
priority:  -> high
type:  -> behavior
versions: +Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3401] wsgiref can't handle unicode environments

2008-07-17 Thread Georg Brandl

Changes by Georg Brandl <[EMAIL PROTECTED]>:


--
assignee:  -> pje
nosy: +pje

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Jesse Noller

Jesse Noller <[EMAIL PROTECTED]> added the comment:

Can you try removing the --with-pydebug flag from configure and  
running that way?

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3402] test_nis is hanging on Solaris

2008-07-17 Thread Benjamin Peterson

New submission from Benjamin Peterson <[EMAIL PROTECTED]>:

The 3.0 Solaris buildbot keeps hanging on test_nis.

--
components: Tests
messages: 69931
nosy: benjamin.peterson
priority: deferred blocker
severity: normal
status: open
title: test_nis is hanging on Solaris
type: behavior
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

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



[issue2235] __eq__ / __hash__ check doesn't take inheritance into account

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3231] re.compile fails with some bytes patterns

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3131] 2to3 can't find fixes_dir

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3139] bytearrays are not thread safe

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3352] Deficiencies in multiprocessing/threading API

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3402] test_nis is hanging on Solaris

2008-07-17 Thread Barry A. Warsaw

Changes by Barry A. Warsaw <[EMAIL PROTECTED]>:


--
priority: deferred blocker -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

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



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

2008-07-17 Thread Stephen Warren

Stephen Warren <[EMAIL PROTECTED]> added the comment:

I'd probably argue for at least 0660<<16, if not 0666<<16, since group
permissions are pretty typically set, but even 0666<<16 would be OK,
since the umask on extraction would take away any permissions the
extracting user didn't want.

But, as long as the chosen mask includes at least 0600, I'd consider the
issue fixed.

___
Python tracker <[EMAIL PROTECTED]>

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



[issue1432] Strange behavior of urlparse.urljoin

2008-07-17 Thread Alexandr Zamaraev

Changes by Alexandr Zamaraev <[EMAIL PROTECTED]>:


--
nosy: +shura_zam

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3396] rlcompleter can't autocomplete members of callable objects

2008-07-17 Thread Manuel Muradás

Manuel Muradás <[EMAIL PROTECTED]> added the comment:

Oops, you are right. If that is the way we should handle this
regression, I could upload a patch. I also thought we could use
"hasattr", but that means using "getattr" twice. Something like:

if word[:n] == attr and word != "__builtins__" and hasattr(object, word):
val = getattr(object, word)

What do you think about it?

--
nosy: +dieresys

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Ronald Oussoren

Ronald Oussoren <[EMAIL PROTECTED]> added the comment:

This patch is wrong, it drops the call to 'arch' entirely even when the 
call is needed.

The suggestion for "ARCHPREFERENCE" won't work though, "arch" doesn't take 
arguments at all on 10.4.


BTW. This is a duplicate of issue 3381, which includes a patch for fixing 
the issue.

--
resolution:  -> duplicate
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3381] `./configure --enable-framework --enable-universalsdk` fails because of change in r63997

2008-07-17 Thread Ronald Oussoren

Ronald Oussoren <[EMAIL PROTECTED]> added the comment:

Whoops, issue 3393 is a duplicate of this issue and notes that 
Mac/IDLE/Makefile.in is also affected.

I've fixed that makefile in r65091.

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3381] `./configure --enable-framework --enable-universalsdk` fails because of change in r63997

2008-07-17 Thread Trent Mick

Trent Mick <[EMAIL PROTECTED]> added the comment:

Ronald,

The @ARCH_RUN_32BIT@ also needs to be added to two places in
Mac/Makefile.in (as indicated in issue 3393), no? Would you like me to
make that change?

___
Python tracker <[EMAIL PROTECTED]>

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



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

2008-07-17 Thread Christopher Brannon

Christopher Brannon <[EMAIL PROTECTED]> added the comment:

Here is a patch containing code and a unit test.  I set external_attr
to 0600, for the following reason.
When I extract with Infozip, my umask is ignored when setting permissions of
extracted entries.  They have the permissions assigned to them when archived.
tar does respect umask, but it's not pertinent.
The following shell script demonstrates Infozip's behavior:

=begin=
#!/bin/sh
mkdir ziptest_dir
echo hello > ziptest_dir/foo.txt
chmod 666 ziptest_dir/foo.txt
zip -r ziptest_file.zip ziptest_dir/
rm -rf ziptest_dir
umask 077
unzip ziptest_file.zip
=end=

Setting permissions to 0600 seems like the safest course.

I'm not sure if this patch should be accompanied by some documentation,
since the zipfile docs don't say much about external_attr or permissions.

PS.  My earlier comments about timestamps were incorrect and spurious!

--
keywords: +patch
Added file: http://bugs.python.org/file10933/writestr_usable_permissions.diff

___
Python tracker <[EMAIL PROTECTED]>

___Index: Lib/zipfile.py
===
--- Lib/zipfile.py  (revision 65056)
+++ Lib/zipfile.py  (working copy)
@@ -2,7 +2,7 @@
 Read and write ZIP files.
 """
 import struct, os, time, sys, shutil
-import binascii, cStringIO
+import binascii, cStringIO, stat
 
 try:
 import zlib # We may need its compression method
@@ -1064,6 +1064,8 @@
 zinfo = ZipInfo(filename=zinfo_or_arcname,
 date_time=time.localtime(time.time())[:6])
 zinfo.compress_type = self.compression
+# zinfo.external_attr = 0600 << 16
+zinfo.external_attr = (stat.S_IRUSR | stat.S_IWUSR) << 16
 else:
 zinfo = zinfo_or_arcname
 
Index: Lib/test/test_zipfile.py
===
--- Lib/test/test_zipfile.py(revision 65056)
+++ Lib/test/test_zipfile.py(working copy)
@@ -372,6 +372,20 @@
 # remove the test file subdirectories
 shutil.rmtree(os.path.join(os.getcwd(), 'ziptest2dir'))
 
+def zip_test_writestr_permissions(self, f, compression):
+# Make sure that writestr creates files with mode 0600,
+# when it is passed a name rather than a ZipInfo instance.
+
+self.makeTestArchive(f, compression)
+zipfp = zipfile.ZipFile(f, "r")
+zinfo = zipfp.getinfo('strfile')
+self.assertEqual(zinfo.external_attr, 0600 << 16)
+
+def test_writestr_permissions(self):
+for f in (TESTFN2, TemporaryFile(), StringIO()):
+self.zip_test_writestr_permissions(f, zipfile.ZIP_STORED)
+
+
 def tearDown(self):
 os.remove(TESTFN)
 os.remove(TESTFN2)
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Ronald Oussoren

Ronald Oussoren <[EMAIL PROTECTED]> added the comment:

The current trunk should be correct, there are no explicit calls to the 
arch command left, all go through the configure replacement magic.

To test if everything is correct now someone should test the following 
scenarios:

* Build --enable-framework --enable-universalsdk on 10.4

* Build --enable-framework --enable-universalsdk on 10.5

* Build --enable-framework --enable-universalsdk --with-universal-
archs=all on 10.5

I cannot test the first one, and will test the last one (which is the 
one I'm most interested in).

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Ronald Oussoren

Ronald Oussoren <[EMAIL PROTECTED]> added the comment:

BTW. There is a "--with-framework-name" argument to configure that makes 
it possible to have several indepenend framework installations

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3393] `cd Mac && make installmacsubtree` fails on Mac OS X < 10.5 because of r63955

2008-07-17 Thread Trent Mick

Trent Mick <[EMAIL PROTECTED]> added the comment:

> The current trunk should be correct, there are no explicit calls to the
> arch command left, all go through the configure replacement magic.


$ svn info
Path: .
URL: svn+ssh://[EMAIL PROTECTED]/python/trunk/Mac
Repository Root: svn+ssh://[EMAIL PROTECTED]
Repository UUID: 6015fed2-1504-0410-9fe1-9d1591cc4771
Revision: 65091
Node Kind: directory
Schedule: normal
Last Changed Author: ronald.oussoren
Last Changed Rev: 65091
Last Changed Date: 2008-07-17 22:48:03 -0700 (Thu, 17 Jul 2008)
Properties Last Updated: 2008-07-17 22:55:32 -0700 (Thu, 17 Jul 2008)

[EMAIL PROTECTED]:~/src/python/Mac]
$ svn up Makefile.in
At revision 65091.
[EMAIL PROTECTED]:~/src/python/Mac]
$ grep "arch -" Makefile.in
$(RUNSHARED) arch -ppc -i386 $(BUILDPYTHON)
$(srcdir)/scripts/BuildApplet.py \
$(RUNSHARED) arch -ppc -i386 $(BUILDPYTHON) $(CACHERSRC) -v
$(DESTDIR)$(MACLIBDEST) $(DESTDIR)$(MACTOOLSDEST)


Apologies if I am missing something. Your patches for issue 3381 did
not include a change to Mac/Makefile.in.

Trent

___
Python tracker <[EMAIL PROTECTED]>

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



[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

Mark Dickinson <[EMAIL PROTECTED]> added the comment:

Okay:  I just tried the following:

(1) clean svn checkout
(2) ./configure && make
(3) 100 runs of test_multiprocessing, via the shell command:
for ((i=0;i<100;i+=1)); do ./python.exe 
Lib/test/test_multiprocessing.py; sleep 1; done

I got 4 failed runs out of those 100 runs (details below);  2 hangs in 
test_notify_all, a KeyError in test_remote, and a failure of 
test_number_of_objects.

Failed run 1

test_notify_all (__main__.WithManagerTestCondition) ... Process Process-
48:
Traceback (most recent call last):
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 232, in _bootstrap
self.run()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 88, in run
self._target(*self._args, **self._kwargs)
  File "Lib/test/test_multiprocessing.py", line 600, in f
cond.acquire()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/managers.py", 
line 946, in acquire
return self._callmethod('acquire', (blocking,))
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/managers.py", 
line 718, in _callmethod
self._connect()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/managers.py", 
line 705, in _connect
conn = self._Client(self._token.address, authkey=self._authkey)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/connection.py", 
line 133, in Client
c = SocketClient(address)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/connection.py", 
line 254, in SocketClient
s.connect(address)
  File "", line 1, in connect
error: [Errno 61] Connection refused
^CProcess PoolWorker-5:4:
Traceback (most recent call last):
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 232, in _bootstrap
Process PoolWorker-5:3:
Traceback (most recent call last):
self.run()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 88, in run
self._target(*self._args, **self._kwargs)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/pool.py", line 
57, in worker
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 232, in _bootstrap
task = get()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/queues.py", 
line 337, in get
self.run()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 88, in run
self._target(*self._args, **self._kwargs)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/pool.py", line 
57, in worker
racquire()
KeyboardInterrupt
task = get()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/queues.py", 
line 337, in get
racquire()
KeyboardInterrupt
Process PoolWorker-5:1:
Traceback (most recent call last):
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 232, in _bootstrap
Process Process-50:
Process Process-49:
Traceback (most recent call last):
self.run()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 88, in run
self._target(*self._args, **self._kwargs)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 232, in _bootstrap
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/pool.py", line 
57, in worker
task = get()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/queues.py", 
line 339, in get
self.run()
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/process.py", 
line 88, in run
self._target(*self._args, **self._kwargs)
  File "Lib/test/test_multiprocessing.py", line 602, in f
return recv()
KeyboardInterrupt
cond.wait(timeout)
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/managers.py", 
line 959, in wait
return self._callmethod('wait', (timeout,))
Traceback (most recent call last):
  File "Lib/test/test_multiprocessing.py", line 1786, in 
  File 
"/Users/dickinsm/python_source/trunk/Lib/multiprocessing/managers.py", 
line 722, in _callmethod
kind, result = conn.recv()
KeyboardInterrupt
main()
  File "Lib/test/test_multiprocessing.py", line 1783, in main
test_main(unittest.TextTestRunner(verbosity=2).run)
  File "Lib/test/test_multiprocessing.py", line 1773, in test_main
run(suite)
  File "/Users/dickinsm/python_source/trunk/Lib/unittest.py", line 750, 
in run
Process PoolWorker-5:2:
test(result)
  File "/Users/dickinsm/python_source/trunk/Lib/unittest.py", line 461, 
in __call__
return self.run(*args, **kwds)
  File "/Users/dickinsm/python_source/trunk/Lib/unittest.py", line 457, 
in run
test(result)
  File "/Users/dickinsm/python_source/trunk/Lib/unittest.py", line 461, 
in __call__
return self.run(*args, **kwds)
  File "/Users/dickinsm/python_source/trunk/Lib/unittest.py", line 457, 
in run
test(result)
  File "/Users/dickinsm/python_source/trunk/L

[issue3399] Memory corruption in multiprocessing module, OS X 10.5.4

2008-07-17 Thread Mark Dickinson

Mark Dickinson <[EMAIL PROTECTED]> added the comment:

I should add to the previous message that this was revision 65090, and
that it was a non-debug build.

___
Python tracker <[EMAIL PROTECTED]>

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