Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #49156
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!hq-usenetpeers.eweka.nl!81.171.88.250.MISMATCH!newsfeed.eweka.nl!eweka.nl!feeder3.eweka.nl!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <Marco.Perniciaro@tomtom.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.002 |
| X-Spam-Evidence | '*H*': 1.00; '*S*': 0.00; 'output': 0.05; 'i?ve': 0.07; 'subject:getting': 0.07; 'sys': 0.07; 'lines:': 0.09; 'python': 0.11; '2.7': 0.14; '"python"': 0.16; "'a',": 0.16; "'b',": 0.16; '(windows': 0.16; 'marco': 0.16; 'skip:[ 30': 0.16; 'variable.': 0.16; 'import': 0.22; 'previously': 0.22; 'to:name :python-list@python.org': 0.22; 'print': 0.22; 'environment': 0.24; "i've": 0.25; 'script': 0.25; 'installed': 0.27; 'file': 0.32; 'received:169.254': 0.32; 'could': 0.34; 'charset:us-ascii': 0.36; 'hi,': 0.36; 'received:169': 0.37; 'two': 0.37; 'received:10': 0.37; 'skip:[ 10': 0.38; 'to:addr:python-list': 0.38; 'issue': 0.38; 'to:addr:python.org': 0.39; 'called': 0.40; 'new': 0.61; 'simple': 0.61; 'different': 0.65; 'behavior': 0.77 |
| From | Marco Perniciaro <Marco.Perniciaro@tomtom.com> |
| To | "python-list@python.org" <python-list@python.org> |
| Subject | Inconsistency on getting arguments |
| Thread-Topic | Inconsistency on getting arguments |
| Thread-Index | Ac5xhK6Vobkih/UxSTWKiJYa591NqA== |
| Date | Tue, 25 Jun 2013 09:16:32 +0000 |
| Accept-Language | en-US |
| Content-Language | en-US |
| X-MS-Has-Attach | |
| X-MS-TNEF-Correlator | |
| x-originating-ip | [10.96.72.60] |
| Content-Type | multipart/alternative; boundary="_000_5EDCC30CBA986647AAD0B4DA15FAC92D36FCD5FANLSRVWPEXM02ttg_" |
| MIME-Version | 1.0 |
| X-Mailman-Approved-At | Tue, 25 Jun 2013 14:50:06 +0200 |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.3826.1372164608.3114.python-list@python.org> (permalink) |
| Lines | 100 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1372164608 news.xs4all.nl 15864 [2001:888:2000:d::a6]:34414 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:49156 |
Show key headers only | View raw
[Multipart message — attachments visible in raw view] - view raw
Hi,
I've been working with Python for a long time.
Yet, I came across an issue which I cannot explain.
Recently I have a new PC (Windows 7).
Previously I could call a Python script with or without the "python" word at the beginning.
Now the behavior is different if I use or not use the "python" prefix!
I only have Python 2.7 installed and the path in in my environment variable.
I create a simple file called "example.py" which contains two lines:
import sys
print sys.argv
This is the output result:
C:\Users\mapr>example.py a b c
['C:\\Users\\mapr\\example.py']
C:\Users\mapr>python example.py a b c
['example.py', 'a', 'b', 'c']
Can someone please explain?
Regards,
Marco
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Inconsistency on getting arguments Marco Perniciaro <Marco.Perniciaro@tomtom.com> - 2013-06-25 09:16 +0000
csiph-web