[ python-Bugs-1178510 ] configure: refuses setgroups

2005-04-08 Thread SourceForge.net
Bugs item #1178510, was opened at 2005-04-07 14:53
Message generated for change (Comment added) made by zosh
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178510&group_id=5470

Category: Build
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: zosh (zosh)
Assigned to: Nobody/Anonymous (nobody)
Summary: configure: refuses setgroups

Initial Comment:
On Irix 6.5 with MIPS cc 7.30 configure refuses to recognize
the existence of "setgroups". 

configure:14453: checking for setgroups
configure:14477: cc -c -g  conftest.c >&5
cc-1020 cc: ERROR File = conftest.c, Line = 159
  The identifier "setgroups" is undefined.

  void* p = setgroups
 ...
1 error detected in the compilation of "conftest.c".
configure:14483: $? = 2
configure: failed program was:
| /* confdefs.h.  */
...
| #include 
| #ifdef HAVE_GRP_H
| #include 
| #endif
| 
| int
| main ()
| {
| void* p = setgroups
|   ;
|   return 0;
| }

When I compile a short test program that includes only unistd.h
with cc, it reports no errors.

So I had to manipulate pyconfig.h by hand to force the desired
behaviour. Is this a known issue? Please tell me if I have to
perform other test on my box to solve the issue.

--

>Comment By: zosh (zosh)
Date: 2005-04-08 09:51

Message:
Logged In: YES 
user_id=1254741

My test program that compiled correctly with "cc -c -g":

#include 
int main ()
{
 void *p = setgroups;
 return 0;
}

The definition of setgroups in :
#if _SGIAPI
...
#if defined(_BSD_COMPAT)
extern int setgroups(int, int *);
#else   /* !_BSD_COMPAT */
extern int setgroups(int, const gid_t *);
#endif /* _BSD_COMPAT */
...
#endif /* _SGIAPI */

So it should catch one of these defines.



--

Comment By: Martin v. Löwis (loewis)
Date: 2005-04-08 00:50

Message:
Logged In: YES 
user_id=21627

When you say "I compile a short test program that includes
only unistd.h" did you literally mean a program that only
includes unistd.h (i.e. has no main function)? If not, what
is the short program? In particular, make sure it includes
the line

void *p = setgroups;

Please locate the declaration of setgroups in unistd.h (or
whereever it is declared), and report whether this is in a
conditional compilation section, and if so, what precisely
the condition is.

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178510&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-660083 ] GNU readline 4.2 prompt issue

2005-04-08 Thread SourceForge.net
Bugs item #660083, was opened at 2002-12-30 17:47
Message generated for change (Comment added) made by mwh
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=660083&group_id=5470

Category: Extension Modules
>Group: 3rd Party
>Status: Closed
>Resolution: Out of Date
Priority: 5
Submitted By: Guido van Rossum (gvanrossum)
Assigned to: Nobody/Anonymous (nobody)
Summary: GNU readline 4.2 prompt issue

Initial Comment:
When Python is linked with GNU readline 4.2, using
raw_input() without a prompt causes the most recent
non-empty prompt to be used. GNU readline 4.1 and
before don't have this behavior. I don't want it,  but
I don't know how to disable it (I am passing an empty
string for the prompt to readline()).

--

>Comment By: Michael Hudson (mwh)
Date: 2005-04-08 09:06

Message:
Logged In: YES 
user_id=6656

Oops, I have readline 4.3 too.

Still, I'm going to close this as out of date/3rd party.

--

Comment By: Guido van Rossum (gvanrossum)
Date: 2005-04-07 17:46

Message:
Logged In: YES 
user_id=6380

Me neither, but then I've got GNU readline 4.3 here, not
4.2, and I'm to lazy to try to reproduce it.

Assuming that you actually tested with 4.2, just close it.

--

Comment By: Michael Hudson (mwh)
Date: 2005-04-07 09:55

