Closed marechenok closed 3 years ago
@marechenok please provide the full stack trace.
It seems, that it is declaration incompatibility with your package laravel-pivot-events 'Trait method 'newBelongsToMany' will not be applied, because it collides with 'ExtendRelationsTrait' - that's what i see in phpstorm errors reporting.
But i don't use belongsToMany at this project, so can't give you full stacktrace.
I've this error only on staging env while running tests in CI/CD pipeline, so I can't give you any traces. Downgrade to 0.10.1 fixes problem for now.
So at this point I'm not sure where this error is being seen. All the unit tests are passing. If you are seeing this in PHPStorm, this is a bug there: #354. I will close this for now, as I am unable to recreate with the information given. If you are able to provide more information, please do respond here and I will re-open if I am able to recreate the issue.
Describe the bug WIth php 7.4 got this error, 7.3 seems ok. Php 7.4 with 0.10.1 --> ok
Eloquent Query Try using any model with Cachable trait.
Stack Trace
Could not check compatibility between GeneaLabs\LaravelModelCaching\Traits\Cachable::newBelongsToMany(GeneaLabs\LaravelModelCaching\EloquentBuilder $query, Illuminate\Database\Eloquent\Model $parent, $table, $foreignPivotKey, $relatedPivotKey, $parentKey, $relatedKey, $relationName = NULL) and Illuminate\Database\Eloquent\Model::newBelongsToMany(Illuminate\Database\Eloquent\Builder $query, Illuminate\Database\Eloquent\Model $parent, $table, $foreignPivotKey, $relatedPivotKey, $parentKey, $relatedKey, $relationName = NULL), because class GeneaLabs\LaravelModelCaching\EloquentBuilder is not available
Environment