Skip to main content

this_file: README.md

Fly: short FontLab imports

Fly gives FontLab scripts ten short imports. Each alias returns the original module object. It adds no native API emulation or alternative alias targets. Importing fly alone loads none of the target packages.

Alias Canonical module Use
fl echopy.fontlab FontLab bindings
fg echopy.fontgate FontGate bindings
tr typerig TypeRig library
pr echopy.fontpr FontLab command bridge
qt PythonQt Host Qt binding
ap fontlabapp Shared script and UI helpers
qs pythonqtside PySide-style access to host PythonQt
gp fontlab_glyport Glyphs.app compatibility
fp fontlab_fontport fontParts/UFO interoperability
pens fontlab_pens Pen and PointPen protocols

Install

To install into FontLab 9, open install.vfpy from a checkout in FontLab (double-click it or drop it onto FontLab), then restart FontLab. The file is a short stub that hands the work to fontlab-instamix; if instamix is not installed yet, the stub installs it from PyPI first. Instamix installs the package into FontLab's own site-packages and records the install under the extension id com.fontlab.fly.

Requires Python 3.11 or later. FontLab host work targets Python 3.11 arm64. FontLab supplies PythonQt. A separate Python environment cannot supply the native FontLab runtime by installing Fly.

For standalone development, use the external environment recipe under Test and lint. It installs Fly without its target dependencies, which is sufficient for Fly's offline tests. For real use, install the target distributions from their checkouts or artifacts into the same runtime. Declared minimums:

  • fontlab-echopy>=0.1.0, typerig>=0.1.0;
  • fontlab-fontlabapp>=1.2.0, pythonqtside>=0.1.0;
  • fontlab-glyport>=1.2.0, fontlab-fontport>=1.2.0;
  • fontlab-python-pens>=1.0.0.

Install fontlab-python-pens before Fly.

Meet the target packages' own requirements: metadata minimums do not guarantee compatibility with every newer script. Editable installs into FontLab are owner-managed. Do not run these standalone installation commands against FontLab's site-packages.

Use inside FontLab

from fly import fl, fg, tr, pr, qt, ap, qs, gp, fp, pens
import fly.fl
import fly.gp
import fly.fp
import fly.pens
import fontlab_glyport
import fontlab_fontport
import fontlab_pens

assert fly.fl is fl
assert gp is fly.gp is fontlab_glyport
assert fp is fly.fp is fontlab_fontport
assert pens is fly.pens is fontlab_pens

Both import forms keep the canonical module identity and metadata, including native modules whose __spec__ is None. Child imports use the same routing:

from fly.fp.pens import FontGatePointPen
from fly.ap.fontui.feature_blocks import read_feature_blocks, write_feature_blocks
import fly.ap.core.history.glyphs as history

Feature source helpers belong to App's fontui.feature_blocks; the shared fly.ap.core.scripting module also exports lazy wrappers. Load App submodules with their explicit domain paths as above.

For supported Glyphs-style code, use the public Glyport API through Fly:

from fly import gp

Glyphs = gp.GlyphsApp.Glyphs

gp.GlyphsApp is the lazy public fontlab_glyport.GlyphsApp module. First access to Glyphs binds a FontLab GUI-thread session. Outside FontLab, bind an explicit backend with gp.GlyphsApp.use_backend(backend) first; call gp.GlyphsApp.unbind() when done. See Glyport's compatibility guide for limits.

Accessing an alias imports its target. Accessing ap alone does not construct App's Application or preference library. qt requires native PythonQt; a missing target raises ModuleNotFoundError with alias context. A missing internal dependency keeps its original error. Other exceptions propagate from the target. PythonQt uses QtGui for widgets and PythonQt.private for QObject.

General UI/shared helpers belong in fontlabapp. Fontport owns fontParts/UFO support; Glyport owns Glyphs.app compatibility. Pens owns the Pen/PointPen protocols. Each alias exposes its complete canonical module; Fly adds no API subset or wrappers. Scripts use App through Fly.

Agent skills

skills/ provides agent instructions for the FontLab ecosystem:

Skill Covers
fontlab-setup Installing every package and script collection with install.vfpy, in dependency order; listing, uninstalling, troubleshooting
fontlab-remote Controlling a running FontLab from outside with Remopy: MCP setup, run/eval/@fl.python, tools, limits and safety
fontlab-scripting Writing scripts with the Fly aliases, where code belongs, one-step Undo, testing

Link the skill folders into the skills directory used by your agent.

Module and file map

Path Role
src/fly/init.py Alias map, lazy attributes, import finder and metadata-preserving loader
examples/native_smoke.py Ten-alias identity smoke for a fresh FontLab import session
tests/test_aliases.py Lazy loading, identity, metadata, reload, child imports and errors
tests/test_packaging.py Builds a wheel; checks byte-exact LICENSE/NOTICE and licence metadata
test.sh Runs pytest through uv run --no-sync
pyproject.toml Runtime requirements, pytest paths, Hatch build and Git-tag versioning
DEPENDENCIES.md Dependency roles
PLAN.md, TODO.md Current goals and open acceptance tasks
CHANGELOG.md, WORK.md, RELEASE.md Changes, test evidence and historical release evidence

