[issue7586] Typo in collections documentation

2009-12-28 Thread Georg Brandl

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

Thanks, fixed in r77084.

--
resolution:  - fixed
status: open - closed

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



[issue7381] subprocess.check_output: docstring has inconsistent leading whitespace

2009-12-28 Thread Georg Brandl

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

OK, applied in r77086, r77087.

--
resolution:  - fixed
status: open - closed

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



[issue7569] ctypes doc improvement: c_char_p

2009-12-28 Thread Georg Brandl

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

Wouldn't a general pointer better be of type c_void_p?

--

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



[issue7578] Behavior of operations on a closed file object is not documented correctly

2009-12-28 Thread Georg Brandl

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

I agree; though I would wish for a bit finer-grained I/O related
exceptions...

--

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



[issue7578] Behavior of operations on a closed file object is not documented correctly

2009-12-28 Thread Georg Brandl

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


--
assignee: georg.brandl - pitrou

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



[issue7530] doc of multiprocessing.managers is wrong (server_forever)

2009-12-28 Thread Georg Brandl

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


--
assignee: georg.brandl - jnoller

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



[issue7033] C/API - Document exceptions

2009-12-28 Thread Georg Brandl

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

Thanks for the patch! I rewrote the C function a bit to also take a dict
argument, and added a test for that.  Committed in r77088.  Will merge
to py3k.

--
resolution:  - accepted
status: open - closed

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



[issue1286] fileinput, StringIO, and cStringIO do not support the with protocol

2009-12-28 Thread Georg Brandl

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

FWIW, for the sake of consistency I'm +1 on supporting the context
manager protocol on all file-like objects in the stdlib.

--

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



[issue7404] optparse Documentation References Example Files that do not Exist

2009-12-28 Thread Georg Brandl

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

Thanks for the report. I removed the references in r77092.

--
resolution:  - fixed
status: open - closed

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



[issue7033] C/API - Document exceptions

2009-12-28 Thread lekma

lekma lekma...@gmail.com added the comment:

 Thanks for the patch! I rewrote the C function a bit to also take a dict
 argument, and added a test for that.  Committed in r77088.  Will merge
 to py3k.

Great!
Thanks to all for the help!

--

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



[issue7587] Python 3.1.1 source build issues

2009-12-28 Thread Anurag

New submission from Anurag anurag.sharma@gmail.com:

Hi

I downloaded the source for Python-3.1.1 for windows x86. I followed the
instructions in the PCbuild\Readme.txt file to build python

Basically, all I did was
1.  Open the “PCbuild\pcbuild.sln” in VS2008.
2.  Select the “Win32” as Solution Platform and “Release” as Solution
Configuration
3.  Build Solution (F6)

I got the following error messages
Error  1  fatal error C1083: Cannot open source file:
'..\..\sqlite-3.5.9\sqlite3.c': No such file or directory   c1 
  sqlite3
Error  11   fatal error C1083: Cannot open include file:
'bzlib.h': No such file or directory  
Desktop\Python-3.1.1__\Python-3.1.1\Modules\bz2module.c 12   bz2
Error  12   fatal error C1083: Cannot open include file:
'tcl.h': No such file or directory  
Desktop\Python-3.1.1__\Python-3.1.1\Modules\_tkinter.c   66
  _tkinter
Error  13   fatal error C1083: Cannot open include file:
'tcl.h': No such file or directory  
Desktop\Python-3.1.1__\Python-3.1.1\Modules\tkappinit.c  16
  _tkinter
Error  14   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  15   error PRJ0019: A tool returned an error code
from Performing Pre-Build Event...   _ssl_ssl
Error  16   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  17   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  18   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  19   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  20   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  21   fatal error C1083: Cannot open include file:
'sqlite3.h': No such file or directory  
desktop\python-3.1.1__\python-3.1.1\modules\_sqlite\connection.h 33
  _sqlite3
Error  23   error PRJ0019: A tool returned an error code
from Performing Pre-Build Event...   _hashlib   
_hashlib



To fix the missing sqllite code issue, I did the following
1. I created a folder named sqlite-3.5.9 under Modules. 
2. I downloaded the code for sqlite-3.5.9 (This code is attached). 
3. I copied the downlaoded code for sqlite-3.5.9 under the following
directory
Desktop\Python-3.1.1\Python-3.1.1\Modules\sqlite-3.5.9
4. From the newly copied files, I copied the sqlite3.h file to the
following folder
Desktop\Python-3.1.1\Python-3.1.1\Modules\_sqlite

