[Python-bugs-list] [ python-Bugs-539319 ] sys.argv only works with python exe
noreply@sourceforge.net
noreply@sourceforge.net
Thu, 04 Apr 2002 09:13:54 -0800
Bugs item #539319, was opened at 2002-04-04 18:38
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=539319&group_id=5470
Category: Python Library
Group: Platform-specific
Status: Open
Resolution: None
Priority: 5
Submitted By: Mike Hostetler (thehaas)
Assigned to: Nobody/Anonymous (nobody)
Summary: sys.argv only works with python exe
Initial Comment:
This is a weird one, and I've know it works on other
Win2000 installations, but it doesn't work on mine.
sys.argv only works when I put "python" in front of it
in the cmd command line. However, the script does run
if I just type in it's name, but it ignores all command
line arguments.
Version: 2.2
Platform: Win2000
Example:
C:\stuff>type test.py
import sys
print sys.argv
C:\stuff>test.py arg1 arg2
['C:\stuff\test.py']
C:\stuff>python test.py arg1 arg2
['test.py', 'arg1', 'arg2']
Is this something with my setup, or something else??
----------------------------------------------------------------------
>Comment By: Thomas Heller (theller)
Date: 2002-04-04 19:13
Message:
Logged In: YES
user_id=11105
I can reproduce this behaviour if I change the association
for Python files from the default entry
'C:\python22\python.exe "%1" %*'
into
'C:\python22\python.exe "%1"'.
You can find this entry from Windows Explorer,
Tools->Folder Options->File Types.
Select the 'PY Python File' entry, press advanced, select
the 'open' entry, press edit, and look at the "Appplication
used to perform action" entry.
Probably something wrong with your setup.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=539319&group_id=5470