Documentation website

Fly guide sources build locally; Pages is not deployed. Private Pages publication is held by the owner on the current account plan. Use Python 3.13 and the hash-locked src_docs/requirements.txt; sh src_docs/build.sh reads src_docs/mkdocs.yml and regenerates docs. The development guide covers main-push CI: two full builds qualify source/output without requesting Pages.

Test and lint

Run from this repository root on macOS arm64. Install uv first. The selected Python must be installed or available for uv to download. Pytest and the wheel build dependencies (Hatchling and hatch-vcs) must be available from the package index or cache. Set FONTLAB_SCRATCH to a writable external-drive folder first.

: "${FONTLAB_SCRATCH:?Set FONTLAB_SCRATCH to a writable external-drive folder}"
export TMPDIR="$FONTLAB_SCRATCH/tmp" UV_CACHE_DIR="$FONTLAB_SCRATCH/fontlab-fly-cache"
mkdir -p "$TMPDIR" "$UV_CACHE_DIR" || exit 1
export PYTHONPATH="$PWD/src"
export PYTHONDONTWRITEBYTECODE=1 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
export GIT_OPTIONAL_LOCKS=0
uv run --python cpython-3.11-macos-aarch64-none --no-project --with pytest \
  python -m pytest -q -p no:cacheprovider

PYTHONPATH is required by subprocess tests when Fly is not installed. The explicit Python selector prevents accidental x86_64 or Python 3.12 use. Tests use stand-in target modules; installing the target packages is not needed.

For a reusable standalone environment, use the same exports and prepare it first:

uv venv --python cpython-3.11-macos-aarch64-none "$TMPDIR/fontlab-fly-venv"
uv pip install --python "$TMPDIR/fontlab-fly-venv/bin/python" pytest
uv pip install --python "$TMPDIR/fontlab-fly-venv/bin/python" --no-deps -e .
UV_PROJECT_ENVIRONMENT="$TMPDIR/fontlab-fly-venv" ./test.sh -q -p no:cacheprovider

./test.sh runs uv run --no-sync. It requires a prepared Python 3.11 arm64 environment with pytest; it does not install pytest or select the host Python. Without UV_PROJECT_ENVIRONMENT, it uses the project's .venv. A missing .venv can cause uv to create an unsuitable environment and fail without pytest. The editable install above affects only the standalone environment.

Ruff is installed separately:

ruff check --no-cache src tests examples

To build both distributions, keep the same cache/temp exports and run:

uv build --out-dir "$TMPDIR/fontlab-fly-dist"

Builds use Hatchling and hatch-vcs; versioning uses Git tags. Building artifacts alone does not prove that they work in FontLab.

The suite includes a real wheel build and tests target routing with stand-in modules. The separate tests_docs/ suite checks publishing and generated pages. On 2026-10-22, the offline suite passed on Python 3.11.17 arm64 (exit 0, 17 passed); Ruff passed (exit 0). These checks do not prove native FontLab behavior.

Run examples/native_smoke.py inside FontLab with all targets available and a fresh App import state. It also checks that importing ap has not created app; a reused session can already contain it. The smoke proves alias identity, not child-module behavior or full target functionality. Native acceptance uses the workspace runner, owned fixtures and loaded-path checks because canonical editable installs can shadow the worktree.

WORK.md retains historical FontLab 9.0.9783/Python 3.11.6/Qt 5.15.19 wheel/sdist checks predating the provider refactor. Current native acceptance remains open.

Releases and licence

v0.2.0 shipped the original seven aliases. v0.2.1 added gp and fp. v0.2.2 set their dependency minimums and included NOTICE in wheel licence files.

Apache-2.0; NOTICE credits Echopy. Providers retain their own licences.

Metadata

Release files for fontlab-fly 1.3.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fontlab-fly 1.3.9
File Size Uploaded Provenance Actions
fontlab_fly-1.3.9.tar.gz 40.2 kB With provenance Details for fontlab_fly-1.3.9.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for fontlab-fly 1.3.9
File Interpreter ABI Platform Actions
fontlab_fly-1.3.9-py3-none-any.whl Python 3 none any Details for fontlab_fly-1.3.9-py3-none-any.whl

Total release size: 51.0 kB

Release files / fontlab_fly-1.3.9.tar.gz

Download URL fontlab_fly-1.3.9.tar.gz
Size 40.2 kB
Tags Source
SHA-256 checksum
How to use checksums
2dd2e7dc4998bd1b66e1302acff5afca4be7f7187fb59446331b9c57f0b32871
BLAKE2b-256 checksum
How to use checksums
7b2a050baf87075e3a541219e05ac7d2eb5a224be4ab4dba56ec265acc1f9615
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Release files / fontlab_fly-1.3.9-py3-none-any.whl

Download URL fontlab_fly-1.3.9-py3-none-any.whl
Size 10.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ebcfb6e1ad2defcaf781f51511bb66c1988b0a965fb5d19f8bdad9491e642ed7
BLAKE2b-256 checksum
How to use checksums
f94f00e1ec583a30b9fb89cca1865830d0de87f82b334ba00d8e6cbe6da05897
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Security for fontlab-fly 1.3.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for fontlab_fly-1.3.9.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page