Spaces:
Sleeping
Sleeping
Commit
·
e82805c
1
Parent(s):
e919d49
changes
Browse files
app.py
CHANGED
|
@@ -24,7 +24,7 @@ IS_HUGGINGFACE = os.environ.get('SPACE_ID') is not None
|
|
| 24 |
if IS_HUGGINGFACE:
|
| 25 |
logger.info("Running on Hugging Face Spaces environment")
|
| 26 |
# Ensure sessions work properly on Hugging Face
|
| 27 |
-
app.config["SESSION_COOKIE_SECURE"] = True
|
| 28 |
app.config["SESSION_COOKIE_HTTPONLY"] = True
|
| 29 |
app.config["SESSION_COOKIE_SAMESITE"] = "Lax"
|
| 30 |
# Add more durable storage for Hugging Face
|
|
|
|
| 24 |
if IS_HUGGINGFACE:
|
| 25 |
logger.info("Running on Hugging Face Spaces environment")
|
| 26 |
# Ensure sessions work properly on Hugging Face
|
| 27 |
+
app.config["SESSION_COOKIE_SECURE"] = False # Changed from True to False for HTTP connections
|
| 28 |
app.config["SESSION_COOKIE_HTTPONLY"] = True
|
| 29 |
app.config["SESSION_COOKIE_SAMESITE"] = "Lax"
|
| 30 |
# Add more durable storage for Hugging Face
|