diff --git a/README.md b/README.md index 13b12e9..4b78e8c 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Theme Song Booth -**Version:** `v0.4.4` +**Version:** `v0.4.5` A Flask web app for a convention booth where visitors request a custom AI-generated theme song, the operator manages the queue, and the final MP3(s) are delivered by email after payment. diff --git a/VERSION b/VERSION index 6f2743d..0bfccb0 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.4.4 +0.4.5 diff --git a/app.py b/app.py index f200833..2c0f3b9 100644 --- a/app.py +++ b/app.py @@ -360,8 +360,9 @@ def sign_prompt_callback(rid, expires_at=None): """ secret = current_app.config['SECRET_KEY'].encode() if expires_at is None: - # Default expiry: 1 hour. - expires_at = int(time.time()) + 3600 + # Default expiry: 7 days, so operators have plenty of time to copy the + # callback URL into Hermes and for Hermes to POST back. + expires_at = int(time.time()) + 7 * 24 * 3600 payload = f"{rid}:{expires_at}" sig = hmac.new(secret, payload.encode(), hashlib.sha256).hexdigest()[:16] return f"{rid}:{expires_at}:{sig}"