Skip to content

Commit

Permalink
[pre-commit.ci] pre-commit autoupdate (#354)
Browse files Browse the repository at this point in the history
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Kemal Zebari <[email protected]>
  • Loading branch information
pre-commit-ci[bot] and kemzeb authored Apr 16, 2024
1 parent 6d4d4a7 commit 1bebb55
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ repos:
- id: pyproject-fmt
additional_dependencies: ["tox>=4.12.1"]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.3.5"
rev: "v0.3.7"
hooks:
- id: ruff-format
- id: ruff
Expand Down
2 changes: 1 addition & 1 deletion src/pipdeptree/_models/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def render_as_root(self, *, frozen: bool) -> str:

def render_as_branch(self, *, frozen: bool) -> str:
if not frozen:
req_ver = self.version_spec if self.version_spec else "Any"
req_ver = self.version_spec or "Any"
return f"{self.project_name} [required: {req_ver}, installed: {self.installed_version}]"
return self.render_as_root(frozen=frozen)

Expand Down
4 changes: 2 additions & 2 deletions src/pipdeptree/_render/text.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def aux( # noqa: PLR0913, PLR0917
# Without this extra space, bullets will point to the space just before the project name
prefix += " " if use_bullets else ""
next_prefix = prefix
node_str = prefix + bullet + node_str
node_str = prefix + bullet + node_str # noqa: PLR6104
elif include_license:
node_str += " " + node.licenses()

Expand Down Expand Up @@ -138,7 +138,7 @@ def aux(
node_str = node.render(parent, frozen=frozen)
if parent:
prefix = " " * indent + ("- " if use_bullets else "")
node_str = prefix + node_str
node_str = prefix + node_str # noqa: PLR6104
elif include_license:
node_str += " " + node.licenses()
result = [node_str]
Expand Down

0 comments on commit 1bebb55

Please sign in to comment.