Free From

Free From reads a folder of source code and prints an allergen-style label of what the text contains, what it found none of, and what it could not read. It reads JS/TS, Python, Go and Rust files by text pattern, with comments removed and strings kept, in six categories: network access, file writes, subprocess calls, environment reads, telemetry libraries, and code built at run time. It never runs, installs or sends anything. Run it with uv run free_from.py path/to/folder (no argument reads the current folder), uv run free_from.py --patterns to print the exact pattern table in use, and uv run python test_free_from.py for the checks. It needs Python 3.10 or newer and nothing else. The input is any real folder on your machine: a repo you just cloned, something in your downloads folder, your own checkout, or a language's installed standard library.

The limit

Line 1 of every label is Text patterns only. Code built at run time is not seen. That is the whole method and its whole limit. A call assembled from strings, loaded from a file or fetched at run time is invisible to a text scan, so the label counts the lines that could do that ("Built at run time") and the files it could not read ("Not examined"). If either number is above zero, every "None found" row ends with * and a footnote says why. "None found" is the most the label will ever say. It gives no verdict, no score and no grade.

Reading the label

Text patterns only. Code built at run time is not seen.
================================================================
FREE FROM                                              <folder>
================================================================
Lot <8 hex>                                 Scanned <YYYY-MM-DD>
Searched: <files>, <lines>
Not examined: <files> (<reasons>)
Not read: <files> (<top five extensions>)
Dependencies not read: <skipped folders>
________________________________________________________________
Built at run time       <count>   <first file:line>
________________________________________________________________
CONTAINS
  <category>            <count>   <first file:line>
FREE FROM
  <category>            None found (<files>, <lines>) *
* <why the asterisk>
________________________________________________________________
Not examined
  <path>
    <reason>  <licence banner, if the file kept one>
________________________________________________________________
Standard library by: <how each language's list was made>.
May contain traces of: <standard-library modules imported>.

A count is a number of matching lines. The location is the first one in sorted path order. The Lot is a hash of every source file's path and bytes, so the same folder always gets the same lot, whatever the date. Files over 2 MB, binary or non-UTF-8 files, files with a line over 1000 characters (most minified bundles) and files that cannot be opened are listed under Not examined and never counted as searched. The folders .git, node_modules, target, vendor, .venv, venv, __pycache__ and *.dist-info are skipped and named. Symbolic links are not followed. Colour appears only on a true-colour terminal (COLORTERM=truecolor) with NO_COLOR unset; piped output is plain text.

The pattern table

The patterns are regular expressions in free_from.py, one table per category per language. They over-report on purpose: a pattern inside a string or a docstring counts, and a / that might open a JS regex keeps the rest of its line. They will also miss things a person would catch. If a pattern is wrong, edit the regex and keep the category. Known gaps, stated on purpose: template-literal ${} nesting is not parsed, a Python import continued with a backslash is read as its first line only, an import after a semicolon is not seen, and a folder that cannot be opened is skipped without a mention. Line numbers follow Python's splitlines, which also breaks at form feed and the Unicode line separators. The Node builtin list is a dated constant (Node 22, written down 2026-10-14) and will age; --patterns prints its date.

Colophon

One file, the standard library, a sorted walk, some regular expressions and a hash. Printed on cream, ink only, rules in = and _. Contents may settle during transport.

normal is dead

Files