Skip to content

Commit

Permalink
fix: lazy check for local wheel installation via path
Browse files Browse the repository at this point in the history
Signed-off-by: Aaron Pham <29749331+aarnphm@users.noreply.github.com>
  • Loading branch information
aarnphm committed Nov 2, 2022
1 parent 3193102 commit 24a90e5
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/bentoml/_internal/bento/build_dev_bentoml_whl.py
Expand Up @@ -43,11 +43,7 @@ def build_bentoml_editable_wheel(target_path: str) -> None:
raise BentoMLException("Could not find bentoml module location.")
bentoml_path = Path(module_location)

try:
from importlib import import_module

_ = import_module("bentoml.grpc.v1alpha1.service_pb2")
except ModuleNotFoundError:
if not Path(module_location, "grpc", "v1alpha1", "service_pb2.py").exists():
raise ModuleNotFoundError(
f"Generated stubs are not found. Make sure to run '{bentoml_path.as_posix()}/scripts/generate_grpc_stubs.sh' beforehand to generate gRPC stubs."
) from None
Expand Down

0 comments on commit 24a90e5

Please sign in to comment.