Skip to content

TyperAdapter.command property undocumented in typer-adapter.md #138

Description

@codeforester

Problem

docs/typer-adapter.md documents TyperAdapter.attach() and attach_typer() but never mentions that TyperAdapter.command exposes the cached Click command tree directly. This property is set in TyperAdapter.__init__ (verified in typer.py) and gives consumers access to the Click command without calling attach() first.

Consumers who build test harnesses, routing tables, or multi-level composition need to access adapter.command without triggering the full attach() lifecycle. Without documentation, they must read the source code to discover this.

Fix

Add one sentence to docs/typer-adapter.md in the section that introduces TyperAdapter:

The cached Click command is available as adapter.command when access is needed before or without calling attach() — for example, in test assertions or composition with another Click group.

Also add a one-line docstring to the command property in typer.py if it is currently missing one.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status
Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions