compact(): Undefined variable: operator

InvoiceNinja 6.5.11
Debian 8 Linux

I just recently ran a apt update and apt upgrade. It seemed to have upgraded my php from 7.0 to 7.3.3.

When trying to run the following, I get the error:

Wed, 13 Mar 2019 16:03:10 +0000 Running SendRecurringInvoices... Wed, 13 Mar 2019 16:03:10 +0000 112 recurring invoice(s) found Wed, 13 Mar 2019 16:03:18 +0000 0 recurring expenses(s) found Wed, 13 Mar 2019 16:03:18 +0000 Done Wed, 13 Mar 2019 16:03:19 +0000 Running SendReminders... Wed, 13 Mar 2019 16:03:19 +0000 1 due recurring invoice instance(s) found

In Builder.php line 1229:

compact(): Undefined variable: operator

How can I fix this?

PHP 7.3 isn’t yet supported

Okay thanks.

I noticed in your docs:

The applications requires PHP >= 7.0.0 and MySQL.

But I guess it should say PHP >=7.0.0.0 < 7.3.0.0 :slight_smile:

Yeah, they’re just out of date

Is 7.2 supported?

i’m now getting:

Wed, 13 Mar 2019 16:49:52 +0000 Processing report: 1 Wed, 13 Mar 2019 16:50:09 +0000 ERROR: Function create_function() is deprecated Wed, 13 Mar 2019 16:50:10 +0000 Processing report: 2 Wed, 13 Mar 2019 16:50:28 +0000 ERROR: Function create_function() is deprecated Wed, 13 Mar 2019 16:50:28 +0000 Processing report: 3 Wed, 13 Mar 2019 16:50:46 +0000 ERROR: Function create_function() is deprecated Wed, 13 Mar 2019 16:50:46 +0000 Processing report: 4 Wed, 13 Mar 2019 16:50:49 +0000 ERROR: Function create_function() is deprecated Wed, 13 Mar 2019 16:50:49 +0000 Done

Not sure, 7.2 should work. You may want to try 7.1 as this is likely related to 7.2.

Yup that works.

Thank you.

I guess I won’t be doing any php updates for now.

I had the same problem with builder.php after migrating to 4.5 but i didn´t want to install another or old php version. I solved this when i changed the line in vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php

from
$this->wheres[] = compact('type', 'operator', 'query', 'boolean');

to
"$this->wheres[] = compact('type', 'query', 'boolean');

The reminders are send and the problem is gone.