mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-19 23:33:13 +09:00
Log the message of an instance start error without a stack (#1066)
HostRouter.wakeInstance() logged err.stack, which RequestError leaves undefined, so a failed start was logged as "Error starting instance: undefined" and the reason, such as no game port left in the range, was lost. Claude-Session: https://claude.ai/code/session_01F7obMEi4L4PzUQ8w8q9Uyz Co-authored-by: ILLISIS <jayson.harris01@gmail.com> Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2 files changed
+30
-2
No files matched your search
@@ -218,7 +218,7 @@ export class HostRouter {
|
||||
this.host._connectInstance(dst.id).then(instanceConnection => {
|
||||
instanceConnection.connector.forward(message);
|
||||
}).catch(err => {
|
||||
logger.error(`Error starting instance:\n${err.stack}`, this.host.instanceLogMeta(dst.id));
|
||||
logger.error(`Error starting instance:\n${err.stack ?? err.message}`, this.host.instanceLogMeta(dst.id));
|
||||
origin.connector.sendResponseError(
|
||||
new lib.ResponseError(err.message, err.code, err.stack), message.src
|
||||
);
|
||||
|
||||
Reference in new issue
Block a user