Showing 536 of 578 total issues
Function _load_data_from_tree
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _load_data_from_tree(index, prefix, ws, key, tree, hash_name):
Function worktree_view_by_remotes
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def worktree_view_by_remotes(
index: "Index",
targets: Optional["TargetType"] = None,
push: bool = False,
**kwargs: Any,
- 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 collect_rev
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def collect_rev(
Function _download_studio
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def _download_studio(
repo_url: str,
name: str,
version: Optional[str] = None,
stage: Optional[str] = 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 add
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def add(
Function targets_view
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def targets_view(
Function __init__
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def __init__( # noqa: PLR0915, PLR0913
self,
root_dir: Optional[str] = None,
fs: Optional["FileSystem"] = None,
rev: Optional[str] = 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 _collect_specific_target
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def _collect_specific_target(
loader: "StageLoad",
target: str,
with_deps: bool,
recursive: bool,
- 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 post
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def post(
Function load_from_vars
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def load_from_vars(
Function resolve_str
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def resolve_str(
Function test_import
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def test_import(bench_dvc, tmp_dir, scm, dvc, make_dataset, remote):
Function compose_and_dump
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def compose_and_dump(
Function collect
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def collect(
Function make_dvc_bin
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def make_dvc_bin(
Function add_remote
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_remote(self, *, url=None, config=None, name="upstream", default=True):
Function init
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def init(self, *, scm=False, dvc=False, subdir=False):
from dvc.repo import Repo
from dvc.scm import Git
assert not scm or not hasattr(self, "scm")
- 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_url
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def get_url(
Function debugtools
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def debugtools(args: Optional["Namespace"] = None, **kwargs):
kw = vars(args) if args else {}
kw.update(kwargs)
with ExitStack() as stack:
- 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 _dump
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def _dump(data, stream):
old_params = data[_PARAMS_KEY]
new_params = {
key: value
for key, value in data.items()
- 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"