Merge lp://staging/~cjwatson/lazr.config/faster-version into lp://staging/lazr.config

Proposed by Colin Watson
Status: Merged
Merged at revision: 18
Proposed branch: lp://staging/~cjwatson/lazr.config/faster-version
Merge into: lp://staging/lazr.config
Diff against target: 81 lines (+14/-7)
7 files modified
MANIFEST.in (+1/-1)
conf.py (+3/-1)
setup.py (+2/-1)
src/lazr/config/__init__.py (+2/-3)
src/lazr/config/_version.py (+1/-0)
src/lazr/config/docs/NEWS.rst (+5/-0)
src/lazr/config/version.txt (+0/-1)
To merge this branch: bzr merge lp://staging/~cjwatson/lazr.config/faster-version
Reviewer Review Type Date Requested Status
William Grant (community) code Approve
Review via email: mp+331833@code.staging.launchpad.net

Commit message

Adjust versioning strategy to avoid importing pkg_resources, which is slow in large environments.

Description of the change

With this and a collection of other changes, I can get the startup time of Launchpad's bin/py down from about 0.95 seconds (after conversion to virtualenv and pip) to about 0.27 seconds on my laptop. pkg_resources accounts for about half a second of that, so is well worth avoiding on the fast path.

To post a comment you must log in.
Revision history for this message
William Grant (wgrant) :
review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches