KIRUTHICKBJ commited on
Commit
1b6d59b
·
verified ·
1 Parent(s): 2f2028b

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +2 -2
main.py CHANGED
@@ -39,8 +39,8 @@ def stress_detection_app():
39
 
40
  # Store the prediction in Supabase
41
  user_id = st.session_state.get("user_id", "anonymous") # Fallback to "anonymous" if no user_id
42
- timestamp = datetime.datetime.now().isoformat() # Current timestamp in ISO format
43
-
44
  response = supabase.table("predictions").insert({
45
  "user_id": user_id,
46
  "prediction": prediction,
 
39
 
40
  # Store the prediction in Supabase
41
  user_id = st.session_state.get("user_id", "anonymous") # Fallback to "anonymous" if no user_id
42
+ timestamp = int(datetime.datetime.now().timestamp()) # Convert to Unix epoch time (integer)
43
+
44
  response = supabase.table("predictions").insert({
45
  "user_id": user_id,
46
  "prediction": prediction,