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

anmol's avatar
Level 2

php artisan serve

i was working on user roles and after i wrote code i wanted to check my website but i am not able to start my project,this is happening for the first time .everytime i run the command php artisan serve my laptop freezes and everything hangs.i don't knw whats wrong.i have worked so hard on this project if anyone coould plz help me.127.0.0.1:8000 in't just working. plz anykind of help will be appreciated. i have worked really hard on this project.currently i am using ubuntu 16.10

0 likes
11 replies
anmol's avatar
Level 2
Document root is /opt/lampp/htdocs/laravel/blog/public
Press Ctrl-C to quit.
[Fri Mar  3 22:14:36 2017] PHP Fatal error:  Maximum execution time of 30 seconds exceeded in /opt/lampp/htdocs/laravel/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 647
[Fri Mar  3 22:14:36 2017] 127.0.0.1:43688 [500]: / - Maximum execution time of 30 seconds exceeded in /opt/lampp/htdocs/laravel/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 647
[Fri Mar  3 22:14:36 2017] 127.0.0.1:44354 [200]: /favicon.ico
[Fri Mar  3 22:14:36 2017] 127.0.0.1:44364 [200]: /favicon.ico
[Fri Mar  3 22:15:09 2017] PHP Fatal error:  Maximum execution time of 30 seconds exceeded in /opt/lampp/htdocs/laravel/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 647
[Fri Mar  3 22:15:09 2017] 127.0.0.1:44402 [500]: / - Maximum execution time of 30 seconds exceeded in /opt/lampp/htdocs/laravel/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 647```


anmol's avatar
Level 2

@primeordial this is what terminal shows,my prject is still not opening tho.do you have any idea about the error its talking about?

primordial's avatar

Not really :-( Appears to be referring to the IoC container. Have you be binding interfaces?

Try the usual

php artisan cache:clear
composer dumpautoload

To confirm; The command should be run from the application root folder.

anmol's avatar
Level 2

it hanged again.don't know what's happening,

clay's avatar

Sounds like you may have an infinite loop in your code. Some operation is taking too long. Are you using version control? It would be good if you could switch to another branch and test. You need some way to narrow down where the bad code is located. Is there any additional info in the laravel logs?

anmol's avatar
Level 2

Maximum execution time of 30 seconds exceeded in /opt/lampp/htdocs/laravel/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 647is the bad code located here??

anmol's avatar
Level 2

protected function findInContextualBindings($abstract) { if (isset($this->contextual[end($this->buildStack)][$abstract])) { return $this->contextual[end($this->buildStack)][$abstract]; } } this is the place line no 647 in container.php which it is pointing to,and i don't understand anything about this function and i have never messed with this file,i don't know why is it showing error???

anmol's avatar
Level 2

no i haven't tried valet.

Please or to participate in this conversation.