Showing 507 of 611 total issues
Function text_validator
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def text_validator(*, name, max_length, min_length=0, invalid_ctrl_chars="\0", invalid_chars="", no_blanks=False):
Function setup_logging
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def setup_logging(
Function sizeof_fmt
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def sizeof_fmt(num, suffix="B", units=None, power=None, sep="", precision=2, sign=False):
Function process_dev
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def process_dev(self, *, path, parent_fd, name, st, dev_type, strip_prefix):
Function _read
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def _read(self, fd, header, segment, offset, acceptable_tags, read_data=True):
Function get_item_uid_gid
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def get_item_uid_gid(item, *, numeric, uid_forced=None, gid_forced=None, uid_default=0, gid_default=0):
Function OsOpen
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def OsOpen(*, flags, path=None, parent_fd=None, name=None, noatime=False, op="open"):
Function process_pipe
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def process_pipe(self, *, path, cache, fd, mode, user=None, group=None):
Function cache_if_remote
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def cache_if_remote(repository, *, decrypted_cache=False, pack=None, unpack=None, transform=None, force_cache=False):
Function read
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def read(self, segment, offset, id, *, read_data=True, expected_size=None):
Function with_repository
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def with_repository(
Function compat_check
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def compat_check(*, create, manifest, key, cache, compatibility, decorator_name):
Function find_chunks
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def find_chunks(repository, repo_objs, cache, stats, ctype, clevel, olevel):
Function do_transfer
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def do_transfer(self, args, *, repository, manifest, cache, other_repository=None, other_manifest=None):
Function add_chunk
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def add_chunk(self, id, meta, data, stats=None, wait=True, ro_type=None):
Function exec_cmd
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def exec_cmd(*args, archiver=None, fork=False, exe=None, input=b"", binary_output=False, **kw):
Function acquire_release_loop
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def acquire_release_loop(
Function _process_leaf
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def _process_leaf(self, name, item, parent, prefix, is_dir, item_inode, hlm):
Function argon2
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def argon2(
Function cache_if_remote
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
def cache_if_remote(repository, *, decrypted_cache=False, pack=None, unpack=None, transform=None, force_cache=False):
"""
Return a Repository(No)Cache for *repository*.
If *decrypted_cache* is a repo_objs object, then get and get_many will return a tuple
- 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"