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

nyrsimon's avatar

Forge Deploy Issues

So I have taken the plunge and am trying out Forge. I have a Linode (Akamai) server.

I have the basic deployment working. I am on a subdomain app.notionpotion.io

I can load the basic site (think no data access) and navigate around - as soon as I try to do anything that is hitting something on the back end e.g. register or login, some errors are being thrown. I've looked the logs but must be missing something...It looks like it is hitting an exception but without an actual message getting passed but something funky is going on. I'm still learning here, so am hoping it is something obvious. Log data below

[2023-06-07 23:41:06] production.ERROR: Undefined property: App\Exceptions\Handler::$messages {"exception":"[object] (ErrorException(code: 0): Undefined property: App\Exceptions\Handler::$messages at /home/forge/app.notionpotion.io/app/Exceptions/Handler.php:66)
[stacktrace]
#0 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(250): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError()
#1 /home/forge/app.notionpotion.io/app/Exceptions/Handler.php(66): Illuminate\Foundation\Bootstrap\HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}()
#2 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(51): App\Exceptions\Handler->render()
#3 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(185): Illuminate\Routing\Pipeline->handleException()
#4 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(116): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
#5 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(175): Illuminate\Pipeline\Pipeline->then()
#6 /home/forge/app.notionpotion.io/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(144): Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter()
#7 /home/forge/app.notionpotion.io/public/index.php(51): Illuminate\Foundation\Http\Kernel->handle()
#8 {main}
"} 
0 likes
2 replies
Niush's avatar
Niush
Best Answer
Level 50

You most likely have some custom logic in app/Exceptions/Handler.php file. Paste that code here if possible.

You are accessing $messages somewhere there, incorrectly.

1 like
nyrsimon's avatar

@Niush Awesome you pointed me in the right direction. It worked in Dev but not on Forge and was due to the env variable (local vs production) there was some logic in there that I need to review Thanks for the swift reply!

Please or to participate in this conversation.