[Python-Dev] PEP: per user site-packages directory (original) (raw)
Christian Heimes lists at cheimes.de
Sun Jan 13 20:12:43 CET 2008
- Previous message: [Python-Dev] PEP: per user site-packages directory
- Next message: [Python-Dev] PEP: per user site-packages directory
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Gregory P. Smith wrote:
I also tried to check if os.stat(main.file).stuid == os.getuid() but the real main is not available in site.py. It's loaded and assigned much later. Is sys.argv[0] available at that point?
No, it's not available, too. The 'site' module is imported by Py_Initialize(). sys.argv and the real main module are set much later in Modules/main.c.
Christian
- Previous message: [Python-Dev] PEP: per user site-packages directory
- Next message: [Python-Dev] PEP: per user site-packages directory
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]