Skip to content

Do not cause unrelated exception when throwing Error object in environment without debug module#1488

Merged
Perryvw merged 1 commit intomasterfrom
throw-no-debug
Sep 23, 2023
Merged

Do not cause unrelated exception when throwing Error object in environment without debug module#1488
Perryvw merged 1 commit intomasterfrom
throw-no-debug

Conversation

@Perryvw
Copy link
Copy Markdown
Member

@Perryvw Perryvw commented Sep 23, 2023

This was reported in the discord.

Some environments remove the debug module for various reasons such as security. In that case throwing an Error object should just contain an undefined stack trace.

Currently we try to get the stacktrace anyway and it is throwing a nil indexing exception in the Error constructor, that has been corrected in this PR.

@Perryvw Perryvw merged commit df3adb7 into master Sep 23, 2023
@Perryvw Perryvw deleted the throw-no-debug branch September 23, 2023 15:47
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

Successfully merging this pull request may close these issues.

1 participant