Skip to content

Commit d7df1e7

Browse files
It's beyond me why this is implemented this way
1 parent 3fba55a commit d7df1e7

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

tidy3d/web/api/container.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -679,7 +679,11 @@ def num_jobs(self) -> int:
679679
def upload(self) -> None:
680680
"""Upload a series of tasks associated with this ``Batch`` using multi-threading."""
681681
if self.simulation_type == "microwave":
682-
self._check_folder(self.folder_name, projects_endpoint="tidy3d/projects/rf")
682+
self._check_folder(
683+
self.folder_name,
684+
projects_endpoint="tidy3d/projects/rf",
685+
project_endpoint="tidy3d/project/rf",
686+
)
683687
else:
684688
self._check_folder(self.folder_name)
685689
with ThreadPoolExecutor(max_workers=self.num_workers) as executor:

tidy3d/web/core/task_core.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,11 @@ def list(cls, projects_endpoint: str = "tidy3d/projects") -> []:
5757

5858
@classmethod
5959
def get(
60-
cls, folder_name: str, create: bool = False, projects_endpoint: str = "tidy3d/projects"
60+
cls,
61+
folder_name: str,
62+
create: bool = False,
63+
projects_endpoint: str = "tidy3d/projects",
64+
project_endpoint: str = "tidy3d/project",
6165
):
6266
"""Get folder by name.
6367
@@ -74,7 +78,7 @@ def get(
7478
"""
7579
folder = FOLDER_CACHE.get(folder_name)
7680
if not folder:
77-
resp = http.get(projects_endpoint, params={"projectName": folder_name})
81+
resp = http.get(project_endpoint, params={"projectName": folder_name})
7882
if resp:
7983
folder = Folder(**resp)
8084
if create and not folder:

0 commit comments

Comments
 (0)