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
Py_GetArgcArgv() is no longer exported by the C API #85087
Comments
Python 3.9 is now built with -fvisibility=hidden. The Py_GetArgcArgv() function is no longer exported. Previously, it was exported because all symbols were exported by default. I'm working on a PR to export it again. Fedora downstream issue, setproctitle is broken on Python 3.9: https://bugzilla.redhat.com/show_bug.cgi?id=1792059 |
setproctitle upstream report: |
See also bpo-15577 "Real argc and argv in embedded interpreter". |
See also bpo-5672 "Implement a way to change the python process name", especially this comment: """ Python3 porting is not straightforward because python2 exports the original argv pointer using Py_GetArgcArgv() whereas python3 only exports a decoded version in a wchar_t* array. This may not be a showstopper: probably the original argv can still be found scanning backwards from environ: I want to test it but I haven't had requests for it yet, so it wasn't a top priority. So, while I'd be pleased to have it included in the stdlib, I'm not really convinced it would be useful to such a large audience. Anyway I'm available for any improvement it would make the tool more useful and to anybody eager to push for its inclusion. |
See also bpo-29857: Provide |
See also bpo-23427 "Python should expose command when invoked with -c" |
Thank you for opening this. FYI:
this is how the module works indeed in Python 3. |
Py_GetArgcArgv() is not new at all. It exists since: commit ac56b03
Previously, the function was known as getargcargv() and it existed since: commit 7b1e974
+void |
Ok, I fixed Python 3.9: Py_GetArgcArgv() function is exported again. Let's continue the discussion in bpo-23427. |
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:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: