Skip to content
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

hard-reset check for the users table, even on its first run (when no tables exists) #51

Open
igwan opened this issue Feb 22, 2017 · 1 comment

Comments

@igwan
Copy link

igwan commented Feb 22, 2017

During the installation, I was trying to run hard-reset to create the database but got the error :
Can't connect to database. please check your settings!

I added cliLog($exception->getMessage()); in core/php/dependencies.php line 349 to get a better error message :

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'slimpddb.users' doesn't exist (SQL: select * from `users` where `users`.`uid` = 1 limit 1)

It seems the database check in core/php/dependencies.php is using the users table and the hard-reset script is calling this dependencies.php script even on its first run, when no tables exists.

I'm not sure how to solve this, either create a init-db task which doesn't run the dependencies.php code or find another way to check for database connectivity.

Anyway the quick workaround is to run CREATE TABLE users (uid int(11));.

@othmar52
Copy link
Owner

@igwan
thank you for reporting. i already noticed this issue a few weeks ago as i decided to use eloquent for the user model.

currently i have no idea to solve this problem without creating an ugly hack. but i am looking forward to find a solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants