Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify coverage and profiling handling and semantics. Fixes #81. #86

Merged
merged 2 commits into from
Apr 16, 2015
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix master merge against PEX_* consolidation review.
  • Loading branch information
wickman committed Apr 16, 2015
commit 238c2bf9c65ed6da1d4cd97924d14b81e5462f8e
2 changes: 1 addition & 1 deletion pex/pex.py
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@ class Error(Exception): pass
class NotFound(Error): pass

@classmethod
def clean_environment(cls, forking=False):
def clean_environment(cls):
try:
del os.environ['MACOSX_DEPLOYMENT_TARGET']
except KeyError:
26 changes: 18 additions & 8 deletions pex/variables.py
Original file line number Diff line number Diff line change
@@ -89,6 +89,15 @@ def PEX_COVERAGE(self):
"""
return self._get_bool('PEX_COVERAGE', default=False)

@property
def PEX_COVERAGE_FILENAME(self):
"""Filename

Write the coverage data to the specified filename. If PEX_COVERAGE_FILENAME is not specified
but PEX_COVERAGE is, coverage information will be printed to stdout and not saved.
"""
return self._get_path('PEX_COVERAGE_FILENAME', default=None)

@property
def PEX_FORCE_LOCAL(self):
"""Boolean
@@ -143,24 +152,25 @@ def PEX_MODULE(self):

@property
def PEX_PROFILE(self):
"""Filename
"""Boolean

Enable application profiling and dump a profile into the specified filename in the standard
"profile" module format.
Enable application profiling. If specified and PEX_PROFILE_FILENAME is not specified, PEX will
print profiling information to stdout.
"""
return self._get_path('PEX_PROFILE', default=None)

@property
def PEX_PROFILE_ENTRIES(self):
"""Integer
def PEX_PROFILE_FILENAME(self):
"""Filename

Toggle the number of profile entries printed out to stdout when profiling. Default: 1000.
Profile the application and dump a profile into the specified filename in the standard
"profile" module format.
"""
return self._get_int('PEX_PROFILE_ENTRIES', default=1000)
return self._get_path('PEX_PROFILE_FILENAME', default=None)

@property
def PEX_PROFILE_SORT(self):
"""Integer
"""String

Toggle the profile sorting algorithm used to print out profile columns. Default:
'cumulative'.
You are viewing a condensed version of this merge commit. You can view the full changes here.