Flowscript

Full language reference

Where to find every Flowscript function, rule and error code, and the module catalog, in full.

These docs explain Flowscript by example. The full references are generated from the compiler and the module registry, so they're always current:

Error codes#

Errors are FS0xxx and stop a save; warnings are FS09xx and point at a line that probably doesn't do what it seems to:

CodeMeans
FS0901A condition that is never true (often a window that includes the bar it's compared with)
FS0902A while that buys at every bar, with no guard
FS0903A const nothing reads
FS0904A divide by zero
FS0905bps(n) used as a number, which is n, not n / 10000

Formatting#

ftw-trade fmt *.flow --write formats Flowscript files the way the editor does.