Message:
Logged In: YES 
user_id=6656

I can't reproduce this.

(looking at old open readline bugs -- me?)

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=660083&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-1168983 ] ftplib.py string index out of range

2005-04-08 Thread SourceForge.net
Bugs item #1168983, was opened at 2005-03-23 10:05
Message generated for change (Comment added) made by vmlinuxz
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1168983&group_id=5470

Category: Python Library
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: David Carroll (vmlinuxz)
Assigned to: Nobody/Anonymous (nobody)
Summary: ftplib.py string index out of range

Initial Comment:
The following code works great on all of the 2.3.x
releases I have used.

def
ftpFetch(localPath,remoteFileDate,ftpSite,ftpPass,ftpDir,ftpUser):
print "Fetching split_mgr report"
fileList=[]
processList=[]
ftp = FTP(ftpSite)
ftp.login(ftpUser,ftpPass)   
ftp.dir('LIST '+ftpDir,fileList.append)
for x in range(len(fileList)):
if (string.find(fileList[x],remoteFileDate) != -1):
print fileList[x]
TMP=fileList[x]
output=localPath+str(TMP[45:])
print output
processList.append(output)
print processList
outfile = open(output,'w')
ftp.retrbinary('RETR '+ftpDir+TMP[45:],
open(output, 'wb').write)
ftp.quit()
print processList
return processList

However I get the following error under 2.4

Traceback (most recent call last):
  File
"C:\Python24\lib\site-packages\PythonCard\widget.py",
line 417, in _dispatch
handler(background, aWxEvent)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\readwaitreport.py",
line 61, in on_btnRun_command
mainRwclassLoop(self, mm+dd+yy, yesterday)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\rwclass.py",
line 39, in mainRwclassLoop
processList =
ftpFetch(localPath,"split_mgr."+date[0:4],ftpSite,ftpPass,ftpDir,ftpUser)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\rwclass.py",
line 173, in ftpFetch
ftp.dir('LIST '+ftpDir,fileList.append)
  File "C:\Python24\lib\ftplib.py", line 464, in dir
self.retrlines(cmd, func)
  File "C:\Python24\lib\ftplib.py", line 396, in retrlines
conn = self.transfercmd(cmd)
  File "C:\Python24\lib\ftplib.py", line 345, in
transfercmd
return self.ntransfercmd(cmd, rest)[0]
  File "C:\Python24\lib\ftplib.py", line 328, in
ntransfercmd
if resp[0] != '1':
IndexError: string index out of range

https://lists.dulug.duke.edu/pipermail/yum/2004-August/005067.html
discusses a similar problem under Linux in the YUM
script, I have reproduced this error under 2000, and XP.

I'm a fairly new programmer, and thus very new to
python so I hope this is enough information.  I will
try and keep track of this and help out with more
information in any capacity I can.

Thank you for all your hard work and dedication.
David Carroll

--

>Comment By: David Carroll (vmlinuxz)
Date: 2005-04-08 10:13

Message:
Logged In: YES 
user_id=684143

I achieve the same results with the following code.

ftp = FTP('ftp.cdrom.com')
ftp.login('anonymous', 'anonymous@')
ftp.retrlines('LIST')

This code works just fine with your patched ftplib.py, or
the old ftplib.py against all public internet ftp servers I
have tried it on.  It works on the server at work only
sporadically,, and  raising the protocol exception the rest
of the time.  I'm inclined to think that there may be a
problem with the protocol implementation on the server side.
 The server software version is  wu-2.6.2(1), and the only
oddity I see with it is a pretty sizeable delay before
giving the login.  Up to 10 seconds.  

I'd love to get a pointer of where to take this debugging
process next.  Perhaps I need to use a sniffer on the
connection or something.  I would love to see what ftplib.py
is getting back that is breaking it.



--

Comment By: David Carroll (vmlinuxz)
Date: 2005-04-07 09:51

Message:
Logged In: YES 
user_id=684143

