Logging#

The OneTick engine log uses the OneTick tick-server line shape:

<YYYYMMDDHHMMSS> <LEVEL>: worker <pid>:<message>

The PID attributes each line to the server process. The current launcher is single-process; the worker label is retained for compatibility with existing OneTick log tooling.

The KX launcher separately writes its operational and audit stream to stderr in the launcher’s own format. The OneTick engine handlers write engine messages to stdout and, when LOG_TO_FILE=true, to the dated file described below. The dated file also receives selected launcher lifecycle and audit messages so it can be used as a combined operational record.

Daily file rotation#

LOG_UTC (default true) controls both the timestamp timezone and the date boundary used for the daily file rollover. Set LOG_UTC=false to use local time for both.

The log directory (LOG_DIR, default ./logs) is created on startup if it does not exist. The server fails fast if the directory cannot be created or written to.

Log files are named:

<LOG_DIR>/<LOG_FILE_PREFIX>.<YYYYMMDD>.log

for example ./logs/onetick-mcp.20260701.log. A new file is opened when the date rolls over; restarts on the same day append to the existing file, and files are never renamed or deleted.

uvicorn integration#

When file logging is enabled, uvicorn.error (startup, shutdown, and error messages) is also routed to the file. uvicorn.access (per-request lines) is deliberately left on stdout only.

Configuration variables#

For the full list of logging environment variables, see Logging variables in the configuration reference.