[issue17359] Mention "__main__.py" explicitly in command line docs

2021-08-24 Thread Łukasz Langa

Łukasz Langa  added the comment:

Solved as part of BPO-39452.

--
nosy: +lukasz.langa
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention "__main__.py" explicitly in command line docs

2021-08-22 Thread Jack DeVries


Change by Jack DeVries :


--
keywords: +patch
nosy: +jack__d
nosy_count: 8.0 -> 9.0
pull_requests: +26356
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26883

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention "__main__.py" explicitly in command line docs

2021-06-20 Thread Cameron Simpson


Change by Cameron Simpson :


--
nosy: +cameron

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention "__main__.py" explicitly in command line docs

2021-06-19 Thread Irit Katriel


Change by Irit Katriel :


--
versions: +Python 3.11 -Python 2.7, Python 3.3, Python 3.4

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention "__main__.py" explicitly in command line docs

2021-06-19 Thread Irit Katriel


Irit Katriel  added the comment:

See also Issue39452.

--
nosy: +iritkatriel

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2015-07-16 Thread Ezio Melotti

Ezio Melotti added the comment:

See also #24632.

--
nosy: +ezio.melotti
type:  - enhancement

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2013-10-06 Thread Chris Rebert

Changes by Chris Rebert pyb...@rebertia.com:


--
nosy: +cvrebert

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2013-08-03 Thread Eli Bendersky

Changes by Eli Bendersky eli...@gmail.com:


--
nosy:  -eli.bendersky

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2013-04-02 Thread Marc-Andre Lemburg

Marc-Andre Lemburg added the comment:

I still don't think that the available documentation is detailed enough. It 
leaves too many unanswered question, e.g.

* What happens if you have both __init__.py and __main__.py in a directory or a 
ZIP file ?

* What does the script name is added to the start of sys.path mean when using 
a ZIP file ?

* What are the implications of Directories and zipfiles containing a 
__main__.py file at the top level are now considered valid Python scripts. and 
where does this scope end ? The wording suggests that you can also import such 
directories or ZIP files.

* How are sys.path, __name__ and possibly __path__ setup when using this 
approach of running a dir/package/ZIP file ?

and probably a few more. The above can all be answered using trial-and-error, 
but it would be better to actually document the intended behavior.

Some quirks I found (dir is a directory with both __init__.py and __main__.py):

* python2.6 dir runs the __main__.py file, while python2.6 -m dir does not. 
Both work in the same way in Python 2.7.

* In Python 2.7, the two approaches differ in the way sys.path[0] is setup: 
python2.7 dir causes this to be set to dir, while python2.7 -m dir 
results in .

Background: The reason why I'm interested in this is that we are trying to 
mimic the Python command line interface with pyrun 
(http://www.egenix.com/products/python/PyRun/).

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2013-04-01 Thread Nick Coghlan

Changes by Nick Coghlan ncogh...@gmail.com:


--
title: Mention __main__.py explicit in command line docs - Mention 
__main__.py explicitly in command line docs

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17359] Mention __main__.py explicitly in command line docs

2013-04-01 Thread Nick Coghlan

Nick Coghlan added the comment:

There's also a problem where the CLI docs claim __main__.py support was added 
in 2.5 - that's not accurate, it was only added in 2.6.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17359
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com