Skip to content

Use ty's None-union truthiness rule - #3298

Merged
adamtheturtle merged 1 commit into
mainfrom
use-ty-none-union-rule
Oct 12, 2026
Merged

adamtheturtle merged 1 commit into
mainfrom
use-ty-none-union-rule

Conversation

@adamtheturtle

Copy link
Copy Markdown
Member

Upgrade ty from 0.0.84 to 0.0.85, the first release containing astral-sh/ruff#28889. The existing rules.all = "error" setting enables truthiness-test-of-none-union, so truthiness checks that conflate None with other falsy values are now rejected.

Validation: project-wide ty check, pyproject-fmt --check, and git diff --check passed. A temporary int | None example confirmed that the project configuration emits the new diagnostic. The existing ty documentation-example command also passed. No source changes or rule suppressions were needed.

@adamtheturtle
adamtheturtle merged commit 27eeac2 into main Oct 12, 2026
15 checks passed
@adamtheturtle
adamtheturtle deleted the use-ty-none-union-rule branch October 12, 2026 10:01

This branch was successfully deployed

1 active deployment
development — 67ca5278 Deployed Oct 12, 2026 by adamtheturtle via pages #1173
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