Fix SQLite threading bug, correct FTP upload path
- Add check_same_thread=False to SQLite connection (watchdog callbacks run in a separate thread) - Camera upload dir is /data/photos/incoming (not /incoming) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -53,7 +53,7 @@ Configure an FTP profile on the camera:
|
|||||||
| Passive Mode | **ON** |
|
| Passive Mode | **ON** |
|
||||||
| Username | `fujiftp` |
|
| Username | `fujiftp` |
|
||||||
| Password | *(your password)* |
|
| Password | *(your password)* |
|
||||||
| Upload Dir | `/incoming` |
|
| Upload Dir | `/data/photos/incoming` |
|
||||||
| Auto Transfer | ON (or manual trigger) |
|
| Auto Transfer | ON (or manual trigger) |
|
||||||
|
|
||||||
> **Note**: Bij FTPS kun je via **FTP OPTIONAL SETTING → ROOT CERTIFICATE** een self-signed root certificaat laden als je NAS er een gebruikt.
|
> **Note**: Bij FTPS kun je via **FTP OPTIONAL SETTING → ROOT CERTIFICATE** een self-signed root certificaat laden als je NAS er een gebruikt.
|
||||||
|
|||||||
2
TODO.md
2
TODO.md
@@ -52,7 +52,7 @@
|
|||||||
- [ ] Passive mode: ON
|
- [ ] Passive mode: ON
|
||||||
- [ ] Username: `fujiftp`
|
- [ ] Username: `fujiftp`
|
||||||
- [ ] Password: (het ingestelde wachtwoord)
|
- [ ] Password: (het ingestelde wachtwoord)
|
||||||
- [ ] Upload directory: `/incoming`
|
- [ ] Upload directory: `/data/photos/incoming`
|
||||||
- [ ] Optioneel: FTP OPTIONAL SETTING → ROOT CERTIFICATE (als NAS self-signed cert gebruikt)
|
- [ ] Optioneel: FTP OPTIONAL SETTING → ROOT CERTIFICATE (als NAS self-signed cert gebruikt)
|
||||||
- [ ] Profiel naam: "NAS-FTPS"
|
- [ ] Profiel naam: "NAS-FTPS"
|
||||||
- [ ] Opslaan
|
- [ ] Opslaan
|
||||||
|
|||||||
@@ -50,7 +50,7 @@ log = logging.getLogger("processor")
|
|||||||
def init_db():
|
def init_db():
|
||||||
"""Initialize the SQLite tracking database."""
|
"""Initialize the SQLite tracking database."""
|
||||||
DB_PATH.parent.mkdir(parents=True, exist_ok=True)
|
DB_PATH.parent.mkdir(parents=True, exist_ok=True)
|
||||||
conn = sqlite3.connect(str(DB_PATH))
|
conn = sqlite3.connect(str(DB_PATH), check_same_thread=False)
|
||||||
conn.execute(
|
conn.execute(
|
||||||
"""CREATE TABLE IF NOT EXISTS processed_files (
|
"""CREATE TABLE IF NOT EXISTS processed_files (
|
||||||
filename TEXT PRIMARY KEY,
|
filename TEXT PRIMARY KEY,
|
||||||
|
|||||||
Reference in New Issue
Block a user