Spaces:
Sleeping
Sleeping
Update app.py (#2)
Browse files- Update app.py (f28ea0a5d52f9ededd6d6d71ed085b708e4c2a85)
Co-authored-by: Sachin Verma <CosmoAI@users.noreply.huggingface.co>
app.py
CHANGED
@@ -16,6 +16,12 @@ client = MongoClient(uri, tlsCertificateKeyFile="cert.pem")
|
|
16 |
db = client["reshav"]
|
17 |
col=db["mine"]
|
18 |
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
def login():
|
20 |
st.title("Login")
|
21 |
data = json.load(open("database/data.json"))
|
|
|
16 |
db = client["reshav"]
|
17 |
col=db["mine"]
|
18 |
|
19 |
+
try:
|
20 |
+
client.admin.command("ping")
|
21 |
+
print("Connection Established!")
|
22 |
+
except Exception as e:
|
23 |
+
print(e)
|
24 |
+
|
25 |
def login():
|
26 |
st.title("Login")
|
27 |
data = json.load(open("database/data.json"))
|