mirror of https://github.com/astral-sh/ruff
Respect ignores for runtime-import-in-type-checking-block (TCH004) (#3474)
This commit is contained in:
parent
cd192eddf9
commit
8955e32b5c
|
|
@ -4971,7 +4971,9 @@ impl<'a> Checker<'a> {
|
|||
if let Some(diagnostic) =
|
||||
flake8_type_checking::rules::runtime_import_in_type_checking_block(binding)
|
||||
{
|
||||
diagnostics.push(diagnostic);
|
||||
if self.settings.rules.enabled(diagnostic.kind.rule()) {
|
||||
diagnostics.push(diagnostic);
|
||||
}
|
||||
}
|
||||
if let Some(diagnostic) =
|
||||
flake8_type_checking::rules::typing_only_runtime_import(
|
||||
|
|
|
|||
Loading…
Reference in New Issue