Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[python] Re-enable isort via ruff; fix MANIFEST.in #135

Merged
merged 2 commits into from
Feb 18, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
global-exclude *
include pyproject.toml
include MANIFEST.in
recursive-include python-spec/README.md
recursive python-spec/README.md
Copy link
Contributor Author

Choose a reason for hiding this comment

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

i’m a dingus

Copy link
Member

Choose a reason for hiding this comment

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

torpedodingus :D

recursive-include python-spec/src *.py py.typed
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ write_to = "python-spec/src/somacore/_version.py"
# by requiring `python-` at the start of the tag (e.g. `python-v1.2.3`).
tag_regex = '^python-(?P<version>[vV]?\d+(?:\.\d+){0,2}[^\+]*)(?:\+.*)?$'

[tool.ruff]
extend-select = ["I"]

[tool.ruff.isort]
force-single-line = true
known-first-party = ["somacore"]
Expand Down
4 changes: 2 additions & 2 deletions python-spec/src/somacore/ephemeral/collections.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
from typing import Any, Dict, Iterator, NoReturn, Optional, TypeVar
from typing_extensions import Self

from .. import options
from typing_extensions import Self

from .. import base
from .. import collection
from .. import data
from .. import experiment
from .. import measurement
from .. import options

_Elem = TypeVar("_Elem", bound=base.SOMAObject)

Expand Down
4 changes: 2 additions & 2 deletions python-spec/src/somacore/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
import enum
from typing import Any, Mapping, Optional, Sequence, Union

from . import types

import attrs
import numpy as np
import numpy.typing as npt
import pyarrow as pa
from typing_extensions import Final, Literal

from . import types

SOMA_JOINID: Final = "soma_joinid"
"""Global constant for the SOMA join ID."""

Expand Down
3 changes: 2 additions & 1 deletion python-spec/src/somacore/types.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
"""Type and interface declarations that are not specific to options."""

import sys
from typing import Any, NoReturn, Optional, Type, TypeVar, Sequence, TYPE_CHECKING
from typing import TYPE_CHECKING, Any, NoReturn, Optional, Sequence, Type, TypeVar

from typing_extensions import Protocol, TypeGuard


Expand Down
2 changes: 1 addition & 1 deletion python-spec/testing/test_types.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import itertools
from typing import Any, Iterable
import unittest
from typing import Any, Iterable

from somacore import types

Expand Down