Skip to content

Comments

Add check command#15692

Merged
MichaReiser merged 2 commits intomainfrom
micha/check-command
Jan 24, 2025
Merged

Add check command#15692
MichaReiser merged 2 commits intomainfrom
micha/check-command

Conversation

@MichaReiser
Copy link
Member

@MichaReiser MichaReiser commented Jan 23, 2025

Summary

This PR changes the CLI to introduce a dedicated check command similar to ruff check (vs just red_knot <path>)

Test Plan

Updated CLI tests

@MichaReiser MichaReiser added the ty Multi-file analysis & type inference label Jan 23, 2025
),
])?;

case.insta_settings().bind(|| {
Copy link
Member Author

@MichaReiser MichaReiser Jan 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some more tidy work. I realised I can use a guard to attach the settings automatically. The only change other than removing the insta_settings method is to call knot check over just knot

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool!

),
])?;

case.insta_settings().bind(|| {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool!

Copy link
Contributor

@carljm carljm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@MichaReiser MichaReiser force-pushed the micha/ignore-warn-error-cli-arguments branch from e7a74fb to 61f473d Compare January 24, 2025 15:12
Base automatically changed from micha/ignore-warn-error-cli-arguments to main January 24, 2025 15:20
@MichaReiser MichaReiser merged commit 9353482 into main Jan 24, 2025
21 checks passed
@MichaReiser MichaReiser deleted the micha/check-command branch January 24, 2025 16:00
dcreager added a commit that referenced this pull request Jan 24, 2025
* main:
  Add `check` command (#15692)
  [red-knot] Use itertools to clean up `SymbolState::merge` (#15702)
  [red-knot] Add `--ignore`, `--warn`, and `--error` CLI arguments (#15689)
  Use `uv init --lib` in tutorial (#15718)
  [red-knot] Use `Unknown | T_inferred` for undeclared public symbols (#15674)
  [`ruff`] Parenthesize fix when argument spans multiple lines for `unnecessary-round` (`RUF057`) (#15703)
  [red-knot] Rename `TestDbBuilder::typeshed` to `.custom_typeshed` (#15712)
  Honor banned top level imports by TID253 in PLC0415.  (#15628)
  Apply `AIR302`-context check only in `@task` function (#15711)
  [`airflow`] Update `AIR302` to check for deprecated context keys (#15144)
  Remove test rules from JSON schema (#15627)
  Add two missing commits to changelog (#15701)
  Fix grep for version number in docker build (#15699)
  Bump version to 0.9.3 (#15698)
  Preserve raw string prefix and escapes (#15694)
  [`flake8-pytest-style`] Rewrite references to `.exception` (`PT027`) (#15680)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ty Multi-file analysis & type inference

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants