Skip to content

Commit

Permalink
[pre-commit.ci] pre-commit autoupdate (#225)
Browse files Browse the repository at this point in the history
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.8.6 → v0.9.4](astral-sh/ruff-pre-commit@v0.8.6...v0.9.4)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
pre-commit-ci[bot] authored Feb 4, 2025
1 parent 175fc2c commit 37adb8a
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ repos:
language: python
files: \.py$
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.8.6"
rev: "v0.9.4"
hooks:
- id: ruff-format
- repo: https://github.com/pre-commit/mirrors-prettier
Expand Down
3 changes: 1 addition & 2 deletions examples/drag_and_drop/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ def on_cells_added_handler(cell_ids):

def on_terminal_changed_handler(cell_id, terminal_type, new_terminal_id, old_terminal_id):
print(
f"{terminal_type} of {cell_id} changed from"
f" {old_terminal_id} to {new_terminal_id}"
f"{terminal_type} of {cell_id} changed from {old_terminal_id} to {new_terminal_id}"
)

def on_cells_removed_handler(cell_ids):
Expand Down
2 changes: 1 addition & 1 deletion scripts/svg_to_stencil.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ def _add_drawing_commands(self, value):
import argparse

arg_parser = argparse.ArgumentParser(
description="Converts a SVG file to a stencil file " "compatible with mxGraph."
description="Converts a SVG file to a stencil file compatible with mxGraph."
)
arg_parser.add_argument(
"svg",
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
name="qmxgraph",
use_scm_version=True,
setup_requires=["setuptools_scm"],
description="A Qt graph drawing widget using JavaScript's mxGraph " "library.",
description="A Qt graph drawing widget using JavaScript's mxGraph library.",
long_description=readme + "\n\n" + history,
author="Rafael Bertoldi",
author_email="tochaman@gmail.com",
Expand Down
2 changes: 1 addition & 1 deletion src/qmxgraph/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ def host(port, options=None, styles=None, stencils=tuple()):
for stencil in stencils:
candidate = os.path.dirname(stencil)
assert candidate != stencils_path, (
"Due to simplification, expects " "all stencils in same folder"
"Due to simplification, expects all stencils in same folder"
)
stencils_path = candidate
stencils_.append("stencils/{}".format(os.path.basename(stencil)))
Expand Down
4 changes: 2 additions & 2 deletions tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def create_web_resource(resource_name, src_dir):
@invoke.task(
help={
"python-version": (
"Can be used to define the python version used when creating the" " work environment"
"Can be used to define the python version used when creating the work environment"
),
}
)
Expand Down Expand Up @@ -380,7 +380,7 @@ def fix_alias(a):
]
if not files:
raise RuntimeError(
"Unable to collect anything for " ".qrc file in folder {}".format(source_dir)
"Unable to collect anything for .qrc file in folder {}".format(source_dir)
)

qrc_filename = os.path.join(target_dir, "{basename}{ext}".format(basename=basename, ext=".qrc"))
Expand Down
4 changes: 2 additions & 2 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def get(self):
os.remove(lock_file)

if attempts == 0:
raise IOError("Unable to obtain unique port after " "{} attempts".format(attempts))
raise IOError("Unable to obtain unique port after {} attempts".format(attempts))

return port_

Expand Down Expand Up @@ -962,7 +962,7 @@ def _wait_graph_page_ready(host, selenium):
)
except timeout_exceptions as e:
raise TimeoutException(
"Graph page wasn't ready in address {} after a timeout of {}" " seconds".format(
"Graph page wasn't ready in address {} after a timeout of {} seconds".format(
host.address, timeout
)
) from e
Expand Down

0 comments on commit 37adb8a

Please sign in to comment.