Skip to content

9.4: documentation for both objects, in Max's own system and the ReadMe - #49

Merged
tap merged 2 commits into
mainfrom
v2/docs
Oct 10, 2026
Merged

tap merged 2 commits into
mainfrom
v2/docs

Conversation

@tap

@tap tap commented Oct 10, 2026

Copy link
Copy Markdown
Owner

Plan item 9.4 (docs/TAP-PYTHON-PLAN.md).

What's added

  • ReadMe
    • A new section, Objects without audio: tap.python. It covers loading, the output table, outlets and the dumpout, messages and anything, and the threads and their limits.
    • The intro and the install steps now point to the Overview, the help files and the Documentation window.
  • Reference pages
    • docs/tap.python.maxref.xml, written by hand because a plain SDK class has no generator.
    • See-also links both ways. tap.python~'s link comes from MIN_RELATED, and its page is Max's own rewrite.
  • Documentation window (Package Docs › PythonTap):
    • a package topic, in docs/topics/;
    • the guide Writing Max Objects in Python, in docs/vignettes/;
    • three tutorials with their patchers, in docs/tutorials/pythontap-tut/: a gain per sample and per vector, a filter with prepare(), and an object without audio.
  • Help patchers, in tabs
    • tap.python: basic, lists, outlets, messages, threads and ?.
    • tap.python~: basic, numpy, allpass, mc. and ?. Its old single page overlapped its own objects, so the basic tab was rebuilt.
  • PythonTap Overview in extras/: listed in the Extras menu and set as the package's home patcher.
  • scripts/check-docs.py, run in CI. It checks that the pages are well-formed XML with the right root element, that every link resolves, and that every patcher's patch cords connect real boxes and inlets.

A bug the docs found: mc.tap.python~ was "No such object"

  • Cause: Max wraps an external in mc. through an init/ mapping; Max's own init/ maps mc.cycle~ this way. The package had no such mapping, so the ReadMe's "wrap the object in mc." didn't work.
  • Fix: init/tap.python.txt now maps mc.tap.python~ to Max's MC wrapper around tap.python~. assemble-package.py fails a package that lacks the line.
  • Test: a runtime test pins it: it fails 8 checks without the line and passes all 10 with it. It checks two instances, setvalue 2 gain 0.1 reaching one instance, applyvalues gain 0.5 0.25 giving each its own value, and setvalue 1 float 0.75 calling a method.
  • Limit: a plain gain 0.5 sent to the wrapper is not understood. A class's attributes and messages belong to each instance, so the wrapper only forwards them through setvalue and applyvalues. The ReadMe and the help say so.

Checked in Max 9.1.5 on macOS

  • Every page and patcher opened, and every help tab clicked through.
  • Tutorial 3's patcher ran: the metro gave euclid's rhythm, a key gave note_name's C# and 4, and scale returned its list.
  • The Documentation window lists the topic, the guide and the tutorials under Topics, Guides and Tutorials. This answers 9.0's open question.
  • A tutorial's Open Tutorial button opens its patcher.
  • The Overview is in the Extras menu.
  • tap.python is listed as a reference page, not an object, because it has no file of its own. Max lists its own init-mapped objects (mc.abs~) the same way.
  • Every runtime test passes.

Not done here

  • Windows: these docs haven't been checked in Max on Windows yet. That happens at 9.6.
  • Performance tables: the ReadMe's tables aren't regenerated (the machine wasn't idle). That also happens at 9.6, and adds the measured tap.python message sentence.

🤖 Generated with Claude Code

https://claude.ai/code/session_019rVV9SkjkWmiBXFMT4whkz

tap and others added 2 commits October 9, 2026 20:07
The ReadMe gains "Objects without audio: tap.python" — loading, the output table, outlets and the
dumpout, messages and anything, the threads and their limits — and points the reader to the
Overview, the help files and the Documentation window. For that window: tap.python's reference page,
by hand (docs/tap.python.maxref.xml; a plain SDK class has no generator), with see-also links both
ways (tap.python~'s through MIN_RELATED, its page rewritten by Max); a package topic
(docs/topics/), the guide "Writing Max Objects in Python" (docs/vignettes/), and three tutorials with
their patchers (docs/tutorials/pythontap-tut/: a gain per sample and per vector, a filter with
prepare(), an object without audio). The help patchers are in tabs — tap.python's basic, lists,
outlets, messages and threads; tap.python~'s basic, numpy, allpass and mc. — with Max's ? tab; the
PythonTap Overview is in extras/, the Extras menu and the package's home patcher.

Writing the mc. tab found that [mc.tap.python~] was "No such object": Max wraps an external in mc.
through an init/ mapping, as its own init/ maps mc.cycle~, and the package had none. init/
tap.python.txt now maps mc.tap.python~ to Max's MC wrapper, assembling a package requires the line,
and a runtime test pins it (failing eight checks without the line): two instances, setvalue and
applyvalues reaching the class's attributes and messages — which, being each instance's own, a
plain message to the wrapper does not. The ReadMe says so.

scripts/check-docs.py checks what is written by hand, in CI: the pages well-formed with the right
roots, every link between them resolving, every patcher's patch cords whole.

Checked in Max 9.1.5 on macOS: every page and patcher opened, the help tabs clicked through, the
tutorial patchers run (euclid's rhythm, note_name's C# and 4, scale's list), the Package Docs'
Topics, Guides and Tutorials listing the topic, the guide and the tutorials, a tutorial's Open
Tutorial opening its patcher, and the Overview in the Extras menu; every runtime test passes.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019rVV9SkjkWmiBXFMT4whkz
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019rVV9SkjkWmiBXFMT4whkz
@tap
tap merged commit ac54829 into main Oct 10, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant