Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing PyAirtable dependency (#1259) #1291

Merged
merged 2 commits into from
Oct 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions ersilia/hub/fetch/fetch.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,16 +221,16 @@ def _standard_csv_example(self, model_id):

def _fetch(self, model_id):
self.logger.debug("Starting fetching procedure")
do_hosted = self._decide_if_use_hosted(model_id=model_id)
if do_hosted:
self.logger.debug("Fetching from hosted")
self._fetch_from_hosted(model_id=model_id)
return
do_dockerhub = self._decide_if_use_dockerhub(model_id=model_id)
if do_dockerhub:
self.logger.debug("Decided to fetch from DockerHub")
self._fetch_from_dockerhub(model_id=model_id)
return
do_hosted = self._decide_if_use_hosted(model_id=model_id)
if do_hosted:
self.logger.debug("Fetching from hosted")
self._fetch_from_hosted(model_id=model_id)
return
if self.overwrite is None:
self.logger.debug("Overwriting")
self.overwrite = True
Expand All @@ -244,3 +244,4 @@ def fetch(self, model_id):
model_source_file = os.path.join(self._model_path(model_id), MODEL_SOURCE_FILE)
with open(model_source_file, "w") as f:
f.write(self.model_source)