Spaces:
Running
Running
admin
commited on
Commit
•
fa05e82
1
Parent(s):
301e30f
upd period
Browse files
app.py
CHANGED
@@ -107,7 +107,11 @@ def get_spaces(username: str):
|
|
107 |
studios = []
|
108 |
for space in spaces:
|
109 |
if space["author"] == username:
|
110 |
-
|
|
|
|
|
|
|
|
|
111 |
|
112 |
return studios
|
113 |
|
@@ -210,7 +214,7 @@ def activate(hf_users: str, ms_users: str):
|
|
210 |
return pd.DataFrame(output)
|
211 |
|
212 |
|
213 |
-
def monitor(hf_users: str, ms_users: str, period=
|
214 |
if schedule.get_jobs():
|
215 |
return
|
216 |
|
|
|
107 |
studios = []
|
108 |
for space in spaces:
|
109 |
if space["author"] == username:
|
110 |
+
url = f"https://{space['id'].replace('/', '-')}.hf.space"
|
111 |
+
if "keep-spaces-active" in url:
|
112 |
+
studios.insert(0, url)
|
113 |
+
else:
|
114 |
+
studios.append(url)
|
115 |
|
116 |
return studios
|
117 |
|
|
|
214 |
return pd.DataFrame(output)
|
215 |
|
216 |
|
217 |
+
def monitor(hf_users: str, ms_users: str, period=4):
|
218 |
if schedule.get_jobs():
|
219 |
return
|
220 |
|