Showing 4,804 of 7,770 total issues
Avoid too many return
statements within this function. Open
return;
Avoid too many return
statements within this function. Open
return "sourcecolname";
Avoid too many return
statements within this function. Open
return;
Avoid too many return
statements within this function. Open
return "cosmos.appendpoints";
Avoid too many return
statements within this function. Open
return "singleitemconfigobject";
Avoid too many return
statements within this function. Open
return true;
Avoid too many return
statements within this function. Open
return false;
Avoid too many return
statements within this function. Open
return "appendpointconigobject";
Avoid too many return
statements within this function. Open
return;
Avoid too many return
statements within this function. Open
return "cosmos.appendpoints";
Avoid too many return
statements within this function. Open
return getAppSettingsByAppImpl(application, settingsName);
Avoid too many return
statements within this function. Open
return;
Avoid too many return
statements within this function. Open
return "interceptorconigobject";
Function parseFile
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Parser.prototype.parseFile = function () {
var sections = [];
while (true) {
var section = this.parseSection();
if (section === null) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function add_operation_processor
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def add_operation_processor(self, processor, object_name, access_types):
assert isinstance(access_types, collections.Iterable)
assert len(object_name) > 0
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function find
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def find(self, user, object_name, query, columns, limit=5000):
logging.debug("ObjectService::find::{0}".format(object_name))
#assert inspect.ismethod(callback)
allowed_access_type = self.check_access(user, object_name, columns, AccessType.READ, True)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function read_gridfs_owned_file
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def read_gridfs_owned_file(user, db, collection_name, file_id, properties):
owner_id = user.get("_id")
if len(owner_id) < 1:
raise tornado.web.HTTPError(401, "Unauthorized")
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function delete
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def delete(self, object_path):
params = object_path.split('/')
params = list(filter(len, params))
object_name = params[0]
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function test_observer
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def test_observer(user, object_service, object_name, data, access_type, columns = None, *args, **kwargs):
assert object_name == "test"
assert access_type == AccessType.READ or access_type == AccessType.INSERT or access_type == AccessType.UPDATE or access_type == AccessType.DELETE
logging.info("Test object observer is called with [{}, {}, {}, {}, {}, {}].".format(user, object_service, object_name, data, access_type, columns))
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function package_sample
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def package_sample(path, sample_def_path, exclude=["local_settings.py"]):
print ("----------------------------------------------------------------------")
print ("Packaging application from [{0}] to [{1}]".format(path, sample_def_path))
print ("----------------------------------------------------------------------")
file_list = get_files(path, exclude)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"