@typeberry/jam 0.0.5-6e657f4 → 0.0.5-ab52154

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12970,7 +12970,6 @@ const GLOBAL_CONFIG = {
12970
12970
  */
12971
12971
  class Logger {
12972
12972
  moduleName;
12973
- fileName;
12974
12973
  config;
12975
12974
  /**
12976
12975
  * Create a new logger instance given filename and an optional module name.
@@ -12983,7 +12982,8 @@ class Logger {
12983
12982
  */
12984
12983
  static new(fileName, moduleName) {
12985
12984
  const fName = fileName ?? "unknown";
12986
- return new Logger(moduleName ?? fName, fName, GLOBAL_CONFIG);
12985
+ const module = moduleName ?? fName;
12986
+ return new Logger(module.padStart(8, " "), GLOBAL_CONFIG);
12987
12987
  }
12988
12988
  /**
12989
12989
  * Return currently configured level for given module. */
@@ -13020,9 +13020,8 @@ class Logger {
13020
13020
  const options = parseLoggerOptions(input, defaultLevel, workingDir);
13021
13021
  Logger.configureAllFromOptions(options);
13022
13022
  }
13023
- constructor(moduleName, fileName, config) {
13023
+ constructor(moduleName, config) {
13024
13024
  this.moduleName = moduleName;
13025
- this.fileName = fileName;
13026
13025
  this.config = config;
13027
13026
  }
13028
13027
  /** Log a message with `INSANE` level. */
@@ -18355,7 +18354,7 @@ class GeneratorReady extends State {
18355
18354
 
18356
18355
 
18357
18356
 
18358
- const block_generator_logger = Logger.new(import.meta.filename, "block-generator");
18357
+ const block_generator_logger = Logger.new(import.meta.filename, "generator");
18359
18358
  if (!external_node_worker_threads_namespaceObject.isMainThread) {
18360
18359
  Logger.configureAll(process.env.JAM_LOG ?? "", Level.LOG);
18361
18360
  const machine = generatorStateMachine();