You are here
Alfredo - Wed, 2021/03/31 - 02:50
Error in define variables:
When I try to access the knowledge-based categories:
Fails! × compact(): Undefined variable: time
When I try to create new agent too:
Fails! × compact(): Undefined variable: assign
According to what I found on the internet the problem occurs with php7.3.
PHP7.3 is the one that is installed by default on v16.0.
Install and active php7.2 solve this problem. Apparently.
Forum:
Thank for reporting this.
Thanks so much for reporting this. I'll have a closer look into it ASAP.
FWIW, the Faveo Helpdesk docs suggest that it should support PHP7.3.
I wonder if it's a missing PHP dependency? From a glance, I think we have them mostly covered. Except I note "ionCube Loaders v10.3 and above for PHP 7.3.x" in the list. That does not appear to be packaged for Debian?! So I don't think we're installing that! I'm not sure if that would cause the issue you've hit, but it needs further investigation anyway.
I'll set one up and see if I can reproduce the issue you've reported. Hopefully I can and we'll work it out. It's good to know that using PHP7.2 might be a workaround, but if we can find a proper fix that ensure's it's compatible with PHP7.3 would be better! :)
Hmm, seems you might be right re PHP7.2!?
My instance isn't actually giving exactly the same errors, but close. I.e. in the browser I get "Sorry, something went wrong" and in the log (/var/www/faveo-helpdesk/storage/logs/laravel-2021-03-31.log) I have these errors:
FWIW, I got that via this command:
There are esentially 2 errors here; a "horizon" error and a "compat()" error.
Whilst the message is different, the compat() error, likely has the same cause as yours. It also appears to be a known issue in Faveo. And as you noted, it seems likely that this is related to PHP7.3! If you read the link provided in that post (see the "Undefined variables in compact()" section in Deprecations and Changes for PHP 7.3) it notes that the change in v7.3 is that undefined variables in calls to compat() are now raised as errors (instead of ignored as they were in
Re the "horizon" error I'm seeing. That appears to be a missing (Laravel) dependency which can't be resolved via composer. I'm going to need to work that out, but may also be resolvable via downgrading PHP (to v7.2)? I'll report back ASAP.
Yes...
Yes, it also appeared to me, after trying to go to the categories, the message Ooops something went wrong.
To have more information I activated the debug function in FAVEO.
Ok confirmation that downgrading PHP to 7.2 resolves issues
TBH, it's far from ideal, but downgrading PHP to 7.2 definitely resolves the issues.
I cleaned the log file and downgraded PHP to 7.2. I then poked around the webUI, including checking the "knowledgebase" links and logging in. All appears to be ok and the log file is still empty! :)
I'll rebuild the appliance with PHP7.2 ASAP (will probably not be available for a week or so). In the meantime, to make it easier to get going with the current appliance, I've built a script to downgrade PHP. Try this:
Thanks again for reporting and I hope that helps.
[update] I've open an issue on our issue tracker.
Downgrade-php i great!!!
This script works great.
Thanks a lot!!!
I will be attentive to future updates!
Thanks Jeremy !!! :)
I'm still getting this error
The log is filling with "horizon not defined" every other second.
60MB per day is a bit too much...
Any news on how to solve the problem without the need to downgrade PHP?
Thanks!
Add new comment