Component failure on sync

Getting the following error upon sync:

Error: [Exception... "'[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [mozIStorageStatement.execute]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: chrome://zotero/content/xpcom/db.js :: anonymous :: line 123" data: no] [QUERY: DELETE FROM creatorData WHERE creatorDataID=?] [ERROR: constraint failed]' when calling method: [nsIDOMEventListener::handleEvent]" nsresult: "0x8057001e (NS_ERROR_XPC_JS_THREW_STRING)" location: "<unknown>" data: no]
  • Any ideas on this? I tried the debug mode, but the output was too verbose to find out what was going on.
  • Can you post the last 15 or so lines of debug output, up to "Rolling back transaction" or "Flagging nested transaction for rollback"?
  • zotero(5): Transaction in progress -- increasing level to 2

    zotero(3): Changing itemID 13260 to 34

    zotero(5): SELECT * FROM items WHERE itemID=?

    zotero(5): Binding parameter 1 of type int: 13260

    zotero(5): INSERT INTO items VALUES (?, ?, ?, ?, ?)

    zotero(5): Binding parameter 1 of type int: 34

    zotero(5): Binding parameter 2 of type int: 14

    zotero(5): Binding parameter 3 of type string: "2007-11-10 14:21:18"

    zotero(5): Binding parameter 4 of type string: "2007-11-10 14:21:18"

    zotero(5): Binding parameter 5 of type string: "TEMPKEY"

    zotero(5): UPDATE annotations SET itemID=? WHERE itemID=?

    zotero(5): Binding parameter 1 of type int: 34

    zotero(5): Binding parameter 2 of type int: 13260

    zotero(5): UPDATE collectionItems SET itemID=? WHERE itemID=?

    zotero(5): Binding parameter 1 of type int: 34

    zotero(5): Binding parameter 2 of type int: 13260

    zotero(5): UPDATE highlights SET itemID=? WHERE itemID=?

    zotero(5): Binding parameter 1 of type int: 34

    zotero(5): Binding parameter 2 of type int: 13260

    zotero(5): Rolling back transaction

    zotero(3): Resetting Notifier event queue

    zotero(3): Releasing session lock

    zotero(3): HTTP POST version=1&sessionid=8b27d38910dc3e16c3b774f239a50e7a to htt
    ps://sync.zotero.org/unlock
  • Deleting the offending item created an error. Please see report ID: 1519159521
  • So it seems that standalone snapshots are causing these errors.
  • OK, there are actually three different errors here. The error you provided the debug output for should now be fixed in the latest trunk build—it could occur trying to sync attachments with highlights or annotations (which aren't synced currently but shouldn't break the process).

    If you want to test this, you can grab the latest trunk build and verify that it fixes the problem and then see if you can still reproduce the other errors. If so, provide debug output for those as well. Thanks for your help.
  • Correction: It's now fixed on the trunk.
  • edited August 4, 2008
    Yup, that error seems to be resolved, only to get a new one later on in the sync. TypeError this time.

    Here's some output:

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 7

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 8

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 9

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 10

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 11

    zotero(5): SELECT collectionID AS id, 0 AS type, collectionName AS collectionName FROM collections WHERE parentCollectionID=?1 UNION SELECT itemID AS id, 1 AS type, NULL AS collectionName FROM collectionItems WHERE collectionID=?1

    zotero(5): Binding parameter 1 of type int: 12

    zotero(3): Processing locally changed searches

    zotero(5): SELECT COUNT(*) FROM savedSearches WHERE savedSearchID=?

    zotero(5): Binding parameter 1 of type int: 1

    zotero(5): SELECT S.*, MAX(searchConditionID) AS maxID FROM savedSearches S LEFT JOIN savedSearchConditions USING (savedSearchID) WHERE savedSearchID=? GROUP BY savedSearchID

    zotero(5): Binding parameter 1 of type int: 1

    zotero(5): SELECT * FROM savedSearchConditions WHERE savedSearchID=? ORDER BY searchConditionID

    zotero(5): Binding parameter 1 of type int: 1

    zotero(3): Processing locally changed tags

    zotero(5): SELECT COUNT(*) FROM tags WHERE tagID=?

    zotero(5): Binding parameter 1 of type int: 1

    zotero(5): Rolling back transaction
  • What's the full error?
  • I didn't get any more information than TypeError that time, unless I'm mistaken. I'll check when I get home.
  • Yup, it only displays TypeError. There might be more info for you in report 1477539521
  • Would it be possible to upload this database to the DB Repair Tool and send the Upload ID to support@zot....org so that we can take a look?

    Also, is this a database that you upgraded or a new one you created in 1.5?
  • This is an upgraded database. Emailing you the Upload ID
  • Thanks. Can you send the full debug output for the TypeError to support@zot....org? Zotero appears to be looking for collections, saved searches, and tags that don't exist in the database you uploaded.

    If you've made local changes since the last upload, a new Upload ID would also be helpful.
  • Done. I could only get the last 9999 lines of output though.

This is an old discussion that has not been active in a long time. Instead of commenting here, you should start a new discussion. If you think the content of this discussion is still relevant, you can link to it from your new discussion.