-
-
Notifications
You must be signed in to change notification settings - Fork 31
incompatibility with sqlite-utils v2+ #20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for the detailed bug report! This is definitely a compatibility problem with |
OK, I think I have a fix for this in #21 @adipasquale would you mind testing this for me? You can install the fix directly from the branch like this:
|
I just tested it against your example from above and it works (whereas older versions fail). |
Fixed in 80c064f - I will release this shortly as |
hi @simonw thanks for the incredibly fast answer and fix :o I tried to test it with your git branch but I think it still installed and used the master version when pip installs the db-to-sqlite package and its dependencies .. my pip skills are quite restricted, sorry. If it works for you with the example I gave it should be ok! Thanks 🙇 |
This is now available to install from PyPI directly: |
Hi @simonw and thanks for such great tools! I'm using datasette on http://data.greenferries.org/ , it's been a delight.
I think there is an incompatibility with the breaking changes you made on
upsert_all
in version 2+ of sqlite-utils.I get this error when trying to convert a PostgresQL db:
I've managed to mitigate this problem by adding
sqlite-utils==1.12.1
to myrequirements.txt
beforedb-to-sqlite[postgresql]
, and now it works as expected.I tried to understand the actual problem with v2 but I'm not familiar enough with your codebase sorry :/ let me know if I can help somehow.
After digging, it seems to be linked to a specific table in my PostgreSQL db, namely the rails Schema migrations one that contains a single varchar column with 21 entries in my case (surprising). I've bissected it to
db-to-sqlite --table schema_migrations "postgresql://localhost/greenferries_prod_tmp" greenferries.db
triggering the error, I can skip it and it fixes the problem (with sqlite-utils v2+ that is).I've uploaded a small SQL dump on gist so you can reproduce:
(btw I don't actually need this table in datasette, so I've only created this issue for reference).
The text was updated successfully, but these errors were encountered: