Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pre-commit.ci] pre-commit autoupdate #837

Merged
merged 2 commits into from
Apr 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ repos:
- id: trailing-whitespace
- id: debug-statements
- repo: https://github.com/asottile/pyupgrade
rev: 'v3.15.0'
rev: 'v3.15.2'
hooks:
- id: pyupgrade
args:
Expand All @@ -21,11 +21,11 @@ repos:
hooks:
- id: isort
- repo: https://github.com/psf/black
rev: '23.12.1'
rev: '24.3.0'
hooks:
- id: black
- repo: https://github.com/PyCQA/flake8
rev: '6.1.0'
rev: '7.0.0'
hooks:
- id: flake8
- repo: https://github.com/PyCQA/pydocstyle
Expand Down
6 changes: 3 additions & 3 deletions flow/aggregates.py
Original file line number Diff line number Diff line change
Expand Up @@ -435,9 +435,9 @@ def _register_aggregates(self):
except TypeError: # aggregate is not iterable
raise ValueError("Invalid aggregator_function provided by the user.")
# Store aggregate by id to allow searching by id
self._aggregates_by_id[
get_aggregate_id(stored_aggregate)
] = stored_aggregate
self._aggregates_by_id[get_aggregate_id(stored_aggregate)] = (
stored_aggregate
)

def _generate_aggregates(self):
jobs = self._project
Expand Down
36 changes: 18 additions & 18 deletions flow/project.py
Original file line number Diff line number Diff line change
Expand Up @@ -1846,26 +1846,26 @@ def _setup_template_environment(self):
)

# Setup standard filters that can be used to format context variables.
template_environment.filters[
"format_timedelta"
] = template_filters.format_timedelta
template_environment.filters["format_timedelta"] = (
template_filters.format_timedelta
)
template_environment.filters["format_memory"] = template_filters.format_memory
template_environment.filters["identical"] = template_filters.identical
template_environment.filters["with_np_offset"] = template_filters.with_np_offset
template_environment.filters["calc_tasks"] = template_filters.calc_tasks
template_environment.filters["calc_num_nodes"] = template_filters.calc_num_nodes
template_environment.filters["calc_walltime"] = template_filters.calc_walltime
template_environment.filters["calc_memory"] = template_filters.calc_memory
template_environment.filters[
"check_utilization"
] = template_filters.check_utilization
template_environment.filters[
"homogeneous_openmp_mpi_config"
] = template_filters.homogeneous_openmp_mpi_config
template_environment.filters["check_utilization"] = (
template_filters.check_utilization
)
template_environment.filters["homogeneous_openmp_mpi_config"] = (
template_filters.homogeneous_openmp_mpi_config
)
template_environment.filters["get_config_value"] = flow_config.get_config_value
template_environment.filters[
"get_account_name"
] = template_filters.get_account_name
template_environment.filters["get_account_name"] = (
template_filters.get_account_name
)
template_environment.filters["print_warning"] = template_filters.print_warning
template_environment.filters["quote_argument"] = shlex.quote

Expand Down Expand Up @@ -3238,9 +3238,9 @@ def dotted_get(mapping, key):
status_legend = " ".join(f"[{v}]:{k}" for k, v in self.ALIASES.items())
context["jobs"] = list(statuses.values())
context["total_num_jobs_or_aggregates"] = total_num_jobs_or_aggregates
context[
"total_num_eligible_jobs_or_aggregates"
] = total_num_eligible_jobs_or_aggregates
context["total_num_eligible_jobs_or_aggregates"] = (
total_num_eligible_jobs_or_aggregates
)
context["total_num_job_labels"] = len(job_labels)
context["overview"] = overview
context["detailed"] = detailed
Expand Down Expand Up @@ -4736,9 +4736,9 @@ def _register_groups(self):
else:
entry.group_aggregator = aggregator.groupsof()
if entry.group_aggregator not in created_aggregate_stores:
created_aggregate_stores[
entry.group_aggregator
] = entry.group_aggregator._create_AggregateStore(self)
created_aggregate_stores[entry.group_aggregator] = (
entry.group_aggregator._create_AggregateStore(self)
)
# Associate the group with its aggregate store
self._group_to_aggregate_store[group] = created_aggregate_stores[
entry.group_aggregator
Expand Down
1 change: 1 addition & 0 deletions flow/scripts/template_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Implement the test-workflow flow CLI subcommand."""

import errno
import logging
import os
Expand Down
Loading