Skip to content

Releases

v0.4.0

Choose a tag to compare

@github-actions github-actions released this 07 Nov 12:00
Immutable release. Only release title and notes can be modified.
80ca0dd

Added

  • Add FontResource.unicode_range so each subset of a family registers under one
    name and serves only the codepoints its @font-face declares.
  • Add Renderer.unregister_font and Renderer.clear_fonts to release registered
    fonts.
  • Add a budgeted font cache, Takumi's cacheFont/cachedFonts:
    Renderer.cache_font(font, key) registers a font the renderer may release,
    Renderer.cached_fonts(key) reports whether it still holds one, and
    Renderer(font_cache_max_bytes=...) releases the least recently used cached
    families past the budget. Renders mark the families in font_families used, and
    fonts from register_font are never released.
  • Decode data: URI images through the renderer's resource cache, so repeated
    renders that inline the same image decode it once.
  • Add a Takumi 2.17 migration guide, and document font subsets, font release,
    animation frame-rate limits, and the Takumi submodule upgrade procedure.
  • Deploy the documentation on main as a dev version in both languages, listed
    above the releases in the version selector, through the new Preview · Docs
    workflow; latest stays on the newest release.
  • Add make changelog, which dates the [Unreleased] notes as the project version
    and appends the release's commits, grouped by type and linked by hash, with
    @-mentions of its contributors, generated with git-changelog.
  • Publish the documentation in Simplified Chinese alongside the American English
    primary, with a one-click language toggle in the header that keeps the version,
    page, and anchor, a Chinese README, and a docs build check that keeps both
    languages' pages, anchors, code samples, and configuration in sync.
  • Add make release VERSION=x.y.z, which sets the version in pyproject.toml,
    Cargo.toml, and both lock files, writes the changelog entry, and checks the
    release contract.
  • Release alphas, betas, and release candidates, such as 0.4.0rc1 (0.4.0-rc.1 in
    Cargo.toml): they publish as GitHub prereleases, and their documentation never
    takes latest.
  • Publish wheels for four more platforms: musllinux_1_2 x86_64 and aarch64, for
    Alpine and other musl-based Linux, macOS on Intel, and Windows on arm64. These
    platforms no longer build from the source distribution.
  • Smoke-test the cp311-abi3 wheel on Python 3.15.
  • Publish project links, classifiers, and keywords on PyPI.
  • Document the versioning and deprecation policy in the support matrix. Deprecation
    warnings now name the release that removes the API: FontResource.subset_of and
    dithering="floyd-steinberg" go in 0.6.0.
  • Add SECURITY.md, which asks for vulnerability reports through GitHub's private
    vulnerability reporting.
  • Have Dependabot propose weekly uv and Cargo updates alongside GitHub Actions, with
    separate pull requests for the exactly pinned ty and Zensical.
  • Show a banner on every documentation version but the latest release: the dev
    preview says it comes from main and can describe unreleased changes, and older
    releases and prereleases link to the latest one.

Changed

  • Clarify that compiled HTML bundles currently return no stylesheets, and describe
    render options, resources, keyframes, and result types in the generated API
    reference.
  • Update Takumi from 2.5.4 to 2.17.1, including takumi-core 0.32.0,
    takumi-raster 0.5.9, takumi-svg 0.3.31, and takumi-html 0.6.0. Layout,
    text, filters, backgrounds, decorations, and paint order now follow Chrome more
    closely; see the upstream changelog for the rendering changes.
  • Update PyO3 from 0.28 to 0.30 and refresh compatible Rust dependencies.
  • Declare rust-version = "1.91" so dependency resolution stays within the
    pinned CI toolchain.
  • The renderer resource cache now defaults to 64 MiB, up from 16 MiB.
  • Publish each version's CHANGELOG.md section as its GitHub Release notes, instead of
    GitHub's generated notes.
  • Release · Tag and Release · Publish share one release-contract check, which now
    also requires the commit list make changelog generates.
  • Refresh the toolchain to Zensical 0.0.72, ty 0.0.91, Ruff 0.17, mypy 2.4, and
    maturin 1.15, with current Prek hooks. ty and Zensical, still at 0.0.x, are pinned
    exactly so that each upgrade is deliberate, and the commit message hook now
    accepts chore and typing commits.
  • Name the GitHub Actions workflows by stage: Check · Build and test, Check · Docs,
    Check · Lint, Release · Tag, and Release · Publish, with verb-first job names.
    Workflow file names, and so the PyPI Trusted Publisher binding, are unchanged.
  • Stream render_animation frames straight into the encoder, so an animation holds
    one raw frame at a time instead of all of them.
  • Split the native extension into focused modules and pass resolved options, fonts,
    images, and frames across the private _core boundary as objects instead of
    positional keyword lists and tuples. The public Python API and its output are
    unchanged.
  • Reject conflicting encoder options, such as lossless=True with PNG output,
    before rendering rather than after.
  • Link the READMEs to the hosted documentation of the latest release instead of the
    Markdown sources, and check that each link names an existing page in both
    languages.
  • Restructure the documentation: English sources move to docs/en/, new HTML and
    CSS and Output formats guides take over from the overloaded rendering guide, the
    release guide is now in English, and the README keeps only the overview,
    installation, and quickstart.
  • <img> without a src now parses as an empty box instead of raising
    HtmlParseError.
  • Run the core fixture smoke test over upstream's relocated fixtures-html
    sources, which restores coverage to all 336 HTML fixtures.

