Showing 1,384 of 1,384 total issues
Avoid deeply nested control flow statements. Open
Open
if index in _metadata and path in _metadata[index]:
_metadata[index][path].remove(target)
# if there's no keys left in the entry, trim it
if len(_metadata[index][path]) == 0:
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if isinstance(value, messages.Message):
_packed[field.name] = _walk_struct(value)
else:
_packed[field.name] = value
return _packed
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
with open(source_name, 'rb') as staticread:
staticwrite.write(staticread.read())
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if subquery.sub_operator is query.OR:
_or_filters.append(subquery)
# double-filters
if len(_filters[prop]) == 2:
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
for target in entity.target:
if isinstance(target, Key) and not (
isinstance(target, VertexKey)): # pragma: no cover
# @TODO(sgammon): unambiguous graph keys
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
for target in entity['peers']:
if origin == target: continue
_graph['neighbors']['undirected'][origin].add(target)
_graph['edges']['undirected'][origin].add(entity.key)
_graph['edges']['undirected'][target].add(entity.key)
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if _f.tails is None: # undirected query
_target_edge_index = (
_graph[_graph_base]['undirected'].get(_filter_val, set()))
else: # directed queries
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if isinstance(_val, model.Key): # pragma: no cover
raise RuntimeError('Cannot reference embedded submodel'
' by key "%s".' % repr(_val))
_bundle.append(_val.to_dict() if convert_models else _val)
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if low_bound and not high_bound:
evaluate = lambda bundle: (low_bound < bundle[0])
elif low_bound and high_bound:
evaluate = lambda bundle: (low_bound < bundle[0] < high_bound)
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if _fblock.operator in frozenset((query.EQUALS,
query.CONTAINS,
query.KEY_KIND,
query.KEY_ANCESTOR)):
- Create a ticketCreate a ticket
Function compile_dir
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def compile_dir(self, source, destination,
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if _index_key in _metadata[cls._index_prefix]:
_unsorted_indexes.append((
False, (_f, _metadata[cls._index_prefix][_index_key])))
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if config_item in config.config['TemplateAPI']['haml']:
setattr(*(
environment,
target_attr,
config.config['TemplateAPI']['haml'][config_item]))
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if isinstance(bundle[-1], dict):
positional, _config = bundle[0:-1], bundle[-1]
_arguments.append((_add_argument, positional, _config))
# is it a subtool?
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if (isinstance(_path, dict) and 'source' in _path or (
isinstance(_path, basestring))):
choices.append(FileLoader(_path['source'] if (
isinstance(_path, dict)) else _path))
- Create a ticketCreate a ticket
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(self, environ=None,
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if (query.LESS_THAN in _operators) or (
query.LESS_THAN_EQUAL_TO in _operators):
# range value query over sorted index
greater, lesser = max(_values), min(_values)
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if isinstance(_val, model.Model) and not (
_val.key): # pragma: no cover
raise RuntimeError('Cannot reference non-embedded submodel'
' "%s" with empty key.' % repr(_val))
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
for o, source in enumerate(entity.peers):
if isinstance(source, Key) and not (
isinstance(source, VertexKey)): # pragma: no cover
# @TODO(sgammon): unambiguous graph keys
- Create a ticketCreate a ticket
Avoid deeply nested control flow statements. Open
Open
if svalue in _metadata[index]:
sorted_entry = _metadata[index][svalue].get(target)
if sorted_entry:
_metadata[index][value].remove(sorted_entry)
- Create a ticketCreate a ticket