Thank you for leaving this open.  I will try and get your
example today.  I'm too uneducated to realize what I'm doing
wrong, so maybe you can use my ignorance for the common good
=).  

--

Comment By: Raymond Hettinger (rhettinger)
Date: 2005-04-05 04:31

Message:
Logged In: YES 
user_id=80475

I fixed the IndexError.  It should have been a protocol
error.  See Lib/ftplib.py  1.74.

Leaving the bug open so the OP can make a more detailed post
so we can see what the root issue is about.

--

Comment By: Ilya Sandler (isandler)
Date: 2005-04-05 03:37

Message:
Logged In: YES 
user_id=971153

It turns out that the code in plain text bug report is more
or less readable, so I can see what you were trying to do...

Seems like you are doing 
  ftp.dir("LIST "+ftpDir)

But ftplib docs:
http://www.python.org/doc/cur

[ python-Bugs-1168983 ] ftplib.py string index out of range

2005-04-08 Thread SourceForge.net
Bugs item #1168983, was opened at 2005-03-23 10:05
Message generated for change (Settings changed) made by vmlinuxz
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1168983&group_id=5470

Category: Python Library
Group: Python 2.4
Status: Open
>Resolution: Accepted
Priority: 5
Submitted By: David Carroll (vmlinuxz)
>Assigned to: Raymond Hettinger (rhettinger)
Summary: ftplib.py string index out of range

Initial Comment:
The following code works great on all of the 2.3.x
releases I have used.

def
ftpFetch(localPath,remoteFileDate,ftpSite,ftpPass,ftpDir,ftpUser):
print "Fetching split_mgr report"
fileList=[]
processList=[]
ftp = FTP(ftpSite)
ftp.login(ftpUser,ftpPass)   
ftp.dir('LIST '+ftpDir,fileList.append)
for x in range(len(fileList)):
if (string.find(fileList[x],remoteFileDate) != -1):
print fileList[x]
TMP=fileList[x]
output=localPath+str(TMP[45:])
print output
processList.append(output)
print processList
outfile = open(output,'w')
ftp.retrbinary('RETR '+ftpDir+TMP[45:],
open(output, 'wb').write)
ftp.quit()
print processList
return processList

However I get the following error under 2.4

Traceback (most recent call last):
  File
"C:\Python24\lib\site-packages\PythonCard\widget.py",
line 417, in _dispatch
handler(background, aWxEvent)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\readwaitreport.py",
line 61, in on_btnRun_command
mainRwclassLoop(self, mm+dd+yy, yesterday)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\rwclass.py",
line 39, in mainRwclassLoop
processList =
ftpFetch(localPath,"split_mgr."+date[0:4],ftpSite,ftpPass,ftpDir,ftpUser)
  File "C:\Documents and
Settings\PROTECTED\Desktop\ReadWaitReport\ReadWaitReport\rwclass.py",
line 173, in ftpFetch
ftp.dir('LIST '+ftpDir,fileList.append)
  File "C:\Python24\lib\ftplib.py", line 464, in dir
self.retrlines(cmd, func)
  File "C:\Python24\lib\ftplib.py", line 396, in retrlines
conn = self.transfercmd(cmd)
  File "C:\Python24\lib\ftplib.py", line 345, in
transfercmd
return self.ntransfercmd(cmd, rest)[0]
  File "C:\Python24\lib\ftplib.py", line 328, in
ntransfercmd
if resp[0] != '1':
IndexError: string index out of range

https://lists.dulug.duke.edu/pipermail/yum/2004-August/005067.html
discusses a similar problem under Linux in the YUM
script, I have reproduced this error under 2000, and XP.

I'm a fairly new programmer, and thus very new to
python so I hope this is enough information.  I will
try and keep track of this and help out with more
information in any capacity I can.

Thank you for all your hard work and dedication.
David Carroll

--

Comment By: David Carroll (vmlinuxz)
Date: 2005-04-08 10:13

