bc748d05ac4a3115d3f376eb9a0b584619bc6a8e
The sync engine was adding per-photo backoff delays (2-60s) inside the processing loop, during which the user would navigate to another page (browser -> queue -> browser), killing the sync mid-wait. The upload POST never fired because the delay ran out the clock. Changes: - Remove per-photo backoff delay from processQueue loop — uploads start immediately on page load without blocking - Move retry scheduling to after the full queue pass: if any uploads failed, schedule a new triggerSync() after 15s instead of blocking inline - Keep the duplicate check on retries (fast, catches interrupted uploads that actually succeeded server-side) - uploadPhoto now returns true/false so processQueue can track failures Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
NextSnap
Offline-first photo capture web app for Nextcloud.
Quick Start
Development
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
python run.py
Visit http://localhost:5000/api/health to verify the server is running.
Docker Deployment
export SECRET_KEY="your-secret-key-here"
export NEXTCLOUD_URL="https://your-nextcloud-instance.com"
docker-compose up -d
Architecture
- Backend: Flask + Gunicorn
- Frontend: Vanilla JavaScript (no framework)
- Offline Storage: IndexedDB via Dexie.js
- Service Worker: For offline-first capabilities
- Nextcloud Integration: WebDAV API for file operations
Build Order
See nextsnap.md for the complete specification and phased implementation plan.
Description
Languages
JavaScript
42.2%
HTML
29.1%
Python
21.6%
CSS
5.6%
Makefile
0.6%
Other
0.9%