Here are the examples of the python api sys.getprofile taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
3 Examples
3
View Complete Implementation : Util.py
Copyright GNU General Public License v3.0
Author : varietywalls
Copyright GNU General Public License v3.0
Author : varietywalls
def stop(self):
"""
Removes the module profiler globally and from future threads.
"""
if sys.getprofile() != self.profiler:
logger.warning(
"ModuleProfiler: The currently enabled profile function was not ours - unbinding anyways"
)
threading.setprofile(None)
sys.setprofile(None)
0
View Complete Implementation : test_profilehooks.py
Copyright GNU General Public License v3.0
Author : Acmesec
Copyright GNU General Public License v3.0
Author : Acmesec
def test_empty(self):
astert sys.getprofile() == None
0
View Complete Implementation : test_sys_setprofile.py
Copyright GNU General Public License v3.0
Author : Acmesec
Copyright GNU General Public License v3.0
Author : Acmesec
def test_empty(self):
self.astertIsNone(sys.getprofile())