After this I tried cleaned and build again.

Errors reduced. I got the following errors this time.

Error   1   fatal error C1083: Cannot open source file:
'..\..\sqlite-3.5.9\sqlite3.c': No such file or directory   c1  sqlite3
Error   2   fatal error C1083: Cannot open include file: 'bzlib.h': No such
file or directory
Desktop\Python-3.1.1\Python-3.1.1\Modules\bz2module.c   12  bz2
Error   3   fatal error C1083: Cannot open include file: 'tcl.h': No such
file or directory
Desktop\Python-3.1.1\Python-3.1.1\Modules\_tkinter.c66  _tkinter
Error   4   fatal error C1083: Cannot open include file: 'tcl.h': No such
file or directory
Desktop\Python-3.1.1\Python-3.1.1\Modules\tkappinit.c   16  _tkinter
Error   5   error PRJ0019: A tool returned an error code from Performing
Pre-Build Event... _ssl_ssl
Error   6   fatal error LNK1181: cannot open input file '.\sqlite3.lib'
_sqlite3_sqlite3
Error   7   error PRJ0019: A tool returned an error code from Performing
Pre-Build Event... _hashlib_hashlib


Can someone help me fix these errors.

Thanks in advance


Thanks
Anurag

--
components: Build
files: sqlite-source-3_5_9.zip
messages: 96947
nosy: sharmaag
severity: normal
status: open
title: Python 3.1.1 source build issues
type: compile error
versions: Python 3.1
Added file: http://bugs.python.org/file15683/sqlite-source-3_5_9.zip

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7587
___
___
Python-bugs-list mailing list
Unsubscribe: 

[issue7588] unittest.TestCase.shortDescription isn't short anymore

2009-12-28 Thread Jean-Paul Calderone

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

Sometime between Python 2.6 and 2.7a1, the
unittest.TestCase.shortDescription method changed from returning just
the test method name to the test method name, in parentheses, the fully
qualified Python name of the test case.

This breaks several Twisted unit tests and, I think, goes against the
expectations users have of the shortDescription method.

--
components: Library (Lib)
messages: 96948
nosy: exarkun
severity: normal
status: open
title: unittest.TestCase.shortDescription isn't short anymore
type: behavior
versions: Python 2.7

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



[issue7587] Python 3.1.1 source build issues

2009-12-28 Thread Martin v . Löwis

Martin v. Löwis mar...@v.loewis.de added the comment:

The purpose of this bug tracker is not to obtain help, but to report
bugs etc.

See PCbuild/readme.txt for detailed instructions.

--
nosy: +loewis
resolution:  - invalid
status: open - closed

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



[issue7579] Patch to add docstrings to msvcrt

2009-12-28 Thread Brian Curtin

Brian Curtin cur...@acm.org added the comment:

I fixed up the bodies of the docstrings, removed the weird quotes around
pushed back (copy/paste error), and got the heapmin/locking name fixed up.

Thanks for taking a look at this.

--
Added file: http://bugs.python.org/file15684/msvcrt_docstrings_v2.diff

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



[issue7588] unittest.TestCase.shortDescription isn't short anymore

2009-12-28 Thread R. David Murray

Changes by R. David Murray rdmur...@bitdance.com:


--
nosy: +michael.foord
priority:  - normal

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



[issue7587] Python 3.1.1 source build issues

2009-12-28 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc amaur...@gmail.com added the comment:

To the poster's defense, the paragraph mentioning external.bat is
below the list of the external projects.

--
nosy: +amaury.forgeotdarc

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



[issue1755841] Patch for [ 735515 ] urllib2 should cache 301 redir

2009-12-28 Thread Senthil Kumaran

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

 Antoine Pitrou added the Comment:
  
   
 I have trouble understanding what the patch does. I would expect it to
 cache the original URL - redirected URL mapping, but it seems   
 cache the final HTTP response instead.

Oops. My mistake. I got carried away by my misunderstanding of the RFC
section on 301. The patch is wrong. I coded it to cache the response
from the redirection instead of just the redirected URL.
I shall write the correct one to cache just the redirection.   
   
   
   
 Aren't http_error_301 and friends for internal use?
   
  
Not really. They are exposed methods and I believe are being used by
clients. There have been bug reports related those redirection 
methods. Even the related Issue735515, explains pretty clearly about
the redirection required. (My bad again and my comment in that issue
is irrelevant.) In this issue, John says that there is no obvious need
to change the interface.  

