Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upError connecting to SQLite database #208
Comments
This comment has been minimized.
|
Can you give some steps to reproduce? Do you have write access to that directory? (Also does that directory exist?) |
This comment has been minimized.
zamith
commented
Feb 12, 2016
|
Even if I copy the database to the project's folder it's the same thing. I even tried creating a new database with The result for ruby was an error because there was no table (expected), on diesel it complained with the "unable to open database file" again. There's probably something I'm doing wrong in the rust code. I've pushed it up here. |
This comment has been minimized.
zamith
commented
Feb 12, 2016
|
I get the same error if I remove the |
This comment has been minimized.
|
When I run the test suite against a file backed database with |
This comment has been minimized.
zamith
commented
Feb 12, 2016
|
How can I run that? I can try that locally on my machine, and try to figure out what I'm doing wrong. |
This comment has been minimized.
|
https://gist.github.com/sgrif/1495ed44ac1d83cf2381, then set |
This comment has been minimized.
|
I was able to replicate the error by attempting to run tests with a file in the |
This comment has been minimized.
|
It appears that SQLite doesn't like paths with a space in them. |
This comment has been minimized.
zamith
commented
Feb 12, 2016
|
Hum... But even if I have the file on the same directory it is failing for me. I'm defining the path as |
This comment has been minimized.
|
No,
and not
or
Based on your original post, I'm guessing that you have double quotes in your |
This comment has been minimized.
|
Also, doing |
This comment has been minimized.
zamith
commented
Feb 12, 2016
|
That's correct. By removing the quotes it works. That's probably something that could be added to dotenv rust then. Thanks and sorry for the trouble. |
zamith
closed this
Feb 12, 2016
This comment has been minimized.
|
I'm opening an issue there now. No worries, glad we got it resolved. |
zamith commentedFeb 12, 2016
I have this rust program that uses diesel, but fails when running with
'Error connection to "/Users/zamith/Library/Application Support/ActionAlly/action_ally.db": BadConnection("unable to open database file")':This is strange, because accessing the same DB in Ruby works just fine:
Am I doing anything wrong? Is this even an issue with Diesel or with
libsqlite3-sys?