Skip to content

Commit

Permalink
fix(python): Remove .pyi annotations (#12314)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #12314

Removing .pyi annotations by properly setting interface includes and
dependencies.

Reviewed By: kevinwilfong

Differential Revision: D69538934

fbshipit-source-id: 9f9608741e5e16e49e9138021749752f5f292442
  • Loading branch information
pedroerp authored and facebook-github-bot committed Feb 12, 2025
1 parent e14fc1d commit d8cac2f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 11 deletions.
2 changes: 0 additions & 2 deletions velox/py/arrow/arrow.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,8 @@

from typing import List

# pyre-fixme[21]: Could not find `velox.py.vector`.
from velox.py.vector import Vector
from pyarrow import Array

# pyre-fixme[11]: Annotation `Vector` is not defined as a type.
def to_velox(array: Array) -> Vector: ...
def to_arrow(vector: Vector) -> Array: ...
7 changes: 1 addition & 6 deletions velox/py/plan_builder/plan_builder.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,8 @@
from enum import Enum
from typing import List, Dict, Type

# pyre-fixme[21]: Could not find `velox.py.type`.
from velox.py.type import Type

# pyre-fixme[21]: Could not find `velox.py.type`.
from velox.py.file import File
from velox.py.type import Type


class JoinType(Enum):
Expand All @@ -37,13 +34,11 @@ class PlanBuilder:
def __init__(self) -> None: ...
def table_scan(
self,
# pyre-fixme[11]: Annotation `Type` is not defined as a type.
output_schema: Type,
aliases: Dict[str, str] = {},
subfields: Dict[str, List[int]] = {},
row_index: str = "",
connector_id: str = "prism",
# pyre-fixme[11]: Annotation `File` is not defined as a type.
input_files: List[File] = [],
) -> PlanBuilder: ...
def get_plan_node(self) -> PlanBuilder: ...
Expand Down
4 changes: 1 addition & 3 deletions velox/py/runner/runner.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,11 @@

from typing import Iterator

# pyre-fixme[21]: Could not find `velox.py.type`.
from velox.py.cector import Vector
from velox.py.vector import Vector


class LocalRunner:
def __init__(self, PlanNode) -> None: ...
# pyre-fixme[11]: Annotation `Vector` is not defined as a type.
def execute(self) -> Iterator[Vector]: ...
def add_file_split(self, plan_id: str, file_path: str) -> None: ...

Expand Down

0 comments on commit d8cac2f

Please sign in to comment.