Custom Query (344 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (76 - 78 of 344)

Ticket Resolution Summary Owner Reporter
#141 fixed python: subprocess.Popen (shell=True) fails dmik
Description

I've just discovered that subprocess.Popen (shell=True) fails with

  File "C:/USR/lib/python2.7/subprocess.py", line 709, in __init__
    errread, errwrite)
  File "C:/USR/lib/python2.7/subprocess.py", line 1328, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory

This relates to the current Python version 2.7.6-11.

#148 fixed python: os.popen doesn't accept backslashes dmik
Description

I discovered a strange problem with os.popen regarding paths containing backslashes:

import os

gcc_exe = "C:\\usr\\bin\\gcc.exe"

print "["+repr(gcc_exe)+"]"

# [1] This works
exists = os.access(gcc_exe, os.X_OK)
print "exists", exists

if exists:

    # [2] This works too, if uncommented
    #os.execl(gcc_exe, "gcc", "-dumpversion")

    # [3] This doesn't work :(((
    out = os.popen(gcc_exe + ' -dumpversion', 'r')
    try:
        out_string = out.read()
        print out_string
    finally:
        out.close()

This gives the following output here:

D:>python popen.py
['C:\\usr\\bin\\gcc.exe']
exists True
C:usrbingcc.exe: not found

Both [1] and [2] cases work, but case [3] does not. Seems that some extra string evaluation happens before the string is passed down to the popen implementation (as if str(gcc_exe) were called) which effectively kills backslashes.

#150 wontfix python: deal with reverse /@unixroot replacement dmik
Description

When doing some path absolutization, python causes /@unixroot in paths to be replaced with the actual value of $UNIXROOT (e.g. "C:"). This gives for paths like /@unixroot/usr/bin/python.exe paths like C:/USR/BIN/python.exe. The main problem with these paths is that they are not portable across different installations (i.e. installations using different UNIXROOT settings, e.g. different drive letters or such).

One such problem is shown in r529. But there are surely more of these.

Note: See TracQuery for help on using queries.