Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
56 changes: 56 additions & 0 deletions .basedpyright/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -27537,6 +27537,14 @@
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
"startColumn": 19,
"endColumn": 51,
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
Expand All @@ -27545,6 +27553,14 @@
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 24,
"endColumn": 51,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
Expand All @@ -27553,6 +27569,14 @@
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
"startColumn": 19,
"endColumn": 51,
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
Expand All @@ -27561,6 +27585,14 @@
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 24,
"endColumn": 51,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
Expand All @@ -27569,6 +27601,22 @@
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
"startColumn": 19,
"endColumn": 47,
"lineCount": 1
}
},
{
"code": "reportAttributeAccessIssue",
"range": {
"startColumn": 24,
"endColumn": 47,
"lineCount": 1
}
},
{
"code": "reportUnknownMemberType",
"range": {
Expand Down Expand Up @@ -27617,6 +27665,14 @@
"lineCount": 1
}
},
{
"code": "reportArgumentType",
"range": {
"startColumn": 21,
"endColumn": 25,
"lineCount": 1
}
},
{
"code": "reportCallIssue",
"range": {
Expand Down
7 changes: 4 additions & 3 deletions boxtree/traversal.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@

# NOTE: Tree cannot go into the TYPE_CHECKING block because it is needed
# by `dataclass_array_container` (which evals the types)
from boxtree.tree import Tree # noqa: TC001
from boxtree.tree import Tree, TreeOfBoxes # noqa: TC001


if TYPE_CHECKING:
Expand Down Expand Up @@ -1760,8 +1760,9 @@ def get_kernel_info(self, *,
source_boxes_has_mask: bool,
source_parent_boxes_has_mask: bool,
debug: bool = False) -> _KernelInfo:
# FIXME: not clear this is the right default?
if particle_id_dtype is None:
# This only happens for TreeOfBoxes, where there is no particle info
assert not (sources_have_extent or targets_have_extent)
particle_id_dtype = np.dtype(np.int32)

# {{{ process from_sep_smaller_crit
Expand Down Expand Up @@ -1961,7 +1962,7 @@ def get_kernel_info(self, *,

def __call__(self,
actx: ArrayContext,
tree: Tree,
tree: Tree | TreeOfBoxes,
wait_for: cl.WaitList = None,
debug: bool = False,
_from_sep_smaller_min_nsources_cumul: int | None = None,
Expand Down
Loading