Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os.exec* and first 'arg' #39569

Closed
aschmolck mannequin opened this issue Nov 19, 2003 · 3 comments
Closed

os.exec* and first 'arg' #39569

aschmolck mannequin opened this issue Nov 19, 2003 · 3 comments
Labels
docs Documentation in the Doc dir

Comments

@aschmolck
Copy link
Mannequin

aschmolck mannequin commented Nov 19, 2003

BPO 845342
Nosy @birkenfeld

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2005-12-26.23:31:57.000>
created_at = <Date 2003-11-19.19:30:32.000>
labels = ['docs']
title = "os.exec* and first 'arg'"
updated_at = <Date 2005-12-26.23:31:57.000>
user = 'https://bugs.python.org/aschmolck'

bugs.python.org fields:

activity = <Date 2005-12-26.23:31:57.000>
actor = 'georg.brandl'
assignee = 'none'
closed = True
closed_date = None
closer = None
components = ['Documentation']
creation = <Date 2003-11-19.19:30:32.000>
creator = 'aschmolck'
dependencies = []
files = []
hgrepos = []
issue_num = 845342
keywords = []
message_count = 2.0
messages = ['19044', '19045']
nosy_count = 2.0
nosy_names = ['georg.brandl', 'aschmolck']
pr_nums = []
priority = 'normal'
resolution = 'wont fix'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue845342'
versions = []

@aschmolck
Copy link
Mannequin Author

aschmolck mannequin commented Nov 19, 2003

The current

I'd suggest the following change to the docstrings for
the exec* functions, because I think it's quite easy to
get bitten:

execv(...)
    execv(path, args)
    
    Execute an executable path with arguments,
replacing current process.
    
            path: path of executable file
            args: tuple or list of strings (NOTE: the
first argument is
                     analoguous to sys.argv[0], *not*
sys.argv[1]!)

instead of:

execv(...)
    execv(path, args)
    
    Execute an executable path with arguments,
replacing current process.
    
            path: path of executable file
            args: tuple or list of strings

@aschmolck aschmolck mannequin closed this as completed Nov 19, 2003
@aschmolck aschmolck mannequin added the docs Documentation in the Doc dir label Nov 19, 2003
@birkenfeld
Copy link
Member

Logged In: YES
user_id=1188172

This is covered in the Library Manual.
Docstrings aren't meant to be complete, just quick overviews
of what the functions do.

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 9, 2022
@buhtz
Copy link

buhtz commented Dec 18, 2022

#reopen

This is covered in the Library Manual.

Please point to it. Is it different from help(os.execvp)?

It is still unclear how to treat the args argument. Based on my own tests it seems that both versions are working.

os.execvp(cmd[0], cmd)
os.execvp(cmd[0], cmd[1:])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir
Projects
None yet
Development

No branches or pull requests

2 participants