FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

bpo-29585: optimize site.py startup time by methane · Pull Request #136 · python/cpython · GitHub

Repository navigation

Merged
Prev Previous commit
Next Next commit
Add note comment for duplicated code.
  • Loading branch information
methane committed Jun 28, 2017
commit 5aabcec1e633feac7ac2a171001f87e483852ada
3 changes: 3 additions & 0 deletions Lib/sysconfig.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
'scripts': '{base}/Scripts',
'data': '{base}',
},
# NOTE: When modifying "purelib" scheme, update site._get_path() too.
'nt_user': {
'stdlib': '{userbase}/Python{py_version_nodot}',
'platstdlib': '{userbase}/Python{py_version_nodot}',
Expand Down Expand Up @@ -177,6 +178,8 @@ def _get_default_scheme():
return os.name


# NOTE: site.py has stripped copy of this function.
# Update it too when modify this function.
def _getuserbase():
env_base = os.environ.get("PYTHONUSERBASE", None)

Expand Down

Back | FazBrowse Home | New Git URL