Open tontonAurel opened 5 years ago
I also have the same problem after updating from 1.0.7 to 1.0.8
Use redis for caching as described in the config file:
/* | -------------------------------------------------------------------------- | Cache Tags |
---|---|---|
Cache tags are not supported when using the file or database cache | ||
drivers in Laravel. This is done so that only locations can be cleared. | ||
*/
Yes, i'm agree with you but it's minor update (from 1.0.7 to 1.0.8), it should not break the application since we didn't change anything else
I have a same issue, no matter what I try It doesn't work. I'm using Laravel 5.7 and geoip 1.0.8
Agreed, I have cache set to none and it still happens.
Edit:
cache => 'none',
cache_tags => null,
Seems to work.
Change your Cache driver to 'array' in .env
I had commented out the cache_tags line when I first installed the package a year ago for this exact reason, and it's been working fine with file-based caching.
//'cache_tags' => ['torann-geoip-location'],
This update broke it. So what specifically changed is that now cache_tags
defaults to on instead of off. Instead of commenting out that line, you now need to explicitly set cache_tags to false or null, like @rappasoft said.
'cache_tags' => false,
Edit: Just to clarify, you can leave caching on and set tags to off. The only thing cache_tags does is make it possible to clear the geoip cache without touching anything else that has been cached.
'cache' => 'all',
'cache_tags' => false,
'cache_expires' => 30,
This is how I fixed the problem
Open up config/geoip.php
-[ ] Change the service to 'maxmind_database' -[ ] Change the cache tags to a more dynamic method of handling the environment.
Setup the service
service' => 'maxmind_database',
Change the Cache Tags
'cache_tags' => env('CACHE_DRIVER', 'array') === "file" ? null : ['torann-geoip-location'],
Don't forget to run php artisan config:cache
after editing config/geoip
When updated torann/geoip from 1.0.7 to 1.0.8 i got this error :
This cache store does not support tagging
. I use file as cache driver and my version of laravel is 5.6.38