Plugin Logs
Canvas provides two ways to access Plugin Logs:
- UI:
https://<your-instance>.canvasmedical.com/admin/plugin-io→ Logs - CLI:
canvas logs --help
This guide explains how to open the UI view and how to use the CLI to filter, paginate, and (optionally) follow live logs.
Plugin Logs in the Admin UI #
From the Django Admin:
Navigation path:
Home › Plugin_IO › Plugin Logs
The UI lets you:
- Filter by source (e.g.,
plugin-runner,effect-interpreter) - Filter by level (
ERROR,WARN,INFO,DEBUG) - Filter by time (start/end)
- Inspect full JSON of a log entry in a modal
- Load more results without leaving the page
CLI Overview #
canvas logs now supports historical lookback, filters, stateless pagination with cursors, and interactive paging, all without breaking the original behavior.
- Default (no flags) → live stream (unchanged)
- Add a time window → fetch history (tail), then follow by default
- Stop after history →
--no-follow - Page through large result sets →
--limit,--page-size,--interactive, or cursor tokens
Run canvas logs --help to see all options.
Common Filters & Examples #
Filter by source #
$ canvas logs --source plugin-runner
Filter by level (repeat flag) #
# Only errors:
$ canvas logs --level ERROR
# Errors and warnings:
$ canvas logs --level ERROR --level WARN
Time windows: since / start / end #
Relative lookback (--since)
Fetch the last 24 hours, then continue following:
$ canvas logs --since 24h
Absolute window (--start/--end)
Fetch a fixed window and stop:
$ canvas logs --start "2025-09-12T10:00:00Z" --end "2025-09-12T12:00:00Z" --no-follow
Combine filters #
# Errors from plugin-runner in the last 2 hours:
$ canvas logs --since 2h --level ERROR --source plugin-runner --no-follow
Interactive Mode #
Use --interactive in historical mode to page through results one page at a time:
$ canvas logs --no-follow --since 24h --interactive
# Shows one page, prompts:
# Load more? [Y/n]
- The prompt repeats after each page.
Stateless Paging with Cursors #
When more results are available, the CLI prints a resume command with a cursor token (encodes the search_after and original filters). Re-run it to continue exactly where you left off:
More available. To load the next page, run:
canvas logs \
--no-follow \
--cursor <TOKEN>
.
Limits & Page Size #
--page-size: how many logs to fetch per request (batching).
Default is optimized for typical usage.--limit: maximum number of logs to print across pages.
Examples:
# One fixed page of size 200 (default page-size):
$ canvas logs --no-follow --since 24h
# Fetch up to 2000 logs across pages (non-interactive):
$ canvas logs --no-follow --since 72h --limit 2000
# Smaller batches for slow connections:
$ canvas logs --no-follow --since 24h --limit 1000 --page-size 100
No-Follow (Historical Only) #
Add --no-follow to fetch only historical logs and exit:
$ canvas logs --no-follow --since 24h