• [Python-announce] [ANN] notebookproof 0.3.0 - preflight checks for Jupyter notebooks and pandas/Polars DataFrames

    From Scott Campbell@[email protected] to comp.lang.python.announce on Sat Oct 10 16:59:25 2026
    From Newsgroup: comp.lang.python.announce

    notebookproof 0.3.0 is available on PyPI.

    notebookproof is a small MIT-licensed package that you call from a notebook cell before you share a notebook or report a number from it.

    - check(path) reads a saved .ipynb without executing it and reports likely missing or forward references, syntax errors, saved execution errors,
    missing or out-of-order execution counts, possibly stale outputs, star
    imports, notebook commands, and some random calls with no visible earlier
    seed.
    - check(path, run=True), with the optional [verify] extra, also runs the
    saved notebook in a fresh kernel using nbclient, reports the first failing cell, and compares each cell's fresh output with its saved output. Cells
    that could not be compared are listed. verify(path) runs the same execution
    and comparison on its own.
    - frame(df) checks an eager pandas or Polars DataFrame for missing values, mixed value types, repeated rows, declared-key duplicates, constant
    columns, numeric outliers, infinite values, identical columns and strong correlations. You can also declare per-column rules (nullable, unique, min, max); violations show counts and affected row positions. It does not modify
    the data.
    - save_report(report, path) writes a standalone local HTML summary without source code, raw outputs or data values.

    New in 0.3.0: fresh-run output comparison, declared DataFrame rules, the
    HTML report, and a quieter default display (informational findings are
    shown with details=True). If you upgrade in a notebook where an older
    version is already imported, restart the kernel.

    check() without run=True is static analysis and does not prove that a
    notebook is reproducible. A fresh run executes the saved code with your
    normal permissions, so it is not a sandbox, and matching outputs do not
    prove the analysis is correct.

    Install: pip install notebookproof
    For fresh-kernel runs: pip install "notebookproof[verify]"
    Requires Python 3.9 or newer. No required dependencies.
    Source: https://github.com/scottcampbelldata/notebookproof
    PyPI: https://pypi.org/project/notebookproof/

    Scott Campbell
    --- Synchronet 3.22a-Linux NewsLink 1.2