RFC had a statement along the lines that 301 redirection is cached by
default, unless indicated otherwise. This is where I thought, an option
to turn-off the cacheable behavior might be needed.
   
Thanks for looking at this quickly.

--

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



[issue7588] unittest.TestCase.shortDescription isn't short anymore

2009-12-28 Thread Michael Foord

Michael Foord mich...@voidspace.org.uk added the comment:

Personally I agree. I'll see if I can find the change (don't think it
was me) and see if there was some kind of rationale.

--

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



[issue7589] setup.py shouldn't try to build nis module when nis headers aren't available

2009-12-28 Thread Arfrever Frehtes Taifersar Arahesis

New submission from Arfrever Frehtes Taifersar Arahesis 
arfrever@gmail.com:

setup.py shouldn't try to build nis module when nis headers aren't
available (e.g. on uclibc systems). I'm attaching the patch for
setup.py.

--
components: Build
files: python-nis.patch
keywords: patch
messages: 96954
nosy: Arfrever
severity: normal
status: open
title: setup.py shouldn't try to build nis module when nis headers aren't 
available
versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file15685/python-nis.patch

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



[issue7569] ctypes doc improvement: c_char_p

2009-12-28 Thread Nikolaus Rath

Nikolaus Rath nikol...@rath.org added the comment:

I don't want to judge if the best way to represent binary data in C is a
void* or char*, but there is a lot of C code out there that uses char*,
and if we want to interface with such a library we need to use
POINTER(c_char).

Note that my docpatch doesn't say anything about using void_p or not:
For a general *character* pointer that may point to binary data,
POINTER(c_char) must be used. This refers only to char*, so if the C
code uses void* instead, we can of course also use c_void_p on the
Python side.

--

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



[issue7589] setup.py shouldn't try to build nis module when nis headers aren't available

2009-12-28 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +loewis

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



[issue735515] urllib / urllib2 should cache 301 redirections

2009-12-28 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
dependencies:  -Patch for [ 735515 ] urllib2 should cache 301 redir
resolution:  - duplicate
status: open - closed
superseder:  - Patch for [ 735515 ] urllib2 should cache 301 redir

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



[issue7559] TestLoader.loadTestsFromName swallows import errors

2009-12-28 Thread Salman Haq

Salman Haq salman@gmail.com added the comment:

I'm attaching a patch (against trunk) which I think is a step in the
right direction but I could use some feedback. 

This patch modifies 'loadTestsFromName()' so that it saves and re-raises
an ImportError.

Further this patch introduces a new unittest
(test_loadTestsFromName__badimport) and slightly modifies two existing
unittests (test_loadTestsFromName__unknown_attr_name,
test_loadTestsFromNames__unknown_attr_name) in test_unittest.py. Also, I
think a second new unittest is needed (test_loadTestsFromNames__badimport).

--
keywords: +patch
Added file: http://bugs.python.org/file15686/issuee7559_trunk_patch.diff

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



[issue6283] Cannot build extension in amd64 using msvc9compiler

2009-12-28 Thread Stefan Krah

Stefan Krah stefan-use...@bytereef.org added the comment:

Duplicate of issue 7511.

--
nosy: +skrah

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



[issue1755841] Patch for [ 735515 ] urllib2 should cache 301 redir

2009-12-28 Thread R. David Murray

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

