From 322e412766a2c31a723d83ae6fa153b64304f4dc Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 20 Aug 2024 13:58:47 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- aiida_hyperqueue/scheduler.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/aiida_hyperqueue/scheduler.py b/aiida_hyperqueue/scheduler.py index 1f65a65..a762e4b 100644 --- a/aiida_hyperqueue/scheduler.py +++ b/aiida_hyperqueue/scheduler.py @@ -26,9 +26,9 @@ "FINISHED": JobState.DONE, } + class AiiDAHypereQueueDeprecationWarning(Warning): - """Class for HypereQueue plugin deprecations. - """ + """Class for HypereQueue plugin deprecations.""" class HyperQueueJobResource(JobResource): @@ -72,10 +72,10 @@ def validate_resources(cls, **kwargs): "Must specify `num_cpus`, or (`num_machines` and `num_mpiprocs_per_machine`)" ) else: - message = 'The `num_machines` and `num_mpiprocs_per_machine` for setting hyperqueue resources are deprecated. ' - 'Please set `num_cpus` and `memory_mb`.' + message = "The `num_machines` and `num_mpiprocs_per_machine` for setting hyperqueue resources are deprecated. " + "Please set `num_cpus` and `memory_mb`." - message = f'{message} (this will be removed in aiida-hyperqueue v1.0)' + message = f"{message} (this will be removed in aiida-hyperqueue v1.0)" warnings.warn(message, AiiDAHypereQueueDeprecationWarning, stacklevel=3) else: if not isinstance(resources.num_cpus, int):