@quarks/theia-core
TypeScript icon, indicating that this package has built-in type declarations

1.0.15 • Public • Published

Theia - Core extension

Logging configuration

It's possible to change the log level for the entire Theia application by passing it the --log-level={fatal,error,warn,info,debug,trace} option. For more fine-grained adjustment, it's also possible to set the log level per logger (i.e. per topic). The root logger is a special catch-all logger through which go all messages not sent through a particular logger. To change the log level of particular loggers, create a config file such as

{
  "defaultLevel": "info",
  "levels": {
    "terminal": "debug",
    "task": "error"
  }
}

where levels contains the logger-to-log-level mapping. defaultLevel contains the log level to use for loggers not specified in levels. This file can then be specified using the --log-config option. Theia will watch that file for changes, so it's possible to change log levels at runtime by modifying this file.

It's unfortunately currently not possible to query Theia for the list of existing loggers. However, each log message specifies from which logger it comes from, which can give an idea, without having to read the code:

root INFO [nsfw-watcher: 10734] Started watching: /Users/captain.future/git/theia/CONTRIBUTING.md
^^^^ ^^^^  ^^^^^^^^^^^^^^^^^^^

Where root is the name of the logger and INFO is the log level. These are optionally followed by the name of a child process and the process ID.

License

Readme

Keywords

Package Sidebar

Install

npm i @quarks/theia-core

Weekly Downloads

1

Version

1.0.15

License

EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0

Unpacked Size

3.52 MB

Total Files

1056

Last publish

Collaborators

  • gabriel.campos
  • ademar.carneiro