I haven't reviewed the patch, but I would like the caching behavior to
be settable.  I can easily imagine a use case where I would not want the
URLs cached: when using urllib in a test suite or test tool.  (I just
ran into this problem trying to use firefox as a test tool...at the time
I was doing it I wasn't aware that firefox cached the 301 responses).

--
nosy: +r.david.murray

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



[issue7569] ctypes doc improvement: c_char_p

2009-12-28 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

The suggestion looks good to me.

--
nosy: +pitrou

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



[issue7585] [patch] difflib should separate filename from timestamp with tab

2009-12-28 Thread Brian Curtin

Brian Curtin cur...@acm.org added the comment:

I don't think the conditional checks around the timestamps are
necessary. Couldn't you just put the \t directly in the string that gets
yielded? That way the chunk headers always follow the same format.

--
nosy: +brian.curtin

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



[issue7582] [patch] diff.py to use iso timestamp

2009-12-28 Thread Brian Curtin

Brian Curtin cur...@acm.org added the comment:

Look at time.timezone -
http://docs.python.org/library/time.html#time.timezone

# I'm in US Central time, so it's -6 from UTC
 import time
 tz = time.timezone
 tz
21600
 tz / 60 / 60
6

--
nosy: +brian.curtin

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Greg

Greg greg.helli...@gmail.com added the comment:

Did this ever happen?  It seems like overkill in the non-Python sort of 
way to continue pointing people to over-riding classes and extending 
objects when such a small patch adds so powerful and useful a 
functionality to the library.

--
nosy: +greg.hellings

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



[issue2204] document ConfigParser behaviour when a file has same section multiple times

2009-12-28 Thread honesthacker

Changes by honesthacker jus...@honesthacker.com:


--
nosy: +honesthacker

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread R. David Murray

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

Since Gregory didn't update the ticket, it seems likely that it hasn't
happened yet.  If you'd care to try the patch and report on your
results, that would help the process.  We'll also need unit tests and
documentation updates, so patches for those would also speed the process.

--
keywords: +easy
nosy: +r.david.murray
stage:  - test needed
versions: +Python 3.2 -Python 3.1

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



[issue7590] 'exceptions' module mentioned in documentation

2009-12-28 Thread July Tikhonov

New submission from July Tikhonov july.t...@gmail.com:

As I can see, 'exceptions' module does not exist in py3k.

But it is mentioned in documentation
http://docs.python.org/dev/py3k/library/exceptions.html
The exceptions are defined in the module exceptions. This module never 
needs to be imported explicitly: the exceptions are provided in the 
built-in namespace as well as the exceptions module.

--
assignee: georg.brandl
components: Documentation
messages: 96965
nosy: July, georg.brandl
severity: normal
status: open
title: 'exceptions' module mentioned in documentation
type: behavior
versions: 3rd party

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Greg

Greg greg.helli...@gmail.com added the comment:

Just looking at the indicated file in the 2.6.4 release tarball, it does 
not seem that it would apply cleanly.  The line numbers do not apply 
properly anymore, though the edited lines themselves still appear to be 
unaffected.  Without context diff in the original patch, it's difficult 
for me to asseess exactly which lines should be the affected ones.

Unfortunately, I'm not in a position right now with my job to spend the 
time necessary to produce this as a patch since I'm on a timescale that 
requires equivalent functionality by Wednesday on production systems.  
Modifying it to apply cleanly to the latest versions of Python appears 
like it would be easy, if the internals of that file have not changed 
drastically in structure since 2.6.4.

Documentation should be relatively straightforward as well, since the 
functionality the patch introduces is rather transparent.  Unit tests 
are beyond my expertise to comment on.

Would have loved to have seen this in the 2.7/3.1 series, as it would 
make my task much easier!  I'll keep it in mind for my off time this 
holiday weekend.

--

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



[issue7006] The replacement suggested for callable(x) in py3k is not equivalent

2009-12-28 Thread Benjamin Peterson

Benjamin Peterson benja...@python.org added the comment:

Fixed in r77093.

--
resolution:  - accepted
status: open - closed

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

I'm not sure why this is needed in httplib. Isn't it a matter of
configuring the machine's routing tables properly?

--
nosy: +pitrou

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



[issue7591] test_get_platform fails on 3.1

2009-12-28 Thread Antoine Pitrou

New submission from Antoine Pitrou pit...@free.fr:

This started happening recently on some 3.1 buildbots:

==
FAIL: test_get_platform (distutils.tests.test_util.UtilTestCase)
--
Traceback (most recent call last):
  File
/home/doko/buildarea/3.1.klose-debian-alpha/build/Lib/distutils/tests/test_util.py,
line 99, in test_get_platform
self.assertEquals(get_platform(), 'macosx-10.3-i386')
AssertionError: 'macosx-10.3-x86_64' != 'macosx-10.3-i386'

--

--
assignee: tarek
components: Distutils, Tests
messages: 96969
nosy: pitrou, tarek
priority: normal
severity: normal
stage: needs patch
status: open
title: test_get_platform fails on 3.1
type: behavior
versions: Python 3.1

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



[issue4758] Python 3.x internet documentation needs work

2009-12-28 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
title: Python 3.0 internet documentation needs work - Python 3.x internet 
documentation needs work

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Greg

Greg greg.helli...@gmail.com added the comment:

For my own case, I have a machine with 50 IP addresses set and I need to 
run a script to grab data that will randomly select one of those IP 
addresses to use for its outgoing connection.  That's something which 
needs to be selected at the socket level, as best I understand the issue, 
not on the routing end.

--

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

 For my own case, I have a machine with 50 IP addresses set and I need to 
 run a script to grab data that will randomly select one of those IP 
 addresses to use for its outgoing connection.  That's something which 
 needs to be selected at the socket level, as best I understand the issue, 
 not on the routing end.

Why do you need to select manually between those 50 IP addresses?
Load-balancing? Fooling the remote server so that you don't get
blacklisted for opening too many connections?

The problem I see with adding this to httplib is that it's not
HTTP-specific. Other modules (smtplib etc.) might want to benefit,
depending on the use case.

By the way, what I mean by routing is your OS' internal routing table
for outbound packets. For example under Linux:

# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric RefUse Iface
X.Y.223.0   0.0.0.0 255.255.255.0   U 0  00 eth1
X.Y.222.0   0.0.0.0 255.255.255.0   U 0  00 eth0
0.0.0.0 X.Y.222.254 0.0.0.0 UG10000 eth0

The interface for each outbound route is part of the routing table.

--

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



[issue7578] Behavior of operations on a closed file object is not documented correctly

2009-12-28 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

 I agree; though I would wish for a bit finer-grained I/O related
 exceptions...

I agree with that. It probably needs someone to shepherd the idea to
python-dev so as to get it accepted.

--

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread R. David Murray

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

You are correct that more than just httplib may need this; however, it
is a real need.  Consider for example a machine that has multiple IPs on
the same network (perhaps there used to be two machines but the services
were consolidated onto one or something), and some other server it talks
to is using IP based security in its .htaccess file.  So the client
machine needs to bind to the IP address that the server machine has
authorized to access the web service.  This is why, for example, the ssh
command has a '-b' option to specify the port to which the client binds.
 Or, for an even more apropos example, wget has a --bind-address option
for this reason.

--

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Giampaolo Rodola'

Giampaolo Rodola' billiej...@users.sourceforge.net added the comment:

In case it helps, a guy recently reported the same issue for pyftpdlib:
http://code.google.com/p/pyftpdlib/issues/detail?id=123

--

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Eldon Ziegler

Eldon Ziegler eld...@atlanticdb.com added the comment:

The patch files for Python 2.6 and a test file are in the attached tar
file. Both httplib.py and socket.py need to be patched now.

httplib.HTTPConnection(host[, port[, strict[, timeout]]])

becomes

httplib.HTTPConnection(host[, port[, strict[, timeout[, bindip)

and

httplib.HTTPSConnection(host[, port[, key_file[, cert_file[, strict[,
timeout])

becomes

httplib.HTTPSConnection(host[, port[, key_file[, cert_file[, strict[,
timeout[, bindip]])

--
Added file: http://bugs.python.org/file15687/httplibmod2.6.tar.gz

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread R. David Murray

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

If you want the maximum chance for this to get applied, it would be best
to have one or a set of patch files in 'svn diff' format against trunk
(see http://python.org/dev for information on how to produce such a
patch, specifically section 6.1 of the dev FAQ).  The tests will need to
be in unittest format (they would go in test_httplib and/or test_socket).

I imagine that writing the unittests so they will run on any machine
might be a tad tricky.  If I were doing it I'd try binding to 127.0.0.1
and checking to see that the socket is bound to that address rather than
0.0.0.0 in the binaddr case, and that it is bound to 0.0.0.0 in the
default case.

--

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



[issue7592] ssl module documentation: SSLSocket.unwrap description shown twice

2009-12-28 Thread Michael Newman

New submission from Michael Newman michael.b.new...@gmail.com:

For the ssl module documentation at:
http://docs.python.org/3.1/library/ssl.html

I noticed that SSLSocket.unwrap() description is listed twice in the
17.3.2. SSLSocket Objects section.

--
assignee: georg.brandl
components: Documentation
messages: 96977
nosy: georg.brandl, mnewman
severity: normal
status: open
title: ssl module documentation: SSLSocket.unwrap description shown twice
versions: Python 3.1

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



[issue7582] [patch] diff.py to use iso timestamp

2009-12-28 Thread anatoly techtonik

anatoly techtonik techto...@gmail.com added the comment:

Thanks! Now the most elegant patch I could think out.

--
Added file: http://bugs.python.org/file15688/diff.py_iso_timestamps_true.diff

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



[issue7582] [patch] diff.py to use iso timestamp

2009-12-28 Thread Brian Curtin

Brian Curtin cur...@acm.org added the comment:

Looks cleaner and works for me.

One very minor comment: the spaces inside the parenthesis on the
time.localtime call are inconsistent and don't comply with PEP-8.

--

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



[issue7585] [patch] difflib should separate filename from timestamp with tab

2009-12-28 Thread anatoly techtonik

anatoly techtonik techto...@gmail.com added the comment:

Conditional checks are required to prevent leaving trailing whitespace in 
filename when date component is not present. Such trailing whitespace may 
confuse patch tools. [1]

[1] http://code.google.com/p/python-patch/issues/detail?id=2

--

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



[issue7582] [patch] diff.py to use iso timestamp

2009-12-28 Thread anatoly techtonik

anatoly techtonik techto...@gmail.com added the comment:

Pepeighfied and regenerated. Should be flawless now.

--
Added file: http://bugs.python.org/file15689/diff.py_iso_timestamps_true.diff

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



[issue7582] [patch] diff.py to use iso timestamp

2009-12-28 Thread anatoly techtonik

Changes by anatoly techtonik techto...@gmail.com:


Removed file: http://bugs.python.org/file15688/diff.py_iso_timestamps_true.diff

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



[issue3972] Add Option to Bind to a Local IP Address in httplib.py

2009-12-28 Thread Gregory P. Smith

Gregory P. Smith g...@krypto.org added the comment:

yes its a real need and yes we should support this in the standard 
library.  no i have not had time to look at it since my comment a 14 
months ago.

Thanks for the updated patch Eldon!

--

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



[issue210849] Fwd: Debian Bug#42318: urllib.py has problems with malformed proxy env. variables (PR#59)

2009-12-28 Thread Shinnosuke

Shinnosuke shinnosuke.g...@gmail.com added the comment:

I found a solution of the same errors from Windows, and my solution was
removed the double quote at HTTP_PROXY settings.

--
components: +Windows -Library (Lib)
nosy: +shinnosuke
versions: +Python 2.6

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



[issue7593] Computed-goto patch

2009-12-28 Thread A.M. Kuchling

New submission from A.M. Kuchling li...@amk.ca:

Part of Unladen Swallow's roadmap is to use a threaded-interpreter
technique for the regular expression engine.  That sounded like an
interesting idea, so I went ahead and tried to implement it.

The current patch is attached.  To try it: run configure
--with-computed-gotos; apply the patch; and compile Python.

Still to do:

* Benchmarking, to determine if it's actually an improvement.

* Possibly integrate construction of the Modules/re_opcodes.h file into
the build process.  The current file is supplied; to rebuild it, run
python Modules/makereopcodes.py  Modules/re_opcodes.h. (But it only
needs rebuilding if you add new regex opcodes, which is rarely done --
maybe it's sufficient to include a reminder to update it plus the script).

--
components: Regular Expressions
messages: 96984
nosy: akuchling
severity: normal
status: open
title: Computed-goto patch
versions: Python 3.2

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



[issue7593] Computed-goto patch

2009-12-28 Thread A.M. Kuchling

Changes by A.M. Kuchling li...@amk.ca:


Added file: http://bugs.python.org/file15690/re-computed-goto-v1.txt

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



[issue7593] Computed-goto patch

2009-12-28 Thread Ezio Melotti

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


--
keywords: +needs review, patch
nosy: +ezio.melotti
priority:  - normal
stage:  - patch review
type:  - performance

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



[issue4758] Python 3.x internet documentation needs work

2009-12-28 Thread David M. Beazley

David M. Beazley beaz...@users.sourceforge.net added the comment:

An apology on the delay.  Things have been rather hectic.

Regarding a patch, I don't really have a patch so much as a suggested 
procedure.   Basically, I'm suggesting that the maintainers of the 
library documentation simply do a quick survey of network related 
modules and make it clear that many of the operations work on byte 
strings and not strings. In Python 2.X, you could get away with 
being a little sloppy, but in Python 3, the bytes/strings distinction 
becomes much more prominent.

If I have time, I might be able to make a specific patch, but it 
probably wouldn't be until after PyCON sometime.

--

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



[issue7585] [patch] difflib should separate filename from timestamp with tab

2009-12-28 Thread Brian Curtin

Brian Curtin cur...@acm.org added the comment:

Shouldn't the patch tool handle that? FWIW, both the svn diff and *nix
diff utilities produce headers with the parts split by a tab character.

Would the code in example.py work in your tool to handle both tabs and
spaces?

--
Added file: http://bugs.python.org/file15691/example.py

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



[issue7593] Computed-goto patch

2009-12-28 Thread Martin v . Löwis

Changes by Martin v. Löwis mar...@v.loewis.de:


--
nosy: +loewis

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