Skip to content

Commit 1604f55

Browse files
committed
Merge branch 'apppears' of github.com:earthlab/earthpy into apppears
2 parents b4a96fb + 7241165 commit 1604f55

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

earthpy/api/appeears.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,10 @@ def __init__(
105105
if os.path.exists(self.task_id_path):
106106
with open(self.task_id_path, 'r') as task_id_file:
107107
self._task_id = task_id_file.readline()
108+
elif 'APPEEARS_TASKID' in os.environ:
109+
self._task_id = os.environ['APPEEARS_TASKID']
110+
with open(self.task_id_path, 'w') as task_id_file:
111+
task_id_file.write(self._task_id)
108112
else:
109113
self._task_id = None
110114

@@ -355,4 +359,4 @@ def download_files(self, cache=True):
355359
f.write(data)
356360

357361
# Remove task id file when download is complete
358-
os.remove(self.task_id_path)
362+
os.remove(self.task_id_path)

0 commit comments

Comments
 (0)