Build and validation
Run commands from the repository root.
| Command | Purpose |
|---|---|
make deps | Check out the nseries commit pinned in nseries.ref at .deps/nseries (NSERIES_SRC overrides) |
make nseries-update | Move the nseries pin (REF= branch, tag or sha; default the head of nseries main) |
make marketfeed-adapter | Build bin/marketfeed-adapter from the marketfeed commit pinned in marketfeed.ref, against this checkout (MARKETFEED_SRC overrides) |
make marketfeed-update | Move the marketfeed pin (REF= as above) |
make build | Build engine, adapters, tools and Go strategies into bin/ |
make test | Go suites excluding legacy strategies/to-migrate, Python port tests and Rust tests |
make testdata | Derive fixtures from the committed MSFT trade sample |
make run | Run that sample through the Databento adapter and printbars |
make crosscheck | Compare smacross decision streams across available language toolchains |
make bench | Check data-path consistency and collect throughput measurements |
make proto | Regenerate Go protobuf bindings |
make doc | Build Algolang as docs/algolang.pdf using Pandoc and XeLaTeX |
make test-golden | Run build-tagged legacy parity checks against external archive data |
Strategy validation
Use the SDK replay seam to exercise real context and wire behavior with scripted init/bar/fill inputs. Cover warmup silence, an entry and near-miss, an exit after a fill, and each named regression that protects a correction. Use protobuf for multi-order and rich-symbol scenarios that CSV cannot encode. Selftests provide a smoke check, not a strategy correctness proof.
make crosscheck pins summation order, nseries crossover semantics and numeric wire grammar across Go and nine raw-CSV clients. Available toolchains must produce byte-identical order/noop streams from the same fixture.
Golden tests need the marketfeed archive and adapter. make test-golden builds bin/marketfeed-adapter from the pinned marketfeed first; GOLDEN_ADAPTER selects another binary instead. No other location is searched: the tests used to fall back to a hand-built /tmp/algobins/marketfeed-adapter, which a checkout at a different SHA picked up silently, so a missing pinned build now skips the run and names the path (GLE-354). The expprobe probe defaults to the same pinned build; EXPPROBE_ADAPTERS names any other. Besides the golden masters it runs TestGoldenServedSeamReason (GLE-287), which asserts that a served degraded seam’s reason reaches the run (fut:XCME:CHF’s 2014 M14->U14 seam, reason temporal); it fails against an adapter older than marketfeed GLE-281. They are excluded from ordinary make test. Tests for reporting calculations can replay the checked-in blotters independently through internal/goldentest/perfreplay.go.
Maintenance rules
- Preserve process-local buffered readers across the handshake and message loop; flush each response so both peers can make progress.
- Keep strategy stdout exclusively for the wire protocol.
- Preserve deterministic bar ordering, series identity, raw execution prices and the adjusted signal frame. Negative futures prices are valid; nonfinite prices and negative volume are not.
- Keep cache keys aligned with every input that changes served bars. Bump construction semantics versions when a changed policy changes built series.
- Keep protobuf conversions symmetric, including the SDK’s mirrored converters; use existing round-trip and wire tests when adding fields.
- Preserve
--report offbehavior and isolate benchmark fetches from trading. - Document supported behavior here when code lands; remove completed task briefs instead of leaving a second, contradictory feature specification.