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

Unable to find component audits-relation-manager #30

Open
avinmaster opened this issue Aug 8, 2024 · 2 comments
Open

Unable to find component audits-relation-manager #30

avinmaster opened this issue Aug 8, 2024 · 2 comments

Comments

@avinmaster
Copy link

On clicking Restore button, Unable to find component: [tapp.filament-auditing.relation-managers.audits-relation-manager] error occurs.

@russdot
Copy link

russdot commented Nov 29, 2024

I'm having the same issue after a fresh installation and simply adding the Tapp\FilamentAuditing\RelationManagers\AuditsRelationManager relation manager to a model resource in Filament.

Navigating to the relation manager tab on the model resource causes the exception

Unable to find component: [tapp.filament-auditing.relation-managers.audits-relation-manager]

Seems related to Flare according to the stack trace... I'm not even using Flare. (Flare is appearing in the stack trace, but not the source of the component not found error..)

@russdot
Copy link

russdot commented Nov 29, 2024

After some further digging...

The exception occurs from Livewire\Mechanisms\ComponentRegistry->getNameAndClass method. Below is a snapshot of a debugging session.

// Notice how the argument to the function is as follows:
$nameComponentOrClass = "tapp.filament-auditing.relation-managers.audits-relation-manager";

// Which causes the first `is_subclass_of()` check to fail, which converts to a "class" name
$class = "\App\Livewire\Tapp\FilamentAuditing\RelationManagers\AuditsRelationManager";

// but this is not the correct namespace for the relation manager, so the check for class_exists() fails, which appends \\Index

//Finally the 2nd check for `is_sublass_of()` fails, causing ComponentNotFoundException to be thrown.

image

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

2 participants