Skip to content

Refactor: rename "toolkit" to "ptoolkit"#1738

Open
rolandwalker wants to merge 1 commit intomainfrom
RW/refactor-toolkit-as-ptoolkit
Open

Refactor: rename "toolkit" to "ptoolkit"#1738
rolandwalker wants to merge 1 commit intomainfrom
RW/refactor-toolkit-as-ptoolkit

Conversation

@rolandwalker
Copy link
Contributor

Description

Refactor: rename "toolkit" to "ptoolkit" when referring to prompt_toolkit extensions and utilities.

When first reading the layout I assumed that toolkit referred to some generic, rather than specific, toolkit for mycli. This just helps keep things straight.

Checklist

  • I added this contribution to the changelog.md file.
  • I added my name to the AUTHORS file (or it's already there).
  • To lint and format the code, I ran
    uv run ruff check && uv run ruff format && uv run mypy --install-types .

@rolandwalker rolandwalker self-assigned this Mar 24, 2026
@github-actions
Copy link

  1. Low: potential backward-compat break from module rename without shim
  • Changed imports now point to mycli.packages.ptoolkit (for example key_bindings.py:19, main.py:96), and mycli/packages/toolkit/* was renamed to mycli/packages/ptoolkit/*.
  • If any external plugin/user code imports mycli.packages.toolkit.*, this PR will break them at import time.
  • Action: add a temporary compatibility package mycli/packages/toolkit/ that re-exports from ptoolkit, or explicitly call this out as a breaking change in release notes.
  1. Missing regression test coverage for import-path refactor
  • This PR is a pure import/module-path rename, but there is no test asserting those critical imports still resolve (e.g. startup path via mycli.main, key binding history search path).
  • Action: add a small smoke test that imports mycli.main and executes key-binding module import path resolution, so future refactors catch ModuleNotFoundError regressions early.

Security concerns found in this PR: none.

Validation note: I could not run tests in this environment because pytest is not installed.

when referring to prompt_toolkit extensions and utilities
@rolandwalker rolandwalker force-pushed the RW/refactor-toolkit-as-ptoolkit branch from 35846ae to 665d23b Compare March 24, 2026 10:41
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