Message:
Logged In: YES 
user_id=684143

I achieve the same results with the following code.

ftp = FTP('ftp.cdrom.com')
ftp.login('anonymous', 'anonymous@')
ftp.retrlines('LIST')

This code works just fine with your patched ftplib.py, or
the old ftplib.py against all public internet ftp servers I
have tried it on.  It works on the server at work only
sporadically,, and  raising the protocol exception the rest
of the time.  I'm inclined to think that there may be a
problem with the protocol implementation on the server side.
 The server software version is  wu-2.6.2(1), and the only
oddity I see with it is a pretty sizeable delay before
giving the login.  Up to 10 seconds.  

I'd love to get a pointer of where to take this debugging
process next.  Perhaps I need to use a sniffer on the
connection or something.  I would love to see what ftplib.py
is getting back that is breaking it.



--

Comment By: David Carroll (vmlinuxz)
Date: 2005-04-07 09:51

Message:
Logged In: YES 
user_id=684143

Thank you for leaving this open.  I will try and get your
example today.  I'm too uneducated to realize what I'm doing
wrong, so maybe you can use my ignorance for the common good
=).  

--

Comment By: Raymond Hettinger (rhettinger)
Date: 2005-04-05 04:31

Message:
Logged In: YES 
user_id=80475

I fixed the IndexError.  It should have been a protocol
error.  See Lib/ftplib.py  1.74.

Leaving the bug open so the OP can make a more detailed post
so we can see what the root issue is about.

--

Comment By: Ilya Sandler (isandler)
Date: 2005-04-05 03:37

Message:
Logged In: YES 
user_id=971153

It turns out that the code in plain text bug report is more
or less readable, so I can see what you were trying to do...

Seems like you are doing 
  ftp.dir("LIST "+ftpDir)

But ftplib docs:
http://www.pytho

[ python-Bugs-1179168 ] IDLE bug - changing shortcuts

2005-04-08 Thread SourceForge.net
Bugs item #1179168, was opened at 2005-04-08 13:54
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1179168&group_id=5470

Category: IDLE
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Przemysław Gocyła (bld_d16)
Assigned to: Nobody/Anonymous (nobody)
Summary: IDLE bug - changing shortcuts

Initial Comment:
On Python 2.4.1 on WinXP I have changed keyboard 
shortcut settings for indent/unindent.
New shorcut was Tab/Shift+Tab.

When I did it IDLE hanged up and I could not to launch it 
again.

I have tried everything. Uninstall whole Python and then 
reinstall (tried both version 2.3 and 2.4).
It just looks like from the change of shortcuts IDLE don't 
works.

I tried to:
  import idlelib.PyShell
  idlelib.PyShell.main()
and result with bug are in attachment

Where is the information about IDLE shortcuts keeped ?
Why IDLE remember this even after reinstall ?
How to fix it up?

Best regards,
Przemek

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1179168&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-1178145 ] urllib2.py assumes 206 is an error

2005-04-08 Thread SourceForge.net
Bugs item #1178145, was opened at 2005-04-06 18:52
Message generated for change (Comment added) made by jimjjewett
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178145&group_id=5470

Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Barry Alan Scott (barry-scott)
Assigned to: Nobody/Anonymous (nobody)
Summary: urllib2.py assumes 206 is an error

Initial Comment:
I'm writting code that uses the Range header. The
correct response is 206, but the urllib2.py is coded to
treat any code that is not 200 as error. The correct
code needs to treat 200 to 299 as success.

The attached patch fixes the problem.


--

Comment By: Jim Jewett (jimjjewett)
Date: 2005-04-08 12:17

Message:
Logged In: YES 
user_id=764593

Please re-attach.  SF didn't get the file.

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178145&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-1178141 ] urllib.py overwrite HTTPError code with 200

