Has sqlite3 been pulled from the snap store?

Colin Watson cjwatson at ubuntu.com
Sat Jun 13 11:33:16 UTC 2020


On Thu, Jun 11, 2020 at 09:58:32PM -0500, Jim wrote:
> On 6/11/20 8:40 PM, Colin Watson wrote:
> > (If it's "database is locked", then a simple workaround is to copy the
> > .sqlite file somewhere else before trying to open it, since otherwise
> > you may not be able to open it with sqlite3 while Firefox is running.)
> 
> I tried with Firefox running and not running and the results were the same.
> 
> This started because I wanted to write a Python script to delete some
> cookies I acquire each day but don't want to keep. Here is the error from
> the script:
> 
> (env36) jfb at jims-mint18 ~ $ python /home/jfb/Dev/Python/delete_cookies.py
> Traceback (most recent call last):
>   File "/home/jfb/Dev/Python/delete_cookies.py", line 12, in <module>
>     sqlite3Connect()
>   File "/home/jfb/Dev/Python/delete_cookies.py", line 9, in sqlite3Connect
>     conn =
> sqlite3.connect("/home/jfb/.mozilla/firefox/mwadOhks.default/cookies")
> sqlite3.OperationalError: unable to open database file
> 
> So I tried to look at the file with DBbrowser, I didn't run it from a
> terminal so I got a brief error in a dialog : "Invalid file format"
> 
> Then I tried Sqliteman: "Unable to open or create file cookies.sqlite. It is
> probably not a database"

I would try the plain "sqlite3" command-line tool, to rule out any
oddities from graphical programs and probably get clearer error
messages.

> > > So I googled for the easiest way to update sqlite3.
> > 
> > My strong suspicion is that this is a false trail.  I'm not an SQLite
> > expert, but from a scan through https://sqlite.org/fileformat2.html the
> > last mention of a file format change I can find was at 3.8.1.  Without
> > further details of the error message, I'm not yet convinced that
> > updating sqlite3 would help.
> 
> I then moved a copy of the cookies.sqlite file from mint 18.3 to my Ubuntu
> 18.04 and Mint 19.3 partitions and was able to open it in both cases using
> DBbrowser. This is why I concluded I needed to upgrade my version of
> sqlite3.

Have you tried simply copying the file and opening a copy of the file
*without* changing operating system version as well?  The transcript you
gave above doesn't indicate that you tried that, and I think it may be
worth a try.

(I'm running Ubuntu 20.04, and as long as I take a copy of it first I
can open my Firefox cookies database just fine from Ubuntu 16.04, which
uses sqlite3 3.11.0 - the same version you report.  This is among the
reasons I don't think it's a version incompatibility issue, but rather
something else.)

-- 
Colin Watson (he/him)                              [cjwatson at ubuntu.com]




More information about the ubuntu-users mailing list