Deprecated

  • FontResource.subset_of now only sets the family name, taking precedence over
    name; use name with unicode_range instead.
  • dithering="floyd-steinberg" is an alias of "ordered-bayer" now that Takumi
    has dropped its whole-image error-diffusion pass.

Removed

  • Remove the testing-stage warnings from the READMEs and documentation home pages.
  • Breaking: remove the compatibility shims deprecated in 0.2.0: the
    fetched_resources argument of every render call and RenderOptions,
    Renderer(persistent_images=...), and Renderer.load_font, load_fonts,
    put_persistent_image, and clear_image_store. Pass images to each render and
    register fonts with register_font or register_fonts; the Takumi v2 migration
    guide maps each one.
  • Drop Python 3.10 support. takumi-py now requires Python 3.11 or later and
    publishes cp311-abi3 wheels.
  • Drop the typing-extensions runtime dependency; TypedDict and NotRequired
    come from the standard library on Python 3.11.
  • Drop the unused direct parley dependency, which Takumi no longer uses.

Fixed

  • Point deprecation warnings at the calling code. Nested public calls, such as
    render_node delegating to render_compiled, attributed them to takumi_py
    itself, where Python's default filters hide DeprecationWarning.
  • Enforce the documented frame-rate limits in render_animation: above 90 fps for
    WebP and APNG, or 50 fps for GIF, it now raises ValueError instead of writing
    frame delays that decoders clamp to 100 ms.
  • Document that set_glyph_cache_max_bytes has no effect once the glyph cache is
    in use, instead of claiming it raises RuntimeError.

Commits

Breaking changes

  • build: require Python 3.11 or later (56927f1)
  • build(release): generate changelog entries with git-changelog (0f0233f)
  • refactor: remove the compatibility shims deprecated in 0.2.0 (0fcd62c)

Features

  • core: update Takumi to 2.17.1 (e04b503)
  • api: adapt bindings to Takumi 2.17.1 (ca03d58)
  • core: expose registered fonts (3caeb02)
  • api: release registered fonts (b3c3300)
  • add a budgeted font cache (884061d)

Bug fixes

  • docs: open dev at a language root that has no release yet (a3d644b)

Performance

  • animation: stream frames into the encoder (a78dad7)

Refactoring

  • core: split the native extension into modules (fc7f8cd)
  • api: pass native options as objects (835535f)

Documentation

Read more

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 02 Aug 10:05
3d938e3

What's Changed

New Contributors

Full Changelog: v0.2.0...v0.3.0

v0.2.0

Choose a tag to compare

@github-actions github-actions released this 10 Jul 10:29
v0.2.0
d904071

Full Changelog: v0.1.0...v0.2.0

v0.1.0

Choose a tag to compare

@BalconyJH BalconyJH released this 11 Jun 01:48
6f420be

Important

takumi-py is currently in a testing stage. APIs, wheel build targets, release automation, and exception types may still change while the Takumi core binding surface is completed; do not treat it as a stable production dependency yet.

Highlights

  • Expanded the Python binding beyond the initial static render path.
  • Added typed RenderOptions for viewport, DPR, debug border, dithering, time_ms, output format, and per-render resources.
  • Added measurement APIs returning typed measured node trees.
  • Added custom font loading, persistent image resources, and per-render fetched resources.
  • Added CSS animation sampling, sequence rendering, and WebP/APNG/GIF animated encoding.
  • Replaced the experimental msgpack/pydantic path with msgspec.
  • Added PEP 561 typing via py.typed and _core.pyi.
  • Added CI, release automation, examples, and smoke tests.

Supported Wheels

  • Linux x86_64
  • Linux aarch64
  • macOS arm64
  • Windows x64

Install

pip install takumi-py