[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-22 Thread nestor
nestor nestornis...@gmail.com added the comment: Fantastic. Applied the patch and it solved the problem with xlc 8.0 on AIX 5.3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6236 ___

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread egreen
egreen egr...@operamail.com added the comment: The problem is that the fileio struct in Modules/_io/fileio.c defines the 2-bit seekable field as int. From the C99 standard, ยง6.7.2: for bit-fields, it is implementation-defined whether the specifier int designates the same type as signed int or

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Sridhar Ratnakumar
Changes by Sridhar Ratnakumar sridh...@activestate.com: -- nosy: +srid ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6236 ___ ___ Python-bugs-list

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6236 ___ ___ Python-bugs-list

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Thanks for the patch! Committed in r75007, r75008, r75009, r75010. If there's any problem, please reopen. -- resolution: accepted - fixed status: open - closed versions: +Python 2.6, Python 2.7, Python 3.2

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-07-28 Thread nestor
nestor nestornis...@gmail.com added the comment: Python 3.1 (r31:73572, Jul 9 2009, 16:28:28) [C] on aix5 Type help, copyright, credits or license for more information. import sys sys.stdout.seekable() True I can access the machine only through ssh. --

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-07-24 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Perhaps, although I don't know where /dev/tty would be involved in os.popen(). For reference, under Linux I get: open(/dev/tty,a) Traceback (most recent call last): File stdin, line 1, in module IOError: [Errno 29] Illegal seek --

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-07-24 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: /dev/tty is probably similar to stdout, at least when python is started without redirection. What is the output of sys.stdout.seekable() when run from an interactive interpreter? Does it depend on the active console? (xterm, ssh...)

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-07-21 Thread nestor
nestor nestornis...@gmail.com added the comment: Maybe this has something to do with it? Python 3.1 (r31:73572, Jul 9 2009, 16:28:28) [C] on aix5 Type help, copyright, credits or license for more information. open(/dev/tty,a).seekable() True --

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-26 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ah, then I don't know what happens... -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6236 ___

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-24 Thread nestor
nestor nestornis...@gmail.com added the comment: That fails consistently: Python 2.6.2 (r262:71600, Jun 4 2009, 16:07:26) [C] on aix5 Type help, copyright, credits or license for more information. import os r,w=os.pipe() os.lseek(r,0,1) Traceback (most recent call last): File stdin, line

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-20 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ouch, this is quite annoying. I will try to fix this before the final release. -- assignee: - pitrou nosy: +pitrou priority: - critical ___ Python tracker rep...@bugs.python.org

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-20 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Here is my current interpretation: subprocess uses os.pipe() to create the file handles used for communication. These handles normally always raise an error ([Errno 29] Illegal seek) when trying to seek() on them, which the IO lib interprets as

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-20 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Just before, could you try to type the following commands: r, w = os.pipe() os.lseek(r, 0, 1) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6236

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-08 Thread nestor
nestor nestornis...@gmail.com added the comment: This quick and dirty fix in pydoc.py makes so it no longer aborts help. (less behaves somewhat strange for some commands but that is better than no help at all) def pipepager(text, cmd): Page through text by feeding it to another program.

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-06-07 Thread nestor
New submission from nestor nestornis...@gmail.com: Python 2.6.2 (r262:71600, Jun 4 2009, 16:07:26) [C] on aix5 Type help, copyright, credits or license for more information. import os os.popen('cat','w') open file 'cat', mode 'w' at 0x1101ab4f8 Python 3.0.1 (r301:69556, Jun 4 2009,