osmose.feedback

Feedback store + token check (pure core — no web/UI imports).

Bug reports / suggestions submitted from the Shiny UI are appended as JSON lines to FEEDBACK_FILE (overridable via OSMOSE_FEEDBACK_FILE). A token-gated read endpoint in app.py serves them back to a maintainer. Mirrors the repo’s JSON-on-disk convention.

Functions

append_feedback(record, *[, path])

Append one record as a JSON line (creates parent dir; POSIX flock; single-worker safe).

build_feedback_record(type, message, *[, ...])

Validated feedback record.

check_feedback_token(provided)

Constant-time token check; total (never raises).

read_feedback(*[, path])

All records newest-first; missing file -> []; corrupt lines skipped (path resolved lazily).