This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: New functions in to get user/global site packages paths
Type: enhancement Stage:
Components: Library (Lib) Versions: Python 3.2, Python 2.7
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: tarek Nosy List: christian.heimes, lemburg, tarek
Priority: normal Keywords: patch

Created on 2009-08-13 08:31 by tarek, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
site.patch tarek, 2009-08-14 08:43
Messages (4)
msg91516 - (view) Author: Tarek Ziadé (tarek) * (Python committer) Date: 2009-08-13 08:31
As discussed in Distutils-SIG.

Here's a patch for that adds:

- getsitepackages : Returns a list containing all global site-packages
directories (and possibly site-python).

- getusersitepackages: Returns the user-specific site-packages directory

- getuserbase: Returns the `user base` directory path.
msg91517 - (view) Author: Marc-Andre Lemburg (lemburg) * (Python committer) Date: 2009-08-13 08:40
Two things:

 * The globals should get a comment explaining what their purpose is and
where they are being initialized.

 * The get*() functions should only initialize the globals if they are
set to None. In the patch, they are initialized every time the functions
are called.
msg91545 - (view) Author: Tarek Ziadé (tarek) * (Python committer) Date: 2009-08-14 08:43

I've put Christian in the loop since he implemented the PEP 370
feature, to make sure these changes are fine with him.
msg91784 - (view) Author: Tarek Ziadé (tarek) * (Python committer) Date: 2009-08-20 21:28
applied in r74526 and r74529
Date User Action Args
2022-04-11 14:56:51adminsetgithub: 50942
2009-08-20 21:28:39tareksetstatus: open -> closed

messages: + msg91784
2009-08-14 08:43:55tareksetfiles: - site.patch
2009-08-14 08:43:45tareksetfiles: + site.patch
nosy: + christian.heimes
messages: + msg91545

2009-08-13 08:40:55lemburgsetnosy: + lemburg
messages: + msg91517
2009-08-13 08:31:56tarekcreate