Skip to content

Update typing to Python 3.12 syntax - #137

Open
loichuder wants to merge 1 commit into
locking-argfrom
py312-typing
Open

loichuder wants to merge 1 commit into
locking-argfrom
py312-typing

Conversation

@loichuder

Copy link
Copy Markdown
Member

No description provided.

Comment thread src/h5grove/content.py
return self._target_path


T = TypeVar("T", h5py.Dataset, h5py.Datatype, h5py.Group)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

def get_handlers(base_dir: str | None, allow_origin: str | None = None):
def get_handlers(
base_dir: str | None, allow_origin: str | None = None
) -> list[tuple[str, type[BaseHandler], dict]]:

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The solution was to simply to use type[BaseHandler] instead of BaseHandler...

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants