production.ERROR: Class "Opcodes\LogViewer\Utils\Utils" not found
Hi, on production server sometimes this error occurs
[2022-10-08 22:26:55] production.ERROR: Class "Opcodes\LogViewer\Utils\Utils" not found (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php) {"userId":20000,"exception":"[object] (Illuminate\\View\\ViewException(code: 0): Class \"Opcodes\\LogViewer\\Utils\\Utils\" not found (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php)
hey @Tiagospem , can you please try clearing the view cache? And updating to the latest Log Viewer. The class definitely exists.
I don't know what happens anymore. I install the package via composer require, I run it the first time, it works perfectly, after a while, error 500 appears, always something is wrong, this only happens with a project in production.
The only thing different is that I use the redis cache, but I have 7 other similar projects and that doesn't happen.
https://user-images.githubusercontent.com/8459781/196788366-2244daf9-d10d-4a89-a799-41c2485f24e8.mp4
https://user-images.githubusercontent.com/8459781/196788404-9fe9a113-29c7-4902-846d-83c4cb223f6c.mp4
production.ERROR: Undefined variable $showLevelsDropdown (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php) (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php) {"userId":20000,"exception":"[object] (Illuminate\\View\\ViewException(code: 0): Undefined variable $showLevelsDropdown (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php) (View: /var/www/vhosts/topoleiloes.com.br/httpdocs/vendor/opcodesio/log-viewer/resources/views/livewire/log-list.blade.php) at /var/www/vhosts/topoleiloes.com.br/httpdocs/storage/framework/views/1b6e4ae27ba0e61a057f2be9e60b9f03d350bd65.php:10)
Hey @Tiagospem
The first video shows installation of a different package :)
You can install this package with the command composer require opcodesio/log-viewer
Also the error Undefined variable $showLevelsDropdown is now different from the original one. I've released an update, v1.6.3 which hopefully fixes this error for you :) Let me know!
sorry, I confused the package installation :/, but the problem occurred with the correct package. Updated to the latest version, let's see, thanks
No problem @Tiagospem
Closing as it's potentially fixed. Let me know if there's still an issue with v1.6.3 version.