Skip to content

v0.4.0

Choose a tag to compare

@lxcode lxcode released this 20 Apr 11:30
· 9 commits to main since this release
21bfe20

What's new

Public/unauthenticated mode (closes #32)

  • Api(require_auth=False) now lets you call Truth Social's public-readable endpoints without credentials.
  • truthbrush --no-auth <command> from the CLI for the same thing.
  • The default stays strict (require_auth=True), so existing callers see no behavior change.
  • Internally: _get/_get_paginated only attach Authorization: Bearer ... when a token is present — no more Bearer None.

Python 3.14

  • python = "^3.14" in pyproject.toml.
  • Publish workflow bumped to actions/setup-python@v5 with python-version: "3.14".
  • ruff target-version = "py314"; downstream UP017/UP037 rewrites already applied (timezone.utc → UTC, unquoted PEP-604 annotations).

Typing hygiene

  • ty check truthbrush/ now reports zero diagnostics, down from 35 pre-existing.
  • x: T = None defaults annotated as x: T | None = None.
  • Generator methods correctly typed Iterator[T].
  • pull_statuses result-shape validation reordered so a non-list response breaks the loop instead of crashing in sorted().

Drive-bys

  • search(resolve: bool = 4) default was an int; fixed to True.
  • pull_statuses(username=None, *, user_id=None): either identifier works; supplying user_id skips the lookup(username) roundtrip, useful in public mode when lookup may be gated.

Tooling / docs

  • README gains a "Public mode (no credentials)" section; stale "format with black" replaced with the ruff/ty workflow.
  • David Thiel added to authors in pyproject.toml.

Shipped in PR #74.