From 3d5575fe6b615ba0714d567f99123a594bd81130 Mon Sep 17 00:00:00 2001 From: Matteo Ferrando Date: Tue, 26 Dec 2023 10:53:48 -0400 Subject: [PATCH] chore: add proto_path $GOPATH/pkg/mod (#14) --- tools/regen_grpc.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/regen_grpc.py b/tools/regen_grpc.py index bce696fa..536981e8 100644 --- a/tools/regen_grpc.py +++ b/tools/regen_grpc.py @@ -1,6 +1,7 @@ from __future__ import annotations import ast +import os import shutil import subprocess import sys @@ -73,7 +74,8 @@ def regen_grpc( sys.executable, "-m", "grpc_tools.protoc", - "--proto_path=.", + "-I=.", + f"-I={os.getenv('GOPATH')}/pkg/mod", "--python_out=.", "--grpc_python_out=.", "--mypy_out=.",