Output, logs and run history
A green status says the script finished; it does not say it did the right thing. The answer is in what main returned — the Output — and, when something looks off, in what it printed — the Logs. Both are kept with every run, so you can come back to a run from last week and read exactly what happened.
- Read the Output as JSON or as a table
- Use logs for diagnosis, never as the result
- Find a run again in Run history and on the Runs page
Output is the answer, logs are the story
The Output is the value main returned (in C and C++, the JSON passed to waiso_set_result / waiso::setResult). It is what a flow’s next step receives, what an API caller gets back and what the Runs page stores. The Logs are everything the script printed — print, console.log, printf — plus system lines such as start and finish, each with a time and a level.
Read the last run
- Check the Output
Run
daily-reportagain and stay on Output. The result is shown as formatted JSON; the toolbar switches between JSON view and Table view, and offers Copy JSON, Download JSON and an expand button for long results. The duration beside it runs from the worker claiming the job to the result. - Read the Logs
Open Logs. You see
3 scores, 2 passedbetween the system lines. Filter by level or use Search logs when a run prints a lot. - Find it on the Runs page
Click Runs in the left column. Your run is the top row: daily-report, Triggered by your e-mail, its Duration, Ran at and a Success status. Click the row: a drawer opens with its Data (inputs and output), Logs and the Code that ran.
Return structure, get a table
Return data, not sentences. An object or a list of objects can be read field by field by a flow, filtered on the Runs page and shown as a table. A list of objects opens straight in Table view, with a search box, sortable columns and a CSV export. Change daily-report to return one row per score:
export async function main(passing: number = 80) {
const scores = [85, 92, 78]
const rows = scores.map((score, i) => ({ student: i + 1, score, passed: score >= passing }))
console.log(`${rows.filter((r) => r.passed).length} of ${rows.length} passed`)
return rows
}| # |
|---|
Two places to find a run
| What | Run history (editor) | Runs page |
|---|---|---|
| Shows | This script’s runs | Every run of the project: scripts, flows, scrapers, from any trigger |
| Best for | Going back to a run while you edit | Seeing what ran, when, and why it failed |
| Actions | Open this run (its code and output), Restore inputs | Filter by status, kind, dates, text and input values; open the drawer |
Viewing an old run
Opening a run from Run history puts the editor in Viewing history: the code shown is the code that ran then, and the Output is that run’s. Back to current returns to your draft. Restore inputs copies that run’s values into the Inputs card, which is the quickest way to reproduce a failure.