partition stringclasses 3
values | func_name stringlengths 1 134 | docstring stringlengths 1 46.9k | path stringlengths 4 223 | original_string stringlengths 75 104k | code stringlengths 75 104k | docstring_tokens listlengths 1 1.97k | repo stringlengths 7 55 | language stringclasses 1
value | url stringlengths 87 315 | code_tokens listlengths 19 28.4k | sha stringlengths 40 40 |
|---|---|---|---|---|---|---|---|---|---|---|---|
test | Pdb.print_list_lines | The printing (as opposed to the parsing part of a 'list'
command. | environment/lib/python2.7/site-packages/IPython/core/debugger.py | def print_list_lines(self, filename, first, last):
"""The printing (as opposed to the parsing part of a 'list'
command."""
try:
Colors = self.color_scheme_table.active_colors
ColorsNormal = Colors.Normal
tpl_line = '%%s%s%%s %s%%s' % (Colors.lineno, ColorsNorm... | def print_list_lines(self, filename, first, last):
"""The printing (as opposed to the parsing part of a 'list'
command."""
try:
Colors = self.color_scheme_table.active_colors
ColorsNormal = Colors.Normal
tpl_line = '%%s%s%%s %s%%s' % (Colors.lineno, ColorsNorm... | [
"The",
"printing",
"(",
"as",
"opposed",
"to",
"the",
"parsing",
"part",
"of",
"a",
"list",
"command",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/debugger.py#L415-L440 | [
"def",
"print_list_lines",
"(",
"self",
",",
"filename",
",",
"first",
",",
"last",
")",
":",
"try",
":",
"Colors",
"=",
"self",
".",
"color_scheme_table",
".",
"active_colors",
"ColorsNormal",
"=",
"Colors",
".",
"Normal",
"tpl_line",
"=",
"'%%s%s%%s %s%%s'",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Pdb.do_pdef | The debugger interface to magic_pdef | environment/lib/python2.7/site-packages/IPython/core/debugger.py | def do_pdef(self, arg):
"""The debugger interface to magic_pdef"""
namespaces = [('Locals', self.curframe.f_locals),
('Globals', self.curframe.f_globals)]
self.shell.find_line_magic('pdef')(arg, namespaces=namespaces) | def do_pdef(self, arg):
"""The debugger interface to magic_pdef"""
namespaces = [('Locals', self.curframe.f_locals),
('Globals', self.curframe.f_globals)]
self.shell.find_line_magic('pdef')(arg, namespaces=namespaces) | [
"The",
"debugger",
"interface",
"to",
"magic_pdef"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/debugger.py#L476-L480 | [
"def",
"do_pdef",
"(",
"self",
",",
"arg",
")",
":",
"namespaces",
"=",
"[",
"(",
"'Locals'",
",",
"self",
".",
"curframe",
".",
"f_locals",
")",
",",
"(",
"'Globals'",
",",
"self",
".",
"curframe",
".",
"f_globals",
")",
"]",
"self",
".",
"shell",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Pdb.checkline | Check whether specified line seems to be executable.
Return `lineno` if it is, 0 if not (e.g. a docstring, comment, blank
line or EOF). Warning: testing is not comprehensive. | environment/lib/python2.7/site-packages/IPython/core/debugger.py | def checkline(self, filename, lineno):
"""Check whether specified line seems to be executable.
Return `lineno` if it is, 0 if not (e.g. a docstring, comment, blank
line or EOF). Warning: testing is not comprehensive.
"""
##########################################################... | def checkline(self, filename, lineno):
"""Check whether specified line seems to be executable.
Return `lineno` if it is, 0 if not (e.g. a docstring, comment, blank
line or EOF). Warning: testing is not comprehensive.
"""
##########################################################... | [
"Check",
"whether",
"specified",
"line",
"seems",
"to",
"be",
"executable",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/debugger.py#L495-L526 | [
"def",
"checkline",
"(",
"self",
",",
"filename",
",",
"lineno",
")",
":",
"#######################################################################",
"# XXX Hack! Use python-2.5 compatible code for this call, because with",
"# all of our changes, we've drifted from the pdb api in 2.6. For ... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | conversion_factor | Generates a multiplying factor used to convert two currencies | forex/models.py | def conversion_factor(from_symbol, to_symbol, date):
"""
Generates a multiplying factor used to convert two currencies
"""
from_currency = Currency.objects.get(symbol=from_symbol)
try:
from_currency_price = CurrencyPrice.objects.get(currency=from_currency, date=date).mid_price
except Cu... | def conversion_factor(from_symbol, to_symbol, date):
"""
Generates a multiplying factor used to convert two currencies
"""
from_currency = Currency.objects.get(symbol=from_symbol)
try:
from_currency_price = CurrencyPrice.objects.get(currency=from_currency, date=date).mid_price
except Cu... | [
"Generates",
"a",
"multiplying",
"factor",
"used",
"to",
"convert",
"two",
"currencies"
] | Valuehorizon/valuehorizon-forex | python | https://github.com/Valuehorizon/valuehorizon-forex/blob/e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8/forex/models.py#L210-L229 | [
"def",
"conversion_factor",
"(",
"from_symbol",
",",
"to_symbol",
",",
"date",
")",
":",
"from_currency",
"=",
"Currency",
".",
"objects",
".",
"get",
"(",
"symbol",
"=",
"from_symbol",
")",
"try",
":",
"from_currency_price",
"=",
"CurrencyPrice",
".",
"object... | e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8 |
test | convert_currency | Converts an amount of money from one currency to another on a specified date. | forex/models.py | def convert_currency(from_symbol, to_symbol, value, date):
"""
Converts an amount of money from one currency to another on a specified date.
"""
if from_symbol == to_symbol:
return value
factor = conversion_factor(from_symbol, to_symbol, date)
if type(value) == float:
output = ... | def convert_currency(from_symbol, to_symbol, value, date):
"""
Converts an amount of money from one currency to another on a specified date.
"""
if from_symbol == to_symbol:
return value
factor = conversion_factor(from_symbol, to_symbol, date)
if type(value) == float:
output = ... | [
"Converts",
"an",
"amount",
"of",
"money",
"from",
"one",
"currency",
"to",
"another",
"on",
"a",
"specified",
"date",
"."
] | Valuehorizon/valuehorizon-forex | python | https://github.com/Valuehorizon/valuehorizon-forex/blob/e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8/forex/models.py#L232-L250 | [
"def",
"convert_currency",
"(",
"from_symbol",
",",
"to_symbol",
",",
"value",
",",
"date",
")",
":",
"if",
"from_symbol",
"==",
"to_symbol",
":",
"return",
"value",
"factor",
"=",
"conversion_factor",
"(",
"from_symbol",
",",
"to_symbol",
",",
"date",
")",
... | e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8 |
test | Currency.compute_return | Compute the return of the currency between two dates | forex/models.py | def compute_return(self, start_date, end_date, rate="MID"):
"""
Compute the return of the currency between two dates
"""
if rate not in ["MID", "ASK", "BID"]:
raise ValueError("Unknown rate type (%s)- must be 'MID', 'ASK' or 'BID'" % str(rate))
if end_date <= start_d... | def compute_return(self, start_date, end_date, rate="MID"):
"""
Compute the return of the currency between two dates
"""
if rate not in ["MID", "ASK", "BID"]:
raise ValueError("Unknown rate type (%s)- must be 'MID', 'ASK' or 'BID'" % str(rate))
if end_date <= start_d... | [
"Compute",
"the",
"return",
"of",
"the",
"currency",
"between",
"two",
"dates"
] | Valuehorizon/valuehorizon-forex | python | https://github.com/Valuehorizon/valuehorizon-forex/blob/e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8/forex/models.py#L59-L75 | [
"def",
"compute_return",
"(",
"self",
",",
"start_date",
",",
"end_date",
",",
"rate",
"=",
"\"MID\"",
")",
":",
"if",
"rate",
"not",
"in",
"[",
"\"MID\"",
",",
"\"ASK\"",
",",
"\"BID\"",
"]",
":",
"raise",
"ValueError",
"(",
"\"Unknown rate type (%s)- must ... | e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8 |
test | CurrencyPriceManager.generate_dataframe | Generate a dataframe consisting of the currency prices (specified by symbols)
from the start to end date | forex/models.py | def generate_dataframe(self, symbols=None, date_index=None, price_type="mid"):
"""
Generate a dataframe consisting of the currency prices (specified by symbols)
from the start to end date
"""
# Set defaults if necessary
if symbols is None:
symbols = list(Curr... | def generate_dataframe(self, symbols=None, date_index=None, price_type="mid"):
"""
Generate a dataframe consisting of the currency prices (specified by symbols)
from the start to end date
"""
# Set defaults if necessary
if symbols is None:
symbols = list(Curr... | [
"Generate",
"a",
"dataframe",
"consisting",
"of",
"the",
"currency",
"prices",
"(",
"specified",
"by",
"symbols",
")",
"from",
"the",
"start",
"to",
"end",
"date"
] | Valuehorizon/valuehorizon-forex | python | https://github.com/Valuehorizon/valuehorizon-forex/blob/e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8/forex/models.py#L81-L125 | [
"def",
"generate_dataframe",
"(",
"self",
",",
"symbols",
"=",
"None",
",",
"date_index",
"=",
"None",
",",
"price_type",
"=",
"\"mid\"",
")",
":",
"# Set defaults if necessary",
"if",
"symbols",
"is",
"None",
":",
"symbols",
"=",
"list",
"(",
"Currency",
".... | e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8 |
test | CurrencyPrice.save | Sanitation checks | forex/models.py | def save(self, *args, **kwargs):
"""
Sanitation checks
"""
if self.ask_price < 0:
raise ValidationError("Ask price must be greater than zero")
if self.bid_price < 0:
raise ValidationError("Bid price must be greater than zero")
if self.ask_price < s... | def save(self, *args, **kwargs):
"""
Sanitation checks
"""
if self.ask_price < 0:
raise ValidationError("Ask price must be greater than zero")
if self.bid_price < 0:
raise ValidationError("Bid price must be greater than zero")
if self.ask_price < s... | [
"Sanitation",
"checks"
] | Valuehorizon/valuehorizon-forex | python | https://github.com/Valuehorizon/valuehorizon-forex/blob/e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8/forex/models.py#L160-L171 | [
"def",
"save",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"if",
"self",
".",
"ask_price",
"<",
"0",
":",
"raise",
"ValidationError",
"(",
"\"Ask price must be greater than zero\"",
")",
"if",
"self",
".",
"bid_price",
"<",
"0",
":"... | e921379ae6c9d07ddad87a1fd3b5bb8fdfc74cb8 |
test | get_stream_enc | Return the given stream's encoding or a default.
There are cases where sys.std* might not actually be a stream, so
check for the encoding attribute prior to returning it, and return
a default if it doesn't exist or evaluates as False. `default'
is None if not provided. | environment/lib/python2.7/site-packages/IPython/utils/encoding.py | def get_stream_enc(stream, default=None):
"""Return the given stream's encoding or a default.
There are cases where sys.std* might not actually be a stream, so
check for the encoding attribute prior to returning it, and return
a default if it doesn't exist or evaluates as False. `default'
is None i... | def get_stream_enc(stream, default=None):
"""Return the given stream's encoding or a default.
There are cases where sys.std* might not actually be a stream, so
check for the encoding attribute prior to returning it, and return
a default if it doesn't exist or evaluates as False. `default'
is None i... | [
"Return",
"the",
"given",
"stream",
"s",
"encoding",
"or",
"a",
"default",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/utils/encoding.py#L20-L31 | [
"def",
"get_stream_enc",
"(",
"stream",
",",
"default",
"=",
"None",
")",
":",
"if",
"not",
"hasattr",
"(",
"stream",
",",
"'encoding'",
")",
"or",
"not",
"stream",
".",
"encoding",
":",
"return",
"default",
"else",
":",
"return",
"stream",
".",
"encodin... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | getdefaultencoding | Return IPython's guess for the default encoding for bytes as text.
Asks for stdin.encoding first, to match the calling Terminal, but that
is often None for subprocesses. Fall back on locale.getpreferredencoding()
which should be a sensible platform default (that respects LANG environment),
and finally... | environment/lib/python2.7/site-packages/IPython/utils/encoding.py | def getdefaultencoding():
"""Return IPython's guess for the default encoding for bytes as text.
Asks for stdin.encoding first, to match the calling Terminal, but that
is often None for subprocesses. Fall back on locale.getpreferredencoding()
which should be a sensible platform default (that respects L... | def getdefaultencoding():
"""Return IPython's guess for the default encoding for bytes as text.
Asks for stdin.encoding first, to match the calling Terminal, but that
is often None for subprocesses. Fall back on locale.getpreferredencoding()
which should be a sensible platform default (that respects L... | [
"Return",
"IPython",
"s",
"guess",
"for",
"the",
"default",
"encoding",
"for",
"bytes",
"as",
"text",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/utils/encoding.py#L37-L54 | [
"def",
"getdefaultencoding",
"(",
")",
":",
"enc",
"=",
"get_stream_enc",
"(",
"sys",
".",
"stdin",
")",
"if",
"not",
"enc",
"or",
"enc",
"==",
"'ascii'",
":",
"try",
":",
"# There are reports of getpreferredencoding raising errors",
"# in some cases, which may well b... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | get_userpass_value | Gets the username / password from config.
Uses the following rules:
1. If it is specified on the cli (`cli_value`), use that.
2. If `config[key]` is specified, use that.
3. Otherwise prompt using `prompt_strategy`.
:param cli_value: The value supplied from the command line or `None`.
:type cl... | virtualEnvironment/lib/python2.7/site-packages/twine/utils.py | def get_userpass_value(cli_value, config, key, prompt_strategy):
"""Gets the username / password from config.
Uses the following rules:
1. If it is specified on the cli (`cli_value`), use that.
2. If `config[key]` is specified, use that.
3. Otherwise prompt using `prompt_strategy`.
:param cli... | def get_userpass_value(cli_value, config, key, prompt_strategy):
"""Gets the username / password from config.
Uses the following rules:
1. If it is specified on the cli (`cli_value`), use that.
2. If `config[key]` is specified, use that.
3. Otherwise prompt using `prompt_strategy`.
:param cli... | [
"Gets",
"the",
"username",
"/",
"password",
"from",
"config",
"."
] | tnkteja/myhelp | python | https://github.com/tnkteja/myhelp/blob/fb3a4809d448ad14d5b2e6ddf2e7e89ad52b71cb/virtualEnvironment/lib/python2.7/site-packages/twine/utils.py#L89-L114 | [
"def",
"get_userpass_value",
"(",
"cli_value",
",",
"config",
",",
"key",
",",
"prompt_strategy",
")",
":",
"if",
"cli_value",
"is",
"not",
"None",
":",
"return",
"cli_value",
"elif",
"config",
".",
"get",
"(",
"key",
")",
":",
"return",
"config",
"[",
"... | fb3a4809d448ad14d5b2e6ddf2e7e89ad52b71cb |
test | KernelApp.load_connection_file | load ip/port/hmac config from JSON connection file | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def load_connection_file(self):
"""load ip/port/hmac config from JSON connection file"""
try:
fname = filefind(self.connection_file, ['.', self.profile_dir.security_dir])
except IOError:
self.log.debug("Connection file not found: %s", self.connection_file)
# T... | def load_connection_file(self):
"""load ip/port/hmac config from JSON connection file"""
try:
fname = filefind(self.connection_file, ['.', self.profile_dir.security_dir])
except IOError:
self.log.debug("Connection file not found: %s", self.connection_file)
# T... | [
"load",
"ip",
"/",
"port",
"/",
"hmac",
"config",
"from",
"JSON",
"connection",
"file"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L164-L186 | [
"def",
"load_connection_file",
"(",
"self",
")",
":",
"try",
":",
"fname",
"=",
"filefind",
"(",
"self",
".",
"connection_file",
",",
"[",
"'.'",
",",
"self",
".",
"profile_dir",
".",
"security_dir",
"]",
")",
"except",
"IOError",
":",
"self",
".",
"log"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.write_connection_file | write connection info to JSON file | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def write_connection_file(self):
"""write connection info to JSON file"""
if os.path.basename(self.connection_file) == self.connection_file:
cf = os.path.join(self.profile_dir.security_dir, self.connection_file)
else:
cf = self.connection_file
write_connection_fil... | def write_connection_file(self):
"""write connection info to JSON file"""
if os.path.basename(self.connection_file) == self.connection_file:
cf = os.path.join(self.profile_dir.security_dir, self.connection_file)
else:
cf = self.connection_file
write_connection_fil... | [
"write",
"connection",
"info",
"to",
"JSON",
"file"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L188-L198 | [
"def",
"write_connection_file",
"(",
"self",
")",
":",
"if",
"os",
".",
"path",
".",
"basename",
"(",
"self",
".",
"connection_file",
")",
"==",
"self",
".",
"connection_file",
":",
"cf",
"=",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"profile_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.init_heartbeat | start the heart beating | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def init_heartbeat(self):
"""start the heart beating"""
# heartbeat doesn't share context, because it mustn't be blocked
# by the GIL, which is accessed by libzmq when freeing zero-copy messages
hb_ctx = zmq.Context()
self.heartbeat = Heartbeat(hb_ctx, (self.ip, self.hb_port))
... | def init_heartbeat(self):
"""start the heart beating"""
# heartbeat doesn't share context, because it mustn't be blocked
# by the GIL, which is accessed by libzmq when freeing zero-copy messages
hb_ctx = zmq.Context()
self.heartbeat = Heartbeat(hb_ctx, (self.ip, self.hb_port))
... | [
"start",
"the",
"heart",
"beating"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L236-L248 | [
"def",
"init_heartbeat",
"(",
"self",
")",
":",
"# heartbeat doesn't share context, because it mustn't be blocked",
"# by the GIL, which is accessed by libzmq when freeing zero-copy messages",
"hb_ctx",
"=",
"zmq",
".",
"Context",
"(",
")",
"self",
".",
"heartbeat",
"=",
"Heart... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.log_connection_info | display connection info, and store ports | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def log_connection_info(self):
"""display connection info, and store ports"""
basename = os.path.basename(self.connection_file)
if basename == self.connection_file or \
os.path.dirname(self.connection_file) == self.profile_dir.security_dir:
# use shortname
tai... | def log_connection_info(self):
"""display connection info, and store ports"""
basename = os.path.basename(self.connection_file)
if basename == self.connection_file or \
os.path.dirname(self.connection_file) == self.profile_dir.security_dir:
# use shortname
tai... | [
"display",
"connection",
"info",
"and",
"store",
"ports"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L250-L265 | [
"def",
"log_connection_info",
"(",
"self",
")",
":",
"basename",
"=",
"os",
".",
"path",
".",
"basename",
"(",
"self",
".",
"connection_file",
")",
"if",
"basename",
"==",
"self",
".",
"connection_file",
"or",
"os",
".",
"path",
".",
"dirname",
"(",
"sel... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.init_session | create our session object | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def init_session(self):
"""create our session object"""
default_secure(self.config)
self.session = Session(config=self.config, username=u'kernel') | def init_session(self):
"""create our session object"""
default_secure(self.config)
self.session = Session(config=self.config, username=u'kernel') | [
"create",
"our",
"session",
"object"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L267-L270 | [
"def",
"init_session",
"(",
"self",
")",
":",
"default_secure",
"(",
"self",
".",
"config",
")",
"self",
".",
"session",
"=",
"Session",
"(",
"config",
"=",
"self",
".",
"config",
",",
"username",
"=",
"u'kernel'",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.init_blackhole | redirects stdout/stderr to devnull if necessary | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def init_blackhole(self):
"""redirects stdout/stderr to devnull if necessary"""
if self.no_stdout or self.no_stderr:
blackhole = open(os.devnull, 'w')
if self.no_stdout:
sys.stdout = sys.__stdout__ = blackhole
if self.no_stderr:
sys.std... | def init_blackhole(self):
"""redirects stdout/stderr to devnull if necessary"""
if self.no_stdout or self.no_stderr:
blackhole = open(os.devnull, 'w')
if self.no_stdout:
sys.stdout = sys.__stdout__ = blackhole
if self.no_stderr:
sys.std... | [
"redirects",
"stdout",
"/",
"stderr",
"to",
"devnull",
"if",
"necessary"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L272-L279 | [
"def",
"init_blackhole",
"(",
"self",
")",
":",
"if",
"self",
".",
"no_stdout",
"or",
"self",
".",
"no_stderr",
":",
"blackhole",
"=",
"open",
"(",
"os",
".",
"devnull",
",",
"'w'",
")",
"if",
"self",
".",
"no_stdout",
":",
"sys",
".",
"stdout",
"=",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.init_io | Redirect input streams and set a display hook. | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def init_io(self):
"""Redirect input streams and set a display hook."""
if self.outstream_class:
outstream_factory = import_item(str(self.outstream_class))
sys.stdout = outstream_factory(self.session, self.iopub_socket, u'stdout')
sys.stderr = outstream_factory(self.s... | def init_io(self):
"""Redirect input streams and set a display hook."""
if self.outstream_class:
outstream_factory = import_item(str(self.outstream_class))
sys.stdout = outstream_factory(self.session, self.iopub_socket, u'stdout')
sys.stderr = outstream_factory(self.s... | [
"Redirect",
"input",
"streams",
"and",
"set",
"a",
"display",
"hook",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L281-L289 | [
"def",
"init_io",
"(",
"self",
")",
":",
"if",
"self",
".",
"outstream_class",
":",
"outstream_factory",
"=",
"import_item",
"(",
"str",
"(",
"self",
".",
"outstream_class",
")",
")",
"sys",
".",
"stdout",
"=",
"outstream_factory",
"(",
"self",
".",
"sessi... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | KernelApp.init_kernel | Create the Kernel object itself | environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py | def init_kernel(self):
"""Create the Kernel object itself"""
kernel_factory = import_item(str(self.kernel_class))
self.kernel = kernel_factory(config=self.config, session=self.session,
shell_socket=self.shell_socket,
iopub_socket=se... | def init_kernel(self):
"""Create the Kernel object itself"""
kernel_factory = import_item(str(self.kernel_class))
self.kernel = kernel_factory(config=self.config, session=self.session,
shell_socket=self.shell_socket,
iopub_socket=se... | [
"Create",
"the",
"Kernel",
"object",
"itself"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/zmq/kernelapp.py#L294-L303 | [
"def",
"init_kernel",
"(",
"self",
")",
":",
"kernel_factory",
"=",
"import_item",
"(",
"str",
"(",
"self",
".",
"kernel_class",
")",
")",
"self",
".",
"kernel",
"=",
"kernel_factory",
"(",
"config",
"=",
"self",
".",
"config",
",",
"session",
"=",
"self... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | EngineFactory.init_connector | construct connection function, which handles tunnels. | environment/lib/python2.7/site-packages/IPython/parallel/engine/engine.py | def init_connector(self):
"""construct connection function, which handles tunnels."""
self.using_ssh = bool(self.sshkey or self.sshserver)
if self.sshkey and not self.sshserver:
# We are using ssh directly to the controller, tunneling localhost to localhost
self.sshserve... | def init_connector(self):
"""construct connection function, which handles tunnels."""
self.using_ssh = bool(self.sshkey or self.sshserver)
if self.sshkey and not self.sshserver:
# We are using ssh directly to the controller, tunneling localhost to localhost
self.sshserve... | [
"construct",
"connection",
"function",
"which",
"handles",
"tunnels",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/engine/engine.py#L80-L117 | [
"def",
"init_connector",
"(",
"self",
")",
":",
"self",
".",
"using_ssh",
"=",
"bool",
"(",
"self",
".",
"sshkey",
"or",
"self",
".",
"sshserver",
")",
"if",
"self",
".",
"sshkey",
"and",
"not",
"self",
".",
"sshserver",
":",
"# We are using ssh directly t... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | EngineFactory.register | send the registration_request | environment/lib/python2.7/site-packages/IPython/parallel/engine/engine.py | def register(self):
"""send the registration_request"""
self.log.info("Registering with controller at %s"%self.url)
ctx = self.context
connect,maybe_tunnel = self.init_connector()
reg = ctx.socket(zmq.DEALER)
reg.setsockopt(zmq.IDENTITY, self.bident)
connect(reg,... | def register(self):
"""send the registration_request"""
self.log.info("Registering with controller at %s"%self.url)
ctx = self.context
connect,maybe_tunnel = self.init_connector()
reg = ctx.socket(zmq.DEALER)
reg.setsockopt(zmq.IDENTITY, self.bident)
connect(reg,... | [
"send",
"the",
"registration_request"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/engine/engine.py#L119-L134 | [
"def",
"register",
"(",
"self",
")",
":",
"self",
".",
"log",
".",
"info",
"(",
"\"Registering with controller at %s\"",
"%",
"self",
".",
"url",
")",
"ctx",
"=",
"self",
".",
"context",
"connect",
",",
"maybe_tunnel",
"=",
"self",
".",
"init_connector",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | html_to_text | Converts html content to plain text | toolware/utils/convert.py | def html_to_text(content):
""" Converts html content to plain text """
text = None
h2t = html2text.HTML2Text()
h2t.ignore_links = False
text = h2t.handle(content)
return text | def html_to_text(content):
""" Converts html content to plain text """
text = None
h2t = html2text.HTML2Text()
h2t.ignore_links = False
text = h2t.handle(content)
return text | [
"Converts",
"html",
"content",
"to",
"plain",
"text"
] | un33k/django-toolware | python | https://github.com/un33k/django-toolware/blob/973f3e003dc38b812897dab88455bee37dcaf931/toolware/utils/convert.py#L5-L11 | [
"def",
"html_to_text",
"(",
"content",
")",
":",
"text",
"=",
"None",
"h2t",
"=",
"html2text",
".",
"HTML2Text",
"(",
")",
"h2t",
".",
"ignore_links",
"=",
"False",
"text",
"=",
"h2t",
".",
"handle",
"(",
"content",
")",
"return",
"text"
] | 973f3e003dc38b812897dab88455bee37dcaf931 |
test | md_to_text | Converts markdown content to text | toolware/utils/convert.py | def md_to_text(content):
""" Converts markdown content to text """
text = None
html = markdown.markdown(content)
if html:
text = html_to_text(content)
return text | def md_to_text(content):
""" Converts markdown content to text """
text = None
html = markdown.markdown(content)
if html:
text = html_to_text(content)
return text | [
"Converts",
"markdown",
"content",
"to",
"text"
] | un33k/django-toolware | python | https://github.com/un33k/django-toolware/blob/973f3e003dc38b812897dab88455bee37dcaf931/toolware/utils/convert.py#L20-L26 | [
"def",
"md_to_text",
"(",
"content",
")",
":",
"text",
"=",
"None",
"html",
"=",
"markdown",
".",
"markdown",
"(",
"content",
")",
"if",
"html",
":",
"text",
"=",
"html_to_text",
"(",
"content",
")",
"return",
"text"
] | 973f3e003dc38b812897dab88455bee37dcaf931 |
test | parts_to_uri | Converts uri parts to valid uri.
Example: /memebers, ['profile', 'view'] => /memembers/profile/view | toolware/utils/convert.py | def parts_to_uri(base_uri, uri_parts):
"""
Converts uri parts to valid uri.
Example: /memebers, ['profile', 'view'] => /memembers/profile/view
"""
uri = "/".join(map(lambda x: str(x).rstrip('/'), [base_uri] + uri_parts))
return uri | def parts_to_uri(base_uri, uri_parts):
"""
Converts uri parts to valid uri.
Example: /memebers, ['profile', 'view'] => /memembers/profile/view
"""
uri = "/".join(map(lambda x: str(x).rstrip('/'), [base_uri] + uri_parts))
return uri | [
"Converts",
"uri",
"parts",
"to",
"valid",
"uri",
".",
"Example",
":",
"/",
"memebers",
"[",
"profile",
"view",
"]",
"=",
">",
"/",
"memembers",
"/",
"profile",
"/",
"view"
] | un33k/django-toolware | python | https://github.com/un33k/django-toolware/blob/973f3e003dc38b812897dab88455bee37dcaf931/toolware/utils/convert.py#L29-L35 | [
"def",
"parts_to_uri",
"(",
"base_uri",
",",
"uri_parts",
")",
":",
"uri",
"=",
"\"/\"",
".",
"join",
"(",
"map",
"(",
"lambda",
"x",
":",
"str",
"(",
"x",
")",
".",
"rstrip",
"(",
"'/'",
")",
",",
"[",
"base_uri",
"]",
"+",
"uri_parts",
")",
")"... | 973f3e003dc38b812897dab88455bee37dcaf931 |
test | domain_to_fqdn | returns a fully qualified app domain name | toolware/utils/convert.py | def domain_to_fqdn(domain, proto=None):
""" returns a fully qualified app domain name """
from .generic import get_site_proto
proto = proto or get_site_proto()
fdqn = '{proto}://{domain}'.format(proto=proto, domain=domain)
return fdqn | def domain_to_fqdn(domain, proto=None):
""" returns a fully qualified app domain name """
from .generic import get_site_proto
proto = proto or get_site_proto()
fdqn = '{proto}://{domain}'.format(proto=proto, domain=domain)
return fdqn | [
"returns",
"a",
"fully",
"qualified",
"app",
"domain",
"name"
] | un33k/django-toolware | python | https://github.com/un33k/django-toolware/blob/973f3e003dc38b812897dab88455bee37dcaf931/toolware/utils/convert.py#L38-L43 | [
"def",
"domain_to_fqdn",
"(",
"domain",
",",
"proto",
"=",
"None",
")",
":",
"from",
".",
"generic",
"import",
"get_site_proto",
"proto",
"=",
"proto",
"or",
"get_site_proto",
"(",
")",
"fdqn",
"=",
"'{proto}://{domain}'",
".",
"format",
"(",
"proto",
"=",
... | 973f3e003dc38b812897dab88455bee37dcaf931 |
test | NoseExclude.options | Define the command line options for the plugin. | environment/lib/python2.7/site-packages/nose_exclude.py | def options(self, parser, env=os.environ):
"""Define the command line options for the plugin."""
super(NoseExclude, self).options(parser, env)
env_dirs = []
if 'NOSE_EXCLUDE_DIRS' in env:
exclude_dirs = env.get('NOSE_EXCLUDE_DIRS','')
env_dirs.extend(exclude_dirs.... | def options(self, parser, env=os.environ):
"""Define the command line options for the plugin."""
super(NoseExclude, self).options(parser, env)
env_dirs = []
if 'NOSE_EXCLUDE_DIRS' in env:
exclude_dirs = env.get('NOSE_EXCLUDE_DIRS','')
env_dirs.extend(exclude_dirs.... | [
"Define",
"the",
"command",
"line",
"options",
"for",
"the",
"plugin",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose_exclude.py#L9-L32 | [
"def",
"options",
"(",
"self",
",",
"parser",
",",
"env",
"=",
"os",
".",
"environ",
")",
":",
"super",
"(",
"NoseExclude",
",",
"self",
")",
".",
"options",
"(",
"parser",
",",
"env",
")",
"env_dirs",
"=",
"[",
"]",
"if",
"'NOSE_EXCLUDE_DIRS'",
"in"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | NoseExclude.configure | Configure plugin based on command line options | environment/lib/python2.7/site-packages/nose_exclude.py | def configure(self, options, conf):
"""Configure plugin based on command line options"""
super(NoseExclude, self).configure(options, conf)
self.exclude_dirs = {}
# preload directories from file
if options.exclude_dir_file:
if not options.exclude_dirs:
... | def configure(self, options, conf):
"""Configure plugin based on command line options"""
super(NoseExclude, self).configure(options, conf)
self.exclude_dirs = {}
# preload directories from file
if options.exclude_dir_file:
if not options.exclude_dirs:
... | [
"Configure",
"plugin",
"based",
"on",
"command",
"line",
"options"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose_exclude.py#L52-L85 | [
"def",
"configure",
"(",
"self",
",",
"options",
",",
"conf",
")",
":",
"super",
"(",
"NoseExclude",
",",
"self",
")",
".",
"configure",
"(",
"options",
",",
"conf",
")",
"self",
".",
"exclude_dirs",
"=",
"{",
"}",
"# preload directories from file",
"if",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | NoseExclude.wantDirectory | Check if directory is eligible for test discovery | environment/lib/python2.7/site-packages/nose_exclude.py | def wantDirectory(self, dirname):
"""Check if directory is eligible for test discovery"""
if dirname in self.exclude_dirs:
log.debug("excluded: %s" % dirname)
return False
else:
return None | def wantDirectory(self, dirname):
"""Check if directory is eligible for test discovery"""
if dirname in self.exclude_dirs:
log.debug("excluded: %s" % dirname)
return False
else:
return None | [
"Check",
"if",
"directory",
"is",
"eligible",
"for",
"test",
"discovery"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose_exclude.py#L87-L93 | [
"def",
"wantDirectory",
"(",
"self",
",",
"dirname",
")",
":",
"if",
"dirname",
"in",
"self",
".",
"exclude_dirs",
":",
"log",
".",
"debug",
"(",
"\"excluded: %s\"",
"%",
"dirname",
")",
"return",
"False",
"else",
":",
"return",
"None"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | build_ext.links_to_dynamic | Return true if 'ext' links to a dynamic lib in the same package | environment/lib/python2.7/site-packages/distribute-0.6.31-py2.7.egg/setuptools/command/build_ext.py | def links_to_dynamic(self, ext):
"""Return true if 'ext' links to a dynamic lib in the same package"""
# XXX this should check to ensure the lib is actually being built
# XXX as dynamic, and not just using a locally-found version or a
# XXX static-compiled version
libnames = dict... | def links_to_dynamic(self, ext):
"""Return true if 'ext' links to a dynamic lib in the same package"""
# XXX this should check to ensure the lib is actually being built
# XXX as dynamic, and not just using a locally-found version or a
# XXX static-compiled version
libnames = dict... | [
"Return",
"true",
"if",
"ext",
"links",
"to",
"a",
"dynamic",
"lib",
"in",
"the",
"same",
"package"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/distribute-0.6.31-py2.7.egg/setuptools/command/build_ext.py#L190-L199 | [
"def",
"links_to_dynamic",
"(",
"self",
",",
"ext",
")",
":",
"# XXX this should check to ensure the lib is actually being built",
"# XXX as dynamic, and not just using a locally-found version or a",
"# XXX static-compiled version",
"libnames",
"=",
"dict",
".",
"fromkeys",
"(",
"[... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | call_each | call each func from func list.
return the last func value or None if func list is empty. | jasily/collection/funcs.py | def call_each(funcs: list, *args, **kwargs):
'''
call each func from func list.
return the last func value or None if func list is empty.
'''
ret = None
for func in funcs:
ret = func(*args, **kwargs)
return ret | def call_each(funcs: list, *args, **kwargs):
'''
call each func from func list.
return the last func value or None if func list is empty.
'''
ret = None
for func in funcs:
ret = func(*args, **kwargs)
return ret | [
"call",
"each",
"func",
"from",
"func",
"list",
"."
] | Jasily/jasily-python | python | https://github.com/Jasily/jasily-python/blob/1c821a120ebbbbc3c5761f5f1e8a73588059242a/jasily/collection/funcs.py#L10-L19 | [
"def",
"call_each",
"(",
"funcs",
":",
"list",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"ret",
"=",
"None",
"for",
"func",
"in",
"funcs",
":",
"ret",
"=",
"func",
"(",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"return",
"ret"
] | 1c821a120ebbbbc3c5761f5f1e8a73588059242a |
test | call_each_reversed | call each func from reversed func list.
return the last func value or None if func list is empty. | jasily/collection/funcs.py | def call_each_reversed(funcs: list, *args, **kwargs):
'''
call each func from reversed func list.
return the last func value or None if func list is empty.
'''
ret = None
for func in reversed(funcs):
ret = func(*args, **kwargs)
return ret | def call_each_reversed(funcs: list, *args, **kwargs):
'''
call each func from reversed func list.
return the last func value or None if func list is empty.
'''
ret = None
for func in reversed(funcs):
ret = func(*args, **kwargs)
return ret | [
"call",
"each",
"func",
"from",
"reversed",
"func",
"list",
"."
] | Jasily/jasily-python | python | https://github.com/Jasily/jasily-python/blob/1c821a120ebbbbc3c5761f5f1e8a73588059242a/jasily/collection/funcs.py#L21-L30 | [
"def",
"call_each_reversed",
"(",
"funcs",
":",
"list",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"ret",
"=",
"None",
"for",
"func",
"in",
"reversed",
"(",
"funcs",
")",
":",
"ret",
"=",
"func",
"(",
"*",
"args",
",",
"*",
"*",
"kwargs... | 1c821a120ebbbbc3c5761f5f1e8a73588059242a |
test | CallableList.append_func | append func with given arguments and keywords. | jasily/collection/funcs.py | def append_func(self, func, *args, **kwargs):
'''
append func with given arguments and keywords.
'''
wraped_func = partial(func, *args, **kwargs)
self.append(wraped_func) | def append_func(self, func, *args, **kwargs):
'''
append func with given arguments and keywords.
'''
wraped_func = partial(func, *args, **kwargs)
self.append(wraped_func) | [
"append",
"func",
"with",
"given",
"arguments",
"and",
"keywords",
"."
] | Jasily/jasily-python | python | https://github.com/Jasily/jasily-python/blob/1c821a120ebbbbc3c5761f5f1e8a73588059242a/jasily/collection/funcs.py#L41-L46 | [
"def",
"append_func",
"(",
"self",
",",
"func",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"wraped_func",
"=",
"partial",
"(",
"func",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"self",
".",
"append",
"(",
"wraped_func",
")"
] | 1c821a120ebbbbc3c5761f5f1e8a73588059242a |
test | CallableList.insert_func | insert func with given arguments and keywords. | jasily/collection/funcs.py | def insert_func(self, index, func, *args, **kwargs):
'''
insert func with given arguments and keywords.
'''
wraped_func = partial(func, *args, **kwargs)
self.insert(index, wraped_func) | def insert_func(self, index, func, *args, **kwargs):
'''
insert func with given arguments and keywords.
'''
wraped_func = partial(func, *args, **kwargs)
self.insert(index, wraped_func) | [
"insert",
"func",
"with",
"given",
"arguments",
"and",
"keywords",
"."
] | Jasily/jasily-python | python | https://github.com/Jasily/jasily-python/blob/1c821a120ebbbbc3c5761f5f1e8a73588059242a/jasily/collection/funcs.py#L48-L53 | [
"def",
"insert_func",
"(",
"self",
",",
"index",
",",
"func",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"wraped_func",
"=",
"partial",
"(",
"func",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"self",
".",
"insert",
"(",
"index",
",... | 1c821a120ebbbbc3c5761f5f1e8a73588059242a |
test | PrettyHelpFormatter.format_usage | ensure there is only one newline between usage and the first heading
if there is no description | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/baseparser.py | def format_usage(self, usage):
"""
ensure there is only one newline between usage and the first heading
if there is no description
"""
msg = 'Usage: %s' % usage
if self.parser.description:
msg += '\n'
return msg | def format_usage(self, usage):
"""
ensure there is only one newline between usage and the first heading
if there is no description
"""
msg = 'Usage: %s' % usage
if self.parser.description:
msg += '\n'
return msg | [
"ensure",
"there",
"is",
"only",
"one",
"newline",
"between",
"usage",
"and",
"the",
"first",
"heading",
"if",
"there",
"is",
"no",
"description"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/baseparser.py#L53-L61 | [
"def",
"format_usage",
"(",
"self",
",",
"usage",
")",
":",
"msg",
"=",
"'Usage: %s'",
"%",
"usage",
"if",
"self",
".",
"parser",
".",
"description",
":",
"msg",
"+=",
"'\\n'",
"return",
"msg"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | BaseParallelApplication.initialize | initialize the app | environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py | def initialize(self, argv=None):
"""initialize the app"""
super(BaseParallelApplication, self).initialize(argv)
self.to_work_dir()
self.reinit_logging() | def initialize(self, argv=None):
"""initialize the app"""
super(BaseParallelApplication, self).initialize(argv)
self.to_work_dir()
self.reinit_logging() | [
"initialize",
"the",
"app"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py#L153-L157 | [
"def",
"initialize",
"(",
"self",
",",
"argv",
"=",
"None",
")",
":",
"super",
"(",
"BaseParallelApplication",
",",
"self",
")",
".",
"initialize",
"(",
"argv",
")",
"self",
".",
"to_work_dir",
"(",
")",
"self",
".",
"reinit_logging",
"(",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | BaseParallelApplication.write_pid_file | Create a .pid file in the pid_dir with my pid.
This must be called after pre_construct, which sets `self.pid_dir`.
This raises :exc:`PIDFileError` if the pid file exists already. | environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py | def write_pid_file(self, overwrite=False):
"""Create a .pid file in the pid_dir with my pid.
This must be called after pre_construct, which sets `self.pid_dir`.
This raises :exc:`PIDFileError` if the pid file exists already.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, ... | def write_pid_file(self, overwrite=False):
"""Create a .pid file in the pid_dir with my pid.
This must be called after pre_construct, which sets `self.pid_dir`.
This raises :exc:`PIDFileError` if the pid file exists already.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, ... | [
"Create",
"a",
".",
"pid",
"file",
"in",
"the",
"pid_dir",
"with",
"my",
"pid",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py#L202-L218 | [
"def",
"write_pid_file",
"(",
"self",
",",
"overwrite",
"=",
"False",
")",
":",
"pid_file",
"=",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"profile_dir",
".",
"pid_dir",
",",
"self",
".",
"name",
"+",
"u'.pid'",
")",
"if",
"os",
".",
"path",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | BaseParallelApplication.remove_pid_file | Remove the pid file.
This should be called at shutdown by registering a callback with
:func:`reactor.addSystemEventTrigger`. This needs to return
``None``. | environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py | def remove_pid_file(self):
"""Remove the pid file.
This should be called at shutdown by registering a callback with
:func:`reactor.addSystemEventTrigger`. This needs to return
``None``.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, self.name + u'.pid')
if... | def remove_pid_file(self):
"""Remove the pid file.
This should be called at shutdown by registering a callback with
:func:`reactor.addSystemEventTrigger`. This needs to return
``None``.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, self.name + u'.pid')
if... | [
"Remove",
"the",
"pid",
"file",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py#L220-L233 | [
"def",
"remove_pid_file",
"(",
"self",
")",
":",
"pid_file",
"=",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"profile_dir",
".",
"pid_dir",
",",
"self",
".",
"name",
"+",
"u'.pid'",
")",
"if",
"os",
".",
"path",
".",
"isfile",
"(",
"pid_file",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | BaseParallelApplication.get_pid_from_file | Get the pid from the pid file.
If the pid file doesn't exist a :exc:`PIDFileError` is raised. | environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py | def get_pid_from_file(self):
"""Get the pid from the pid file.
If the pid file doesn't exist a :exc:`PIDFileError` is raised.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, self.name + u'.pid')
if os.path.isfile(pid_file):
with open(pid_file, 'r') as f:
... | def get_pid_from_file(self):
"""Get the pid from the pid file.
If the pid file doesn't exist a :exc:`PIDFileError` is raised.
"""
pid_file = os.path.join(self.profile_dir.pid_dir, self.name + u'.pid')
if os.path.isfile(pid_file):
with open(pid_file, 'r') as f:
... | [
"Get",
"the",
"pid",
"from",
"the",
"pid",
"file",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/parallel/apps/baseapp.py#L235-L250 | [
"def",
"get_pid_from_file",
"(",
"self",
")",
":",
"pid_file",
"=",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"profile_dir",
".",
"pid_dir",
",",
"self",
".",
"name",
"+",
"u'.pid'",
")",
"if",
"os",
".",
"path",
".",
"isfile",
"(",
"pid_file... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | construct_parser | Construct an argument parser using the function decorations. | environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py | def construct_parser(magic_func):
""" Construct an argument parser using the function decorations.
"""
kwds = getattr(magic_func, 'argcmd_kwds', {})
if 'description' not in kwds:
kwds['description'] = getattr(magic_func, '__doc__', None)
arg_name = real_name(magic_func)
parser = MagicArg... | def construct_parser(magic_func):
""" Construct an argument parser using the function decorations.
"""
kwds = getattr(magic_func, 'argcmd_kwds', {})
if 'description' not in kwds:
kwds['description'] = getattr(magic_func, '__doc__', None)
arg_name = real_name(magic_func)
parser = MagicArg... | [
"Construct",
"an",
"argument",
"parser",
"using",
"the",
"function",
"decorations",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py#L95-L121 | [
"def",
"construct_parser",
"(",
"magic_func",
")",
":",
"kwds",
"=",
"getattr",
"(",
"magic_func",
",",
"'argcmd_kwds'",
",",
"{",
"}",
")",
"if",
"'description'",
"not",
"in",
"kwds",
":",
"kwds",
"[",
"'description'",
"]",
"=",
"getattr",
"(",
"magic_fun... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | real_name | Find the real name of the magic. | environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py | def real_name(magic_func):
""" Find the real name of the magic.
"""
magic_name = magic_func.__name__
if magic_name.startswith('magic_'):
magic_name = magic_name[len('magic_'):]
return getattr(magic_func, 'argcmd_name', magic_name) | def real_name(magic_func):
""" Find the real name of the magic.
"""
magic_name = magic_func.__name__
if magic_name.startswith('magic_'):
magic_name = magic_name[len('magic_'):]
return getattr(magic_func, 'argcmd_name', magic_name) | [
"Find",
"the",
"real",
"name",
"of",
"the",
"magic",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py#L130-L136 | [
"def",
"real_name",
"(",
"magic_func",
")",
":",
"magic_name",
"=",
"magic_func",
".",
"__name__",
"if",
"magic_name",
".",
"startswith",
"(",
"'magic_'",
")",
":",
"magic_name",
"=",
"magic_name",
"[",
"len",
"(",
"'magic_'",
")",
":",
"]",
"return",
"get... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | argument.add_to_parser | Add this object's information to the parser. | environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py | def add_to_parser(self, parser, group):
""" Add this object's information to the parser.
"""
if group is not None:
parser = group
parser.add_argument(*self.args, **self.kwds)
return None | def add_to_parser(self, parser, group):
""" Add this object's information to the parser.
"""
if group is not None:
parser = group
parser.add_argument(*self.args, **self.kwds)
return None | [
"Add",
"this",
"object",
"s",
"information",
"to",
"the",
"parser",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py#L185-L191 | [
"def",
"add_to_parser",
"(",
"self",
",",
"parser",
",",
"group",
")",
":",
"if",
"group",
"is",
"not",
"None",
":",
"parser",
"=",
"group",
"parser",
".",
"add_argument",
"(",
"*",
"self",
".",
"args",
",",
"*",
"*",
"self",
".",
"kwds",
")",
"ret... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | argument_group.add_to_parser | Add this object's information to the parser. | environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py | def add_to_parser(self, parser, group):
""" Add this object's information to the parser.
"""
return parser.add_argument_group(*self.args, **self.kwds) | def add_to_parser(self, parser, group):
""" Add this object's information to the parser.
"""
return parser.add_argument_group(*self.args, **self.kwds) | [
"Add",
"this",
"object",
"s",
"information",
"to",
"the",
"parser",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/core/magic_arguments.py#L203-L206 | [
"def",
"add_to_parser",
"(",
"self",
",",
"parser",
",",
"group",
")",
":",
"return",
"parser",
".",
"add_argument_group",
"(",
"*",
"self",
".",
"args",
",",
"*",
"*",
"self",
".",
"kwds",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendHighlighter.highlightBlock | Highlight a block of text. Reimplemented to highlight selectively. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def highlightBlock(self, string):
""" Highlight a block of text. Reimplemented to highlight selectively.
"""
if not self.highlighting_on:
return
# The input to this function is a unicode string that may contain
# paragraph break characters, non-breaking spaces, etc. ... | def highlightBlock(self, string):
""" Highlight a block of text. Reimplemented to highlight selectively.
"""
if not self.highlighting_on:
return
# The input to this function is a unicode string that may contain
# paragraph break characters, non-breaking spaces, etc. ... | [
"Highlight",
"a",
"block",
"of",
"text",
".",
"Reimplemented",
"to",
"highlight",
"selectively",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L36-L59 | [
"def",
"highlightBlock",
"(",
"self",
",",
"string",
")",
":",
"if",
"not",
"self",
".",
"highlighting_on",
":",
"return",
"# The input to this function is a unicode string that may contain",
"# paragraph break characters, non-breaking spaces, etc. Here we acquire",
"# the string a... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendHighlighter.rehighlightBlock | Reimplemented to temporarily enable highlighting if disabled. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def rehighlightBlock(self, block):
""" Reimplemented to temporarily enable highlighting if disabled.
"""
old = self.highlighting_on
self.highlighting_on = True
super(FrontendHighlighter, self).rehighlightBlock(block)
self.highlighting_on = old | def rehighlightBlock(self, block):
""" Reimplemented to temporarily enable highlighting if disabled.
"""
old = self.highlighting_on
self.highlighting_on = True
super(FrontendHighlighter, self).rehighlightBlock(block)
self.highlighting_on = old | [
"Reimplemented",
"to",
"temporarily",
"enable",
"highlighting",
"if",
"disabled",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L61-L67 | [
"def",
"rehighlightBlock",
"(",
"self",
",",
"block",
")",
":",
"old",
"=",
"self",
".",
"highlighting_on",
"self",
".",
"highlighting_on",
"=",
"True",
"super",
"(",
"FrontendHighlighter",
",",
"self",
")",
".",
"rehighlightBlock",
"(",
"block",
")",
"self"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendHighlighter.setFormat | Reimplemented to highlight selectively. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def setFormat(self, start, count, format):
""" Reimplemented to highlight selectively.
"""
start += self._current_offset
super(FrontendHighlighter, self).setFormat(start, count, format) | def setFormat(self, start, count, format):
""" Reimplemented to highlight selectively.
"""
start += self._current_offset
super(FrontendHighlighter, self).setFormat(start, count, format) | [
"Reimplemented",
"to",
"highlight",
"selectively",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L69-L73 | [
"def",
"setFormat",
"(",
"self",
",",
"start",
",",
"count",
",",
"format",
")",
":",
"start",
"+=",
"self",
".",
"_current_offset",
"super",
"(",
"FrontendHighlighter",
",",
"self",
")",
".",
"setFormat",
"(",
"start",
",",
"count",
",",
"format",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget.copy | Copy the currently selected text to the clipboard, removing prompts. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def copy(self):
""" Copy the currently selected text to the clipboard, removing prompts.
"""
if self._page_control is not None and self._page_control.hasFocus():
self._page_control.copy()
elif self._control.hasFocus():
text = self._control.textCursor().selection()... | def copy(self):
""" Copy the currently selected text to the clipboard, removing prompts.
"""
if self._page_control is not None and self._page_control.hasFocus():
self._page_control.copy()
elif self._control.hasFocus():
text = self._control.textCursor().selection()... | [
"Copy",
"the",
"currently",
"selected",
"text",
"to",
"the",
"clipboard",
"removing",
"prompts",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L181-L193 | [
"def",
"copy",
"(",
"self",
")",
":",
"if",
"self",
".",
"_page_control",
"is",
"not",
"None",
"and",
"self",
".",
"_page_control",
".",
"hasFocus",
"(",
")",
":",
"self",
".",
"_page_control",
".",
"copy",
"(",
")",
"elif",
"self",
".",
"_control",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._is_complete | Returns whether 'source' can be completely processed and a new
prompt created. When triggered by an Enter/Return key press,
'interactive' is True; otherwise, it is False. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _is_complete(self, source, interactive):
""" Returns whether 'source' can be completely processed and a new
prompt created. When triggered by an Enter/Return key press,
'interactive' is True; otherwise, it is False.
"""
complete = self._input_splitter.push(source)
... | def _is_complete(self, source, interactive):
""" Returns whether 'source' can be completely processed and a new
prompt created. When triggered by an Enter/Return key press,
'interactive' is True; otherwise, it is False.
"""
complete = self._input_splitter.push(source)
... | [
"Returns",
"whether",
"source",
"can",
"be",
"completely",
"processed",
"and",
"a",
"new",
"prompt",
"created",
".",
"When",
"triggered",
"by",
"an",
"Enter",
"/",
"Return",
"key",
"press",
"interactive",
"is",
"True",
";",
"otherwise",
"it",
"is",
"False",
... | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L199-L207 | [
"def",
"_is_complete",
"(",
"self",
",",
"source",
",",
"interactive",
")",
":",
"complete",
"=",
"self",
".",
"_input_splitter",
".",
"push",
"(",
"source",
")",
"if",
"interactive",
":",
"complete",
"=",
"not",
"self",
".",
"_input_splitter",
".",
"push_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._execute | Execute 'source'. If 'hidden', do not show any output.
See parent class :meth:`execute` docstring for full details. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _execute(self, source, hidden):
""" Execute 'source'. If 'hidden', do not show any output.
See parent class :meth:`execute` docstring for full details.
"""
msg_id = self.kernel_manager.shell_channel.execute(source, hidden)
self._request_info['execute'][msg_id] = self._Execut... | def _execute(self, source, hidden):
""" Execute 'source'. If 'hidden', do not show any output.
See parent class :meth:`execute` docstring for full details.
"""
msg_id = self.kernel_manager.shell_channel.execute(source, hidden)
self._request_info['execute'][msg_id] = self._Execut... | [
"Execute",
"source",
".",
"If",
"hidden",
"do",
"not",
"show",
"any",
"output",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L209-L218 | [
"def",
"_execute",
"(",
"self",
",",
"source",
",",
"hidden",
")",
":",
"msg_id",
"=",
"self",
".",
"kernel_manager",
".",
"shell_channel",
".",
"execute",
"(",
"source",
",",
"hidden",
")",
"self",
".",
"_request_info",
"[",
"'execute'",
"]",
"[",
"msg_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._prompt_finished_hook | Called immediately after a prompt is finished, i.e. when some input
will be processed and a new prompt displayed. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _prompt_finished_hook(self):
""" Called immediately after a prompt is finished, i.e. when some input
will be processed and a new prompt displayed.
"""
# Flush all state from the input splitter so the next round of
# reading input starts with a clean buffer.
self._... | def _prompt_finished_hook(self):
""" Called immediately after a prompt is finished, i.e. when some input
will be processed and a new prompt displayed.
"""
# Flush all state from the input splitter so the next round of
# reading input starts with a clean buffer.
self._... | [
"Called",
"immediately",
"after",
"a",
"prompt",
"is",
"finished",
"i",
".",
"e",
".",
"when",
"some",
"input",
"will",
"be",
"processed",
"and",
"a",
"new",
"prompt",
"displayed",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L226-L235 | [
"def",
"_prompt_finished_hook",
"(",
"self",
")",
":",
"# Flush all state from the input splitter so the next round of",
"# reading input starts with a clean buffer.",
"self",
".",
"_input_splitter",
".",
"reset",
"(",
")",
"if",
"not",
"self",
".",
"_reading",
":",
"self",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._tab_pressed | Called when the tab key is pressed. Returns whether to continue
processing the event. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _tab_pressed(self):
""" Called when the tab key is pressed. Returns whether to continue
processing the event.
"""
# Perform tab completion if:
# 1) The cursor is in the input buffer.
# 2) There is a non-whitespace character before the cursor.
text = self._... | def _tab_pressed(self):
""" Called when the tab key is pressed. Returns whether to continue
processing the event.
"""
# Perform tab completion if:
# 1) The cursor is in the input buffer.
# 2) There is a non-whitespace character before the cursor.
text = self._... | [
"Called",
"when",
"the",
"tab",
"key",
"is",
"pressed",
".",
"Returns",
"whether",
"to",
"continue",
"processing",
"the",
"event",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L237-L250 | [
"def",
"_tab_pressed",
"(",
"self",
")",
":",
"# Perform tab completion if:",
"# 1) The cursor is in the input buffer.",
"# 2) There is a non-whitespace character before the cursor.",
"text",
"=",
"self",
".",
"_get_input_buffer_cursor_line",
"(",
")",
"if",
"text",
"is",
"None... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._context_menu_make | Reimplemented to add an action for raw copy. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _context_menu_make(self, pos):
""" Reimplemented to add an action for raw copy.
"""
menu = super(FrontendWidget, self)._context_menu_make(pos)
for before_action in menu.actions():
if before_action.shortcut().matches(QtGui.QKeySequence.Paste) == \
QtGui... | def _context_menu_make(self, pos):
""" Reimplemented to add an action for raw copy.
"""
menu = super(FrontendWidget, self)._context_menu_make(pos)
for before_action in menu.actions():
if before_action.shortcut().matches(QtGui.QKeySequence.Paste) == \
QtGui... | [
"Reimplemented",
"to",
"add",
"an",
"action",
"for",
"raw",
"copy",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L256-L265 | [
"def",
"_context_menu_make",
"(",
"self",
",",
"pos",
")",
":",
"menu",
"=",
"super",
"(",
"FrontendWidget",
",",
"self",
")",
".",
"_context_menu_make",
"(",
"pos",
")",
"for",
"before_action",
"in",
"menu",
".",
"actions",
"(",
")",
":",
"if",
"before_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._event_filter_console_keypress | Reimplemented for execution interruption and smart backspace. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _event_filter_console_keypress(self, event):
""" Reimplemented for execution interruption and smart backspace.
"""
key = event.key()
if self._control_key_down(event.modifiers(), include_command=False):
if key == QtCore.Qt.Key_C and self._executing:
self.r... | def _event_filter_console_keypress(self, event):
""" Reimplemented for execution interruption and smart backspace.
"""
key = event.key()
if self._control_key_down(event.modifiers(), include_command=False):
if key == QtCore.Qt.Key_C and self._executing:
self.r... | [
"Reimplemented",
"for",
"execution",
"interruption",
"and",
"smart",
"backspace",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L275-L305 | [
"def",
"_event_filter_console_keypress",
"(",
"self",
",",
"event",
")",
":",
"key",
"=",
"event",
".",
"key",
"(",
")",
"if",
"self",
".",
"_control_key_down",
"(",
"event",
".",
"modifiers",
"(",
")",
",",
"include_command",
"=",
"False",
")",
":",
"if... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._insert_continuation_prompt | Reimplemented for auto-indentation. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _insert_continuation_prompt(self, cursor):
""" Reimplemented for auto-indentation.
"""
super(FrontendWidget, self)._insert_continuation_prompt(cursor)
cursor.insertText(' ' * self._input_splitter.indent_spaces) | def _insert_continuation_prompt(self, cursor):
""" Reimplemented for auto-indentation.
"""
super(FrontendWidget, self)._insert_continuation_prompt(cursor)
cursor.insertText(' ' * self._input_splitter.indent_spaces) | [
"Reimplemented",
"for",
"auto",
"-",
"indentation",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L307-L311 | [
"def",
"_insert_continuation_prompt",
"(",
"self",
",",
"cursor",
")",
":",
"super",
"(",
"FrontendWidget",
",",
"self",
")",
".",
"_insert_continuation_prompt",
"(",
"cursor",
")",
"cursor",
".",
"insertText",
"(",
"' '",
"*",
"self",
".",
"_input_splitter",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_complete_reply | Handle replies for tab completion. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_complete_reply(self, rep):
""" Handle replies for tab completion.
"""
self.log.debug("complete: %s", rep.get('content', ''))
cursor = self._get_cursor()
info = self._request_info.get('complete')
if info and info.id == rep['parent_header']['msg_id'] and \
... | def _handle_complete_reply(self, rep):
""" Handle replies for tab completion.
"""
self.log.debug("complete: %s", rep.get('content', ''))
cursor = self._get_cursor()
info = self._request_info.get('complete')
if info and info.id == rep['parent_header']['msg_id'] and \
... | [
"Handle",
"replies",
"for",
"tab",
"completion",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L317-L327 | [
"def",
"_handle_complete_reply",
"(",
"self",
",",
"rep",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"complete: %s\"",
",",
"rep",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"cursor",
"=",
"self",
".",
"_get_cursor",
"(",
")",
"info",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._silent_exec_callback | Silently execute `expr` in the kernel and call `callback` with reply
the `expr` is evaluated silently in the kernel (without) output in
the frontend. Call `callback` with the
`repr <http://docs.python.org/library/functions.html#repr> `_ as first argument
Parameters
----------
... | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _silent_exec_callback(self, expr, callback):
"""Silently execute `expr` in the kernel and call `callback` with reply
the `expr` is evaluated silently in the kernel (without) output in
the frontend. Call `callback` with the
`repr <http://docs.python.org/library/functions.html#repr> `... | def _silent_exec_callback(self, expr, callback):
"""Silently execute `expr` in the kernel and call `callback` with reply
the `expr` is evaluated silently in the kernel (without) output in
the frontend. Call `callback` with the
`repr <http://docs.python.org/library/functions.html#repr> `... | [
"Silently",
"execute",
"expr",
"in",
"the",
"kernel",
"and",
"call",
"callback",
"with",
"reply"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L329-L359 | [
"def",
"_silent_exec_callback",
"(",
"self",
",",
"expr",
",",
"callback",
")",
":",
"# generate uuid, which would be used as an indication of whether or",
"# not the unique request originated from here (can use msg id ?)",
"local_uuid",
"=",
"str",
"(",
"uuid",
".",
"uuid1",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_exec_callback | Execute `callback` corresponding to `msg` reply, after ``_silent_exec_callback``
Parameters
----------
msg : raw message send by the kernel containing an `user_expressions`
and having a 'silent_exec_callback' kind.
Notes
-----
This function will look for... | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_exec_callback(self, msg):
"""Execute `callback` corresponding to `msg` reply, after ``_silent_exec_callback``
Parameters
----------
msg : raw message send by the kernel containing an `user_expressions`
and having a 'silent_exec_callback' kind.
Notes
... | def _handle_exec_callback(self, msg):
"""Execute `callback` corresponding to `msg` reply, after ``_silent_exec_callback``
Parameters
----------
msg : raw message send by the kernel containing an `user_expressions`
and having a 'silent_exec_callback' kind.
Notes
... | [
"Execute",
"callback",
"corresponding",
"to",
"msg",
"reply",
"after",
"_silent_exec_callback"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L361-L385 | [
"def",
"_handle_exec_callback",
"(",
"self",
",",
"msg",
")",
":",
"user_exp",
"=",
"msg",
"[",
"'content'",
"]",
".",
"get",
"(",
"'user_expressions'",
")",
"if",
"not",
"user_exp",
":",
"return",
"for",
"expression",
"in",
"user_exp",
":",
"if",
"express... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_execute_reply | Handles replies for code execution. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_execute_reply(self, msg):
""" Handles replies for code execution.
"""
self.log.debug("execute: %s", msg.get('content', ''))
msg_id = msg['parent_header']['msg_id']
info = self._request_info['execute'].get(msg_id)
# unset reading flag, because if execute finish... | def _handle_execute_reply(self, msg):
""" Handles replies for code execution.
"""
self.log.debug("execute: %s", msg.get('content', ''))
msg_id = msg['parent_header']['msg_id']
info = self._request_info['execute'].get(msg_id)
# unset reading flag, because if execute finish... | [
"Handles",
"replies",
"for",
"code",
"execution",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L387-L423 | [
"def",
"_handle_execute_reply",
"(",
"self",
",",
"msg",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"execute: %s\"",
",",
"msg",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"msg_id",
"=",
"msg",
"[",
"'parent_header'",
"]",
"[",
"'msg_id... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_input_request | Handle requests for raw_input. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_input_request(self, msg):
""" Handle requests for raw_input.
"""
self.log.debug("input: %s", msg.get('content', ''))
if self._hidden:
raise RuntimeError('Request for raw input during hidden execution.')
# Make sure that all output from the SUB channel has... | def _handle_input_request(self, msg):
""" Handle requests for raw_input.
"""
self.log.debug("input: %s", msg.get('content', ''))
if self._hidden:
raise RuntimeError('Request for raw input during hidden execution.')
# Make sure that all output from the SUB channel has... | [
"Handle",
"requests",
"for",
"raw_input",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L425-L441 | [
"def",
"_handle_input_request",
"(",
"self",
",",
"msg",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"input: %s\"",
",",
"msg",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"if",
"self",
".",
"_hidden",
":",
"raise",
"RuntimeError",
"(",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_kernel_died | Handle the kernel's death by asking if the user wants to restart. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_kernel_died(self, since_last_heartbeat):
""" Handle the kernel's death by asking if the user wants to restart.
"""
self.log.debug("kernel died: %s", since_last_heartbeat)
if self.custom_restart:
self.custom_restart_kernel_died.emit(since_last_heartbeat)
el... | def _handle_kernel_died(self, since_last_heartbeat):
""" Handle the kernel's death by asking if the user wants to restart.
"""
self.log.debug("kernel died: %s", since_last_heartbeat)
if self.custom_restart:
self.custom_restart_kernel_died.emit(since_last_heartbeat)
el... | [
"Handle",
"the",
"kernel",
"s",
"death",
"by",
"asking",
"if",
"the",
"user",
"wants",
"to",
"restart",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L443-L454 | [
"def",
"_handle_kernel_died",
"(",
"self",
",",
"since_last_heartbeat",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"kernel died: %s\"",
",",
"since_last_heartbeat",
")",
"if",
"self",
".",
"custom_restart",
":",
"self",
".",
"custom_restart_kernel_died",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_object_info_reply | Handle replies for call tips. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_object_info_reply(self, rep):
""" Handle replies for call tips.
"""
self.log.debug("oinfo: %s", rep.get('content', ''))
cursor = self._get_cursor()
info = self._request_info.get('call_tip')
if info and info.id == rep['parent_header']['msg_id'] and \
... | def _handle_object_info_reply(self, rep):
""" Handle replies for call tips.
"""
self.log.debug("oinfo: %s", rep.get('content', ''))
cursor = self._get_cursor()
info = self._request_info.get('call_tip')
if info and info.id == rep['parent_header']['msg_id'] and \
... | [
"Handle",
"replies",
"for",
"call",
"tips",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L456-L478 | [
"def",
"_handle_object_info_reply",
"(",
"self",
",",
"rep",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"oinfo: %s\"",
",",
"rep",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"cursor",
"=",
"self",
".",
"_get_cursor",
"(",
")",
"info",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_pyout | Handle display hook output. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_pyout(self, msg):
""" Handle display hook output.
"""
self.log.debug("pyout: %s", msg.get('content', ''))
if not self._hidden and self._is_from_this_session(msg):
text = msg['content']['data']
self._append_plain_text(text + '\n', before_prompt=True) | def _handle_pyout(self, msg):
""" Handle display hook output.
"""
self.log.debug("pyout: %s", msg.get('content', ''))
if not self._hidden and self._is_from_this_session(msg):
text = msg['content']['data']
self._append_plain_text(text + '\n', before_prompt=True) | [
"Handle",
"display",
"hook",
"output",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L480-L486 | [
"def",
"_handle_pyout",
"(",
"self",
",",
"msg",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"pyout: %s\"",
",",
"msg",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"if",
"not",
"self",
".",
"_hidden",
"and",
"self",
".",
"_is_from_this_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_stream | Handle stdout, stderr, and stdin. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_stream(self, msg):
""" Handle stdout, stderr, and stdin.
"""
self.log.debug("stream: %s", msg.get('content', ''))
if not self._hidden and self._is_from_this_session(msg):
# Most consoles treat tabs as being 8 space characters. Convert tabs
# to spaces ... | def _handle_stream(self, msg):
""" Handle stdout, stderr, and stdin.
"""
self.log.debug("stream: %s", msg.get('content', ''))
if not self._hidden and self._is_from_this_session(msg):
# Most consoles treat tabs as being 8 space characters. Convert tabs
# to spaces ... | [
"Handle",
"stdout",
"stderr",
"and",
"stdin",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L488-L499 | [
"def",
"_handle_stream",
"(",
"self",
",",
"msg",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"stream: %s\"",
",",
"msg",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"if",
"not",
"self",
".",
"_hidden",
"and",
"self",
".",
"_is_from_thi... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._handle_shutdown_reply | Handle shutdown signal, only if from other console. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _handle_shutdown_reply(self, msg):
""" Handle shutdown signal, only if from other console.
"""
self.log.debug("shutdown: %s", msg.get('content', ''))
if not self._hidden and not self._is_from_this_session(msg):
if self._local_kernel:
if not msg['content'][... | def _handle_shutdown_reply(self, msg):
""" Handle shutdown signal, only if from other console.
"""
self.log.debug("shutdown: %s", msg.get('content', ''))
if not self._hidden and not self._is_from_this_session(msg):
if self._local_kernel:
if not msg['content'][... | [
"Handle",
"shutdown",
"signal",
"only",
"if",
"from",
"other",
"console",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L501-L534 | [
"def",
"_handle_shutdown_reply",
"(",
"self",
",",
"msg",
")",
":",
"self",
".",
"log",
".",
"debug",
"(",
"\"shutdown: %s\"",
",",
"msg",
".",
"get",
"(",
"'content'",
",",
"''",
")",
")",
"if",
"not",
"self",
".",
"_hidden",
"and",
"not",
"self",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget.execute_file | Attempts to execute file with 'path'. If 'hidden', no output is
shown. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def execute_file(self, path, hidden=False):
""" Attempts to execute file with 'path'. If 'hidden', no output is
shown.
"""
self.execute('execfile(%r)' % path, hidden=hidden) | def execute_file(self, path, hidden=False):
""" Attempts to execute file with 'path'. If 'hidden', no output is
shown.
"""
self.execute('execfile(%r)' % path, hidden=hidden) | [
"Attempts",
"to",
"execute",
"file",
"with",
"path",
".",
"If",
"hidden",
"no",
"output",
"is",
"shown",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L552-L556 | [
"def",
"execute_file",
"(",
"self",
",",
"path",
",",
"hidden",
"=",
"False",
")",
":",
"self",
".",
"execute",
"(",
"'execfile(%r)'",
"%",
"path",
",",
"hidden",
"=",
"hidden",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget.interrupt_kernel | Attempts to interrupt the running kernel.
Also unsets _reading flag, to avoid runtime errors
if raw_input is called again. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def interrupt_kernel(self):
""" Attempts to interrupt the running kernel.
Also unsets _reading flag, to avoid runtime errors
if raw_input is called again.
"""
if self.custom_interrupt:
self._reading = False
self.custom_interrupt_requested.emit()
... | def interrupt_kernel(self):
""" Attempts to interrupt the running kernel.
Also unsets _reading flag, to avoid runtime errors
if raw_input is called again.
"""
if self.custom_interrupt:
self._reading = False
self.custom_interrupt_requested.emit()
... | [
"Attempts",
"to",
"interrupt",
"the",
"running",
"kernel",
".",
"Also",
"unsets",
"_reading",
"flag",
"to",
"avoid",
"runtime",
"errors",
"if",
"raw_input",
"is",
"called",
"again",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L558-L572 | [
"def",
"interrupt_kernel",
"(",
"self",
")",
":",
"if",
"self",
".",
"custom_interrupt",
":",
"self",
".",
"_reading",
"=",
"False",
"self",
".",
"custom_interrupt_requested",
".",
"emit",
"(",
")",
"elif",
"self",
".",
"kernel_manager",
".",
"has_kernel",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget.reset | Resets the widget to its initial state if ``clear`` parameter or
``clear_on_kernel_restart`` configuration setting is True, otherwise
prints a visual indication of the fact that the kernel restarted, but
does not clear the traces from previous usage of the kernel before it
was restarted.... | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def reset(self, clear=False):
""" Resets the widget to its initial state if ``clear`` parameter or
``clear_on_kernel_restart`` configuration setting is True, otherwise
prints a visual indication of the fact that the kernel restarted, but
does not clear the traces from previous usage of t... | def reset(self, clear=False):
""" Resets the widget to its initial state if ``clear`` parameter or
``clear_on_kernel_restart`` configuration setting is True, otherwise
prints a visual indication of the fact that the kernel restarted, but
does not clear the traces from previous usage of t... | [
"Resets",
"the",
"widget",
"to",
"its",
"initial",
"state",
"if",
"clear",
"parameter",
"or",
"clear_on_kernel_restart",
"configuration",
"setting",
"is",
"True",
"otherwise",
"prints",
"a",
"visual",
"indication",
"of",
"the",
"fact",
"that",
"the",
"kernel",
"... | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L574-L600 | [
"def",
"reset",
"(",
"self",
",",
"clear",
"=",
"False",
")",
":",
"if",
"self",
".",
"_executing",
":",
"self",
".",
"_executing",
"=",
"False",
"self",
".",
"_request_info",
"[",
"'execute'",
"]",
"=",
"{",
"}",
"self",
".",
"_reading",
"=",
"False... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget.restart_kernel | Attempts to restart the running kernel. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def restart_kernel(self, message, now=False):
""" Attempts to restart the running kernel.
"""
# FIXME: now should be configurable via a checkbox in the dialog. Right
# now at least the heartbeat path sets it to True and the manual restart
# to False. But those should just be th... | def restart_kernel(self, message, now=False):
""" Attempts to restart the running kernel.
"""
# FIXME: now should be configurable via a checkbox in the dialog. Right
# now at least the heartbeat path sets it to True and the manual restart
# to False. But those should just be th... | [
"Attempts",
"to",
"restart",
"the",
"running",
"kernel",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L602-L647 | [
"def",
"restart_kernel",
"(",
"self",
",",
"message",
",",
"now",
"=",
"False",
")",
":",
"# FIXME: now should be configurable via a checkbox in the dialog. Right",
"# now at least the heartbeat path sets it to True and the manual restart",
"# to False. But those should just be the pre... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._call_tip | Shows a call tip, if appropriate, at the current cursor location. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _call_tip(self):
""" Shows a call tip, if appropriate, at the current cursor location.
"""
# Decide if it makes sense to show a call tip
if not self.enable_calltips:
return False
cursor = self._get_cursor()
cursor.movePosition(QtGui.QTextCursor.Left)
... | def _call_tip(self):
""" Shows a call tip, if appropriate, at the current cursor location.
"""
# Decide if it makes sense to show a call tip
if not self.enable_calltips:
return False
cursor = self._get_cursor()
cursor.movePosition(QtGui.QTextCursor.Left)
... | [
"Shows",
"a",
"call",
"tip",
"if",
"appropriate",
"at",
"the",
"current",
"cursor",
"location",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L653-L672 | [
"def",
"_call_tip",
"(",
"self",
")",
":",
"# Decide if it makes sense to show a call tip",
"if",
"not",
"self",
".",
"enable_calltips",
":",
"return",
"False",
"cursor",
"=",
"self",
".",
"_get_cursor",
"(",
")",
"cursor",
".",
"movePosition",
"(",
"QtGui",
"."... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._complete | Performs completion at the current cursor location. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _complete(self):
""" Performs completion at the current cursor location.
"""
context = self._get_context()
if context:
# Send the completion request to the kernel
msg_id = self.kernel_manager.shell_channel.complete(
'.'.join(context), ... | def _complete(self):
""" Performs completion at the current cursor location.
"""
context = self._get_context()
if context:
# Send the completion request to the kernel
msg_id = self.kernel_manager.shell_channel.complete(
'.'.join(context), ... | [
"Performs",
"completion",
"at",
"the",
"current",
"cursor",
"location",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L674-L687 | [
"def",
"_complete",
"(",
"self",
")",
":",
"context",
"=",
"self",
".",
"_get_context",
"(",
")",
"if",
"context",
":",
"# Send the completion request to the kernel",
"msg_id",
"=",
"self",
".",
"kernel_manager",
".",
"shell_channel",
".",
"complete",
"(",
"'.'"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._get_context | Gets the context for the specified cursor (or the current cursor
if none is specified). | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _get_context(self, cursor=None):
""" Gets the context for the specified cursor (or the current cursor
if none is specified).
"""
if cursor is None:
cursor = self._get_cursor()
cursor.movePosition(QtGui.QTextCursor.StartOfBlock,
QtGu... | def _get_context(self, cursor=None):
""" Gets the context for the specified cursor (or the current cursor
if none is specified).
"""
if cursor is None:
cursor = self._get_cursor()
cursor.movePosition(QtGui.QTextCursor.StartOfBlock,
QtGu... | [
"Gets",
"the",
"context",
"for",
"the",
"specified",
"cursor",
"(",
"or",
"the",
"current",
"cursor",
"if",
"none",
"is",
"specified",
")",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L689-L698 | [
"def",
"_get_context",
"(",
"self",
",",
"cursor",
"=",
"None",
")",
":",
"if",
"cursor",
"is",
"None",
":",
"cursor",
"=",
"self",
".",
"_get_cursor",
"(",
")",
"cursor",
".",
"movePosition",
"(",
"QtGui",
".",
"QTextCursor",
".",
"StartOfBlock",
",",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._process_execute_error | Process a reply for an execution request that resulted in an error. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _process_execute_error(self, msg):
""" Process a reply for an execution request that resulted in an error.
"""
content = msg['content']
# If a SystemExit is passed along, this means exit() was called - also
# all the ipython %exit magic syntax of '-k' to be used to keep
... | def _process_execute_error(self, msg):
""" Process a reply for an execution request that resulted in an error.
"""
content = msg['content']
# If a SystemExit is passed along, this means exit() was called - also
# all the ipython %exit magic syntax of '-k' to be used to keep
... | [
"Process",
"a",
"reply",
"for",
"an",
"execution",
"request",
"that",
"resulted",
"in",
"an",
"error",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L705-L718 | [
"def",
"_process_execute_error",
"(",
"self",
",",
"msg",
")",
":",
"content",
"=",
"msg",
"[",
"'content'",
"]",
"# If a SystemExit is passed along, this means exit() was called - also",
"# all the ipython %exit magic syntax of '-k' to be used to keep",
"# the kernel running",
"if... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._process_execute_ok | Process a reply for a successful execution request. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _process_execute_ok(self, msg):
""" Process a reply for a successful execution request.
"""
payload = msg['content']['payload']
for item in payload:
if not self._process_execute_payload(item):
warning = 'Warning: received unknown payload of type %s'
... | def _process_execute_ok(self, msg):
""" Process a reply for a successful execution request.
"""
payload = msg['content']['payload']
for item in payload:
if not self._process_execute_payload(item):
warning = 'Warning: received unknown payload of type %s'
... | [
"Process",
"a",
"reply",
"for",
"a",
"successful",
"execution",
"request",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L720-L727 | [
"def",
"_process_execute_ok",
"(",
"self",
",",
"msg",
")",
":",
"payload",
"=",
"msg",
"[",
"'content'",
"]",
"[",
"'payload'",
"]",
"for",
"item",
"in",
"payload",
":",
"if",
"not",
"self",
".",
"_process_execute_payload",
"(",
"item",
")",
":",
"warni... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | FrontendWidget._document_contents_change | Called whenever the document's content changes. Display a call tip
if appropriate. | environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py | def _document_contents_change(self, position, removed, added):
""" Called whenever the document's content changes. Display a call tip
if appropriate.
"""
# Calculate where the cursor should be *after* the change:
position += added
document = self._control.document()
... | def _document_contents_change(self, position, removed, added):
""" Called whenever the document's content changes. Display a call tip
if appropriate.
"""
# Calculate where the cursor should be *after* the change:
position += added
document = self._control.document()
... | [
"Called",
"whenever",
"the",
"document",
"s",
"content",
"changes",
".",
"Display",
"a",
"call",
"tip",
"if",
"appropriate",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/frontend/qt/console/frontend_widget.py#L749-L758 | [
"def",
"_document_contents_change",
"(",
"self",
",",
"position",
",",
"removed",
",",
"added",
")",
":",
"# Calculate where the cursor should be *after* the change:",
"position",
"+=",
"added",
"document",
"=",
"self",
".",
"_control",
".",
"document",
"(",
")",
"i... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginProxy.addPlugin | Add plugin to my list of plugins to call, if it has the attribute
I'm bound to. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def addPlugin(self, plugin, call):
"""Add plugin to my list of plugins to call, if it has the attribute
I'm bound to.
"""
meth = getattr(plugin, call, None)
if meth is not None:
if call == 'loadTestsFromModule' and \
len(inspect.getargspec(meth)[0]... | def addPlugin(self, plugin, call):
"""Add plugin to my list of plugins to call, if it has the attribute
I'm bound to.
"""
meth = getattr(plugin, call, None)
if meth is not None:
if call == 'loadTestsFromModule' and \
len(inspect.getargspec(meth)[0]... | [
"Add",
"plugin",
"to",
"my",
"list",
"of",
"plugins",
"to",
"call",
"if",
"it",
"has",
"the",
"attribute",
"I",
"m",
"bound",
"to",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L101-L111 | [
"def",
"addPlugin",
"(",
"self",
",",
"plugin",
",",
"call",
")",
":",
"meth",
"=",
"getattr",
"(",
"plugin",
",",
"call",
",",
"None",
")",
"if",
"meth",
"is",
"not",
"None",
":",
"if",
"call",
"==",
"'loadTestsFromModule'",
"and",
"len",
"(",
"insp... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginProxy.chain | Call plugins in a chain, where the result of each plugin call is
sent to the next plugin as input. The final output result is returned. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def chain(self, *arg, **kw):
"""Call plugins in a chain, where the result of each plugin call is
sent to the next plugin as input. The final output result is returned.
"""
result = None
# extract the static arguments (if any) from arg so they can
# be passed to each plugi... | def chain(self, *arg, **kw):
"""Call plugins in a chain, where the result of each plugin call is
sent to the next plugin as input. The final output result is returned.
"""
result = None
# extract the static arguments (if any) from arg so they can
# be passed to each plugi... | [
"Call",
"plugins",
"in",
"a",
"chain",
"where",
"the",
"result",
"of",
"each",
"plugin",
"call",
"is",
"sent",
"to",
"the",
"next",
"plugin",
"as",
"input",
".",
"The",
"final",
"output",
"result",
"is",
"returned",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L130-L144 | [
"def",
"chain",
"(",
"self",
",",
"*",
"arg",
",",
"*",
"*",
"kw",
")",
":",
"result",
"=",
"None",
"# extract the static arguments (if any) from arg so they can",
"# be passed to each plugin call in the chain",
"static",
"=",
"[",
"a",
"for",
"(",
"static",
",",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginProxy.generate | Call all plugins, yielding each item in each non-None result. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def generate(self, *arg, **kw):
"""Call all plugins, yielding each item in each non-None result.
"""
for p, meth in self.plugins:
result = None
try:
result = meth(*arg, **kw)
if result is not None:
for r in result:
... | def generate(self, *arg, **kw):
"""Call all plugins, yielding each item in each non-None result.
"""
for p, meth in self.plugins:
result = None
try:
result = meth(*arg, **kw)
if result is not None:
for r in result:
... | [
"Call",
"all",
"plugins",
"yielding",
"each",
"item",
"in",
"each",
"non",
"-",
"None",
"result",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L146-L161 | [
"def",
"generate",
"(",
"self",
",",
"*",
"arg",
",",
"*",
"*",
"kw",
")",
":",
"for",
"p",
",",
"meth",
"in",
"self",
".",
"plugins",
":",
"result",
"=",
"None",
"try",
":",
"result",
"=",
"meth",
"(",
"*",
"arg",
",",
"*",
"*",
"kw",
")",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginProxy.simple | Call all plugins, returning the first non-None result. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def simple(self, *arg, **kw):
"""Call all plugins, returning the first non-None result.
"""
for p, meth in self.plugins:
result = meth(*arg, **kw)
if result is not None:
return result | def simple(self, *arg, **kw):
"""Call all plugins, returning the first non-None result.
"""
for p, meth in self.plugins:
result = meth(*arg, **kw)
if result is not None:
return result | [
"Call",
"all",
"plugins",
"returning",
"the",
"first",
"non",
"-",
"None",
"result",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L163-L169 | [
"def",
"simple",
"(",
"self",
",",
"*",
"arg",
",",
"*",
"*",
"kw",
")",
":",
"for",
"p",
",",
"meth",
"in",
"self",
".",
"plugins",
":",
"result",
"=",
"meth",
"(",
"*",
"arg",
",",
"*",
"*",
"kw",
")",
"if",
"result",
"is",
"not",
"None",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginManager.addPlugins | extraplugins are maintained in a separate list and
re-added by loadPlugins() to prevent their being overwritten
by plugins added by a subclass of PluginManager | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def addPlugins(self, plugins=(), extraplugins=()):
"""extraplugins are maintained in a separate list and
re-added by loadPlugins() to prevent their being overwritten
by plugins added by a subclass of PluginManager
"""
self._extraplugins = extraplugins
for plug in iterchai... | def addPlugins(self, plugins=(), extraplugins=()):
"""extraplugins are maintained in a separate list and
re-added by loadPlugins() to prevent their being overwritten
by plugins added by a subclass of PluginManager
"""
self._extraplugins = extraplugins
for plug in iterchai... | [
"extraplugins",
"are",
"maintained",
"in",
"a",
"separate",
"list",
"and",
"re",
"-",
"added",
"by",
"loadPlugins",
"()",
"to",
"prevent",
"their",
"being",
"overwritten",
"by",
"plugins",
"added",
"by",
"a",
"subclass",
"of",
"PluginManager"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L267-L274 | [
"def",
"addPlugins",
"(",
"self",
",",
"plugins",
"=",
"(",
")",
",",
"extraplugins",
"=",
"(",
")",
")",
":",
"self",
".",
"_extraplugins",
"=",
"extraplugins",
"for",
"plug",
"in",
"iterchain",
"(",
"plugins",
",",
"extraplugins",
")",
":",
"self",
"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | PluginManager.configure | Configure the set of plugins with the given options
and config instance. After configuration, disabled plugins
are removed from the plugins list. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def configure(self, options, config):
"""Configure the set of plugins with the given options
and config instance. After configuration, disabled plugins
are removed from the plugins list.
"""
log.debug("Configuring plugins")
self.config = config
cfg = PluginProxy('... | def configure(self, options, config):
"""Configure the set of plugins with the given options
and config instance. After configuration, disabled plugins
are removed from the plugins list.
"""
log.debug("Configuring plugins")
self.config = config
cfg = PluginProxy('... | [
"Configure",
"the",
"set",
"of",
"plugins",
"with",
"the",
"given",
"options",
"and",
"config",
"instance",
".",
"After",
"configuration",
"disabled",
"plugins",
"are",
"removed",
"from",
"the",
"plugins",
"list",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L276-L288 | [
"def",
"configure",
"(",
"self",
",",
"options",
",",
"config",
")",
":",
"log",
".",
"debug",
"(",
"\"Configuring plugins\"",
")",
"self",
".",
"config",
"=",
"config",
"cfg",
"=",
"PluginProxy",
"(",
"'configure'",
",",
"self",
".",
"_plugins",
")",
"c... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | EntryPointPluginManager.loadPlugins | Load plugins by iterating the `nose.plugins` entry point. | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def loadPlugins(self):
"""Load plugins by iterating the `nose.plugins` entry point.
"""
from pkg_resources import iter_entry_points
loaded = {}
for entry_point, adapt in self.entry_points:
for ep in iter_entry_points(entry_point):
if ep.name in loaded:... | def loadPlugins(self):
"""Load plugins by iterating the `nose.plugins` entry point.
"""
from pkg_resources import iter_entry_points
loaded = {}
for entry_point, adapt in self.entry_points:
for ep in iter_entry_points(entry_point):
if ep.name in loaded:... | [
"Load",
"plugins",
"by",
"iterating",
"the",
"nose",
".",
"plugins",
"entry",
"point",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L375-L402 | [
"def",
"loadPlugins",
"(",
"self",
")",
":",
"from",
"pkg_resources",
"import",
"iter_entry_points",
"loaded",
"=",
"{",
"}",
"for",
"entry_point",
",",
"adapt",
"in",
"self",
".",
"entry_points",
":",
"for",
"ep",
"in",
"iter_entry_points",
"(",
"entry_point"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | BuiltinPluginManager.loadPlugins | Load plugins in nose.plugins.builtin | environment/lib/python2.7/site-packages/nose/plugins/manager.py | def loadPlugins(self):
"""Load plugins in nose.plugins.builtin
"""
from nose.plugins import builtin
for plug in builtin.plugins:
self.addPlugin(plug())
super(BuiltinPluginManager, self).loadPlugins() | def loadPlugins(self):
"""Load plugins in nose.plugins.builtin
"""
from nose.plugins import builtin
for plug in builtin.plugins:
self.addPlugin(plug())
super(BuiltinPluginManager, self).loadPlugins() | [
"Load",
"plugins",
"in",
"nose",
".",
"plugins",
".",
"builtin"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/nose/plugins/manager.py#L409-L415 | [
"def",
"loadPlugins",
"(",
"self",
")",
":",
"from",
"nose",
".",
"plugins",
"import",
"builtin",
"for",
"plug",
"in",
"builtin",
".",
"plugins",
":",
"self",
".",
"addPlugin",
"(",
"plug",
"(",
")",
")",
"super",
"(",
"BuiltinPluginManager",
",",
"self"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | latex_to_png | Render a LaTeX string to PNG.
Parameters
----------
s : str
The raw string containing valid inline LaTeX.
encode : bool, optional
Should the PNG data bebase64 encoded to make it JSON'able.
backend : {mpl, dvipng}
Backend for producing PNG data.
None is returned when the... | environment/lib/python2.7/site-packages/IPython/lib/latextools.py | def latex_to_png(s, encode=False, backend='mpl'):
"""Render a LaTeX string to PNG.
Parameters
----------
s : str
The raw string containing valid inline LaTeX.
encode : bool, optional
Should the PNG data bebase64 encoded to make it JSON'able.
backend : {mpl, dvipng}
Backe... | def latex_to_png(s, encode=False, backend='mpl'):
"""Render a LaTeX string to PNG.
Parameters
----------
s : str
The raw string containing valid inline LaTeX.
encode : bool, optional
Should the PNG data bebase64 encoded to make it JSON'able.
backend : {mpl, dvipng}
Backe... | [
"Render",
"a",
"LaTeX",
"string",
"to",
"PNG",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/lib/latextools.py#L34-L58 | [
"def",
"latex_to_png",
"(",
"s",
",",
"encode",
"=",
"False",
",",
"backend",
"=",
"'mpl'",
")",
":",
"if",
"backend",
"==",
"'mpl'",
":",
"f",
"=",
"latex_to_png_mpl",
"elif",
"backend",
"==",
"'dvipng'",
":",
"f",
"=",
"latex_to_png_dvipng",
"else",
":... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | latex_to_html | Render LaTeX to HTML with embedded PNG data using data URIs.
Parameters
----------
s : str
The raw string containing valid inline LateX.
alt : str
The alt text to use for the HTML. | environment/lib/python2.7/site-packages/IPython/lib/latextools.py | def latex_to_html(s, alt='image'):
"""Render LaTeX to HTML with embedded PNG data using data URIs.
Parameters
----------
s : str
The raw string containing valid inline LateX.
alt : str
The alt text to use for the HTML.
"""
base64_data = latex_to_png(s, encode=True)
if ba... | def latex_to_html(s, alt='image'):
"""Render LaTeX to HTML with embedded PNG data using data URIs.
Parameters
----------
s : str
The raw string containing valid inline LateX.
alt : str
The alt text to use for the HTML.
"""
base64_data = latex_to_png(s, encode=True)
if ba... | [
"Render",
"LaTeX",
"to",
"HTML",
"with",
"embedded",
"PNG",
"data",
"using",
"data",
"URIs",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/lib/latextools.py#L121-L133 | [
"def",
"latex_to_html",
"(",
"s",
",",
"alt",
"=",
"'image'",
")",
":",
"base64_data",
"=",
"latex_to_png",
"(",
"s",
",",
"encode",
"=",
"True",
")",
"if",
"base64_data",
":",
"return",
"_data_uri_template_png",
"%",
"(",
"base64_data",
",",
"alt",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | math_to_image | Given a math expression, renders it in a closely-clipped bounding
box to an image file.
*s*
A math expression. The math portion should be enclosed in
dollar signs.
*filename_or_obj*
A filepath or writable file-like object to write the image data
to.
*prop*
If provi... | environment/lib/python2.7/site-packages/IPython/lib/latextools.py | def math_to_image(s, filename_or_obj, prop=None, dpi=None, format=None):
"""
Given a math expression, renders it in a closely-clipped bounding
box to an image file.
*s*
A math expression. The math portion should be enclosed in
dollar signs.
*filename_or_obj*
A filepath or wri... | def math_to_image(s, filename_or_obj, prop=None, dpi=None, format=None):
"""
Given a math expression, renders it in a closely-clipped bounding
box to an image file.
*s*
A math expression. The math portion should be enclosed in
dollar signs.
*filename_or_obj*
A filepath or wri... | [
"Given",
"a",
"math",
"expression",
"renders",
"it",
"in",
"a",
"closely",
"-",
"clipped",
"bounding",
"box",
"to",
"an",
"image",
"file",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/IPython/lib/latextools.py#L138-L180 | [
"def",
"math_to_image",
"(",
"s",
",",
"filename_or_obj",
",",
"prop",
"=",
"None",
",",
"dpi",
"=",
"None",
",",
"format",
"=",
"None",
")",
":",
"from",
"matplotlib",
"import",
"figure",
"# backend_agg supports all of the core output formats",
"from",
"matplotli... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | WheelBuilder.build | Build wheels. | virtualEnvironment/lib/python2.7/site-packages/pip/wheel.py | def build(self):
"""Build wheels."""
# unpack and constructs req set
self.requirement_set.prepare_files(self.finder)
reqset = self.requirement_set.requirements.values()
buildset = []
for req in reqset:
if req.is_wheel:
logger.info(
... | def build(self):
"""Build wheels."""
# unpack and constructs req set
self.requirement_set.prepare_files(self.finder)
reqset = self.requirement_set.requirements.values()
buildset = []
for req in reqset:
if req.is_wheel:
logger.info(
... | [
"Build",
"wheels",
"."
] | tnkteja/myhelp | python | https://github.com/tnkteja/myhelp/blob/fb3a4809d448ad14d5b2e6ddf2e7e89ad52b71cb/virtualEnvironment/lib/python2.7/site-packages/pip/wheel.py#L572-L621 | [
"def",
"build",
"(",
"self",
")",
":",
"# unpack and constructs req set",
"self",
".",
"requirement_set",
".",
"prepare_files",
"(",
"self",
".",
"finder",
")",
"reqset",
"=",
"self",
".",
"requirement_set",
".",
"requirements",
".",
"values",
"(",
")",
"build... | fb3a4809d448ad14d5b2e6ddf2e7e89ad52b71cb |
test | parse_editable | Parses svn+http://blahblah@rev#egg=Foobar into a requirement
(Foobar) and a URL | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py | def parse_editable(editable_req, default_vcs=None):
"""Parses svn+http://blahblah@rev#egg=Foobar into a requirement
(Foobar) and a URL"""
url = editable_req
extras = None
# If a file path is specified with extras, strip off the extras.
m = re.match(r'^(.+)(\[[^\]]+\])$', url)
if m:
... | def parse_editable(editable_req, default_vcs=None):
"""Parses svn+http://blahblah@rev#egg=Foobar into a requirement
(Foobar) and a URL"""
url = editable_req
extras = None
# If a file path is specified with extras, strip off the extras.
m = re.match(r'^(.+)(\[[^\]]+\])$', url)
if m:
... | [
"Parses",
"svn",
"+",
"http",
":",
"//",
"blahblah"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py#L1334-L1394 | [
"def",
"parse_editable",
"(",
"editable_req",
",",
"default_vcs",
"=",
"None",
")",
":",
"url",
"=",
"editable_req",
"extras",
"=",
"None",
"# If a file path is specified with extras, strip off the extras.",
"m",
"=",
"re",
".",
"match",
"(",
"r'^(.+)(\\[[^\\]]+\\])$'",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | InstallRequirement.uninstall | Uninstall the distribution currently satisfying this requirement.
Prompts before removing or modifying files unless
``auto_confirm`` is True.
Refuses to delete or modify files outside of ``sys.prefix`` -
thus uninstallation within a virtual environment can only
modify that virt... | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py | def uninstall(self, auto_confirm=False):
"""
Uninstall the distribution currently satisfying this requirement.
Prompts before removing or modifying files unless
``auto_confirm`` is True.
Refuses to delete or modify files outside of ``sys.prefix`` -
thus uninstallation w... | def uninstall(self, auto_confirm=False):
"""
Uninstall the distribution currently satisfying this requirement.
Prompts before removing or modifying files unless
``auto_confirm`` is True.
Refuses to delete or modify files outside of ``sys.prefix`` -
thus uninstallation w... | [
"Uninstall",
"the",
"distribution",
"currently",
"satisfying",
"this",
"requirement",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py#L403-L496 | [
"def",
"uninstall",
"(",
"self",
",",
"auto_confirm",
"=",
"False",
")",
":",
"if",
"not",
"self",
".",
"check_if_exists",
"(",
")",
":",
"raise",
"UninstallationError",
"(",
"\"Cannot uninstall requirement %s, not installed\"",
"%",
"(",
"self",
".",
"name",
",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | InstallRequirement.check_if_exists | Find an installed distribution that satisfies or conflicts
with this requirement, and set self.satisfied_by or
self.conflicts_with appropriately. | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py | def check_if_exists(self):
"""Find an installed distribution that satisfies or conflicts
with this requirement, and set self.satisfied_by or
self.conflicts_with appropriately."""
if self.req is None:
return False
try:
self.satisfied_by = pkg_resources.get_... | def check_if_exists(self):
"""Find an installed distribution that satisfies or conflicts
with this requirement, and set self.satisfied_by or
self.conflicts_with appropriately."""
if self.req is None:
return False
try:
self.satisfied_by = pkg_resources.get_... | [
"Find",
"an",
"installed",
"distribution",
"that",
"satisfies",
"or",
"conflicts",
"with",
"this",
"requirement",
"and",
"set",
"self",
".",
"satisfied_by",
"or",
"self",
".",
"conflicts_with",
"appropriately",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py#L669-L689 | [
"def",
"check_if_exists",
"(",
"self",
")",
":",
"if",
"self",
".",
"req",
"is",
"None",
":",
"return",
"False",
"try",
":",
"self",
".",
"satisfied_by",
"=",
"pkg_resources",
".",
"get_distribution",
"(",
"self",
".",
"req",
")",
"except",
"pkg_resources"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | RequirementSet.cleanup_files | Clean up files, remove builds. | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py | def cleanup_files(self, bundle=False):
"""Clean up files, remove builds."""
logger.notify('Cleaning up...')
logger.indent += 2
for req in self.reqs_to_cleanup:
req.remove_temporary_source()
remove_dir = []
if self._pip_has_created_build_dir():
rem... | def cleanup_files(self, bundle=False):
"""Clean up files, remove builds."""
logger.notify('Cleaning up...')
logger.indent += 2
for req in self.reqs_to_cleanup:
req.remove_temporary_source()
remove_dir = []
if self._pip_has_created_build_dir():
rem... | [
"Clean",
"up",
"files",
"remove",
"builds",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py#L1095-L1116 | [
"def",
"cleanup_files",
"(",
"self",
",",
"bundle",
"=",
"False",
")",
":",
"logger",
".",
"notify",
"(",
"'Cleaning up...'",
")",
"logger",
".",
"indent",
"+=",
"2",
"for",
"req",
"in",
"self",
".",
"reqs_to_cleanup",
":",
"req",
".",
"remove_temporary_so... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | RequirementSet.install | Install everything in this set (after having downloaded and unpacked the packages) | environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py | def install(self, install_options, global_options=()):
"""Install everything in this set (after having downloaded and unpacked the packages)"""
to_install = [r for r in self.requirements.values()
if not r.satisfied_by]
if to_install:
logger.notify('Installing c... | def install(self, install_options, global_options=()):
"""Install everything in this set (after having downloaded and unpacked the packages)"""
to_install = [r for r in self.requirements.values()
if not r.satisfied_by]
if to_install:
logger.notify('Installing c... | [
"Install",
"everything",
"in",
"this",
"set",
"(",
"after",
"having",
"downloaded",
"and",
"unpacked",
"the",
"packages",
")"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py#L1147-L1178 | [
"def",
"install",
"(",
"self",
",",
"install_options",
",",
"global_options",
"=",
"(",
")",
")",
":",
"to_install",
"=",
"[",
"r",
"for",
"r",
"in",
"self",
".",
"requirements",
".",
"values",
"(",
")",
"if",
"not",
"r",
".",
"satisfied_by",
"]",
"i... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | process_iter | Return a generator yielding a Process class instance for all
running processes on the local machine.
Every new Process instance is only created once and then cached
into an internal table which is updated every time this is used.
The sorting order in which processes are yielded is based on
their P... | environment/lib/python2.7/site-packages/psutil/__init__.py | def process_iter():
"""Return a generator yielding a Process class instance for all
running processes on the local machine.
Every new Process instance is only created once and then cached
into an internal table which is updated every time this is used.
The sorting order in which processes are yiel... | def process_iter():
"""Return a generator yielding a Process class instance for all
running processes on the local machine.
Every new Process instance is only created once and then cached
into an internal table which is updated every time this is used.
The sorting order in which processes are yiel... | [
"Return",
"a",
"generator",
"yielding",
"a",
"Process",
"class",
"instance",
"for",
"all",
"running",
"processes",
"on",
"the",
"local",
"machine",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L792-L835 | [
"def",
"process_iter",
"(",
")",
":",
"def",
"add",
"(",
"pid",
")",
":",
"proc",
"=",
"Process",
"(",
"pid",
")",
"_pmap",
"[",
"proc",
".",
"pid",
"]",
"=",
"proc",
"return",
"proc",
"def",
"remove",
"(",
"pid",
")",
":",
"_pmap",
".",
"pop",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | cpu_percent | Return a float representing the current system-wide CPU
utilization as a percentage.
When interval is > 0.0 compares system CPU times elapsed before
and after the interval (blocking).
When interval is 0.0 or None compares system CPU times elapsed
since last call or module import, returning immedia... | environment/lib/python2.7/site-packages/psutil/__init__.py | def cpu_percent(interval=0.1, percpu=False):
"""Return a float representing the current system-wide CPU
utilization as a percentage.
When interval is > 0.0 compares system CPU times elapsed before
and after the interval (blocking).
When interval is 0.0 or None compares system CPU times elapsed
... | def cpu_percent(interval=0.1, percpu=False):
"""Return a float representing the current system-wide CPU
utilization as a percentage.
When interval is > 0.0 compares system CPU times elapsed before
and after the interval (blocking).
When interval is 0.0 or None compares system CPU times elapsed
... | [
"Return",
"a",
"float",
"representing",
"the",
"current",
"system",
"-",
"wide",
"CPU",
"utilization",
"as",
"a",
"percentage",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L868-L926 | [
"def",
"cpu_percent",
"(",
"interval",
"=",
"0.1",
",",
"percpu",
"=",
"False",
")",
":",
"global",
"_last_cpu_times",
"global",
"_last_per_cpu_times",
"blocking",
"=",
"interval",
"is",
"not",
"None",
"and",
"interval",
">",
"0.0",
"def",
"calculate",
"(",
... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | disk_io_counters | Return system disk I/O statistics as a namedtuple including
the following attributes:
- read_count: number of reads
- write_count: number of writes
- read_bytes: number of bytes read
- write_bytes: number of bytes written
- read_time: time spent reading from disk (in milliseconds)
... | environment/lib/python2.7/site-packages/psutil/__init__.py | def disk_io_counters(perdisk=False):
"""Return system disk I/O statistics as a namedtuple including
the following attributes:
- read_count: number of reads
- write_count: number of writes
- read_bytes: number of bytes read
- write_bytes: number of bytes written
- read_time: time sp... | def disk_io_counters(perdisk=False):
"""Return system disk I/O statistics as a namedtuple including
the following attributes:
- read_count: number of reads
- write_count: number of writes
- read_bytes: number of bytes read
- write_bytes: number of bytes written
- read_time: time sp... | [
"Return",
"system",
"disk",
"I",
"/",
"O",
"statistics",
"as",
"a",
"namedtuple",
"including",
"the",
"following",
"attributes",
":"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L1023-L1047 | [
"def",
"disk_io_counters",
"(",
"perdisk",
"=",
"False",
")",
":",
"rawdict",
"=",
"_psplatform",
".",
"disk_io_counters",
"(",
")",
"if",
"not",
"rawdict",
":",
"raise",
"RuntimeError",
"(",
"\"couldn't find any physical disk\"",
")",
"if",
"perdisk",
":",
"for... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | network_io_counters | Return network I/O statistics as a namedtuple including
the following attributes:
- bytes_sent: number of bytes sent
- bytes_recv: number of bytes received
- packets_sent: number of packets sent
- packets_recv: number of packets received
- errin: total number of errors while rec... | environment/lib/python2.7/site-packages/psutil/__init__.py | def network_io_counters(pernic=False):
"""Return network I/O statistics as a namedtuple including
the following attributes:
- bytes_sent: number of bytes sent
- bytes_recv: number of bytes received
- packets_sent: number of packets sent
- packets_recv: number of packets received
- ... | def network_io_counters(pernic=False):
"""Return network I/O statistics as a namedtuple including
the following attributes:
- bytes_sent: number of bytes sent
- bytes_recv: number of bytes received
- packets_sent: number of packets sent
- packets_recv: number of packets received
- ... | [
"Return",
"network",
"I",
"/",
"O",
"statistics",
"as",
"a",
"namedtuple",
"including",
"the",
"following",
"attributes",
":"
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L1053-L1080 | [
"def",
"network_io_counters",
"(",
"pernic",
"=",
"False",
")",
":",
"rawdict",
"=",
"_psplatform",
".",
"network_io_counters",
"(",
")",
"if",
"not",
"rawdict",
":",
"raise",
"RuntimeError",
"(",
"\"couldn't find any network interface\"",
")",
"if",
"pernic",
":"... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | phymem_usage | Return the amount of total, used and free physical memory
on the system in bytes plus the percentage usage.
Deprecated by psutil.virtual_memory(). | environment/lib/python2.7/site-packages/psutil/__init__.py | def phymem_usage():
"""Return the amount of total, used and free physical memory
on the system in bytes plus the percentage usage.
Deprecated by psutil.virtual_memory().
"""
mem = virtual_memory()
return _nt_sysmeminfo(mem.total, mem.used, mem.free, mem.percent) | def phymem_usage():
"""Return the amount of total, used and free physical memory
on the system in bytes plus the percentage usage.
Deprecated by psutil.virtual_memory().
"""
mem = virtual_memory()
return _nt_sysmeminfo(mem.total, mem.used, mem.free, mem.percent) | [
"Return",
"the",
"amount",
"of",
"total",
"used",
"and",
"free",
"physical",
"memory",
"on",
"the",
"system",
"in",
"bytes",
"plus",
"the",
"percentage",
"usage",
".",
"Deprecated",
"by",
"psutil",
".",
"virtual_memory",
"()",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L1110-L1116 | [
"def",
"phymem_usage",
"(",
")",
":",
"mem",
"=",
"virtual_memory",
"(",
")",
"return",
"_nt_sysmeminfo",
"(",
"mem",
".",
"total",
",",
"mem",
".",
"used",
",",
"mem",
".",
"free",
",",
"mem",
".",
"percent",
")"
] | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Process.as_dict | Utility method returning process information as a hashable
dictionary.
If 'attrs' is specified it must be a list of strings reflecting
available Process class's attribute names (e.g. ['get_cpu_times',
'name']) else all public (read only) attributes are assumed.
'ad_value' is th... | environment/lib/python2.7/site-packages/psutil/__init__.py | def as_dict(self, attrs=[], ad_value=None):
"""Utility method returning process information as a hashable
dictionary.
If 'attrs' is specified it must be a list of strings reflecting
available Process class's attribute names (e.g. ['get_cpu_times',
'name']) else all public (read ... | def as_dict(self, attrs=[], ad_value=None):
"""Utility method returning process information as a hashable
dictionary.
If 'attrs' is specified it must be a list of strings reflecting
available Process class's attribute names (e.g. ['get_cpu_times',
'name']) else all public (read ... | [
"Utility",
"method",
"returning",
"process",
"information",
"as",
"a",
"hashable",
"dictionary",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L138-L185 | [
"def",
"as_dict",
"(",
"self",
",",
"attrs",
"=",
"[",
"]",
",",
"ad_value",
"=",
"None",
")",
":",
"excluded_names",
"=",
"set",
"(",
"[",
"'send_signal'",
",",
"'suspend'",
",",
"'resume'",
",",
"'terminate'",
",",
"'kill'",
",",
"'wait'",
",",
"'is_... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Process.name | The process name. | environment/lib/python2.7/site-packages/psutil/__init__.py | def name(self):
"""The process name."""
name = self._platform_impl.get_process_name()
if os.name == 'posix':
# On UNIX the name gets truncated to the first 15 characters.
# If it matches the first part of the cmdline we return that
# one instead because it's u... | def name(self):
"""The process name."""
name = self._platform_impl.get_process_name()
if os.name == 'posix':
# On UNIX the name gets truncated to the first 15 characters.
# If it matches the first part of the cmdline we return that
# one instead because it's u... | [
"The",
"process",
"name",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L210-L229 | [
"def",
"name",
"(",
"self",
")",
":",
"name",
"=",
"self",
".",
"_platform_impl",
".",
"get_process_name",
"(",
")",
"if",
"os",
".",
"name",
"==",
"'posix'",
":",
"# On UNIX the name gets truncated to the first 15 characters.",
"# If it matches the first part of the cm... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Process.exe | The process executable path. May also be an empty string. | environment/lib/python2.7/site-packages/psutil/__init__.py | def exe(self):
"""The process executable path. May also be an empty string."""
def guess_it(fallback):
# try to guess exe from cmdline[0] in absence of a native
# exe representation
cmdline = self.cmdline
if cmdline and hasattr(os, 'access') and hasattr(os... | def exe(self):
"""The process executable path. May also be an empty string."""
def guess_it(fallback):
# try to guess exe from cmdline[0] in absence of a native
# exe representation
cmdline = self.cmdline
if cmdline and hasattr(os, 'access') and hasattr(os... | [
"The",
"process",
"executable",
"path",
".",
"May",
"also",
"be",
"an",
"empty",
"string",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L232-L262 | [
"def",
"exe",
"(",
"self",
")",
":",
"def",
"guess_it",
"(",
"fallback",
")",
":",
"# try to guess exe from cmdline[0] in absence of a native",
"# exe representation",
"cmdline",
"=",
"self",
".",
"cmdline",
"if",
"cmdline",
"and",
"hasattr",
"(",
"os",
",",
"'acc... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Process.username | The name of the user that owns the process.
On UNIX this is calculated by using *real* process uid. | environment/lib/python2.7/site-packages/psutil/__init__.py | def username(self):
"""The name of the user that owns the process.
On UNIX this is calculated by using *real* process uid.
"""
if os.name == 'posix':
if pwd is None:
# might happen if python was installed from sources
raise ImportError("require... | def username(self):
"""The name of the user that owns the process.
On UNIX this is calculated by using *real* process uid.
"""
if os.name == 'posix':
if pwd is None:
# might happen if python was installed from sources
raise ImportError("require... | [
"The",
"name",
"of",
"the",
"user",
"that",
"owns",
"the",
"process",
".",
"On",
"UNIX",
"this",
"is",
"calculated",
"by",
"using",
"*",
"real",
"*",
"process",
"uid",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L298-L308 | [
"def",
"username",
"(",
"self",
")",
":",
"if",
"os",
".",
"name",
"==",
"'posix'",
":",
"if",
"pwd",
"is",
"None",
":",
"# might happen if python was installed from sources",
"raise",
"ImportError",
"(",
"\"requires pwd module shipped with standard python\"",
")",
"r... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
test | Process.get_children | Return the children of this process as a list of Process
objects.
If recursive is True return all the parent descendants.
Example (A == this process):
A ββ
β
ββ B (child) ββ
β ββ X (grandchild) ββ
β ... | environment/lib/python2.7/site-packages/psutil/__init__.py | def get_children(self, recursive=False):
"""Return the children of this process as a list of Process
objects.
If recursive is True return all the parent descendants.
Example (A == this process):
A ββ
β
ββ B (child) ββ
β ββ X (gra... | def get_children(self, recursive=False):
"""Return the children of this process as a list of Process
objects.
If recursive is True return all the parent descendants.
Example (A == this process):
A ββ
β
ββ B (child) ββ
β ββ X (gra... | [
"Return",
"the",
"children",
"of",
"this",
"process",
"as",
"a",
"list",
"of",
"Process",
"objects",
".",
"If",
"recursive",
"is",
"True",
"return",
"all",
"the",
"parent",
"descendants",
"."
] | cloud9ers/gurumate | python | https://github.com/cloud9ers/gurumate/blob/075dc74d1ee62a8c6b7a8bf2b271364f01629d1e/environment/lib/python2.7/site-packages/psutil/__init__.py#L402-L468 | [
"def",
"get_children",
"(",
"self",
",",
"recursive",
"=",
"False",
")",
":",
"if",
"not",
"self",
".",
"is_running",
"(",
")",
":",
"name",
"=",
"self",
".",
"_platform_impl",
".",
"_process_name",
"raise",
"NoSuchProcess",
"(",
"self",
".",
"pid",
",",... | 075dc74d1ee62a8c6b7a8bf2b271364f01629d1e |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.