2005-04-08 Thread SourceForge.net
Bugs item #1178141, was opened at 2005-04-06 18:48
Message generated for change (Comment added) made by jimjjewett
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178141&group_id=5470

Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Barry Alan Scott (barry-scott)
Assigned to: Nobody/Anonymous (nobody)
Summary: urllib.py overwrite HTTPError code with 200

Initial Comment:
I found this bug while trying to understand why a 404
Not Found error was reported as a 200 Not Found.

Turns out the HTTPError's self.code is overwritten with
200 after
the 404 was correctly assigned.

The attached patch fixes the problem.


--

Comment By: Jim Jewett (jimjjewett)
Date: 2005-04-08 12:18

Message:
Logged In: YES 
user_id=764593

Please reattach (SF didn't catch the file)

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1178141&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-1179412 ] can't import thru cygwin symlink

2005-04-08 Thread SourceForge.net
Bugs item #1179412, was opened at 2005-04-08 15:42
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1179412&group_id=5470

Category: Windows
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: steveward (steveward)
Assigned to: Nobody/Anonymous (nobody)
Summary: can't import thru cygwin symlink

Initial Comment:
This may be a cygwin-specific problem: given foo.py:

> ln -s foo.py bar.py
> python
Python 2.4 (#1, Dec  4 2004, 20:10:33)
[GCC 3.3.3 (cygwin special)] on cygwin
Type "help", "copyright", "credits" or "license" for more 
information.
>>> import foo
This is file foo.py.
>>> import bar
Traceback (most recent call last):
  File "", line 1, in ?
ImportError: No module named bar

Despite the problem with imports,  most os.path utilities 
(exists, isfile, islink, isdir) work on cygwin symlinks.   
An exception is reailpath: realpath("bar.py") returns a 
path to the symlink, not to the real file.

Suspecting this as a key to the import problem, I tried 
several recent python/cygwin release versions (all 
installed via cygwin's setup.exe).  
FIndings: 

 Cygwin   Python   realpath  Import
  1.5.xx:  2.yy:   Works?  Works?
  -  --  ---  --
 1.5.14 2.4NO  NO
 1.5.13   2.3.4 YES  NO
 1.5.14   2.3.4 YES  NO
 1.5.12 2.4NOYES

Neither bug shows up under Linux.

The two problems seem uncorrelated, although it may 
be that each is due to some assumpion about symlink 
semantics that isn't true of the Cygwin implementation.

Apologies if these problems have been previously 
submitted in a form my quick scan didn't identify.  A 
corresponding note has been submitted to the cygwin 
mailing list.

- Steve
 

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1179412&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[ python-Bugs-1176012 ] compiler module didn't get updated for "class foo():pass"

2005-04-08 Thread SourceForge.net
Bugs item #1176012, was opened at 2005-04-03 14:21
Message generated for change (Comment added) made by bcannon
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1176012&group_id=5470

Category: Python Library
Group: Python 2.5
>Status: Closed
>Resolution: Accepted
Priority: 5
Submitted By: logistix (logistix)
Assigned to: Brett Cannon (bcannon)
Summary: compiler module didn't get updated for "class foo():pass"

Initial Comment:
Patch with fix and testcase is attached.

--

>Comment By: Brett Cannon (bcannon)
Date: 2005-04-08 19:34

Message:
Logged In: YES 
user_id=357491

OK, committed in rev. XXX for Modules/parsermodule.c, rev.
XXX for Lib/test/test_parser.py, rev. XXX for
Lib/compiler/transformer.py, and rev. XXX for
Lib/test/test_compiler.py .

Only change from patch to what was committed was changing
the formatting for parsermodule.c to meet the coding
standard and a bug where an assignment was being made
instead of a comparison.

Closed as fixed.  Thanks, logistix.

--

Comment By: logistix (logistix)
Date: 2005-04-03 15:01

Message:
Logged In: YES 
user_id=699438

The parser module didn't get corrected either.  Here is 
another patch with test case for that.

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1176012&group_id=5470
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com