Function _bind
has a Cognitive Complexity of 34 (exceeds 5 allowed). Consider refactoring. Open
def _bind(self):
from ._view.request_view import RequestView
from ._view.abstract_sql_view import AbstractSQLView
def add_to_url_mapping(_meta, _fullpath):
- 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 query_path
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def query_path(self, method, path) -> Tuple[Union[RouteInterfaceInfo, RouteStaticsInfo, None], Optional[Dict]]:
"""
Get route info for specified method and path.
:param method:
:param path:
- 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 interface
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def interface(self, method, url=None, *, summary=None, va_query=None, va_post=None, va_headers=None,
Function get
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def get(self, url=None, *, summary=None, va_query=None, va_post=None, va_headers=None,
Function post
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def post(self, url=None, *, summary=None, va_query=None, va_post=None, va_headers=None,
Function interface
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def interface(self, method, url=None, *, summary=None, va_query=None, va_post=None, va_headers=None,
va_resp=ResponseDataModel, deprecated=False):
"""
Register interface
:param method:
- 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 query_ws_path
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
def query_ws_path(self, path) -> Tuple[Union[RouteWebsocketInfo, None], Optional[Dict]]:
ret = self._url_ws_mappings.get(path)
if ret:
return ret, {}
- 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 view
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def view(self, url, tag_name=None):
"""
Register View Class
:param url:
:param tag_name:
- 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 websocket
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def websocket(self, url=None):
"""
Register Websocket
:param url:
:return:
- 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"