signal-backup icon indicating copy to clipboard operation
signal-backup copied to clipboard

error: pysqlcipher3.dbapi2.DatabaseError: file is not a database

Open ChristopherA opened this issue 6 years ago • 8 comments

I have already done

brew install sqlcipher
pip3 install pysqlcipher3 --user

However, when I cd to the directory with config.json and run python3 ../scab.py I get:

Traceback (most recent call last):
  File "../scab.py", line 41, in <module>
    c.execute("SELECT json, id, name, profileName, type, members FROM conversations")
pysqlcipher3.dbapi2.DatabaseError: file is not a database

Any suggestions?

ChristopherA avatar Oct 01 '19 04:10 ChristopherA

ugh. I just posted about this. should have checked the history. I have the same issue

ekkis avatar Oct 05 '19 18:10 ekkis

the problem is with this compatibility update: https://github.com/mattsta/signal-backup/pull/3 -- if you comment out lines 29-33 of the scab.py it should work. it did for me

ekkis avatar Oct 05 '19 18:10 ekkis

Thanks @ekkis! That worked for me too, although I had to comment out line 30-33, not 29.

tkrunning avatar Oct 13 '19 09:10 tkrunning

hi! did not work for me, any suggestions? thx

brummski avatar Jan 10 '20 15:01 brummski

@brummski did you try commenting out 30-33 as @tkrunning mentioned? 29-33 for me still caused the error, but 30-33 and it ran perfectly

lol-fi avatar Mar 07 '20 19:03 lol-fi

@mattsta, can we get these permanently commented out?

ryanpcmcquen avatar Mar 30 '20 15:03 ryanpcmcquen

@mattsta, can we get these permanently commented out?

why not make a pull request?

lol-fi avatar Mar 30 '20 16:03 lol-fi

I just posted in #13 about why this happens; this is probably a SQLCipher version mismatch, and I presume commenting out those lines causes the library to fall back to the default of version 4, which is now what Signal requires.

501st-alpha1 avatar Jan 25 '21 20:01 501st-alpha1