[P6] Zotero annotation/highlight save errors prevent extraction #93
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Highlighting and extracting annotations from Zotero PDF attachments fails with errors when saving highlights.
Investigation Findings
1. Permissions: NOT the cause
File ownership is uid 100999 on host → maps to uid 1000 (ubuntu) in container via user namespace. Write tests pass for both storage dirs and db directory.
2. SQLite exclusive lock: NORMAL behavior
Zotero 8.0.2 opens the database with
EXCLUSIVElocking mode (no SHM file). This is by design — the missing-shmfile is expected. Externalmode=roconnections fail with "database is locked" — this is a side effect, not the root cause.3. Database integrity: OK
WAL checkpointed successfully (9320 items).
PRAGMA quick_checkreturns ok.itemAnnotationstable exists with correct schema. 2 existing annotations confirm the feature has worked before.4. D-Bus notifications: FAILING
org.freedesktop.Notificationsservice exits with status 1. This may cause Zotero save confirmations to fail silently.5. Debug logging enabled
Added
extensions.zotero.debug.log=trueto prefs.js for next reproduction attempt.Next Steps
conf.connect.zotero()with?immutable=1instead of?mode=roto bypass exclusive lockExternal Reader Fix (conf/connect.py)
Change
mode=rotoimmutable=1for reading while Zotero holds exclusive lock:Note: immutable mode reads only the main db file, not uncommitted WAL data. This is acceptable for bibliography queries.