Skip to content

bugfix/refactor: Logging and error handler improve#8562

Open
littleboobs wants to merge 3 commits intoss220-space:master220from
littleboobs:debug
Open

bugfix/refactor: Logging and error handler improve#8562
littleboobs wants to merge 3 commits intoss220-space:master220from
littleboobs:debug

Conversation

@littleboobs
Copy link
Contributor

@littleboobs littleboobs commented Mar 3, 2026

Первоначальный ПР - #8369

Что этот ПР делает

  1. Починка логирования рекурсий.
  2. Починка stack_traces, который не давал вывода, потому что сам рантаймил.
  3. Замена всех log_runtime(EXCEPTION()) на stack_traces и CRASH.
  4. Логирование "ошибок" шаттлов заменены на WARNING. Часть из них я уже заменял раннее, когда портировал юнит тесты, потому что они совершенно бессмысленно рантаймили. Локалка на фастлоуде больше не засирается 7 рантаймами с нулевой.
  5. PREFTOGGLE_CHAT_DEBUGLOGS добавлен в дефолт список префов.
  6. GLOB.Debug2 и GLOB.Debug1 объединены в GLOB.debugging_enabled

После восстановления:

@github-actions github-actions bot added the Merge Conflict PR содержит изменения, конфликтующие с master-веткой. label Mar 3, 2026
@github-actions github-actions bot removed the Merge Conflict PR содержит изменения, конфликтующие с master-веткой. label Mar 3, 2026
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the logging and error handling system, replacing log_runtime(EXCEPTION(...)) with stack_trace() and CRASH() to enhance stability and debugging. While the refactoring is well-executed, a critical security vulnerability exists in the law_manager.dm module where player-controlled silicon mobs can introduce Stored Cross-Site Scripting (XSS) via raw HTML input. The log_world proc also presents a risk of Log Injection and XSS due to its use of html_decode before logging. Additionally, consider refactoring duplicated code in code/datums/spawners_menu.dm:54-57 for improved readability and maintainability.

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