mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
orm:schema-tool:create more friendly error when it's not able to create database file. #6179
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @CViniciusSDias on GitHub (Feb 20, 2019).
Originally assigned to: @Ocramius on GitHub.
Feature Request
Summary
When we try to execute
php vendor/bin/doctrine orm:schema-tool:createwith an SQLite database configured to a path that doesn't exist, an error like this one is shown:It would be a lot easier to newcomers to figure out what's happening if the CLI informed that the directory where it's trying to create the database file doesn't exist.
@Ocramius commented on GitHub (Feb 21, 2019):
@CViniciusSDias this is what the underlying SQLite layer is reporting to us: we don't check if the directory/path exists, nor if the file is writable, since that's a detail of Sqlite3 or PDO_Sqlite.
Please report this to https://bugs.php.net/ if you want to have the SQLite exception improved.