Error with new installation 4.4

After the installation of 4.4, i’ve this error in the webUI:
Whoops, looks like something went wrong.

in the laravel error log:
[2018-04-25 06:16:00] production.ERROR: Symfony\Component\Debug\Exception\FatalThrowableError [0] : /home/xx/public_html/invoice/vendor/laravelcollective/html/src/FormBuilder.php [Line 1290] => Type error: Argument 1 passed to Collective\Html\FormBuilder::setSessionStore() must be an instance of Illuminate\Contracts\Session\Session, instance of Illuminate\Session\EncryptedStore given, called in /home/xx/public_html/invoice/vendor/laravelcollective/html/src/HtmlServiceProvider.php on line 66 {"context":"PHP","user_id":0,"account_id":0,"user_name":"","method":"GET","user_agent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36","locale":"en","ip":"xxx","count":1,"is_console":"no","is_api":"no","db_server":"mysql","url":"/"} [

[invoice]# php -v
PHP 7.0.29 (cli) (built: Apr 24 2018 22:37:13) ( NTS )

[invoice]# php artisan cache:clear


PHP Fatal error:  Uncaught Error: Call to undefined method Illuminate\Support\Facades\Log::error() in /home/xx/public_html/invoice/bootstrap/cache/compiled.php:6468
Stack trace:
#0 /home/xx/public_html/invoice/app/Libraries/Utils.php(428): Illuminate\Support\Facades\Facade::__callStatic('error', Array)
#1 /home/xx/public_html/invoice/app/Exceptions/Handler.php(82): App\Libraries\Utils::logError('***Symfony\\Comp...')
#2 /home/xx/public_html/invoice/bootstrap/cache/compiled.php(2300): App\Exceptions\Handler->report(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#3 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleException(Object(Symfony\Component\Debug\Exception\FatalThrowableError))
#4 {main}
  thrown in /home/xx/public_html/invoice/bootstrap/cache/compiled.php on line 6468
PHP Fatal error:  Uncaught Error: Call to undefined method Illuminate\Support\Facades\Log::error() in /home/xx/public_html/invoice/bootstrap/cache/compiled.php:6468
Stack trace:
#0 /home/xx/public_html/invoice/app/Libraries/Utils.php(428): Illuminate\Support\Facades\Facade::__callStatic('error', Array)
#1 /home/xx/public_html/invoice/app/Exceptions/Handler.php(82): App\Libraries\Utils::logError('***Symfony\\Comp...')
#2 /home/xx/public_html/invoice/bootstrap/cache/compiled.php(2300): App\Exceptions\Handler->report(Object(Symfony\Component\Debug\Exception\FatalErrorException))
#3 /home/xx/public_html/invoice/bootstrap/cache/compiled.php(2318): Illuminate\Foundation\Bootstrap\HandleExceptions->handleException(Object(Symfony\Component\Debug\Exception\FatalErrorException))
#4 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleShutdown()
#5 {main}
  thrown in /home/xx/public_html/invoice/bootstrap/cache/compiled.php on line 6468

Any idea?

Thx
Christophe

I’m not sure… I’ve seen this error in the past when upgrading the app to >= v4.3, in that case the fix is to delete bootstrap/cache/compiled.php

Don’t know what’s happening, now the cache:clear is solved by deleting the compiled.php but when accessing the update i’ve this:
[2018-04-25 07:22:19] production.ERROR: ErrorException [0] : /home/xx/public_html/invoice/app/Http/Controllers/AppController.php [Line 354] => Undefined property: stdClass::$Tables_in_ {“context”:“PHP”,“user_id”:0,“account_id”:0,“user_name”:"",“method”:“GET”,“user_agent”:“Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36”,“locale”:“en”,“ip”:“xxx”,“count”:3,“is_console”:“no”,“is_api”:“no”,“db_server”:“mysql”,“url”:“update”}

Reviewing the code it looks like that error may be caused if DB_DATABASE isn’t set in the .env file.

The DB is set in the .env, i’ve made a php artisan config:cache to make sure the .env is correctly used.
I’ve tried to again use the /update without any success but when accessing the root folder / all is working fine…

Christophe

If you’ve run config:cache I’d suggest running config:clear to clear the config.

Did you follow a guide which suggested running config:cache?

I did the clear before, i think the problem is linked when you access the /update while the update was already performed wdyt?

I’m laravel dev so i’ve tried what i know to solve an issue on a laravel framework.

Christophe

You should be able to repeatedly load /update, it mainly runs the database migrations and clears the view cache.

What method are you using to install the app? You shouldn’t have the bootstrap/cache/compiled.php file on a new install, it may be related to this problem.

i’m using the Invoice Ninja Self-Hosted Automatic Update.
I see now in the logs that i’ve more and more issues
production.ERROR: TypeError: undefined is not an object (evaluating ‘n.custom_fields.invoice1’) {“context”:“JavaScript”

production.ERROR: Error: Syntax error, unrecognized expression: select[name='mail[driver]' {"context":"JavaScript",

I’ve flushed the browser cache without any luck

C

To clarify…

  • Is this a new install or are you updating an existing install?

  • By ‘Self-Hosted Automatic Update’ do you mean this shell script? https://pastebin.com/j657uv9A

I’ll look into these errors.

Sorry i see that the topic title is confusing.
It’s a migration from 4.3 to 4.4 using the automatic update script as mentioned https://pastebin.com/j657uv9A

Thanks, that’s helpful to know!

What do you now see when loading /update

[2018-04-25 08:33:50] production.ERROR: ErrorException [0] : /home/xx/public_html/invoice/app/Http/Controllers/AppController.php [Line 354] => Undefined property: stdClass::$Tables_in_ {"context":"PHP","user_id":1,"account_id":1,"user_name":"xx","method":"GET","user_agent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36","locale":"en","ip":"xxx","count":13,"is_console":"no","is_api":"no","db_server":"mysql","url":"update"} []

Is the 4.4.0 the correct stable version to be used?

It’s our latest release.

I’m happy to work with you to try to debug the problem or you can downgrade to v4.3.

can we exchange via mail or IM?

I’d suggest joining our Slack group

http://slack.invoiceninja.com/