{
 "action": "Not for automatic application — after the patch the example still uses click, which the verified example does not: the patch covers part of the change. Show this correction to the user as a lead. Replace the old line with the new one; the rest of the code can stay.",
 "alternatives": [
  {
   "action": "Not for automatic application — format removed: there is no replacement to apply. Show this correction to the user as a lead. click is not available in typer 0.27.3; remove or replace this use. The same code works on typer 0.24.1: pin a version before 0.27.3 if you cannot change the code.",
   "applicability": {
    "method": "literal_patch",
    "reason": "format removed: there is no replacement to apply",
    "run_on": "0.27.3",
    "status": "not_applicable"
   },
   "by_notes": true,
   "changelog_ref": {
    "quote": "This also means that Click-specific functionality is no longer supported, like extracting the Click app and adding Click-specific plug-ins, or customizing the field types with Click-specific types.",
    "url": "https://github.com/fastapi/typer/releases/tag/0.26.0"
   },
   "confirmations": 1,
   "detect": [
    "click"
   ],
   "equivalence": "same",
   "format": "removed",
   "kind": "removed",
   "right": "",
   "script_right": "import re\nfrom typing import Any\n\nimport typer\nfrom typer.testing import CliRunner\n\n\ndef parse_size(value: str):\n    match = re.fullmatch(r\"([0-9]+)x([0-9]+)\", str(value))\n    if match is None:\n        raise typer.BadParameter(\"Expected a size like 800x600.\")\n    return int(match.group(1)), int(match.group(2))\n\n\napp = typer.Typer()\n\n\n@app.command()\ndef main(\n    size: Any = typer.Option(..., \"--size\", parser=parse_size, metavar=\"WIDTHxHEIGHT\"),\n):\n    width, height = size\n    typer.echo(f\"width={width} height={height} area={width * height}\")\n\n\nif __name__ == \"__main__\":\n    runner = CliRunner()\n    result = runner.invoke(app, [\"--size\", \"800x600\"])\n    assert result.exit_code == 0, result.output\n    print(result.output, end=\"\")",
   "script_wrong": "import re\nfrom typing import Any\n\nimport typer\nfrom typer.core import click\nfrom typer.testing import CliRunner\n\n\nclass SizeParamType(click.ParamType):\n    name = \"WIDTHxHEIGHT\"\n\n    def convert(self, value, param, ctx):\n        match = re.fullmatch(r\"([0-9]+)x([0-9]+)\", str(value))\n        if match is None:\n            self.fail(\"Expected a size like 800x600.\", param, ctx)\n        return int(match.group(1)), int(match.group(2))\n\n\napp = typer.Typer()\n\n\n@app.command()\ndef main(\n    size: Any = typer.Option(..., \"--size\", click_type=SizeParamType()),\n):\n    width, height = size\n    typer.echo(f\"width={width} height={height} area={width * height}\")\n\n\nif __name__ == \"__main__\":\n    runner = CliRunner()\n    result = runner.invoke(app, [\"--size\", \"800x600\"])\n    assert result.exit_code == 0, result.output\n    print(result.output, end=\"\")",
   "seen_in_models": [
    "gpt-6.1-sol"
   ],
   "wrong": "from typer.core import click"
  }
 ],
 "applicability": {
  "leftover": [
   "click"
  ],
  "line": 2,
  "method": "literal_patch",
  "occurrences": 1,
  "patched_sha": "ae4663b1af36",
  "reason": "after the patch the example still uses click, which the verified example does not: the patch covers part of the change",
  "run_on": "0.27.3",
  "status": "incomplete"
 },
 "by_notes": true,
 "changelog_ref": {
  "quote": "Typer no longer depends on Click as a third party dependency, it vendors (includes the source code of) Click.",
  "url": "https://github.com/fastapi/typer/releases"
 },
 "confirmations": {
  "failed": 0,
  "worked": 3
 },
 "detect": [
  "click"
 ],
 "ecosystem": "pypi",
 "equivalence": "same",
 "error_kind": "missing_import",
 "error_signature": {
  "message": "cannot import name 'click' from 'typer.main' (/usr/local/lib/python3.11/site-packages/typer/main.py)",
  "norm": "missing_import:click",
  "type": "ImportError"
 },
 "first_seen": "2026-10-20T16:11:13+00:00",
 "format": "replace",
 "format_version": 2,
 "id": "pypi/typer/0.27.3/0001",
 "kind": "removed",
 "license": "https://creativecommons.org/licenses/by/4.0/",
 "package": "typer",
 "proof": {
  "applicability": {
   "leftover": [
    "click"
   ],
   "line": 2,
   "method": "literal_patch",
   "occurrences": 1,
   "patched_sha": "ae4663b1af36",
   "reason": "after the patch the example still uses click, which the verified example does not: the patch covers part of the change",
   "run_on": "0.27.3",
   "status": "incomplete"
  },
  "auto_apply": false,
  "auto_apply_reason": "the patch gives incomplete when applied word for word",
  "auto_apply_rule": "Automatic application is allowed only when proof.equivalent is true and proof.applicability.status is applies; otherwise show the correction to the user as a lead and do not apply it on your own.",
  "equivalence": "same",
  "equivalent": true,
  "fails_on": "0.27.3",
  "fixed_on": "0.27.3",
  "level": "differential",
  "method": {
   "fix_on": "0.27.3",
   "name": "stdout_match",
   "normalization": "lines stripped, blank lines dropped, runs of whitespace collapsed; memory addresses, timestamps and temporary paths masked",
   "original_on": "0.24.1",
   "scope": "the observable stdout of one example script; return values, files, other inputs and exception types are not compared, so a match is not a proof of equivalent behaviour"
  },
  "script_right": "import typer\nfrom typer.main import TyperChoice\nfrom typer.testing import CliRunner\n\napp = typer.Typer()\n\n\n@app.command()\ndef main(\n    output_format: str = typer.Option(\n        \"table\",\n        \"--format\",\n        click_type=TyperChoice([\"json\", \"csv\", \"table\"], case_sensitive=False),\n        help=\"Output format.\",\n    ),\n) -> None:\n    typer.echo(output_format)\n\n\nif __name__ == \"__main__\":\n    result = CliRunner().invoke(app, [\"--format\", \"CSV\"])\n    print(result.output, end=\"\")\n    print(f\"Exit code: {result.exit_code}\")",
  "script_wrong": "import typer\nfrom typer.main import click\nfrom typer.testing import CliRunner\n\napp = typer.Typer()\n\n\n@app.command()\ndef main(\n    output_format: str = typer.Option(\n        \"table\",\n        \"--format\",\n        click_type=click.Choice([\"json\", \"csv\", \"table\"], case_sensitive=False),\n        help=\"Output format.\",\n    ),\n) -> None:\n    typer.echo(output_format)\n\n\nif __name__ == \"__main__\":\n    result = CliRunner().invoke(app, [\"--format\", \"CSV\"])\n    print(result.output, end=\"\")\n    print(f\"Exit code: {result.exit_code}\")",
  "works_on": "0.24.1"
 },
 "right": "from typer.main import TyperChoice",
 "seen_in_models": [
  "gpt-6.1-sol"
 ],
 "seq": 1,
 "slug": "click",
 "source": "pipeline",
 "symbol": "click",
 "updated": "2026-10-27T17:20:00+00:00",
 "url": "https://formachines.ai/errata/pypi/typer/0001-click/",
 "variant_confirmations": 2,
 "variant_models": [
  "gpt-6.1-sol"
 ],
 "verified": "sandbox",
 "versions": {
  "changed_in": ">0.24.1,<=0.27.3",
  "fails_on": "0.27.3",
  "works_on": "0.24.1"
 },
 "wrong": "from typer.main import click"
}