Spaces:
Sleeping
Sleeping
Update server.py
Browse files
server.py
CHANGED
@@ -61,7 +61,7 @@ class PredModelRequest(BaseModel):
|
|
61 |
def ping():
|
62 |
return {"message": "pong"}
|
63 |
|
64 |
-
|
65 |
|
66 |
|
67 |
def zip_if_needed(src_dir, zip_path):
|
@@ -150,7 +150,19 @@ def copy_and_extract():
|
|
150 |
|
151 |
|
152 |
|
|
|
|
|
153 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
154 |
|
155 |
|
156 |
|
|
|
61 |
def ping():
|
62 |
return {"message": "pong"}
|
63 |
|
64 |
+
"""
|
65 |
|
66 |
|
67 |
def zip_if_needed(src_dir, zip_path):
|
|
|
150 |
|
151 |
|
152 |
|
153 |
+
"""
|
154 |
+
|
155 |
|
156 |
+
@app.get("/data_check")
|
157 |
+
def data_check():
|
158 |
+
with open("/data/marker.txt", "w") as f:
|
159 |
+
f.write("hello from server.py\n")
|
160 |
+
|
161 |
+
files = os.listdir("/data")
|
162 |
+
return {
|
163 |
+
"message": "done",
|
164 |
+
"contents": files
|
165 |
+
}
|
166 |
|
167 |
|
168 |
|