Skip to content

Commit

Permalink
Ruff formatting adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
andreas-el committed Jan 10, 2025
1 parent 0c59d5c commit c65d4b6
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 10 deletions.
4 changes: 1 addition & 3 deletions komodo/check_up_to_date_pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,7 @@ def run_check_up_to_date(
release_file,
repository_file,
python_version=(
f"{sys.version_info.major}."
f"{sys.version_info.minor}."
f"{sys.version_info.micro}"
f"{sys.version_info.major}.{sys.version_info.minor}.{sys.version_info.micro}"
),
propose_upgrade=False,
ignore=None,
Expand Down
2 changes: 1 addition & 1 deletion komodo/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def rsync_komodo_to_destination(release_name: str, destination: str) -> None:

def move_old_release_from_release_path_if_exists(release_path: Path) -> None:
if release_path.exists():
shell(f"mv {str(release_path)} " f"{str(release_path)}.delete-{uuid.uuid4()}")
shell(f"mv {str(release_path)} {str(release_path)}.delete-{uuid.uuid4()}")


def move_new_release_to_release_path(args: KomodoNamespace, release_path: Path) -> None:
Expand Down
6 changes: 3 additions & 3 deletions komodo/yaml_file_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,9 +368,9 @@ def from_yaml_string(self, value):
return self

def validate_upgrade_key(self, upgrade_key: str) -> None:
assert (
upgrade_key in self.content
), f"No section for this release ({upgrade_key}) in upgrade_proposals.yml"
assert upgrade_key in self.content, (
f"No section for this release ({upgrade_key}) in upgrade_proposals.yml"
)

@staticmethod
def validate_upgrade_proposals_file(upgrade_proposals_file_content: dict) -> None:
Expand Down
6 changes: 3 additions & 3 deletions tests/test_switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ def test_write_activator_switches(tmpdir):
== f"""
if [[ $(uname -r) == *el7* ]] ; then
# Get the full path of the sourced script
{ bash_source_script_path }
{bash_source_script_path}
if [[ $script_path == *deprecated-rhel7* ]] ; then
export KOMODO_ROOT={ prefix }
KOMODO_RELEASE_REAL={ expected_release }
export KOMODO_ROOT={prefix}
KOMODO_RELEASE_REAL={expected_release}
source $KOMODO_ROOT/$KOMODO_RELEASE_REAL-rhel7/enable
export PS1="(${{KOMODO_RELEASE_REAL}}) ${{_PRE_KOMODO_PS1}}"
Expand Down

0 comments on commit c65d4b6

Please sign in to comment.