Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed May 24, 2024
1 parent 5a2aea5 commit 223f86c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/aiida/cmdline/commands/cmd_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ def profile_delete(force, delete_data, profiles):
get_config().delete_profile(profile.name, delete_storage=delete_data)
echo.echo_success(f'Profile `{profile.name}` was deleted.')


@verdi_profile.command('flush')
@arguments.PROFILE(required=True)
@options.FORCE(help='Skip any prompts for confirmation.')
Expand All @@ -221,7 +222,6 @@ def profile_flush(force, profile):
echo.echo_report(f'Deleting of `{profile.name}` cancelled.')

else:

# Delete nodes
qb = QueryBuilder()
qb.append(Node)
Expand Down
4 changes: 1 addition & 3 deletions src/aiida/repository/backend/disk_object_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,7 @@ def _put_object_from_filelike(self, handle: t.BinaryIO) -> str:
return container.add_streamed_object(handle)

def _put_objects_from_filelike_packed(self, handle_list) -> str:
"""Store the byte contents of a list of files in the repository.
"""
"""Store the byte contents of a list of files in the repository."""
with self._container as container:
return container.add_streamed_objects_to_pack(
stream_list=handle_list,
Expand Down
3 changes: 1 addition & 2 deletions src/aiida/tools/archive/imports.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def import_archive(
group: Optional[orm.Group] = None,
test_run: bool = False,
backend: Optional[StorageBackend] = None,
packed: Optional[bool] = False
packed: Optional[bool] = False,
) -> Optional[int]:
"""Import an archive into the AiiDA backend.
Expand Down Expand Up @@ -1209,7 +1209,6 @@ def _add_files_to_repo_packed(backend_from: StorageBackend, backend_to: StorageB
# print('repository_to', repository_to)

with get_progress_reporter()(desc='Adding archive files to repository', total=len(new_keys)) as progress:

from io import BytesIO

from_hashes = list(repository_from.list_objects())
Expand Down

0 comments on commit 223f86c

Please sign in to comment.