Skip to content

proposal: Script Diagnostics and Profiling Commands #11

Description

@PyXiion

Problem

When a script fails during loading or runs slowly, it is difficult to identify the responsible file, handler, module, or line of code.

Proposal

Add administrative diagnostics for scripts and modules.

Possible commands:

/ignis scripts
/ignis modules
/ignis errors
/ignis profile

The diagnostics should expose:

  • Loaded, failed, and disabled scripts.
  • Module/package names and source paths.
  • Lua stack traces with source lines where possible.
  • Load and reload errors retained until cleared or replaced.
  • Handler execution time and slow-handler warnings.
  • Basic execution counts and cumulative time.

Initial scope

  • Start with script/module status and useful stack traces.
  • Add profiling behind an explicit command or configuration option.
  • Avoid collecting expensive timing data permanently.
  • Keep output readable in the server console and in-game for operators.

Open questions

  • Should profiling be per script, module, event, or command?
  • Should diagnostic history survive a reload?
  • What threshold should trigger a slow-handler warning?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions