Spaces:
Running
on
T4
Running
on
T4
sparkleman
commited on
Commit
·
e599bbd
1
Parent(s):
2833293
UPDATE
Browse files
utils.py
CHANGED
|
@@ -77,11 +77,14 @@ def logger():
|
|
| 77 |
print("enable")
|
| 78 |
while True:
|
| 79 |
item = LOGGER_QUEUE.get()
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
|
|
|
|
|
|
|
|
|
| 85 |
|
| 86 |
|
| 87 |
if os.environ.get("LOG_PORT"):
|
|
|
|
| 77 |
print("enable")
|
| 78 |
while True:
|
| 79 |
item = LOGGER_QUEUE.get()
|
| 80 |
+
try:
|
| 81 |
+
requests.post(
|
| 82 |
+
os.environ.get("LOG_PORT"),
|
| 83 |
+
headers={"Content-Type": "application/json"},
|
| 84 |
+
json=item,
|
| 85 |
+
)
|
| 86 |
+
except Exception:
|
| 87 |
+
pass
|
| 88 |
|
| 89 |
|
| 90 |
if os.environ.get("LOG_PORT"):
|