Making passagemath more robust and easier to use
Davis Math Lab project report, Spring 2026
Jun 17, 2026
Passagemath is a modular, pip-installable repackaging of SageMath. Rather than installing all of Sage, users can install just the parts they need and run them in plain Python environments like Google Colab. This quarter, I contributed to fixing bugs in the codebase, building tools and materials to help the group, and exploring how to make linear programming easier to use.
My approach to choosing what to work on was to prioritize based on scale,
neglectedness, and fit. Passagemath's modular design means code that assumed a full
SageMath install could break when dependencies were missing, so I fixed that pattern
across combinatorics, number theory, and others, and wrote
check_unbound_imports.py to scan the codebase for it. In Colab and
JupyterLite, plots used to show up as text instead of images; adding
_repr_png_ and _repr_svg_ to the Graphics class
fixed that. Later, my approach was to be a multiplier and help teammates get started
fast, with onboarding docs, a list of shovel-ready issues, exercise notebooks, and
pm-explore, which generates a runnable notebook from any passagemath file
even when the environment is broken.
I spent the last stretch on linear programming ergonomics, and concluded it was a problem worth solving but that making progress and designing it carefully would take understanding that I didn't have yet. The report has the full account, and the 14 merged pull requests are listed on GitHub.