diff --git a/signac/__init__.py b/signac/__init__.py index 612eaf4d1..9fd8cf5df 100644 --- a/signac/__init__.py +++ b/signac/__init__.py @@ -9,12 +9,14 @@ collectively accessible. """ -from synced_collections.backends.collection_json import BufferedJSONAttrDict as JSONDict +from synced_collections.backends.collection_json import \ + BufferedJSONAttrDict as JSONDict from . import errors, sync from .diff import diff_jobs from .h5store import H5Store, H5StoreManager -from .project import Project, TemporaryProject, get_job, get_project, init_project +from .project import (Project, TemporaryProject, get_job, get_project, + init_project) from .version import __version__ # Alias some properties related to buffering into the signac namespace. diff --git a/signac/__main__.py b/signac/__main__.py index 0e51200b8..7aa99824d 100644 --- a/signac/__main__.py +++ b/signac/__main__.py @@ -30,24 +30,13 @@ READLINE = True from . import get_project, init_project -from ._config import ( - PROJECT_CONFIG_FN, - USER_CONFIG_FN, - _Config, - _load_config, - _locate_config_dir, - _read_config_file, -) +from ._config import (PROJECT_CONFIG_FN, USER_CONFIG_FN, _Config, _load_config, + _locate_config_dir, _read_config_file) from ._utility import _print_err, _query_yes_no, _safe_relpath from ._vendor.configobj import Section, flatten_errors from .diff import diff_jobs -from .errors import ( - DestinationExistsError, - DocumentSyncConflict, - FileSyncConflict, - SchemaSyncConflict, - SyncConflict, -) +from .errors import (DestinationExistsError, DocumentSyncConflict, + FileSyncConflict, SchemaSyncConflict, SyncConflict) from .filterparse import parse_filter_arg from .import_export import _SchemaPathEvaluationError, export_jobs from .sync import DocSync, FileSync diff --git a/signac/diff.py b/signac/diff.py index 626fd78b7..5aa491660 100644 --- a/signac/diff.py +++ b/signac/diff.py @@ -3,7 +3,8 @@ # This software is licensed under the BSD 3-Clause License. """Compute diffs of state points.""" -from ._utility import _dotted_dict_to_nested_dicts, _nested_dicts_to_dotted_keys +from ._utility import (_dotted_dict_to_nested_dicts, + _nested_dicts_to_dotted_keys) def diff_jobs(*jobs): diff --git a/signac/h5store.py b/signac/h5store.py index 458602ea3..1212413b0 100644 --- a/signac/h5store.py +++ b/signac/h5store.py @@ -12,7 +12,8 @@ from ._dict_manager import _DictManager from ._utility import _safe_relpath -from .errors import H5StoreAlreadyOpenError, H5StoreClosedError, InvalidKeyError +from .errors import (H5StoreAlreadyOpenError, H5StoreClosedError, + InvalidKeyError) __all__ = [ "H5Store", diff --git a/signac/job.py b/signac/job.py index c26e396b8..584cb4c7a 100644 --- a/signac/job.py +++ b/signac/job.py @@ -14,10 +14,7 @@ from typing import FrozenSet from synced_collections.backends.collection_json import ( - BufferedJSONAttrDict, - JSONAttrDict, - json_attr_dict_validator, -) + BufferedJSONAttrDict, JSONAttrDict, json_attr_dict_validator) from synced_collections.errors import KeyTypeError from synced_collections.utils import SyncedCollectionJSONEncoder diff --git a/signac/linked_view.py b/signac/linked_view.py index ad941cef7..9f0365301 100644 --- a/signac/linked_view.py +++ b/signac/linked_view.py @@ -46,7 +46,8 @@ def create_linked_view(project, prefix=None, job_ids=None, path=None): When state points contain ``os.sep``. """ - from .import_export import _check_directory_structure_validity, _make_path_function + from .import_export import (_check_directory_structure_validity, + _make_path_function) if prefix is None: prefix = "view" diff --git a/signac/project.py b/signac/project.py index d0cb27938..4da6b68e1 100644 --- a/signac/project.py +++ b/signac/project.py @@ -23,22 +23,13 @@ from synced_collections.backends.collection_json import BufferedJSONAttrDict -from ._config import ( - _Config, - _get_project_config_fn, - _load_config, - _locate_config_dir, - _raise_if_older_schema, - _read_config_file, -) +from ._config import (_Config, _get_project_config_fn, _load_config, + _locate_config_dir, _raise_if_older_schema, + _read_config_file) from ._search_indexer import _SearchIndexer from ._utility import _mkdir_p, _nested_dicts_to_dotted_keys -from .errors import ( - DestinationExistsError, - IncompatibleSchemaVersion, - JobsCorruptedError, - WorkspaceError, -) +from .errors import (DestinationExistsError, IncompatibleSchemaVersion, + JobsCorruptedError, WorkspaceError) from .filterparse import _add_prefix, _root_keys, parse_filter from .h5store import H5StoreManager from .job import Job, calc_id diff --git a/signac/sync.py b/signac/sync.py index 5616cdd8a..aa1332fe1 100644 --- a/signac/sync.py +++ b/signac/sync.py @@ -86,12 +86,8 @@ from multiprocessing.pool import ThreadPool from ._utility import _query_yes_no, _safe_relpath -from .errors import ( - DestinationExistsError, - DocumentSyncConflict, - FileSyncConflict, - SchemaSyncConflict, -) +from .errors import (DestinationExistsError, DocumentSyncConflict, + FileSyncConflict, SchemaSyncConflict) __all__ = [ "FileSync", diff --git a/tests/test_job.py b/tests/test_job.py index 7cf8d6aa6..620b3b71b 100644 --- a/tests/test_job.py +++ b/tests/test_job.py @@ -14,12 +14,8 @@ import signac from signac._config import _load_config -from signac.errors import ( - DestinationExistsError, - InvalidKeyError, - JobsCorruptedError, - KeyTypeError, -) +from signac.errors import (DestinationExistsError, InvalidKeyError, + JobsCorruptedError, KeyTypeError) from signac.job import Job try: diff --git a/tests/test_project.py b/tests/test_project.py index da546ede0..84cf75f3b 100644 --- a/tests/test_project.py +++ b/tests/test_project.py @@ -23,19 +23,11 @@ from test_job import TestJobBase import signac -from signac._config import ( - PROJECT_CONFIG_FN, - _get_project_config_fn, - _load_config, - _read_config_file, -) -from signac.errors import ( - DestinationExistsError, - IncompatibleSchemaVersion, - JobsCorruptedError, - StatepointParsingError, - WorkspaceError, -) +from signac._config import (PROJECT_CONFIG_FN, _get_project_config_fn, + _load_config, _read_config_file) +from signac.errors import (DestinationExistsError, IncompatibleSchemaVersion, + JobsCorruptedError, StatepointParsingError, + WorkspaceError) from signac.job import calc_id from signac.linked_view import _find_all_links from signac.project import JobsCursor, Project # noqa: F401 diff --git a/tests/test_shell.py b/tests/test_shell.py index 172fb1e45..044fa8f33 100644 --- a/tests/test_shell.py +++ b/tests/test_shell.py @@ -9,10 +9,12 @@ from tempfile import TemporaryDirectory import pytest -from test_project import WINDOWS, _initialize_v1_project, skip_windows_without_symlinks +from test_project import (WINDOWS, _initialize_v1_project, + skip_windows_without_symlinks) import signac -from signac._config import USER_CONFIG_FN, _Config, _load_config, _read_config_file +from signac._config import (USER_CONFIG_FN, _Config, _load_config, + _read_config_file) class DummyFile: diff --git a/tests/test_sync.py b/tests/test_sync.py index 758fc7099..eac4eea7f 100644 --- a/tests/test_sync.py +++ b/tests/test_sync.py @@ -12,7 +12,8 @@ import signac from signac import JSONDict, sync from signac._utility import _mkdir_p -from signac.errors import DocumentSyncConflict, FileSyncConflict, SchemaSyncConflict +from signac.errors import (DocumentSyncConflict, FileSyncConflict, + SchemaSyncConflict) from signac.sync import _DocProxy, _FileModifyProxy