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 Mar 12, 2024
1 parent 6b1e480 commit 7babeba
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions noxfile.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Automation using nox."""

import glob
import os

Expand Down
1 change: 1 addition & 0 deletions src/dvc_data/hashfile/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""DVC data."""

import logging
from collections.abc import Iterator
from typing import TYPE_CHECKING, Union, cast
Expand Down
6 changes: 2 additions & 4 deletions src/dvc_data/hashfile/_ignore.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@


class Ignore(Protocol):
def find(self, fs: "FileSystem", path: "AnyFSPath") -> Iterator["AnyFSPath"]:
...
def find(self, fs: "FileSystem", path: "AnyFSPath") -> Iterator["AnyFSPath"]: ...

def walk(self, fs: "FileSystem", path: "AnyFSPath", **kwargs: Any):
...
def walk(self, fs: "FileSystem", path: "AnyFSPath", **kwargs: Any): ...
1 change: 1 addition & 0 deletions src/dvc_data/hashfile/state.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Manages state database used for checksum caching."""

import json
import logging
import os
Expand Down
2 changes: 1 addition & 1 deletion src/dvc_data/hashfile/tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ def load(cls, odb, hash_info, hash_name: Optional[str] = None) -> "Tree":

return tree

def filter(self, prefix: tuple[str]) -> Optional["Tree"]: # noqa: A003
def filter(self, prefix: tuple[str]) -> Optional["Tree"]:
"""Return a filtered copy of this tree that only contains entries
inside prefix.
Expand Down
4 changes: 2 additions & 2 deletions src/dvc_data/index/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def _trie(self):
return SQLiteTrie()

@classmethod
def open(cls, path): # noqa: A003
def open(cls, path):
ret = cls()
ret._trie = SQLiteTrie.open(path)
return ret
Expand Down Expand Up @@ -642,7 +642,7 @@ def _onerror(_, exc):
self.update(*args, **kwargs)

@classmethod
def open(cls, path): # noqa: A003
def open(cls, path):
ret = cls()
ret._trie = DataIndexTrie.open(path)
return ret
Expand Down

0 comments on commit 7babeba

Please sign in to comment.