Showing 22 of 28 total issues
Function create_tar_file
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
def create_tar_file(
path: PathIn,
content_paths: list[PathIn],
*,
overwrite: bool = 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 download_file
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def download_file(
url: str,
*,
dirpath: PathIn | None = None,
filename: str | None = None,
- 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_file_lines_in_range
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def _read_file_lines_in_range(
path: PathIn,
*,
line_start: int = 0,
line_end: int = -1,
- 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 get_unique_name
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def get_unique_name(
path: PathIn,
*,
prefix: str = "",
suffix: str = "",
- 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 transform_filepath
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def transform_filepath(
path: PathIn,
*,
dirpath: str | Callable[[str], str] | None = None,
basename: str | Callable[[str], str] | None = None,
- 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_file_lines
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def read_file_lines(
Function extract_tar_file
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def extract_tar_file(
Function get_unique_name
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def get_unique_name(
Function write_file
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def write_file(
Function copy_dir
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def copy_dir(
Function transform_filepath
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def transform_filepath(
Function move_dir
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def move_dir(
Function _write_file_atomic
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def _write_file_atomic(
Function create_tar_file
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_tar_file(
Function write_file_json
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def write_file_json(
Function extract_zip_file
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def extract_zip_file(
Function _write_file_non_atomic
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def _write_file_non_atomic(
Function copy_file
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def copy_file(
Function move_file
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def move_file(
Function create_zip_file
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def create_zip_file(