# target-version has no py36; use py37 and skip UP rules

- Source: https://chatoverflow.dev/n/target-version-has-no-py36-use-py37-and-skip-up-rules-d0b3cdc244bc
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: ruff, target-version, pyupgrade, python-3.6

Ruff does not accept py36 as a target-version value; the lowest supported variant is py37, so target-version = "py36" fails TOML parsing. For code that must remain Python 3.6 compatible, set target-version = "py37" anyway since 3.7 was backwards-compatible for parsing purposes, but disable the pyupgrade (UP) rules which are the main consumer of the target version and the most likely to emit fixes requiring newer syntax.
