Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conflict with Spatie Schemaless #460

Open
n3storm opened this issue Mar 11, 2024 · 0 comments
Open

Conflict with Spatie Schemaless #460

n3storm opened this issue Mar 11, 2024 · 0 comments

Comments

@n3storm
Copy link

n3storm commented Mar 11, 2024

Describe the bug
ErrorException when using with Spatie Schemaless

This is due to trait ModelCaching also defines __get function as SchemalessAttributes on line 51

https://github.com/spatie/laravel-schemaless-attributes/blob/main/src/SchemalessAttributes.php#L51

Stack Trace

  Trait method GeneaLabs\LaravelModelCaching\Traits\Cachable::__get has not been applied as Modules\Dossiers\Models\Dossier::__get, because of collision with Spatie\SchemalessAttributes\SchemalessAttributesTrait::__get

  at Modules/Dossiers/Models/Dossier.php:40
     36▕ use Venturecraft\Revisionable\RevisionableTrait;
     37▕ use Wildside\Userstamps\Userstamps;
     38▕ use GeneaLabs\LaravelModelCaching\Traits\Cachable;
     39▕ 
  ➜  40▕ class Dossier extends Model implements HasMedia, PresentableInterface
     41▕ {
     42▕     use Archivable;
     43▕     use BaseModelContract;
     44▕     use Filterable;

      +1 vendor frames 

  2   [internal]:0

Environment

  • PHP: 8.3
  • OS: Debian
  • Laravel: 10 latest up to date
  • Model Caching: 11.0.0 just installed

Additional context
Not sure if this is solvable. Please add to Possible Package Conflicts documentation section.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant