Skip to content

Commit

Permalink
fix: errors in pre-commit outside of kazu folder
Browse files Browse the repository at this point in the history
  • Loading branch information
Szymon Palucha authored and paluchasz committed Sep 25, 2024
1 parent b8018fc commit 8d22065
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
import inspect
import os
import sys
from typing import Any
from typing import Any, Union

import kazu

Expand Down Expand Up @@ -144,7 +144,7 @@

# this function is modified from the corresponding one in pandas, which in turn is modified from numpy
# both licenses are included in the docs folder, as PANDAS_LICENSE.txt and NUMPY_LICENSE.txt
def linkcode_resolve(domain, info):
def linkcode_resolve(domain: str, info: dict[str, Any]) -> Union[str, None]:
"""Determine the URL corresponding to Python object."""
if domain != "py":
return None
Expand Down
2 changes: 1 addition & 1 deletion kazu/utils/spacy_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ class SpacyPipelines(metaclass=Singleton):
a long time).
"""

def __init__(self):
def __init__(self) -> None:
self.reload_at = int(os.getenv("KAZU_SPACY_RELOAD_INTERVAL", 1000))
"""The interval (number of calls) at which spaCy models are reloaded.
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ module = [
ignore_missing_imports = true

[[tool.mypy.overrides]]
module = ["kazu.tests.*"]
module = ["kazu.tests.*", "conftest"]
# in particular, return types for pytest test
# functions are always None, we don't want to have to annotate that
disallow_incomplete_defs = false
Expand Down

0 comments on commit 8d22065

Please sign in to comment.