Skip to content

Commit

Permalink
update region description
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilippeMoussalli committed Oct 16, 2023
1 parent 1b0710e commit 1c38505
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions src/fondant/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,8 @@ def register_run(parent_parser):
help="""The project id of the GCP project used to submit the pipeline""",
)
vertex_parser.add_argument(
"--project-region",
help="The project region of the GCP project used to submit the pipeline ",
"--region",
help="The region where to run the pipeline",
)

vertex_parser.add_argument(
Expand Down Expand Up @@ -454,7 +454,7 @@ def run_vertex(args):
finally:
runner = VertexRunner(
project_id=args.project_id,
project_region=args.project_region,
region=args.region,
service_account=args.service_account,
)
runner.run(input_spec=spec_ref)
Expand Down
4 changes: 2 additions & 2 deletions src/fondant/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,14 +97,14 @@ def __resolve_imports(self):
def __init__(
self,
project_id: str,
project_region: str,
region: str,
service_account: t.Optional[str] = None,
):
self.__resolve_imports()

self.aip.init(
project=project_id,
location=project_region,
location=region,
)
self.service_account = service_account

Expand Down
8 changes: 4 additions & 4 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,15 +276,15 @@ def test_vertex_run(tmp_path_factory):
local=False,
vertex=True,
output_path=None,
project_region="europe-west-1",
region="europe-west-1",
project_id="project-123",
service_account=None,
ref="some/path",
)
run_vertex(args)
mock_runner.assert_called_once_with(
project_id="project-123",
project_region="europe-west-1",
region="europe-west-1",
service_account=None,
)

Expand All @@ -300,13 +300,13 @@ def test_vertex_run(tmp_path_factory):
host="localhost2",
output_path=str(fn / "kubeflow_pipelines.yml"),
ref=__name__,
project_region="europe-west-1",
region="europe-west-1",
project_id="project-123",
service_account=None,
)
run_vertex(args)
mock_runner.assert_called_once_with(
project_id="project-123",
project_region="europe-west-1",
region="europe-west-1",
service_account=None,
)

0 comments on commit 1c38505

Please sign in to comment.