You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Importing pystatsd imports the pystatsd.server module, which attempts to import setproctitle, if it is available.
As a consequence of the linked issue, importing pystats within a sitecustomize.py will cause python to fail to execute scripts with command line arguments (if setproctitle is available):
$ touch test.py
$ echo "import pystatsd" > sitecustomize.py
$ export PYTHONPATH=.:$PYTHONPATH
$ python test.py --some-arg
python test.py --some-arg: can't open file 'test.py --some-arg': [Errno 2] No such file or directory
Absent an upstream fix, it may be worth somehow adding an option to disable use of setproctitle, and/or lazily importing it to work around the issue.
Thanks!
The text was updated successfully, but these errors were encountered:
This is related to a setproctitle issue (which unfortunately is marked closed): dvarrazzo/py-setproctitle#49
Importing pystatsd imports the pystatsd.server module, which attempts to import setproctitle, if it is available.
As a consequence of the linked issue, importing pystats within a sitecustomize.py will cause python to fail to execute scripts with command line arguments (if setproctitle is available):
Absent an upstream fix, it may be worth somehow adding an option to disable use of setproctitle, and/or lazily importing it to work around the issue.
Thanks!
The text was updated successfully, but these errors were encountered: