Files
marqdo/lib/log.mq.md
T
cflmyandCursor fecaacd5be docs(lib): narrate remaining stdlib modules (M2)
Add module intros and per-function purpose lines across EN/ZH libs, with
callable examples on the smaller modules; keep + params and host bodies intact.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-14 11:47:35 +08:00

1.1 KiB

title, description
title description
lib/log Level-filtered one-line logs (Mid M6 + Mid2 M10 fields). Default level info.

Level-filtered one-line logs (Mid M6 + Mid2 M10 fields). Default level info.

set_level

+ `level`

level is debug / info / warn / error.

> host_log_set_level level=level

debug

+ `text`
+ `fields`=None

Emit a debug log line; optional fields map.

line = > host_log_line level="debug" text=text fields=fields

  1. line

print text=line


info

+ `text`
+ `fields`=None

Emit an info log line; optional fields map.

line = > host_log_line level="info" text=text fields=fields

  1. line

print text=line


warn

+ `text`
+ `fields`=None

Emit a warn log line; optional fields map.

line = > host_log_line level="warn" text=text fields=fields

  1. line

print text=line


error

+ `text`
+ `fields`=None

Emit an error log line; optional fields map.

line = > host_log_line level="error" text=text fields=fields

  1. line

print text=line