-
Notifications
You must be signed in to change notification settings - Fork 334
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Better organization of types so that they are importable
- Loading branch information
Showing
4 changed files
with
43 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
from __future__ import annotations | ||
|
||
from typing import TYPE_CHECKING, TypeAlias, Union | ||
|
||
from .rerun_bindings import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
from __future__ import annotations | ||
|
||
from typing import TYPE_CHECKING, TypeAlias, Union | ||
|
||
if TYPE_CHECKING: | ||
from rerun._baseclasses import ComponentMixin | ||
|
||
from .rerun_bindings import ( | ||
ComponentColumnDescriptor as ComponentColumnDescriptor, | ||
ComponentColumnSelector as ComponentColumnSelector, | ||
ControlColumnDescriptor as ControlColumnDescriptor, | ||
ControlColumnSelector as ControlColumnSelector, | ||
TimeColumnDescriptor as TimeColumnDescriptor, | ||
TimeColumnSelector as TimeColumnSelector, | ||
) | ||
|
||
|
||
ComponentLike: TypeAlias = Union[str, type["ComponentMixin"]] | ||
|
||
AnyColumn: TypeAlias = Union[ | ||
"ControlColumnDescriptor", | ||
"TimeColumnDescriptor", | ||
"ComponentColumnDescriptor", | ||
"ControlColumnSelector", | ||
"TimeColumnSelector", | ||
"ComponentColumnSelector", | ||
] | ||
|
||
AnyComponentColumn: TypeAlias = Union[ | ||
"ComponentColumnDescriptor", | ||
"ComponentColumnSelector", | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters