Where to find this Client.php laravel
Asked Answered
T

2

6

I upgraded my php version in WSL to 7.4 and I am running an application built with laravel-5.5.

When I run php artisan in the command line I got this error

In Client.php line 1551:

Undefined variable: version

There are many $version available where do I find this Client.php this error talking about?

There is no log record in the log about this.

Thanks

Trochee answered 3/12, 2019 at 10:42 Comment(1)
It's the sentry error if you are using it too...Trochee
T
8

To do solve this temporarily I did this

return $version ?? '0.0.0';

on vendor\sentry\sentry\lib\Raven\Client.php:1551

and change $path{0} to $path[0]

on vendor\sentry\sentry\lib\Raven\Client.php:331

Trochee answered 3/12, 2019 at 19:52 Comment(4)
Worked for Laravel 5.6 with php 7.4Humdrum
but it is not the proper solution. Can't modify vendor files that way!Tartrate
I am saying temporarily.. I am not recommending itTrochee
Not unless sentry update there code, when running composer update you need to do this again, not unless there's other way like extendingTrochee
L
0

After Update composer Issue has been gone. PHP Version : 7.4 and Laravel Version : 5.4

Last answered 13/9, 2024 at 5:38 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.