code wiki / (root) / nx_mediaflow.nx

nx_mediaflow.nx

buildroot/runtime/nx_mediaflow.nx

8783 B163 linesdepth 5pulls 10 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_mediaflow.nx -- aesthetictwin AT36 (2026-09-17): SUBMIT MEDIA, GET A VERIFIED REPORT, ONE CALL. The repeatable work of judging a media file was five hand steps; this organ is the one step. It validates the inputs at the boundary, makes the report directory, picks the media's own row out of an oracle file when one is given, compiles the workflow to plan rows (nx_mediaflow_lib), seeds them into the plan plane under the plane lock, runs the estate's own plan executor over them, prints every step's result and ends with ONE receipt line carrying the live URL and the verdict. The 1-2-3: (1) the media is on the estate (put door, vault capture, a fetch), (2) nx_mediaflow submit, (3) open the URL. nx_mediaflow submit <slug> <file> [oracle-file|-] [real|gen] -> MEDIAFLOW receipt (last line) nx_mediaflow plan <slug> <file> [oracle-file|-] [real|gen] -> the compiled plan rows, nothing seeded or run exit: 0 published and verified | 1 the plan failed (read the step rows) | 2 usage or a refused input | 3 the plan plane refused the seed | 4 the plan executor could not be run license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 5 imports · 0 importers

nx_syscalls.nx nx_itoa_lib.nx nx_store_seed_lib.nx nx_deploy_lib.nx nx_mediaflow_lib.nx nx_mediaflow.nx

imports: nx_syscalls.nxnx_itoa_lib.nxnx_store_seed_lib.nxnx_deploy_lib.nxnx_mediaflow_lib.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main mw_usage mw_puts sys_write mw_refuse mw_puts ↻ sys_mmap nxa_die sys_write ↻ sys_exit nxa_lock_take nxa_lock_addr sys_write ↻ nxa_lock_give nxa_lock_addr ↻ nxa_report_overrun sys_write ↻ nxa_dump_printable sys_write ↻ nxa_dump_sizes sys_write ↻ mf_cat sys_write ↻ mw_puts ↻ mw_oracle_word nxi_out nxi_fd sys_mmap ↻ ccz_cat_num nxi_buf sys_write ↻ sys_munmap sts_lock sts_mm sys_mmap ↻ sts_werr sys_write ↻ sys_exit ↻ ss_cat sys_openat_append

structs

none

consts

18const MW_EXIT_PLAN_FAILED: i64 = 1
19const MW_EXIT_USAGE: i64 = 2
20const MW_EXIT_SEED: i64 = 3
21const MW_EXIT_RUNNER: i64 = 4
22const MW_ARGC_MIN: i64 = 4
23const MW_ARGC_ORACLE: i64 = 5
24const MW_ARGC_KIND: i64 = 6
25const MW_ARG_VERB: i64 = 1
26const MW_ARG_SLUG: i64 = 2
27const MW_ARG_FILE: i64 = 3
28const MW_ARG_ORACLE: i64 = 4
29const MW_ARG_KIND: i64 = 5
30const MW_RUNNER_ELF: *u8 = "./nx_plan_run.elf"
31const MW_CAPTURE_PRE: *u8 = "/tmp/nx_mediaflow_"
32const MW_DRY_ORACLE: *u8 = "/tmp/nx_mediaflow_plan.oracle"
33const MW_ORACLE_PICKED: i64 = 1
34const MW_ORACLE_NONE: i64 = 0
35const MW_ORACLE_NOT_GIVEN: i64 = 2
36const MW_I64: i64 = 8
37const MW_RC_NOEXEC: i64 = 127 // the child could not exec the plan executor (dep_run_capture's own convention)

functions

39func mw_puts(s: *u8) -> i64 { sys_write(1, s, cr_slen(s)); return 0 }
called by 3: mw_usagemw_refusemain calls 1: sys_write
40func mw_usage() -> i64
called by 1: main calls 1: mw_puts
44func mw_refuse(rule: *u8, value: *u8, why: *u8) -> i64
called by 1: main calls 1: mw_puts
50func mw_has(buf: *u8, n: i64, needle: *u8) -> i64
called by 1: main calls 1: cr_eq
60func mw_oracle_word(state: i64) -> *u8
called by 1: main
67func main(argc: i64, argv: **u8) -> i64