Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Raido's avatar
Level 2

Statement with non-compound name 'Request' has no effect

I get this error ''' The use statement with non-compound name 'Request' has no effect''' when I run php artisan command. It worked few days ago. But I have touched several classes and controllers etc. So I am a bit lost were to look exactly for the cause.

Suggestions are highly welcomed!

0 likes
5 replies
Raido's avatar
Level 2

Request is common to almost all created classes... guess I have to start commenting out and see where it hits the nerve... Thank you, @tomi for the link. Do you know is there a way to see were exactly error is generated? Terminal in a way is a black box ;)

Snapey's avatar
Snapey
Best Answer
Level 122

Check the laravel logs. It should contain the controller and line number concerned

1 like
Raido's avatar
Level 2

Such a logical thing to do.... I found the error in one of the controller functions. Shame on me and thank you @Snapey!

Snapey's avatar

I only know because I have done the same myself!

1 like

Please or to participate in this conversation.