diff --git a/CHANGELOG.md b/CHANGELOG.md index 2508b4a54f..3707d70b1d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,47 @@ # Changelog +## 0.14.9 + +Released on 2025-12-11. + +### Preview features + +- \[`ruff`\] New `RUF100` diagnostics for unused range suppressions ([#21783](https://github.com/astral-sh/ruff/pull/21783)) +- \[`pylint`\] Detect subclasses of builtin exceptions (`PLW0133`) ([#21382](https://github.com/astral-sh/ruff/pull/21382)) + +### Bug fixes + +- Fix comment placement in lambda parameters ([#21868](https://github.com/astral-sh/ruff/pull/21868)) +- Skip over trivia tokens after re-lexing ([#21895](https://github.com/astral-sh/ruff/pull/21895)) +- \[`flake8-bandit`\] Fix false positive when using non-standard `CSafeLoader` path (S506). ([#21830](https://github.com/astral-sh/ruff/pull/21830)) +- \[`flake8-bugbear`\] Accept immutable slice default arguments (`B008`) ([#21823](https://github.com/astral-sh/ruff/pull/21823)) + +### Rule changes + +- \[`pydocstyle`\] Suppress `D417` for parameters with `Unpack` annotations ([#21816](https://github.com/astral-sh/ruff/pull/21816)) + +### Performance + +- Use `memchr` for computing line indexes ([#21838](https://github.com/astral-sh/ruff/pull/21838)) + +### Documentation + +- Document `*.pyw` is included by default in preview ([#21885](https://github.com/astral-sh/ruff/pull/21885)) +- Document range suppressions, reorganize suppression docs ([#21884](https://github.com/astral-sh/ruff/pull/21884)) +- Update mkdocs-material to 9.7.0 (Insiders now free) ([#21797](https://github.com/astral-sh/ruff/pull/21797)) + +### Contributors + +- [@Avasam](https://github.com/Avasam) +- [@MichaReiser](https://github.com/MichaReiser) +- [@charliermarsh](https://github.com/charliermarsh) +- [@amyreese](https://github.com/amyreese) +- [@phongddo](https://github.com/phongddo) +- [@prakhar1144](https://github.com/prakhar1144) +- [@mahiro72](https://github.com/mahiro72) +- [@ntBre](https://github.com/ntBre) +- [@LoicRiegel](https://github.com/LoicRiegel) + ## 0.14.8 Released on 2025-12-04. diff --git a/Cargo.lock b/Cargo.lock index b6ca38375b..e75eedb6c2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2860,7 +2860,7 @@ dependencies = [ [[package]] name = "ruff" -version = "0.14.8" +version = "0.14.9" dependencies = [ "anyhow", "argfile", @@ -3118,7 +3118,7 @@ dependencies = [ [[package]] name = "ruff_linter" -version = "0.14.8" +version = "0.14.9" dependencies = [ "aho-corasick", "anyhow", @@ -3475,7 +3475,7 @@ dependencies = [ [[package]] name = "ruff_wasm" -version = "0.14.8" +version = "0.14.9" dependencies = [ "console_error_panic_hook", "console_log", diff --git a/README.md b/README.md index 7e96c92479..091e0d3cfe 100644 --- a/README.md +++ b/README.md @@ -147,8 +147,8 @@ curl -LsSf https://astral.sh/ruff/install.sh | sh powershell -c "irm https://astral.sh/ruff/install.ps1 | iex" # For a specific version. -curl -LsSf https://astral.sh/ruff/0.14.8/install.sh | sh -powershell -c "irm https://astral.sh/ruff/0.14.8/install.ps1 | iex" +curl -LsSf https://astral.sh/ruff/0.14.9/install.sh | sh +powershell -c "irm https://astral.sh/ruff/0.14.9/install.ps1 | iex" ``` You can also install Ruff via [Homebrew](https://formulae.brew.sh/formula/ruff), [Conda](https://anaconda.org/conda-forge/ruff), @@ -181,7 +181,7 @@ Ruff can also be used as a [pre-commit](https://pre-commit.com/) hook via [`ruff ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.14.8 + rev: v0.14.9 hooks: # Run the linter. - id: ruff-check diff --git a/crates/ruff/Cargo.toml b/crates/ruff/Cargo.toml index ff8516ebf2..76dfe3dfe5 100644 --- a/crates/ruff/Cargo.toml +++ b/crates/ruff/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff" -version = "0.14.8" +version = "0.14.9" publish = true authors = { workspace = true } edition = { workspace = true } diff --git a/crates/ruff_linter/Cargo.toml b/crates/ruff_linter/Cargo.toml index 9d11a41e50..28f4b0e413 100644 --- a/crates/ruff_linter/Cargo.toml +++ b/crates/ruff_linter/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff_linter" -version = "0.14.8" +version = "0.14.9" publish = false authors = { workspace = true } edition = { workspace = true } diff --git a/crates/ruff_python_formatter/resources/test/fixtures/ruff/expression/lambda.py b/crates/ruff_python_formatter/resources/test/fixtures/ruff/expression/lambda.py index 1b1c1ee3c2..036ef2c3c8 100644 --- a/crates/ruff_python_formatter/resources/test/fixtures/ruff/expression/lambda.py +++ b/crates/ruff_python_formatter/resources/test/fixtures/ruff/expression/lambda.py @@ -125,6 +125,13 @@ lambda a, /, c: a *x: x ) +( + lambda + # comment + *x, + **y: x +) + ( lambda # comment 1 @@ -196,6 +203,17 @@ lambda: ( # comment x ) +( + lambda # 1 + # 2 + x, # 3 + # 4 + y + : # 5 + # 6 + x +) + ( lambda x, @@ -204,6 +222,71 @@ lambda: ( # comment z ) + +# Leading +lambda x: ( + lambda y: lambda z: x + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + z # Trailing +) # Trailing + + +# Leading +lambda x: lambda y: lambda z: [ + x, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + z +] # Trailing +# Trailing + lambda self, araa, kkkwargs=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs), e=1, f=2, g=2: d # Regression tests for https://github.com/astral-sh/ruff/issues/8179 @@ -228,6 +311,441 @@ def a(): g = 10 ) +def a(): + return b( + c, + d, + e, + f=lambda self, *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ) + 1, + ) + +# Additional ecosystem cases from https://github.com/astral-sh/ruff/pull/21385 +class C: + def foo(): + mock_service.return_value.bucket.side_effect = lambda name: ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) + +class C: + function_dict: Dict[Text, Callable[[CRFToken], Any]] = { + CRFEntityExtractorOptions.POS2: lambda crf_token: crf_token.pos_tag[:2] + if crf_token.pos_tag is not None + else None, + } + +name = re.sub(r"[^\x21\x23-\x5b\x5d-\x7e]...............", lambda m: f"\\{m.group(0)}", p["name"]) + +def foo(): + if True: + if True: + return ( + lambda x: np.exp(cs(np.log(x.to(u.MeV).value))) * u.MeV * u.cm**2 / u.g + ) + +class C: + _is_recognized_dtype: Callable[[DtypeObj], bool] = lambda x: lib.is_np_dtype( + x, "M" + ) or isinstance(x, DatetimeTZDtype) + +class C: + def foo(): + if True: + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ), + ) + + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range[_chain_id, from_ts, to_ts], + ) + +def ddb(): + sql = ( + lambda var, table, n=N: f""" + CREATE TABLE {table} AS + SELECT ROW_NUMBER() OVER () AS id, {var} + FROM ( + SELECT {var} + FROM RANGE({n}) _ ({var}) + ORDER BY RANDOM() + ) + """ + ) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( # 1 + # 2 + lambda x, y, z: # 3 + # 4 + x + y + z # 5 + # 6 +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( + lambda x, y, z: x + y + z +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = lambda x, y, z: x + y + z + +very_long_variable_name_x, very_long_variable_name_y = lambda a: a + some_very_long_expression, lambda b: b * another_very_long_expression_here + +very_long_variable_name_for_result += lambda x: very_long_function_call_that_should_definitely_be_parenthesized_now(x, more_args, additional_parameters) + + +if 1: + if 2: + if 3: + if self.location in EVM_EVMLIKE_LOCATIONS and database is not None: + exported_dict["notes"] = EVM_ADDRESS_REGEX.sub( + repl=lambda matched_address: self._maybe_add_label_with_address( + database=database, + matched_address=matched_address, + ), + string=exported_dict["notes"], + ) + +class C: + def f(): + return dict( + filter( + lambda intent_response: self.is_retrieval_intent_response( + intent_response + ), + self.responses.items(), + ) + ) + +@pytest.mark.parametrize( + "op", + [ + # Not fluent + param( + lambda left, right: ( + ibis.timestamp("2017-04-01") + ), + ), + # These four are fluent and fit on one line inside the parenthesized + # lambda body + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date) + ), + ), + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) + ), + ), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date)), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date).between(left, right)), + # This is too long on one line in the lambda body and gets wrapped + # inside the body. + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right).between(left, right) + ), + ), + ], +) +def test_string_temporal_compare_between(con, op, left, right): ... + +[ + ( + lambda eval_df, _: MetricValue( + scores=eval_df["prediction"].tolist(), + aggregate_results={"prediction_sum": sum(eval_df["prediction"])}, + ) + ), +] + +# reuses the list parentheses +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] + +# adds parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz + +# removes parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx: (xxxxxxxxxxxxxxxxxxxx + 1) + +mapper = lambda x: dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] + +lambda x, y, z: ( + x + y + z +) + +lambda x, y, z: ( + x + y + z + # trailing body +) + +lambda x, y, z: ( + x + y + z # trailing eol body +) + +lambda x, y, z: ( + x + y + z +) # trailing lambda + +lambda x, y, z: ( + # leading body + x + y + z +) + +lambda x, y, z: ( # leading eol body + x + y + z +) + +( + lambda name: + source_bucket # trailing eol comment + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +x = ( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: # dangling header comment + ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: # dangling eol header comment + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: + # dangling header comment before call + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda left, right: + # comment + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda left, right: + ibis.timestamp("2017-04-01") # comment + .cast(dt.date) + .between(left, right) +) + +( + lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy: + # comment + [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] +) + +( + lambda x, y: + # comment + { + "key": x, + "another": y, + } +) + +( + lambda x, y: + # comment + ( + x, + y, + z + ) +) + +( + lambda x: + # comment + dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: + db_evmtx.count_transactions_in_range[ + # comment + _chain_id, from_ts, to_ts + ] +) + +( + lambda + # comment + *args, **kwargs: + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment + *args, **kwargs: + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment 1 + # comment 2 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment 1 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda *args, **kwargs: + # comment 1 + ( # comment 2 + # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 # comment 4 + # comment 5 + ) # comment 6 +) + +( + lambda *brgs, **kwargs: + # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( # comment 2 + # comment 3 + *brgs, **kwargs) + 1 # comment 4 + # comment 5 +) + +( + lambda *crgs, **kwargs: # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*crgs, **kwargs) + 1 +) + +( + lambda *drgs, **kwargs: # comment 1 + ( + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*drgs, **kwargs) + 1 + ) +) + +( + lambda * # comment 1 + ergs, ** + # comment 2 + kwargs # comment 3 + : # comment 4 + ( + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*ergs, **kwargs) + 1 + ) +) + +( + lambda # 1 + # 2 + left, # 3 + # 4 + right: # 5 + # 6 + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda x: # outer comment 1 + ( + lambda y: # inner comment 1 + # inner comment 2 + lambda z: ( + # innermost comment + x + y + z + ) + ) +) + +foo( + lambda from_ts, # comment prevents collapsing the parameters to one line + to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +foo( + lambda from_ts, # but still wrap the body if it gets too long + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_rangeeeeeeeeeeeeeeeeeeeeeeeeeeeee( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +transform = lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date).between(left, right).between(left, right) # trailing comment + +( + lambda: # comment + 1 +) + +( + lambda # comment + : + 1 +) + +( + lambda: + # comment + 1 +) + +( + lambda: # comment 1 + # comment 2 + 1 +) + +( + lambda # comment 1 + # comment 2 + : # comment 3 + # comment 4 + 1 +) + ( lambda * # comment 2 @@ -271,3 +789,18 @@ def a(): x: x ) + +( + lambda: # dangling-end-of-line + # dangling-own-line + ( # leading-body-end-of-line + x + ) +) + +( + lambda: # dangling-end-of-line + ( # leading-body-end-of-line + x + ) +) diff --git a/crates/ruff_python_formatter/src/builders.rs b/crates/ruff_python_formatter/src/builders.rs index 8d7aeb502b..8d3f701e59 100644 --- a/crates/ruff_python_formatter/src/builders.rs +++ b/crates/ruff_python_formatter/src/builders.rs @@ -1,4 +1,4 @@ -use ruff_formatter::{Argument, Arguments, write}; +use ruff_formatter::{Argument, Arguments, format_args, write}; use ruff_text_size::{Ranged, TextRange, TextSize}; use crate::context::{NodeLevel, WithNodeLevel}; @@ -33,20 +33,27 @@ impl<'ast> Format> for ParenthesizeIfExpands<'_, 'ast> { { let mut f = WithNodeLevel::new(NodeLevel::ParenthesizedExpression, f); - write!( - f, - [group(&format_with(|f| { - if_group_breaks(&token("(")).fmt(f)?; - - if self.indent { - soft_block_indent(&Arguments::from(&self.inner)).fmt(f)?; - } else { - Arguments::from(&self.inner).fmt(f)?; - } - - if_group_breaks(&token(")")).fmt(f) - }))] - ) + if self.indent { + let parens_id = f.group_id("indented_parenthesize_if_expands"); + group(&format_args![ + if_group_breaks(&token("(")), + indent_if_group_breaks( + &format_args![soft_line_break(), &Arguments::from(&self.inner)], + parens_id + ), + soft_line_break(), + if_group_breaks(&token(")")) + ]) + .with_id(Some(parens_id)) + .fmt(&mut f) + } else { + group(&format_args![ + if_group_breaks(&token("(")), + Arguments::from(&self.inner), + if_group_breaks(&token(")")), + ]) + .fmt(&mut f) + } } } } diff --git a/crates/ruff_python_formatter/src/expression/expr_lambda.rs b/crates/ruff_python_formatter/src/expression/expr_lambda.rs index f91666ecf7..faab6ef8c5 100644 --- a/crates/ruff_python_formatter/src/expression/expr_lambda.rs +++ b/crates/ruff_python_formatter/src/expression/expr_lambda.rs @@ -1,15 +1,21 @@ -use ruff_formatter::write; -use ruff_python_ast::AnyNodeRef; -use ruff_python_ast::ExprLambda; +use ruff_formatter::{FormatRuleWithOptions, RemoveSoftLinesBuffer, format_args, write}; +use ruff_python_ast::{AnyNodeRef, Expr, ExprLambda}; use ruff_text_size::Ranged; -use crate::comments::dangling_comments; -use crate::expression::parentheses::{NeedsParentheses, OptionalParentheses}; +use crate::builders::parenthesize_if_expands; +use crate::comments::{SourceComment, dangling_comments, leading_comments, trailing_comments}; +use crate::expression::parentheses::{ + NeedsParentheses, OptionalParentheses, Parentheses, is_expression_parenthesized, +}; +use crate::expression::{CallChainLayout, has_own_parentheses}; use crate::other::parameters::ParametersParentheses; use crate::prelude::*; +use crate::preview::is_parenthesize_lambda_bodies_enabled; #[derive(Default)] -pub struct FormatExprLambda; +pub struct FormatExprLambda { + layout: ExprLambdaLayout, +} impl FormatNodeRule for FormatExprLambda { fn fmt_fields(&self, item: &ExprLambda, f: &mut PyFormatter) -> FormatResult<()> { @@ -20,13 +26,19 @@ impl FormatNodeRule for FormatExprLambda { body, } = item; + let body = &**body; + let parameters = parameters.as_deref(); + let comments = f.context().comments().clone(); let dangling = comments.dangling(item); + let preview = is_parenthesize_lambda_bodies_enabled(f.context()); write!(f, [token("lambda")])?; - if let Some(parameters) = parameters { - // In this context, a dangling comment can either be a comment between the `lambda` the + // Format any dangling comments before the parameters, but save any dangling comments after + // the parameters/after the header to be formatted with the body below. + let dangling_header_comments = if let Some(parameters) = parameters { + // In this context, a dangling comment can either be a comment between the `lambda` and the // parameters, or a comment between the parameters and the body. let (dangling_before_parameters, dangling_after_parameters) = dangling .split_at(dangling.partition_point(|comment| comment.end() < parameters.start())); @@ -86,7 +98,7 @@ impl FormatNodeRule for FormatExprLambda { // *x: x // ) // ``` - if comments.has_leading(&**parameters) { + if comments.has_leading(parameters) { hard_line_break().fmt(f)?; } else { write!(f, [space()])?; @@ -95,32 +107,90 @@ impl FormatNodeRule for FormatExprLambda { write!(f, [dangling_comments(dangling_before_parameters)])?; } - write!( - f, - [parameters - .format() - .with_options(ParametersParentheses::Never)] - )?; - - write!(f, [token(":")])?; - - if dangling_after_parameters.is_empty() { - write!(f, [space()])?; + // Try to keep the parameters on a single line, unless there are intervening comments. + if preview && !comments.contains_comments(parameters.into()) { + let mut buffer = RemoveSoftLinesBuffer::new(f); + write!( + buffer, + [parameters + .format() + .with_options(ParametersParentheses::Never)] + )?; } else { - write!(f, [dangling_comments(dangling_after_parameters)])?; + write!( + f, + [parameters + .format() + .with_options(ParametersParentheses::Never)] + )?; } + + dangling_after_parameters } else { - write!(f, [token(":")])?; + dangling + }; - // In this context, a dangling comment is a comment between the `lambda` and the body. - if dangling.is_empty() { - write!(f, [space()])?; - } else { - write!(f, [dangling_comments(dangling)])?; - } + write!(f, [token(":")])?; + + if dangling_header_comments.is_empty() { + write!(f, [space()])?; + } else if !preview { + write!(f, [dangling_comments(dangling_header_comments)])?; } - write!(f, [body.format()]) + if !preview { + return body.format().fmt(f); + } + + let fmt_body = FormatBody { + body, + dangling_header_comments, + }; + + match self.layout { + ExprLambdaLayout::Assignment => fits_expanded(&fmt_body).fmt(f), + ExprLambdaLayout::Default => fmt_body.fmt(f), + } + } +} + +#[derive(Debug, Default, Copy, Clone)] +pub enum ExprLambdaLayout { + #[default] + Default, + + /// The [`ExprLambda`] is the direct child of an assignment expression, so it needs to use + /// `fits_expanded` to prefer parenthesizing its own body before the assignment tries to + /// parenthesize the whole lambda. For example, we want this formatting: + /// + /// ```py + /// long_assignment_target = lambda x, y, z: ( + /// x + y + z + /// ) + /// ``` + /// + /// instead of either of these: + /// + /// ```py + /// long_assignment_target = ( + /// lambda x, y, z: ( + /// x + y + z + /// ) + /// ) + /// + /// long_assignment_target = ( + /// lambda x, y, z: x + y + z + /// ) + /// ``` + Assignment, +} + +impl FormatRuleWithOptions> for FormatExprLambda { + type Options = ExprLambdaLayout; + + fn with_options(mut self, options: Self::Options) -> Self { + self.layout = options; + self } } @@ -137,3 +207,266 @@ impl NeedsParentheses for ExprLambda { } } } + +struct FormatBody<'a> { + body: &'a Expr, + + /// Dangling comments attached to the lambda header that should be formatted with the body. + /// + /// These can include both own-line and end-of-line comments. For lambdas with parameters, this + /// means comments after the parameters: + /// + /// ```py + /// ( + /// lambda x, y # 1 + /// # 2 + /// : # 3 + /// # 4 + /// x + y + /// ) + /// ``` + /// + /// Or all dangling comments for lambdas without parameters: + /// + /// ```py + /// ( + /// lambda # 1 + /// # 2 + /// : # 3 + /// # 4 + /// 1 + /// ) + /// ``` + /// + /// In most cases these should formatted within the parenthesized body, as in: + /// + /// ```py + /// ( + /// lambda: ( # 1 + /// # 2 + /// # 3 + /// # 4 + /// 1 + /// ) + /// ) + /// ``` + /// + /// or without `# 2`: + /// + /// ```py + /// ( + /// lambda: ( # 1 # 3 + /// # 4 + /// 1 + /// ) + /// ) + /// ``` + dangling_header_comments: &'a [SourceComment], +} + +impl Format> for FormatBody<'_> { + fn fmt(&self, f: &mut PyFormatter) -> FormatResult<()> { + let FormatBody { + dangling_header_comments, + body, + } = self; + + let body = *body; + let comments = f.context().comments().clone(); + let body_comments = comments.leading_dangling_trailing(body); + + if !dangling_header_comments.is_empty() { + // Split the dangling header comments into trailing comments formatted with the lambda + // header (1) and leading comments formatted with the body (2, 3, 4). + // + // ```python + // ( + // lambda # 1 + // # 2 + // : # 3 + // # 4 + // y + // ) + // ``` + // + // Note that these are split based on their line position rather than using + // `partition_point` based on a range, for example. + let (trailing_header_comments, leading_body_comments) = dangling_header_comments + .split_at( + dangling_header_comments + .iter() + .position(|comment| comment.line_position().is_own_line()) + .unwrap_or(dangling_header_comments.len()), + ); + + // If the body is parenthesized and has its own leading comments, preserve the + // separation between the dangling lambda comments and the body comments. For + // example, preserve this comment positioning: + // + // ```python + // ( + // lambda: # 1 + // # 2 + // ( # 3 + // x + // ) + // ) + // ``` + // + // 1 and 2 are dangling on the lambda and emitted first, followed by a hard line + // break and the parenthesized body with its leading comments. + // + // However, when removing 2, 1 and 3 can instead be formatted on the same line: + // + // ```python + // ( + // lambda: ( # 1 # 3 + // x + // ) + // ) + // ``` + let comments = f.context().comments(); + if is_expression_parenthesized(body.into(), comments.ranges(), f.context().source()) + && comments.has_leading(body) + { + trailing_comments(dangling_header_comments).fmt(f)?; + + // Note that `leading_body_comments` have already been formatted as part of + // `dangling_header_comments` above, but their presence still determines the spacing + // here. + if leading_body_comments.is_empty() { + space().fmt(f)?; + } else { + hard_line_break().fmt(f)?; + } + + body.format().with_options(Parentheses::Always).fmt(f) + } else { + write!( + f, + [ + space(), + token("("), + trailing_comments(trailing_header_comments), + block_indent(&format_args!( + leading_comments(leading_body_comments), + body.format().with_options(Parentheses::Never) + )), + token(")") + ] + ) + } + } + // If the body has comments, we always want to preserve the parentheses. This also + // ensures that we correctly handle parenthesized comments, and don't need to worry + // about them in the implementation below. + else if body_comments.has_leading() || body_comments.has_trailing_own_line() { + body.format().with_options(Parentheses::Always).fmt(f) + } + // Calls and subscripts require special formatting because they have their own + // parentheses, but they can also have an arbitrary amount of text before the + // opening parenthesis. We want to avoid cases where we keep a long callable on the + // same line as the lambda parameters. For example, `db_evmtx...` in: + // + // ```py + // transaction_count = self._query_txs_for_range( + // get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range( + // chain_id=_chain_id, + // from_ts=from_ts, + // to_ts=to_ts, + // ), + // ) + // ``` + // + // should cause the whole lambda body to be parenthesized instead: + // + // ```py + // transaction_count = self._query_txs_for_range( + // get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: ( + // db_evmtx.count_transactions_in_range( + // chain_id=_chain_id, + // from_ts=from_ts, + // to_ts=to_ts, + // ) + // ), + // ) + // ``` + else if matches!(body, Expr::Call(_) | Expr::Subscript(_)) { + let unparenthesized = body.format().with_options(Parentheses::Never); + if CallChainLayout::from_expression( + body.into(), + comments.ranges(), + f.context().source(), + ) == CallChainLayout::Fluent + { + parenthesize_if_expands(&unparenthesized).fmt(f) + } else { + let unparenthesized = unparenthesized.memoized(); + if unparenthesized.inspect(f)?.will_break() { + expand_parent().fmt(f)?; + } + + best_fitting![ + // body all flat + unparenthesized, + // body expanded + group(&unparenthesized).should_expand(true), + // parenthesized + format_args![token("("), block_indent(&unparenthesized), token(")")] + ] + .fmt(f) + } + } + // For other cases with their own parentheses, such as lists, sets, dicts, tuples, + // etc., we can just format the body directly. Their own formatting results in the + // lambda being formatted well too. For example: + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] + // ``` + // + // gets formatted as: + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: [ + // xxxxxxxxxxxxxxxxxxxx, + // yyyyyyyyyyyyyyyyyyyy, + // zzzzzzzzzzzzzzzzzzzz + // ] + // ``` + else if has_own_parentheses(body, f.context()).is_some() { + body.format().fmt(f) + } + // Finally, for expressions without their own parentheses, use + // `parenthesize_if_expands` to add parentheses around the body, only if it expands + // across multiple lines. The `Parentheses::Never` here also removes unnecessary + // parentheses around lambda bodies that fit on one line. For example: + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz + // ``` + // + // is formatted as: + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: ( + // xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz + // ) + // ``` + // + // while + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx: (xxxxxxxxxxxxxxxxxxxx + 1) + // ``` + // + // is formatted as: + // + // ```py + // lambda xxxxxxxxxxxxxxxxxxxx: xxxxxxxxxxxxxxxxxxxx + 1 + // ``` + else { + parenthesize_if_expands(&body.format().with_options(Parentheses::Never)).fmt(f) + } + } +} diff --git a/crates/ruff_python_formatter/src/preview.rs b/crates/ruff_python_formatter/src/preview.rs index 9d307390d6..62b6b90033 100644 --- a/crates/ruff_python_formatter/src/preview.rs +++ b/crates/ruff_python_formatter/src/preview.rs @@ -52,3 +52,10 @@ pub(crate) const fn is_avoid_parens_for_long_as_captures_enabled( ) -> bool { context.is_preview() } + +/// Returns `true` if the +/// [`parenthesize_lambda_bodies`](https://github.com/astral-sh/ruff/pull/21385) preview style is +/// enabled. +pub(crate) const fn is_parenthesize_lambda_bodies_enabled(context: &PyFormatContext) -> bool { + context.is_preview() +} diff --git a/crates/ruff_python_formatter/src/statement/stmt_assign.rs b/crates/ruff_python_formatter/src/statement/stmt_assign.rs index 5a16e5e8bf..52ebd710a6 100644 --- a/crates/ruff_python_formatter/src/statement/stmt_assign.rs +++ b/crates/ruff_python_formatter/src/statement/stmt_assign.rs @@ -9,6 +9,7 @@ use crate::comments::{ Comments, LeadingDanglingTrailingComments, SourceComment, trailing_comments, }; use crate::context::{NodeLevel, WithNodeLevel}; +use crate::expression::expr_lambda::ExprLambdaLayout; use crate::expression::parentheses::{ NeedsParentheses, OptionalParentheses, Parentheses, Parenthesize, is_expression_parenthesized, optional_parentheses, @@ -18,6 +19,7 @@ use crate::expression::{ maybe_parenthesize_expression, }; use crate::other::interpolated_string::InterpolatedStringLayout; +use crate::preview::is_parenthesize_lambda_bodies_enabled; use crate::statement::trailing_semicolon; use crate::string::StringLikeExtensions; use crate::string::implicit::{ @@ -303,12 +305,7 @@ impl Format> for FormatStatementsLastExpression<'_> { && format_implicit_flat.is_none() && format_interpolated_string.is_none() { - return maybe_parenthesize_expression( - value, - *statement, - Parenthesize::IfBreaks, - ) - .fmt(f); + return maybe_parenthesize_value(value, *statement).fmt(f); } let comments = f.context().comments().clone(); @@ -586,11 +583,7 @@ impl Format> for FormatStatementsLastExpression<'_> { space(), operator, space(), - maybe_parenthesize_expression( - value, - *statement, - Parenthesize::IfBreaks - ) + maybe_parenthesize_value(value, *statement) ] ); } @@ -1369,3 +1362,32 @@ fn is_attribute_with_parenthesized_value(target: &Expr, context: &PyFormatContex _ => false, } } + +/// Like [`maybe_parenthesize_expression`] but with special handling for lambdas in preview. +fn maybe_parenthesize_value<'a>( + expression: &'a Expr, + parent: AnyNodeRef<'a>, +) -> MaybeParenthesizeValue<'a> { + MaybeParenthesizeValue { expression, parent } +} + +struct MaybeParenthesizeValue<'a> { + expression: &'a Expr, + parent: AnyNodeRef<'a>, +} + +impl Format> for MaybeParenthesizeValue<'_> { + fn fmt(&self, f: &mut PyFormatter) -> FormatResult<()> { + let MaybeParenthesizeValue { expression, parent } = self; + + if is_parenthesize_lambda_bodies_enabled(f.context()) + && let Expr::Lambda(lambda) = expression + && !f.context().comments().has_leading(lambda) + { + parenthesize_if_expands(&lambda.format().with_options(ExprLambdaLayout::Assignment)) + .fmt(f) + } else { + maybe_parenthesize_expression(expression, *parent, Parenthesize::IfBreaks).fmt(f) + } + } +} diff --git a/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_long_strings.py.snap b/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_long_strings.py.snap index 7b36236110..ca59cec651 100644 --- a/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_long_strings.py.snap +++ b/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_long_strings.py.snap @@ -906,11 +906,10 @@ x = { -) +string_with_escaped_nameescape = "........................................................................... \\N{LAO KO LA}" --msg = lambda x: ( + msg = lambda x: ( - f"this is a very very very very long lambda value {x} that doesn't fit on a" - " single line" -+msg = ( -+ lambda x: f"this is a very very very very long lambda value {x} that doesn't fit on a single line" ++ f"this is a very very very very long lambda value {x} that doesn't fit on a single line" ) dict_with_lambda_values = { @@ -1403,8 +1402,8 @@ string_with_escaped_nameescape = ".............................................. string_with_escaped_nameescape = "........................................................................... \\N{LAO KO LA}" -msg = ( - lambda x: f"this is a very very very very long lambda value {x} that doesn't fit on a single line" +msg = lambda x: ( + f"this is a very very very very long lambda value {x} that doesn't fit on a single line" ) dict_with_lambda_values = { diff --git a/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_multiline_strings.py.snap b/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_multiline_strings.py.snap index 353d573496..29af6e1b07 100644 --- a/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_multiline_strings.py.snap +++ b/crates/ruff_python_formatter/tests/snapshots/black_compatibility@cases__preview_multiline_strings.py.snap @@ -375,7 +375,7 @@ a = b if """ # Another use case data = yaml.load("""\ a: 1 -@@ -77,19 +106,23 @@ +@@ -77,10 +106,12 @@ b: 2 """, ) @@ -390,19 +390,7 @@ a = b if """ MULTILINE = """ foo - """.replace("\n", "") --generated_readme = lambda project_name: """ -+generated_readme = ( -+ lambda project_name: """ - {} - - - """.strip().format(project_name) -+) - parser.usage += """ - Custom extra help summary. - -@@ -156,16 +189,24 @@ +@@ -156,16 +187,24 @@ 10 LOAD_CONST 0 (None) 12 RETURN_VALUE """ % (_C.__init__.__code__.co_firstlineno + 1,) @@ -433,7 +421,7 @@ a = b if """ [ """cow moos""", -@@ -206,7 +247,9 @@ +@@ -206,7 +245,9 @@ "c" ) @@ -444,7 +432,7 @@ a = b if """ assert some_var == expected_result, """ test -@@ -224,10 +267,8 @@ +@@ -224,10 +265,8 @@ """Sxxxxxxx xxxxxxxx, xxxxxxx xx xxxxxxxxx xxxxxxxxxxxxx xxxxxxx xxxxxxxxx xxx-xxxxxxxxxx xxxxxx xx xxx-xxxxxx""" ), @@ -457,7 +445,7 @@ a = b if """ }, } -@@ -246,14 +287,12 @@ +@@ -246,14 +285,12 @@ a a""" ), @@ -597,13 +585,11 @@ data = yaml.load( MULTILINE = """ foo """.replace("\n", "") -generated_readme = ( - lambda project_name: """ +generated_readme = lambda project_name: """ {} """.strip().format(project_name) -) parser.usage += """ Custom extra help summary. diff --git a/crates/ruff_python_formatter/tests/snapshots/format@expression__lambda.py.snap b/crates/ruff_python_formatter/tests/snapshots/format@expression__lambda.py.snap index 5997ff539a..82ee1639d7 100644 --- a/crates/ruff_python_formatter/tests/snapshots/format@expression__lambda.py.snap +++ b/crates/ruff_python_formatter/tests/snapshots/format@expression__lambda.py.snap @@ -131,6 +131,13 @@ lambda a, /, c: a *x: x ) +( + lambda + # comment + *x, + **y: x +) + ( lambda # comment 1 @@ -202,6 +209,17 @@ lambda: ( # comment x ) +( + lambda # 1 + # 2 + x, # 3 + # 4 + y + : # 5 + # 6 + x +) + ( lambda x, @@ -210,6 +228,71 @@ lambda: ( # comment z ) + +# Leading +lambda x: ( + lambda y: lambda z: x + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + z # Trailing +) # Trailing + + +# Leading +lambda x: lambda y: lambda z: [ + x, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + z +] # Trailing +# Trailing + lambda self, araa, kkkwargs=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs), e=1, f=2, g=2: d # Regression tests for https://github.com/astral-sh/ruff/issues/8179 @@ -234,6 +317,441 @@ def a(): g = 10 ) +def a(): + return b( + c, + d, + e, + f=lambda self, *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ) + 1, + ) + +# Additional ecosystem cases from https://github.com/astral-sh/ruff/pull/21385 +class C: + def foo(): + mock_service.return_value.bucket.side_effect = lambda name: ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) + +class C: + function_dict: Dict[Text, Callable[[CRFToken], Any]] = { + CRFEntityExtractorOptions.POS2: lambda crf_token: crf_token.pos_tag[:2] + if crf_token.pos_tag is not None + else None, + } + +name = re.sub(r"[^\x21\x23-\x5b\x5d-\x7e]...............", lambda m: f"\\{m.group(0)}", p["name"]) + +def foo(): + if True: + if True: + return ( + lambda x: np.exp(cs(np.log(x.to(u.MeV).value))) * u.MeV * u.cm**2 / u.g + ) + +class C: + _is_recognized_dtype: Callable[[DtypeObj], bool] = lambda x: lib.is_np_dtype( + x, "M" + ) or isinstance(x, DatetimeTZDtype) + +class C: + def foo(): + if True: + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ), + ) + + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range[_chain_id, from_ts, to_ts], + ) + +def ddb(): + sql = ( + lambda var, table, n=N: f""" + CREATE TABLE {table} AS + SELECT ROW_NUMBER() OVER () AS id, {var} + FROM ( + SELECT {var} + FROM RANGE({n}) _ ({var}) + ORDER BY RANDOM() + ) + """ + ) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( # 1 + # 2 + lambda x, y, z: # 3 + # 4 + x + y + z # 5 + # 6 +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( + lambda x, y, z: x + y + z +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = lambda x, y, z: x + y + z + +very_long_variable_name_x, very_long_variable_name_y = lambda a: a + some_very_long_expression, lambda b: b * another_very_long_expression_here + +very_long_variable_name_for_result += lambda x: very_long_function_call_that_should_definitely_be_parenthesized_now(x, more_args, additional_parameters) + + +if 1: + if 2: + if 3: + if self.location in EVM_EVMLIKE_LOCATIONS and database is not None: + exported_dict["notes"] = EVM_ADDRESS_REGEX.sub( + repl=lambda matched_address: self._maybe_add_label_with_address( + database=database, + matched_address=matched_address, + ), + string=exported_dict["notes"], + ) + +class C: + def f(): + return dict( + filter( + lambda intent_response: self.is_retrieval_intent_response( + intent_response + ), + self.responses.items(), + ) + ) + +@pytest.mark.parametrize( + "op", + [ + # Not fluent + param( + lambda left, right: ( + ibis.timestamp("2017-04-01") + ), + ), + # These four are fluent and fit on one line inside the parenthesized + # lambda body + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date) + ), + ), + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) + ), + ), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date)), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date).between(left, right)), + # This is too long on one line in the lambda body and gets wrapped + # inside the body. + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right).between(left, right) + ), + ), + ], +) +def test_string_temporal_compare_between(con, op, left, right): ... + +[ + ( + lambda eval_df, _: MetricValue( + scores=eval_df["prediction"].tolist(), + aggregate_results={"prediction_sum": sum(eval_df["prediction"])}, + ) + ), +] + +# reuses the list parentheses +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] + +# adds parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz + +# removes parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx: (xxxxxxxxxxxxxxxxxxxx + 1) + +mapper = lambda x: dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] + +lambda x, y, z: ( + x + y + z +) + +lambda x, y, z: ( + x + y + z + # trailing body +) + +lambda x, y, z: ( + x + y + z # trailing eol body +) + +lambda x, y, z: ( + x + y + z +) # trailing lambda + +lambda x, y, z: ( + # leading body + x + y + z +) + +lambda x, y, z: ( # leading eol body + x + y + z +) + +( + lambda name: + source_bucket # trailing eol comment + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +x = ( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: # dangling header comment + ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: # dangling eol header comment + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: + # dangling header comment before call + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda left, right: + # comment + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda left, right: + ibis.timestamp("2017-04-01") # comment + .cast(dt.date) + .between(left, right) +) + +( + lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy: + # comment + [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] +) + +( + lambda x, y: + # comment + { + "key": x, + "another": y, + } +) + +( + lambda x, y: + # comment + ( + x, + y, + z + ) +) + +( + lambda x: + # comment + dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: + db_evmtx.count_transactions_in_range[ + # comment + _chain_id, from_ts, to_ts + ] +) + +( + lambda + # comment + *args, **kwargs: + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment + *args, **kwargs: + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment 1 + # comment 2 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment 1 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda *args, **kwargs: + # comment 1 + ( # comment 2 + # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 # comment 4 + # comment 5 + ) # comment 6 +) + +( + lambda *brgs, **kwargs: + # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( # comment 2 + # comment 3 + *brgs, **kwargs) + 1 # comment 4 + # comment 5 +) + +( + lambda *crgs, **kwargs: # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*crgs, **kwargs) + 1 +) + +( + lambda *drgs, **kwargs: # comment 1 + ( + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*drgs, **kwargs) + 1 + ) +) + +( + lambda * # comment 1 + ergs, ** + # comment 2 + kwargs # comment 3 + : # comment 4 + ( + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*ergs, **kwargs) + 1 + ) +) + +( + lambda # 1 + # 2 + left, # 3 + # 4 + right: # 5 + # 6 + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda x: # outer comment 1 + ( + lambda y: # inner comment 1 + # inner comment 2 + lambda z: ( + # innermost comment + x + y + z + ) + ) +) + +foo( + lambda from_ts, # comment prevents collapsing the parameters to one line + to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +foo( + lambda from_ts, # but still wrap the body if it gets too long + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_rangeeeeeeeeeeeeeeeeeeeeeeeeeeeee( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +transform = lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date).between(left, right).between(left, right) # trailing comment + +( + lambda: # comment + 1 +) + +( + lambda # comment + : + 1 +) + +( + lambda: + # comment + 1 +) + +( + lambda: # comment 1 + # comment 2 + 1 +) + +( + lambda # comment 1 + # comment 2 + : # comment 3 + # comment 4 + 1 +) + ( lambda * # comment 2 @@ -277,6 +795,21 @@ def a(): x: x ) + +( + lambda: # dangling-end-of-line + # dangling-own-line + ( # leading-body-end-of-line + x + ) +) + +( + lambda: # dangling-end-of-line + ( # leading-body-end-of-line + x + ) +) ``` ## Output @@ -409,6 +942,12 @@ lambda a, /, c: a *x: x ) +( + lambda + # comment + *x, **y: x +) + ( lambda # comment 1 @@ -476,12 +1015,87 @@ lambda: ( # comment x ) +( + lambda # 1 + # 2 + x, # 3 + # 4 + y: # 5 + # 6 + x +) + ( lambda x, # comment y: z ) + +# Leading +lambda x: ( + lambda y: lambda z: x + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + y + + z # Trailing +) # Trailing + + +# Leading +lambda x: lambda y: lambda z: [ + x, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + y, + z, +] # Trailing +# Trailing + lambda self, araa, kkkwargs=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( *args, **kwargs ), e=1, f=2, g=2: d @@ -517,6 +1131,473 @@ def a(): ) +def a(): + return b( + c, + d, + e, + f=lambda self, + *args, + **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1, + ) + + +# Additional ecosystem cases from https://github.com/astral-sh/ruff/pull/21385 +class C: + def foo(): + mock_service.return_value.bucket.side_effect = lambda name: ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) + + +class C: + function_dict: Dict[Text, Callable[[CRFToken], Any]] = { + CRFEntityExtractorOptions.POS2: lambda crf_token: crf_token.pos_tag[:2] + if crf_token.pos_tag is not None + else None, + } + + +name = re.sub( + r"[^\x21\x23-\x5b\x5d-\x7e]...............", lambda m: f"\\{m.group(0)}", p["name"] +) + + +def foo(): + if True: + if True: + return ( + lambda x: np.exp(cs(np.log(x.to(u.MeV).value))) * u.MeV * u.cm**2 / u.g + ) + + +class C: + _is_recognized_dtype: Callable[[DtypeObj], bool] = lambda x: lib.is_np_dtype( + x, "M" + ) or isinstance(x, DatetimeTZDtype) + + +class C: + def foo(): + if True: + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ), + ) + + transaction_count = self._query_txs_for_range( + get_count_fn=lambda from_ts, + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_range[ + _chain_id, from_ts, to_ts + ], + ) + + +def ddb(): + sql = ( + lambda var, table, n=N: f""" + CREATE TABLE {table} AS + SELECT ROW_NUMBER() OVER () AS id, {var} + FROM ( + SELECT {var} + FROM RANGE({n}) _ ({var}) + ORDER BY RANDOM() + ) + """ + ) + + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( # 1 + # 2 + lambda x, y, z: # 3 + # 4 + x + y + z # 5 + # 6 +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( + lambda x, y, z: x + y + z +) + +long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( + lambda x, y, z: x + y + z +) + +very_long_variable_name_x, very_long_variable_name_y = ( + lambda a: a + some_very_long_expression, + lambda b: b * another_very_long_expression_here, +) + +very_long_variable_name_for_result += ( + lambda x: very_long_function_call_that_should_definitely_be_parenthesized_now( + x, more_args, additional_parameters + ) +) + + +if 1: + if 2: + if 3: + if self.location in EVM_EVMLIKE_LOCATIONS and database is not None: + exported_dict["notes"] = EVM_ADDRESS_REGEX.sub( + repl=lambda matched_address: self._maybe_add_label_with_address( + database=database, + matched_address=matched_address, + ), + string=exported_dict["notes"], + ) + + +class C: + def f(): + return dict( + filter( + lambda intent_response: self.is_retrieval_intent_response( + intent_response + ), + self.responses.items(), + ) + ) + + +@pytest.mark.parametrize( + "op", + [ + # Not fluent + param( + lambda left, right: (ibis.timestamp("2017-04-01")), + ), + # These four are fluent and fit on one line inside the parenthesized + # lambda body + param( + lambda left, right: (ibis.timestamp("2017-04-01").cast(dt.date)), + ), + param( + lambda left, right: ( + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) + ), + ), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date)), + param( + lambda left, right: ibis.timestamp("2017-04-01") + .cast(dt.date) + .between(left, right) + ), + # This is too long on one line in the lambda body and gets wrapped + # inside the body. + param( + lambda left, right: ( + ibis.timestamp("2017-04-01") + .cast(dt.date) + .between(left, right) + .between(left, right) + ), + ), + ], +) +def test_string_temporal_compare_between(con, op, left, right): ... + + +[ + ( + lambda eval_df, _: MetricValue( + scores=eval_df["prediction"].tolist(), + aggregate_results={"prediction_sum": sum(eval_df["prediction"])}, + ) + ), +] + +# reuses the list parentheses +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: [ + xxxxxxxxxxxxxxxxxxxx, + yyyyyyyyyyyyyyyyyyyy, + zzzzzzzzzzzzzzzzzzzz, +] + +# adds parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz + +# removes parentheses around the body +lambda xxxxxxxxxxxxxxxxxxxx: (xxxxxxxxxxxxxxxxxxxx + 1) + +mapper = lambda x: dict_with_default[ + np.nan if isinstance(x, float) and np.isnan(x) else x +] + +lambda x, y, z: (x + y + z) + +lambda x, y, z: ( + x + y + z + # trailing body +) + +lambda x, y, z: ( + x + y + z # trailing eol body +) + +lambda x, y, z: (x + y + z) # trailing lambda + +lambda x, y, z: ( + # leading body + x + y + z +) + +lambda x, y, z: ( # leading eol body + x + y + z +) + +( + lambda name: source_bucket # trailing eol comment + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +x = ( + lambda name: + # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +) + +( + lambda name: # dangling header comment + ( + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: # dangling eol header comment + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: + # dangling header comment before call + db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +( + lambda left, right: + # comment + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda left, right: ibis.timestamp("2017-04-01") # comment + .cast(dt.date) + .between(left, right) +) + +( + lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy: + # comment + [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] +) + +( + lambda x, y: + # comment + { + "key": x, + "another": y, + } +) + +( + lambda x, y: + # comment + (x, y, z) +) + +( + lambda x: + # comment + dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] +) + +( + lambda from_ts, to_ts, _chain_id=chain_id: db_evmtx.count_transactions_in_range[ + # comment + _chain_id, from_ts, to_ts + ] +) + +( + lambda + # comment + *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + + 1 +) + +( + lambda # comment + *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + + 1 +) + +( + lambda # comment 1 + # comment 2 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda # comment 1 + *args, **kwargs: # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 +) + +( + lambda *args, **kwargs: + # comment 1 + ( # comment 2 + # comment 3 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + + 1 # comment 4 + # comment 5 + ) # comment 6 +) + +( + lambda *brgs, **kwargs: + # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( # comment 2 + # comment 3 + *brgs, + **kwargs, + ) + + 1 # comment 4 + # comment 5 +) + +( + lambda *crgs, **kwargs: # comment 1 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*crgs, **kwargs) + 1 +) + +( + lambda *drgs, **kwargs: # comment 1 + (aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*drgs, **kwargs) + 1) +) + +( + lambda + # comment 1 + *ergs, + # comment 2 + **kwargs: # comment 3 + # comment 4 + (aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*ergs, **kwargs) + 1) +) + +( + lambda # 1 + # 2 + left, # 3 + # 4 + right: # 5 + # 6 + ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) +) + +( + lambda x: # outer comment 1 + ( + lambda y: # inner comment 1 + # inner comment 2 + lambda z: ( + # innermost comment + x + y + z + ) + ) +) + +foo( + lambda from_ts, # comment prevents collapsing the parameters to one line + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_range( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +foo( + lambda from_ts, # but still wrap the body if it gets too long + to_ts, + _chain_id=chain_id: db_evmtx.count_transactions_in_rangeeeeeeeeeeeeeeeeeeeeeeeeeeeee( + chain_id=_chain_id, + from_ts=from_ts, + to_ts=to_ts, + ) +) + +transform = ( + lambda left, right: ibis.timestamp("2017-04-01") + .cast(dt.date) + .between(left, right) + .between(left, right) +) # trailing comment + +( + lambda: # comment + 1 +) + +( + lambda: # comment + 1 +) + +( + lambda: + # comment + 1 +) + +( + lambda: # comment 1 + # comment 2 + 1 +) + +( + lambda: # comment 1 + # comment 2 + # comment 3 + # comment 4 + 1 +) + ( lambda # comment 2 @@ -553,4 +1634,928 @@ def a(): # comment 1 **x: x ) + +( + lambda: # dangling-end-of-line + # dangling-own-line + ( # leading-body-end-of-line + x + ) +) + +( + lambda: # dangling-end-of-line + ( # leading-body-end-of-line + x + ) +) +``` + + +## Preview changes +```diff +--- Stable ++++ Preview +@@ -27,35 +27,14 @@ + # Trailing + + # Leading +-lambda x: lambda y: lambda z: ( +- x, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- z, ++lambda x: ( ++ lambda y: ( ++ lambda z: (x, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, z) ++ ) + ) # Trailing + # Trailing + +-a = ( +- lambda: # Dangling ++a = lambda: ( # Dangling + 1 + ) + +@@ -74,7 +53,9 @@ + + # lambda arguments don't have parentheses, so we never add a magic trailing comma ... + def f( +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa: bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb = lambda x: y, ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa: bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb = lambda x: ( ++ y ++ ), + ): + pass + +@@ -102,22 +83,25 @@ + + # Dangling comments without parameters. + ( +- lambda: # 3 +- None ++ lambda: ( # 3 ++ None ++ ) + ) + + ( +- lambda: +- # 3 +- None ++ lambda: ( ++ # 3 ++ None ++ ) + ) + + ( +- lambda: # 1 +- # 2 +- # 3 +- # 4 +- None # 5 ++ lambda: ( # 1 ++ # 2 ++ # 3 ++ # 4 ++ None ++ ) # 5 + ) + + ( +@@ -136,16 +120,18 @@ + lambda + # comment 1 + # comment 2 +- *x: +- # comment 3 +- x ++ *x: ( ++ # comment 3 ++ x ++ ) + ) + + ( + lambda # comment 1 + # comment 2 +- *x: # comment 3 +- x ++ *x: ( # comment 3 ++ x ++ ) + ) + + lambda *x: x +@@ -161,30 +147,33 @@ + ) + + ( +- lambda: # comment +- x ++ lambda: ( # comment ++ x ++ ) + ) + + ( +- lambda: +- # comment +- x ++ lambda: ( ++ # comment ++ x ++ ) + ) + + ( +- lambda: # comment +- x ++ lambda: ( # comment ++ x ++ ) + ) + + ( +- lambda: +- # comment +- x ++ lambda: ( ++ # comment ++ x ++ ) + ) + + ( +- lambda: # comment +- ( # comment ++ lambda: ( # comment # comment + x + ) + ) +@@ -192,11 +181,12 @@ + ( + lambda # 1 + # 2 +- x: # 3 +- # 4 +- # 5 +- # 6 +- x ++ x: ( # 3 ++ # 4 ++ # 5 ++ # 6 ++ x ++ ) + ) + + ( +@@ -204,9 +194,10 @@ + # 2 + x, # 3 + # 4 +- y: # 5 +- # 6 +- x ++ y: ( # 5 ++ # 6 ++ x ++ ) + ) + + ( +@@ -218,71 +209,79 @@ + + # Leading + lambda x: ( +- lambda y: lambda z: x +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + y +- + z # Trailing ++ lambda y: ( ++ lambda z: ( ++ x ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + y ++ + z ++ ) ++ ) # Trailing + ) # Trailing + + + # Leading +-lambda x: lambda y: lambda z: [ +- x, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- y, +- z, +-] # Trailing ++lambda x: ( ++ lambda y: ( ++ lambda z: [ ++ x, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ y, ++ z, ++ ] ++ ) ++) # Trailing + # Trailing + +-lambda self, araa, kkkwargs=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( +- *args, **kwargs +-), e=1, f=2, g=2: d ++lambda self, araa, kkkwargs=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs), e=1, f=2, g=2: ( ++ d ++) + + + # Regression tests for https://github.com/astral-sh/ruff/issues/8179 +@@ -291,9 +290,9 @@ + c, + d, + e, +- f=lambda self, +- *args, +- **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs), ++ f=lambda self, *args, **kwargs: ( ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) ++ ), + ) + + +@@ -302,15 +301,9 @@ + c, + d, + e, +- f=lambda self, +- araa, +- kkkwargs, +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, +- args, +- kwargs, +- e=1, +- f=2, +- g=2: d, ++ f=lambda self, araa, kkkwargs, aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, args, kwargs, e=1, f=2, g=2: ( ++ d ++ ), + g=10, + ) + +@@ -320,9 +313,9 @@ + c, + d, + e, +- f=lambda self, +- *args, +- **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1, ++ f=lambda self, *args, **kwargs: ( ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ ), + ) + + +@@ -338,9 +331,9 @@ + + class C: + function_dict: Dict[Text, Callable[[CRFToken], Any]] = { +- CRFEntityExtractorOptions.POS2: lambda crf_token: crf_token.pos_tag[:2] +- if crf_token.pos_tag is not None +- else None, ++ CRFEntityExtractorOptions.POS2: lambda crf_token: ( ++ crf_token.pos_tag[:2] if crf_token.pos_tag is not None else None ++ ), + } + + +@@ -352,42 +345,40 @@ + def foo(): + if True: + if True: +- return ( +- lambda x: np.exp(cs(np.log(x.to(u.MeV).value))) * u.MeV * u.cm**2 / u.g ++ return lambda x: ( ++ np.exp(cs(np.log(x.to(u.MeV).value))) * u.MeV * u.cm**2 / u.g + ) + + + class C: +- _is_recognized_dtype: Callable[[DtypeObj], bool] = lambda x: lib.is_np_dtype( +- x, "M" +- ) or isinstance(x, DatetimeTZDtype) ++ _is_recognized_dtype: Callable[[DtypeObj], bool] = lambda x: ( ++ lib.is_np_dtype(x, "M") or isinstance(x, DatetimeTZDtype) ++ ) + + + class C: + def foo(): + if True: + transaction_count = self._query_txs_for_range( +- get_count_fn=lambda from_ts, +- to_ts, +- _chain_id=chain_id: db_evmtx.count_transactions_in_range( +- chain_id=_chain_id, +- from_ts=from_ts, +- to_ts=to_ts, ++ get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: ( ++ db_evmtx.count_transactions_in_range( ++ chain_id=_chain_id, ++ from_ts=from_ts, ++ to_ts=to_ts, ++ ) + ), + ) + + transaction_count = self._query_txs_for_range( +- get_count_fn=lambda from_ts, +- to_ts, +- _chain_id=chain_id: db_evmtx.count_transactions_in_range[ +- _chain_id, from_ts, to_ts +- ], ++ get_count_fn=lambda from_ts, to_ts, _chain_id=chain_id: ( ++ db_evmtx.count_transactions_in_range[_chain_id, from_ts, to_ts] ++ ), + ) + + + def ddb(): +- sql = ( +- lambda var, table, n=N: f""" ++ sql = lambda var, table, n=N: ( ++ f""" + CREATE TABLE {table} AS + SELECT ROW_NUMBER() OVER () AS id, {var} + FROM ( +@@ -401,18 +392,19 @@ + + long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( # 1 + # 2 +- lambda x, y, z: # 3 +- # 4 +- x + y + z # 5 ++ lambda x, y, z: ( # 3 ++ # 4 ++ x + y + z ++ ) # 5 + # 6 + ) + +-long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( +- lambda x, y, z: x + y + z ++long_assignment_target.with_attribute.and_a_slice[with_an_index] = lambda x, y, z: ( ++ x + y + z + ) + +-long_assignment_target.with_attribute.and_a_slice[with_an_index] = ( +- lambda x, y, z: x + y + z ++long_assignment_target.with_attribute.and_a_slice[with_an_index] = lambda x, y, z: ( ++ x + y + z + ) + + very_long_variable_name_x, very_long_variable_name_y = ( +@@ -420,8 +412,8 @@ + lambda b: b * another_very_long_expression_here, + ) + +-very_long_variable_name_for_result += ( +- lambda x: very_long_function_call_that_should_definitely_be_parenthesized_now( ++very_long_variable_name_for_result += lambda x: ( ++ very_long_function_call_that_should_definitely_be_parenthesized_now( + x, more_args, additional_parameters + ) + ) +@@ -457,12 +449,12 @@ + [ + # Not fluent + param( +- lambda left, right: (ibis.timestamp("2017-04-01")), ++ lambda left, right: ibis.timestamp("2017-04-01"), + ), + # These four are fluent and fit on one line inside the parenthesized + # lambda body + param( +- lambda left, right: (ibis.timestamp("2017-04-01").cast(dt.date)), ++ lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date), + ), + param( + lambda left, right: ( +@@ -471,9 +463,9 @@ + ), + param(lambda left, right: ibis.timestamp("2017-04-01").cast(dt.date)), + param( +- lambda left, right: ibis.timestamp("2017-04-01") +- .cast(dt.date) +- .between(left, right) ++ lambda left, right: ( ++ ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) ++ ) + ), + # This is too long on one line in the lambda body and gets wrapped + # inside the body. +@@ -507,16 +499,18 @@ + ] + + # adds parentheses around the body +-lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz ++lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz: ( ++ xxxxxxxxxxxxxxxxxxxx + yyyyyyyyyyyyyyyyyyyy + zzzzzzzzzzzzzzzzzzzz ++) + + # removes parentheses around the body +-lambda xxxxxxxxxxxxxxxxxxxx: (xxxxxxxxxxxxxxxxxxxx + 1) ++lambda xxxxxxxxxxxxxxxxxxxx: xxxxxxxxxxxxxxxxxxxx + 1 + + mapper = lambda x: dict_with_default[ + np.nan if isinstance(x, float) and np.isnan(x) else x + ] + +-lambda x, y, z: (x + y + z) ++lambda x, y, z: x + y + z + + lambda x, y, z: ( + x + y + z +@@ -527,7 +521,7 @@ + x + y + z # trailing eol body + ) + +-lambda x, y, z: (x + y + z) # trailing lambda ++lambda x, y, z: x + y + z # trailing lambda + + lambda x, y, z: ( + # leading body +@@ -539,21 +533,23 @@ + ) + + ( +- lambda name: source_bucket # trailing eol comment +- if name == source_bucket_name +- else storage.Bucket(mock_service, destination_bucket_name) ++ lambda name: ( ++ source_bucket # trailing eol comment ++ if name == source_bucket_name ++ else storage.Bucket(mock_service, destination_bucket_name) ++ ) + ) + + ( +- lambda name: +- # dangling header comment +- source_bucket +- if name == source_bucket_name +- else storage.Bucket(mock_service, destination_bucket_name) ++ lambda name: ( ++ # dangling header comment ++ source_bucket ++ if name == source_bucket_name ++ else storage.Bucket(mock_service, destination_bucket_name) ++ ) + ) + +-x = ( +- lambda name: ++x = lambda name: ( + # dangling header comment + source_bucket + if name == source_bucket_name +@@ -561,8 +557,7 @@ + ) + + ( +- lambda name: # dangling header comment +- ( ++ lambda name: ( # dangling header comment + source_bucket + if name == source_bucket_name + else storage.Bucket(mock_service, destination_bucket_name) +@@ -570,61 +565,70 @@ + ) + + ( +- lambda from_ts, to_ts, _chain_id=chain_id: # dangling eol header comment +- db_evmtx.count_transactions_in_range( +- chain_id=_chain_id, +- from_ts=from_ts, +- to_ts=to_ts, ++ lambda from_ts, to_ts, _chain_id=chain_id: ( # dangling eol header comment ++ db_evmtx.count_transactions_in_range( ++ chain_id=_chain_id, ++ from_ts=from_ts, ++ to_ts=to_ts, ++ ) + ) + ) + + ( +- lambda from_ts, to_ts, _chain_id=chain_id: +- # dangling header comment before call +- db_evmtx.count_transactions_in_range( +- chain_id=_chain_id, +- from_ts=from_ts, +- to_ts=to_ts, ++ lambda from_ts, to_ts, _chain_id=chain_id: ( ++ # dangling header comment before call ++ db_evmtx.count_transactions_in_range( ++ chain_id=_chain_id, ++ from_ts=from_ts, ++ to_ts=to_ts, ++ ) + ) + ) + + ( +- lambda left, right: +- # comment +- ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) ++ lambda left, right: ( ++ # comment ++ ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) ++ ) + ) + + ( +- lambda left, right: ibis.timestamp("2017-04-01") # comment +- .cast(dt.date) +- .between(left, right) ++ lambda left, right: ( ++ ibis.timestamp("2017-04-01") # comment ++ .cast(dt.date) ++ .between(left, right) ++ ) + ) + + ( +- lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy: +- # comment +- [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] ++ lambda xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy: ( ++ # comment ++ [xxxxxxxxxxxxxxxxxxxx, yyyyyyyyyyyyyyyyyyyy, zzzzzzzzzzzzzzzzzzzz] ++ ) + ) + + ( +- lambda x, y: +- # comment +- { +- "key": x, +- "another": y, +- } ++ lambda x, y: ( ++ # comment ++ { ++ "key": x, ++ "another": y, ++ } ++ ) + ) + + ( +- lambda x, y: +- # comment +- (x, y, z) ++ lambda x, y: ( ++ # comment ++ (x, y, z) ++ ) + ) + + ( +- lambda x: +- # comment +- dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] ++ lambda x: ( ++ # comment ++ dict_with_default[np.nan if isinstance(x, float) and np.isnan(x) else x] ++ ) + ) + + ( +@@ -637,27 +641,31 @@ + ( + lambda + # comment +- *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) +- + 1 ++ *args, **kwargs: ( ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ ) + ) + + ( + lambda # comment +- *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) +- + 1 ++ *args, **kwargs: ( ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ ) + ) + + ( + lambda # comment 1 + # comment 2 +- *args, **kwargs: # comment 3 +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ *args, **kwargs: ( # comment 3 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ ) + ) + + ( + lambda # comment 1 +- *args, **kwargs: # comment 3 +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ *args, **kwargs: ( # comment 3 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 ++ ) + ) + + ( +@@ -672,25 +680,28 @@ + ) + + ( +- lambda *brgs, **kwargs: +- # comment 1 +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( # comment 2 +- # comment 3 +- *brgs, +- **kwargs, +- ) +- + 1 # comment 4 ++ lambda *brgs, **kwargs: ( ++ # comment 1 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( # comment 2 ++ # comment 3 ++ *brgs, ++ **kwargs, ++ ) ++ + 1 ++ ) # comment 4 + # comment 5 + ) + + ( +- lambda *crgs, **kwargs: # comment 1 +- aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*crgs, **kwargs) + 1 ++ lambda *crgs, **kwargs: ( # comment 1 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*crgs, **kwargs) + 1 ++ ) + ) + + ( +- lambda *drgs, **kwargs: # comment 1 +- (aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*drgs, **kwargs) + 1) ++ lambda *drgs, **kwargs: ( # comment 1 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*drgs, **kwargs) + 1 ++ ) + ) + + ( +@@ -698,9 +709,9 @@ + # comment 1 + *ergs, + # comment 2 +- **kwargs: # comment 3 +- # comment 4 +- (aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*ergs, **kwargs) + 1) ++ **kwargs: ( # comment 3 # comment 4 ++ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*ergs, **kwargs) + 1 ++ ) + ) + + ( +@@ -708,19 +719,20 @@ + # 2 + left, # 3 + # 4 +- right: # 5 +- # 6 +- ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) ++ right: ( # 5 ++ # 6 ++ ibis.timestamp("2017-04-01").cast(dt.date).between(left, right) ++ ) + ) + + ( +- lambda x: # outer comment 1 +- ( +- lambda y: # inner comment 1 +- # inner comment 2 +- lambda z: ( +- # innermost comment +- x + y + z ++ lambda x: ( # outer comment 1 ++ lambda y: ( # inner comment 1 ++ # inner comment 2 ++ lambda z: ( ++ # innermost comment ++ x + y + z ++ ) + ) + ) + ) +@@ -738,48 +750,52 @@ + foo( + lambda from_ts, # but still wrap the body if it gets too long + to_ts, +- _chain_id=chain_id: db_evmtx.count_transactions_in_rangeeeeeeeeeeeeeeeeeeeeeeeeeeeee( +- chain_id=_chain_id, +- from_ts=from_ts, +- to_ts=to_ts, ++ _chain_id=chain_id: ( ++ db_evmtx.count_transactions_in_rangeeeeeeeeeeeeeeeeeeeeeeeeeeeee( ++ chain_id=_chain_id, ++ from_ts=from_ts, ++ to_ts=to_ts, ++ ) + ) + ) + +-transform = ( +- lambda left, right: ibis.timestamp("2017-04-01") +- .cast(dt.date) +- .between(left, right) +- .between(left, right) ++transform = lambda left, right: ( ++ ibis.timestamp("2017-04-01").cast(dt.date).between(left, right).between(left, right) + ) # trailing comment + + ( +- lambda: # comment +- 1 ++ lambda: ( # comment ++ 1 ++ ) + ) + + ( +- lambda: # comment +- 1 ++ lambda: ( # comment ++ 1 ++ ) + ) + + ( +- lambda: +- # comment +- 1 ++ lambda: ( ++ # comment ++ 1 ++ ) + ) + + ( +- lambda: # comment 1 +- # comment 2 +- 1 ++ lambda: ( # comment 1 ++ # comment 2 ++ 1 ++ ) + ) + + ( +- lambda: # comment 1 +- # comment 2 +- # comment 3 +- # comment 4 +- 1 ++ lambda: ( # comment 1 ++ # comment 2 ++ # comment 3 ++ # comment 4 ++ 1 ++ ) + ) + + ( +@@ -828,8 +844,7 @@ + ) + + ( +- lambda: # dangling-end-of-line +- ( # leading-body-end-of-line ++ lambda: ( # dangling-end-of-line # leading-body-end-of-line + x + ) + ) ``` diff --git a/crates/ruff_python_formatter/tests/snapshots/format@multiline_string_deviations.py.snap b/crates/ruff_python_formatter/tests/snapshots/format@multiline_string_deviations.py.snap index c4fde9b127..9504e52ae8 100644 --- a/crates/ruff_python_formatter/tests/snapshots/format@multiline_string_deviations.py.snap +++ b/crates/ruff_python_formatter/tests/snapshots/format@multiline_string_deviations.py.snap @@ -1,7 +1,6 @@ --- source: crates/ruff_python_formatter/tests/fixtures.rs input_file: crates/ruff_python_formatter/resources/test/fixtures/ruff/multiline_string_deviations.py -snapshot_kind: text --- ## Input ```python @@ -106,3 +105,22 @@ generated_readme = ( """.strip().format(project_name) ) ``` + + +## Preview changes +```diff +--- Stable ++++ Preview +@@ -44,10 +44,8 @@ + # this by changing `Lambda::needs_parentheses` to return `BestFit` but it causes + # issues when the lambda has comments. + # Let's keep this as a known deviation for now. +-generated_readme = ( +- lambda project_name: """ ++generated_readme = lambda project_name: """ + {} + + + """.strip().format(project_name) +-) +``` diff --git a/crates/ruff_wasm/Cargo.toml b/crates/ruff_wasm/Cargo.toml index a83171ab4b..254f6d5fdc 100644 --- a/crates/ruff_wasm/Cargo.toml +++ b/crates/ruff_wasm/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff_wasm" -version = "0.14.8" +version = "0.14.9" publish = false authors = { workspace = true } edition = { workspace = true } diff --git a/crates/ty/docs/configuration.md b/crates/ty/docs/configuration.md index 4ecf8f8399..0768f1b26a 100644 --- a/crates/ty/docs/configuration.md +++ b/crates/ty/docs/configuration.md @@ -158,7 +158,7 @@ If left unspecified, ty will try to detect common project layouts and initialize * if a `.//` directory exists, include `.` and `./` in the first party search path * otherwise, default to `.` (flat layout) -Besides, if a `./python` or `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file), +Additionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file), it will also be included in the first party search path. **Default value**: `null` @@ -443,7 +443,7 @@ If left unspecified, ty will try to detect common project layouts and initialize * if a `.//` directory exists, include `.` and `./` in the first party search path * otherwise, default to `.` (flat layout) -Besides, if a `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` file), +Additionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` file), it will also be included in the first party search path. **Default value**: `null` diff --git a/crates/ty/tests/cli/python_environment.rs b/crates/ty/tests/cli/python_environment.rs index 1f3479d2fd..bd15d1076a 100644 --- a/crates/ty/tests/cli/python_environment.rs +++ b/crates/ty/tests/cli/python_environment.rs @@ -2390,14 +2390,14 @@ fn default_root_flat_layout() -> anyhow::Result<()> { fn default_root_tests_folder() -> anyhow::Result<()> { let case = CliTest::with_files([ ("src/foo.py", "foo = 10"), - ("tests/bar.py", "bar = 20"), + ("tests/bar.py", "baz = 20"), ( "tests/test_bar.py", r#" from foo import foo - from bar import bar + from bar import baz - print(f"{foo} {bar}") + print(f"{foo} {baz}") "#, ), ])?; diff --git a/crates/ty_ide/src/hover.rs b/crates/ty_ide/src/hover.rs index 8430a46edc..7389b4c1cc 100644 --- a/crates/ty_ide/src/hover.rs +++ b/crates/ty_ide/src/hover.rs @@ -3624,6 +3624,37 @@ def function(): assert_snapshot!(test.hover(), @"Hover provided no content"); } + #[test] + fn hover_named_expression_target() { + let test = CursorTest::builder() + .source( + "mymod.py", + r#" + if a := 10: + pass + "#, + ) + .build(); + + assert_snapshot!(test.hover(), @r###" + Literal[10] + --------------------------------------------- + ```python + Literal[10] + ``` + --------------------------------------------- + info[hover]: Hovered content is + --> mymod.py:2:4 + | + 2 | if a := 10: + | ^- Cursor offset + | | + | source + 3 | pass + | + "###); + } + impl CursorTest { fn hover(&self) -> String { use std::fmt::Write; diff --git a/crates/ty_ide/src/inlay_hints.rs b/crates/ty_ide/src/inlay_hints.rs index d0742f58ec..4f9858e61e 100644 --- a/crates/ty_ide/src/inlay_hints.rs +++ b/crates/ty_ide/src/inlay_hints.rs @@ -6017,9 +6017,9 @@ mod tests { fn test_function_signature_inlay_hint() { let mut test = inlay_hint_test( " - def foo(x: int, *y: bool, z: str | int | list[str]): ... + def foo(x: int, *y: bool, z: str | int | list[str]): ... - a = foo", + a = foo", ); assert_snapshot!(test.inlay_hints(), @r#" @@ -6158,18 +6158,35 @@ mod tests { fn test_module_inlay_hint() { let mut test = inlay_hint_test( " - import foo + import foo - a = foo", + a = foo", ); test.with_extra_file("foo.py", "'''Foo module'''"); - assert_snapshot!(test.inlay_hints(), @r" + assert_snapshot!(test.inlay_hints(), @r#" import foo a[: ] = foo --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:423:7 + | + 422 | @disjoint_base + 423 | class ModuleType: + | ^^^^^^^^^^ + 424 | """Create a module object. + | + info: Source + --> main2.py:4:6 + | + 2 | import foo + 3 | + 4 | a[: ] = foo + | ^^^^^^ + | + info[inlay-hint-location]: Inlay Hint Target --> foo.py:1:1 | @@ -6177,32 +6194,531 @@ mod tests { | ^^^^^^^^^^^^^^^^ | info: Source - --> main2.py:4:5 + --> main2.py:4:14 | 2 | import foo 3 | 4 | a[: ] = foo - | ^^^^^^^^^^^^^^ + | ^^^ | - "); + "#); } #[test] fn test_literal_type_alias_inlay_hint() { let mut test = inlay_hint_test( " - from typing import Literal + from typing import Literal - a = Literal['a', 'b', 'c']", + a = Literal['a', 'b', 'c']", ); assert_snapshot!(test.inlay_hints(), @r#" from typing import Literal a[: ] = Literal['a', 'b', 'c'] + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:351:1 + | + 349 | Final: _SpecialForm + 350 | + 351 | Literal: _SpecialForm + | ^^^^^^^ + 352 | TypedDict: _SpecialForm + | + info: Source + --> main2.py:4:20 + | + 2 | from typing import Literal + 3 | + 4 | a[: ] = Literal['a', 'b', 'c'] + | ^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/builtins.pyi:915:7 + | + 914 | @disjoint_base + 915 | class str(Sequence[str]): + | ^^^ + 916 | """str(object='') -> str + 917 | str(bytes_or_buffer[, encoding[, errors]]) -> str + | + info: Source + --> main2.py:4:28 + | + 2 | from typing import Literal + 3 | + 4 | a[: ] = Literal['a', 'b', 'c'] + | ^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/builtins.pyi:915:7 + | + 914 | @disjoint_base + 915 | class str(Sequence[str]): + | ^^^ + 916 | """str(object='') -> str + 917 | str(bytes_or_buffer[, encoding[, errors]]) -> str + | + info: Source + --> main2.py:4:33 + | + 2 | from typing import Literal + 3 | + 4 | a[: ] = Literal['a', 'b', 'c'] + | ^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/builtins.pyi:915:7 + | + 914 | @disjoint_base + 915 | class str(Sequence[str]): + | ^^^ + 916 | """str(object='') -> str + 917 | str(bytes_or_buffer[, encoding[, errors]]) -> str + | + info: Source + --> main2.py:4:38 + | + 2 | from typing import Literal + 3 | + 4 | a[: ] = Literal['a', 'b', 'c'] + | ^^^ + | "#); } + #[test] + fn test_wrapper_descriptor_inlay_hint() { + let mut test = inlay_hint_test( + " + from types import FunctionType + + a = FunctionType.__get__", + ); + + assert_snapshot!(test.inlay_hints(), @r#" + from types import FunctionType + + a[: ] = FunctionType.__get__ + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:670:7 + | + 669 | @final + 670 | class WrapperDescriptorType: + | ^^^^^^^^^^^^^^^^^^^^^ + 671 | @property + 672 | def __name__(self) -> str: ... + | + info: Source + --> main2.py:4:6 + | + 2 | from types import FunctionType + 3 | + 4 | a[: ] = FunctionType.__get__ + | ^^^^^^^^^^^^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:77:7 + | + 75 | # Make sure this class definition stays roughly in line with `builtins.function` + 76 | @final + 77 | class FunctionType: + | ^^^^^^^^^^^^ + 78 | """Create a function object. + | + info: Source + --> main2.py:4:39 + | + 2 | from types import FunctionType + 3 | + 4 | a[: ] = FunctionType.__get__ + | ^^^^^^^^ + | + "#); + } + + #[test] + fn test_method_wrapper_inlay_hint() { + let mut test = inlay_hint_test( + " + def f(): ... + + a = f.__call__", + ); + + assert_snapshot!(test.inlay_hints(), @r#" + def f(): ... + + a[: ] = f.__call__ + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:684:7 + | + 683 | @final + 684 | class MethodWrapperType: + | ^^^^^^^^^^^^^^^^^ + 685 | @property + 686 | def __self__(self) -> object: ... + | + info: Source + --> main2.py:4:6 + | + 2 | def f(): ... + 3 | + 4 | a[: ] = f.__call__ + | ^^^^^^^^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:134:9 + | + 132 | ) -> Self: ... + 133 | + 134 | def __call__(self, *args: Any, **kwargs: Any) -> Any: + | ^^^^^^^^ + 135 | """Call self as a function.""" + | + info: Source + --> main2.py:4:22 + | + 2 | def f(): ... + 3 | + 4 | a[: ] = f.__call__ + | ^^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/types.pyi:77:7 + | + 75 | # Make sure this class definition stays roughly in line with `builtins.function` + 76 | @final + 77 | class FunctionType: + | ^^^^^^^^^^^^ + 78 | """Create a function object. + | + info: Source + --> main2.py:4:35 + | + 2 | def f(): ... + 3 | + 4 | a[: ] = f.__call__ + | ^^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> main.py:2:5 + | + 2 | def f(): ... + | ^ + 3 | + 4 | a = f.__call__ + | + info: Source + --> main2.py:4:45 + | + 2 | def f(): ... + 3 | + 4 | a[: ] = f.__call__ + | ^ + | + "#); + } + + #[test] + fn test_newtype_inlay_hint() { + let mut test = inlay_hint_test( + " + from typing import NewType + + N = NewType('N', str) + + Y = N", + ); + + assert_snapshot!(test.inlay_hints(), @r#" + from typing import NewType + + N[: ] = NewType([name=]'N', [tp=]str) + + Y[: ] = N + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:615:11 + | + 613 | TypeGuard: _SpecialForm + 614 | + 615 | class NewType: + | ^^^^^^^ + 616 | """NewType creates simple unique types with almost zero runtime overhead. + | + info: Source + --> main2.py:4:6 + | + 2 | from typing import NewType + 3 | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + | ^^^^^^^ + 5 | + 6 | Y[: ] = N + | + + info[inlay-hint-location]: Inlay Hint Target + --> main.py:4:1 + | + 2 | from typing import NewType + 3 | + 4 | N = NewType('N', str) + | ^ + 5 | + 6 | Y = N + | + info: Source + --> main2.py:4:28 + | + 2 | from typing import NewType + 3 | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + | ^ + 5 | + 6 | Y[: ] = N + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:637:28 + | + 635 | """ + 636 | + 637 | def __init__(self, name: str, tp: Any) -> None: ... # AnnotationForm + | ^^^^ + 638 | if sys.version_info >= (3, 11): + 639 | @staticmethod + | + info: Source + --> main2.py:4:44 + | + 2 | from typing import NewType + 3 | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + | ^^^^ + 5 | + 6 | Y[: ] = N + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:637:39 + | + 635 | """ + 636 | + 637 | def __init__(self, name: str, tp: Any) -> None: ... # AnnotationForm + | ^^ + 638 | if sys.version_info >= (3, 11): + 639 | @staticmethod + | + info: Source + --> main2.py:4:56 + | + 2 | from typing import NewType + 3 | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + | ^^ + 5 | + 6 | Y[: ] = N + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:615:11 + | + 613 | TypeGuard: _SpecialForm + 614 | + 615 | class NewType: + | ^^^^^^^ + 616 | """NewType creates simple unique types with almost zero runtime overhead. + | + info: Source + --> main2.py:6:6 + | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + 5 | + 6 | Y[: ] = N + | ^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> main.py:4:1 + | + 2 | from typing import NewType + 3 | + 4 | N = NewType('N', str) + | ^ + 5 | + 6 | Y = N + | + info: Source + --> main2.py:6:28 + | + 4 | N[: ] = NewType([name=]'N', [tp=]str) + 5 | + 6 | Y[: ] = N + | ^ + | + "#); + } + + #[test] + fn test_meta_typevar_inlay_hint() { + let mut test = inlay_hint_test( + " + def f[T](x: type[T]): + y = x", + ); + + assert_snapshot!(test.inlay_hints(), @r#" + def f[T](x: type[T]): + y[: type[T@f]] = x + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/builtins.pyi:247:7 + | + 246 | @disjoint_base + 247 | class type: + | ^^^^ + 248 | """type(object) -> the object's type + 249 | type(name, bases, dict, **kwds) -> a new type + | + info: Source + --> main2.py:3:9 + | + 2 | def f[T](x: type[T]): + 3 | y[: type[T@f]] = x + | ^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> main.py:2:7 + | + 2 | def f[T](x: type[T]): + | ^ + 3 | y = x + | + info: Source + --> main2.py:3:14 + | + 2 | def f[T](x: type[T]): + 3 | y[: type[T@f]] = x + | ^^^ + | + + --------------------------------------------- + info[inlay-hint-edit]: File after edits + info: Source + + def f[T](x: type[T]): + y: type[T@f] = x + "#); + } + + #[test] + fn test_subscripted_protocol_inlay_hint() { + let mut test = inlay_hint_test( + " + from typing import Protocol, TypeVar + T = TypeVar('T') + Strange = Protocol[T]", + ); + + assert_snapshot!(test.inlay_hints(), @r" + from typing import Protocol, TypeVar + T[: typing.TypeVar] = TypeVar([name=]'T') + Strange[: ] = Protocol[T] + --------------------------------------------- + info[inlay-hint-location]: Inlay Hint Target + --> main.py:3:1 + | + 2 | from typing import Protocol, TypeVar + 3 | T = TypeVar('T') + | ^ + 4 | Strange = Protocol[T] + | + info: Source + --> main2.py:3:5 + | + 2 | from typing import Protocol, TypeVar + 3 | T[: typing.TypeVar] = TypeVar([name=]'T') + | ^^^^^^^^^^^^^^ + 4 | Strange[: ] = Protocol[T] + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:276:13 + | + 274 | def __new__( + 275 | cls, + 276 | name: str, + | ^^^^ + 277 | *constraints: Any, # AnnotationForm + 278 | bound: Any | None = None, # AnnotationForm + | + info: Source + --> main2.py:3:32 + | + 2 | from typing import Protocol, TypeVar + 3 | T[: typing.TypeVar] = TypeVar([name=]'T') + | ^^^^ + 4 | Strange[: ] = Protocol[T] + | + + info[inlay-hint-location]: Inlay Hint Target + --> stdlib/typing.pyi:341:1 + | + 340 | Union: _SpecialForm + 341 | Protocol: _SpecialForm + | ^^^^^^^^ + 342 | Callable: _SpecialForm + 343 | Type: _SpecialForm + | + info: Source + --> main2.py:4:26 + | + 2 | from typing import Protocol, TypeVar + 3 | T[: typing.TypeVar] = TypeVar([name=]'T') + 4 | Strange[: ] = Protocol[T] + | ^^^^^^^^^^^^^^^ + | + + info[inlay-hint-location]: Inlay Hint Target + --> main.py:3:1 + | + 2 | from typing import Protocol, TypeVar + 3 | T = TypeVar('T') + | ^ + 4 | Strange = Protocol[T] + | + info: Source + --> main2.py:4:42 + | + 2 | from typing import Protocol, TypeVar + 3 | T[: typing.TypeVar] = TypeVar([name=]'T') + 4 | Strange[: ] = Protocol[T] + | ^ + | + + --------------------------------------------- + info[inlay-hint-edit]: File after edits + info: Source + + from typing import Protocol, TypeVar + T: typing.TypeVar = TypeVar('T') + Strange = Protocol[T] + "); + } + struct InlayHintLocationDiagnostic { source: FileRange, target: FileRange, diff --git a/crates/ty_ide/src/rename.rs b/crates/ty_ide/src/rename.rs index ecea0ffc36..5d7951846a 100644 --- a/crates/ty_ide/src/rename.rs +++ b/crates/ty_ide/src/rename.rs @@ -84,7 +84,7 @@ pub fn rename( /// Helper function to check if a file is included in the project. fn is_file_in_project(db: &dyn Db, file: File) -> bool { - db.project().files(db).contains(&file) + file.path(db).is_system_virtual_path() || db.project().files(db).contains(&file) } #[cfg(test)] diff --git a/crates/ty_ide/src/semantic_tokens.rs b/crates/ty_ide/src/semantic_tokens.rs index 79b37265aa..7cb1ea0580 100644 --- a/crates/ty_ide/src/semantic_tokens.rs +++ b/crates/ty_ide/src/semantic_tokens.rs @@ -302,17 +302,25 @@ impl<'db> SemanticTokenVisitor<'db> { let parsed = parsed_module(db, definition.file(db)); let ty = parameter.node(&parsed.load(db)).inferred_type(&model); - if let Some(ty) = ty - && let Type::TypeVar(type_var) = ty - { - match type_var.typevar(db).kind(db) { - TypeVarKind::TypingSelf => { - return Some((SemanticTokenType::SelfParameter, modifiers)); + if let Some(ty) = ty { + let type_var = match ty { + Type::TypeVar(type_var) => Some((type_var, false)), + Type::SubclassOf(subclass_of) => { + subclass_of.into_type_var().map(|var| (var, true)) } - TypeVarKind::Legacy - | TypeVarKind::ParamSpec - | TypeVarKind::Pep695ParamSpec - | TypeVarKind::Pep695 => {} + _ => None, + }; + + if let Some((type_var, is_cls)) = type_var + && matches!(type_var.typevar(db).kind(db), TypeVarKind::TypingSelf) + { + let kind = if is_cls { + SemanticTokenType::ClsParameter + } else { + SemanticTokenType::SelfParameter + }; + + return Some((kind, modifiers)); } } @@ -1203,7 +1211,7 @@ class MyClass: " class MyClass: @classmethod - def method(cls, x): pass + def method(cls, x): print(cls) ", ); @@ -1215,6 +1223,8 @@ class MyClass: "method" @ 41..47: Method [definition] "cls" @ 48..51: ClsParameter [definition] "x" @ 53..54: Parameter [definition] + "print" @ 57..62: Function + "cls" @ 63..66: ClsParameter "#); } @@ -1246,7 +1256,7 @@ class MyClass: class MyClass: def method(instance, x): pass @classmethod - def other(klass, y): pass + def other(klass, y): print(klass) def complex_method(instance, posonly, /, regular, *args, kwonly, **kwargs): pass ", ); @@ -1262,13 +1272,15 @@ class MyClass: "other" @ 75..80: Method [definition] "klass" @ 81..86: ClsParameter [definition] "y" @ 88..89: Parameter [definition] - "complex_method" @ 105..119: Method [definition] - "instance" @ 120..128: SelfParameter [definition] - "posonly" @ 130..137: Parameter [definition] - "regular" @ 142..149: Parameter [definition] - "args" @ 152..156: Parameter [definition] - "kwonly" @ 158..164: Parameter [definition] - "kwargs" @ 168..174: Parameter [definition] + "print" @ 92..97: Function + "klass" @ 98..103: ClsParameter + "complex_method" @ 113..127: Method [definition] + "instance" @ 128..136: SelfParameter [definition] + "posonly" @ 138..145: Parameter [definition] + "regular" @ 150..157: Parameter [definition] + "args" @ 160..164: Parameter [definition] + "kwonly" @ 166..172: Parameter [definition] + "kwargs" @ 176..182: Parameter [definition] "#); } diff --git a/crates/ty_ide/src/symbols.rs b/crates/ty_ide/src/symbols.rs index ba33af9ef2..7d3f87d516 100644 --- a/crates/ty_ide/src/symbols.rs +++ b/crates/ty_ide/src/symbols.rs @@ -10,10 +10,10 @@ use ruff_db::files::File; use ruff_db::parsed::parsed_module; use ruff_index::{IndexVec, newtype_index}; use ruff_python_ast as ast; -use ruff_python_ast::name::Name; +use ruff_python_ast::name::{Name, UnqualifiedName}; use ruff_python_ast::visitor::source_order::{self, SourceOrderVisitor}; use ruff_text_size::{Ranged, TextRange}; -use rustc_hash::FxHashSet; +use rustc_hash::{FxHashMap, FxHashSet}; use ty_project::Db; use ty_python_semantic::{ModuleName, resolve_module}; @@ -375,7 +375,11 @@ pub(crate) fn symbols_for_file(db: &dyn Db, file: File) -> FlatSymbols { /// While callers can convert this into a hierarchical collection of /// symbols, it won't result in anything meaningful since the flat list /// returned doesn't include children. -#[salsa::tracked(returns(ref), heap_size=ruff_memory_usage::heap_size)] +#[salsa::tracked( + returns(ref), + cycle_initial=symbols_for_file_global_only_cycle_initial, + heap_size=ruff_memory_usage::heap_size, +)] pub(crate) fn symbols_for_file_global_only(db: &dyn Db, file: File) -> FlatSymbols { let parsed = parsed_module(db, file); let module = parsed.load(db); @@ -394,6 +398,14 @@ pub(crate) fn symbols_for_file_global_only(db: &dyn Db, file: File) -> FlatSymbo visitor.into_flat_symbols() } +fn symbols_for_file_global_only_cycle_initial( + _db: &dyn Db, + _id: salsa::Id, + _file: File, +) -> FlatSymbols { + FlatSymbols::default() +} + #[derive(Debug, Clone, PartialEq, Eq, get_size2::GetSize)] struct SymbolTree { parent: Option, @@ -411,6 +423,189 @@ enum ImportKind { Wildcard, } +/// An abstraction for managing module scope imports. +/// +/// This is meant to recognize the following idioms for updating +/// `__all__` in module scope: +/// +/// ```ignore +/// __all__ += submodule.__all__ +/// __all__.extend(submodule.__all__) +/// ``` +/// +/// # Correctness +/// +/// The approach used here is not correct 100% of the time. +/// For example, it is somewhat easy to defeat it: +/// +/// ```ignore +/// from numpy import * +/// from importlib import resources +/// import numpy as np +/// np = resources +/// __all__ = [] +/// __all__ += np.__all__ +/// ``` +/// +/// In this example, `np` will still be resolved to the `numpy` +/// module instead of the `importlib.resources` module. Namely, this +/// abstraction doesn't track all definitions. This would result in a +/// silently incorrect `__all__`. +/// +/// This abstraction does handle the case when submodules are imported. +/// Namely, we do get this case correct: +/// +/// ```ignore +/// from importlib.resources import * +/// from importlib import resources +/// __all__ = [] +/// __all__ += resources.__all__ +/// ``` +/// +/// We do this by treating all imports in a `from ... import ...` +/// statement as *possible* modules. Then when we lookup `resources`, +/// we attempt to resolve it to an actual module. If that fails, then +/// we consider `__all__` invalid. +/// +/// There are likely many many other cases that we don't handle as +/// well, which ty does (it has its own `__all__` parsing using types +/// to deal with this case). We can add handling for those as they +/// come up in real world examples. +/// +/// # Performance +/// +/// This abstraction recognizes that, compared to all possible imports, +/// it is very rare to use one of them to update `__all__`. Therefore, +/// we are careful not to do too much work up-front (like eagerly +/// manifesting `ModuleName` values). +#[derive(Clone, Debug, Default, get_size2::GetSize)] +struct Imports<'db> { + /// A map from the name that a module is available + /// under to its actual module name (and our level + /// of certainty that it ought to be treated as a module). + module_names: FxHashMap<&'db str, ImportModuleKind<'db>>, +} + +impl<'db> Imports<'db> { + /// Track the imports from the given `import ...` statement. + fn add_import(&mut self, import: &'db ast::StmtImport) { + for alias in &import.names { + let asname = alias + .asname + .as_ref() + .map(|ident| &ident.id) + .unwrap_or(&alias.name.id); + let module_name = ImportModuleName::Import(&alias.name.id); + self.module_names + .insert(asname, ImportModuleKind::Definitive(module_name)); + } + } + + /// Track the imports from the given `from ... import ...` statement. + fn add_import_from(&mut self, import_from: &'db ast::StmtImportFrom) { + for alias in &import_from.names { + if &alias.name == "*" { + // FIXME: We'd ideally include the names + // imported from the module, but we don't + // want to do this eagerly. So supporting + // this requires more infrastructure in + // `Imports`. + continue; + } + + let asname = alias + .asname + .as_ref() + .map(|ident| &ident.id) + .unwrap_or(&alias.name.id); + let module_name = ImportModuleName::ImportFrom { + parent: import_from, + child: &alias.name.id, + }; + self.module_names + .insert(asname, ImportModuleKind::Possible(module_name)); + } + } + + /// Return the symbols exported by the module referred to by `name`. + /// + /// e.g., This can be used to resolve `__all__ += submodule.__all__`, + /// where `name` is `submodule`. + fn get_module_symbols( + &self, + db: &'db dyn Db, + importing_file: File, + name: &Name, + ) -> Option<&'db FlatSymbols> { + let module_name = match self.module_names.get(name.as_str())? { + ImportModuleKind::Definitive(name) | ImportModuleKind::Possible(name) => { + name.to_module_name(db, importing_file)? + } + }; + let module = resolve_module(db, importing_file, &module_name)?; + Some(symbols_for_file_global_only(db, module.file(db)?)) + } +} + +/// Describes the level of certainty that an import is a module. +/// +/// For example, `import foo`, then `foo` is definitively a module. +/// But `from quux import foo`, then `quux.foo` is possibly a module. +#[derive(Debug, Clone, Copy, get_size2::GetSize)] +enum ImportModuleKind<'db> { + Definitive(ImportModuleName<'db>), + Possible(ImportModuleName<'db>), +} + +/// A representation of something that can be turned into a +/// `ModuleName`. +/// +/// We don't do this eagerly, and instead represent the constituent +/// pieces, in order to avoid the work needed to build a `ModuleName`. +/// In particular, it is somewhat rare for the visitor to need +/// to access the imports found in a module. At time of writing +/// (2025-12-10), this only happens when referencing a submodule +/// to augment an `__all__` definition. For example, as found in +/// `matplotlib`: +/// +/// ```ignore +/// import numpy as np +/// __all__ = ['rand', 'randn', 'repmat'] +/// __all__ += np.__all__ +/// ``` +/// +/// This construct is somewhat rare and it would be sad to allocate a +/// `ModuleName` for every imported item unnecessarily. +#[derive(Debug, Clone, Copy, get_size2::GetSize)] +enum ImportModuleName<'db> { + /// The `foo` in `import quux, foo as blah, baz`. + Import(&'db Name), + /// A possible module in a `from ... import ...` statement. + ImportFrom { + /// The `..foo` in `from ..foo import quux`. + parent: &'db ast::StmtImportFrom, + /// The `foo` in `from quux import foo`. + child: &'db Name, + }, +} + +impl<'db> ImportModuleName<'db> { + /// Converts the lazy representation of a module name into an + /// actual `ModuleName` that can be used for module resolution. + fn to_module_name(self, db: &'db dyn Db, importing_file: File) -> Option { + match self { + ImportModuleName::Import(name) => ModuleName::new(name), + ImportModuleName::ImportFrom { parent, child } => { + let mut module_name = + ModuleName::from_import_statement(db, importing_file, parent).ok()?; + let child_module_name = ModuleName::new(child)?; + module_name.extend(&child_module_name); + Some(module_name) + } + } + } +} + /// A visitor over all symbols in a single file. /// /// This guarantees that child symbols have a symbol ID greater @@ -431,7 +626,11 @@ struct SymbolVisitor<'db> { /// This is true even when we're inside a function definition /// that is inside a class. in_class: bool, - global_only: bool, + /// When enabled, the visitor should only try to extract + /// symbols from a module that we believed form the "exported" + /// interface for that module. i.e., `__all__` is only respected + /// when this is enabled. It's otherwise ignored. + exports_only: bool, /// The origin of an `__all__` variable, if found. all_origin: Option, /// A set of names extracted from `__all__`. @@ -440,6 +639,11 @@ struct SymbolVisitor<'db> { /// `__all__` idioms or there are any invalid elements in /// `__all__`. all_invalid: bool, + /// A collection of imports found while visiting the AST. + /// + /// These are used to help resolve references to modules + /// in some limited cases. + imports: Imports<'db>, } impl<'db> SymbolVisitor<'db> { @@ -451,21 +655,27 @@ impl<'db> SymbolVisitor<'db> { symbol_stack: vec![], in_function: false, in_class: false, - global_only: false, + exports_only: false, all_origin: None, all_names: FxHashSet::default(), all_invalid: false, + imports: Imports::default(), } } fn globals(db: &'db dyn Db, file: File) -> Self { Self { - global_only: true, + exports_only: true, ..Self::tree(db, file) } } fn into_flat_symbols(mut self) -> FlatSymbols { + // If `__all__` was found but wasn't recognized, + // then we emit a diagnostic message indicating as such. + if self.all_invalid { + tracing::debug!("Invalid `__all__` in `{}`", self.file.path(self.db)); + } // We want to filter out some of the symbols we collected. // Specifically, to respect conventions around library // interface. @@ -474,12 +684,28 @@ impl<'db> SymbolVisitor<'db> { // their position in a sequence. So when we filter some // out, we need to remap the identifiers. // - // N.B. The remapping could be skipped when `global_only` is + // We also want to deduplicate when `exports_only` is + // `true`. In particular, dealing with `__all__` can + // result in cycles, and we need to make sure our output + // is stable for that reason. + // + // N.B. The remapping could be skipped when `exports_only` is // true, since in that case, none of the symbols have a parent // ID by construction. let mut remap = IndexVec::with_capacity(self.symbols.len()); + let mut seen = self.exports_only.then(FxHashSet::default); let mut new = IndexVec::with_capacity(self.symbols.len()); for mut symbol in std::mem::take(&mut self.symbols) { + // If we're deduplicating and we've already seen + // this symbol, then skip it. + // + // FIXME: We should do this without copying every + // symbol name. ---AG + if let Some(ref mut seen) = seen { + if !seen.insert(symbol.name.clone()) { + continue; + } + } if !self.is_part_of_library_interface(&symbol) { remap.push(None); continue; @@ -510,7 +736,7 @@ impl<'db> SymbolVisitor<'db> { } } - fn visit_body(&mut self, body: &[ast::Stmt]) { + fn visit_body(&mut self, body: &'db [ast::Stmt]) { for stmt in body { self.visit_stmt(stmt); } @@ -585,6 +811,11 @@ impl<'db> SymbolVisitor<'db> { /// /// If the assignment isn't for `__all__`, then this is a no-op. fn add_all_assignment(&mut self, targets: &[ast::Expr], value: Option<&ast::Expr>) { + // We don't care about `__all__` unless we're + // specifically looking for exported symbols. + if !self.exports_only { + return; + } if self.in_function || self.in_class { return; } @@ -635,6 +866,31 @@ impl<'db> SymbolVisitor<'db> { ast::Expr::List(ast::ExprList { elts, .. }) | ast::Expr::Tuple(ast::ExprTuple { elts, .. }) | ast::Expr::Set(ast::ExprSet { elts, .. }) => self.add_all_names(elts), + // `__all__ += module.__all__` + // `__all__.extend(module.__all__)` + ast::Expr::Attribute(ast::ExprAttribute { .. }) => { + let Some(unqualified) = UnqualifiedName::from_expr(expr) else { + return false; + }; + let Some((&attr, rest)) = unqualified.segments().split_last() else { + return false; + }; + if attr != "__all__" { + return false; + } + let possible_module_name = Name::new(rest.join(".")); + let Some(symbols) = + self.imports + .get_module_symbols(self.db, self.file, &possible_module_name) + else { + return false; + }; + let Some(ref all) = symbols.all_names else { + return false; + }; + self.all_names.extend(all.iter().cloned()); + true + } _ => false, } } @@ -801,14 +1057,11 @@ impl<'db> SymbolVisitor<'db> { // if a name should be part of the exported API of a module // or not. When there is `__all__`, we currently follow it // strictly. - if self.all_origin.is_some() { - // If `__all__` is somehow invalid, ignore it and fall - // through as-if `__all__` didn't exist. - if self.all_invalid { - tracing::debug!("Invalid `__all__` in `{}`", self.file.path(self.db)); - } else { - return self.all_names.contains(&*symbol.name); - } + // + // If `__all__` is somehow invalid, ignore it and fall + // through as-if `__all__` didn't exist. + if self.all_origin.is_some() && !self.all_invalid { + return self.all_names.contains(&*symbol.name); } // "Imported symbols are considered private by default. A fixed @@ -839,8 +1092,8 @@ impl<'db> SymbolVisitor<'db> { } } -impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { - fn visit_stmt(&mut self, stmt: &ast::Stmt) { +impl<'db> SourceOrderVisitor<'db> for SymbolVisitor<'db> { + fn visit_stmt(&mut self, stmt: &'db ast::Stmt) { match stmt { ast::Stmt::FunctionDef(func_def) => { let kind = if self @@ -865,7 +1118,7 @@ impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { import_kind: None, }; - if self.global_only { + if self.exports_only { self.add_symbol(symbol); // If global_only, don't walk function bodies return; @@ -894,7 +1147,7 @@ impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { import_kind: None, }; - if self.global_only { + if self.exports_only { self.add_symbol(symbol); // If global_only, don't walk class bodies return; @@ -943,6 +1196,12 @@ impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { ast::Stmt::AugAssign(ast::StmtAugAssign { target, op, value, .. }) => { + // We don't care about `__all__` unless we're + // specifically looking for exported symbols. + if !self.exports_only { + return; + } + if self.all_origin.is_none() { // We can't update `__all__` if it doesn't already // exist. @@ -961,6 +1220,12 @@ impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { } } ast::Stmt::Expr(expr) => { + // We don't care about `__all__` unless we're + // specifically looking for exported symbols. + if !self.exports_only { + return; + } + if self.all_origin.is_none() { // We can't update `__all__` if it doesn't already exist. return; @@ -990,19 +1255,33 @@ impl SourceOrderVisitor<'_> for SymbolVisitor<'_> { source_order::walk_stmt(self, stmt); } ast::Stmt::Import(import) => { + // We ignore any names introduced by imports + // unless we're specifically looking for the + // set of exported symbols. + if !self.exports_only { + return; + } // We only consider imports in global scope. if self.in_function { return; } + self.imports.add_import(import); for alias in &import.names { self.add_import_alias(stmt, alias); } } ast::Stmt::ImportFrom(import_from) => { + // We ignore any names introduced by imports + // unless we're specifically looking for the + // set of exported symbols. + if !self.exports_only { + return; + } // We only consider imports in global scope. if self.in_function { return; } + self.imports.add_import_from(import_from); for alias in &import_from.names { if &alias.name == "*" { self.add_exported_from_wildcard(import_from); @@ -1975,6 +2254,363 @@ class X: ); } + #[test] + fn reexport_and_extend_from_submodule_import_statement_plus_equals() { + let test = PublicTestBuilder::default() + .source( + "foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import foo + from foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += foo.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_statement_extend() { + let test = PublicTestBuilder::default() + .source( + "foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import foo + from foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__.extend(foo.__all__) + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_statement_alias() { + let test = PublicTestBuilder::default() + .source( + "foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import foo as blah + from foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += blah.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_statement_nested_alias() { + let test = PublicTestBuilder::default() + .source("parent/__init__.py", "") + .source( + "parent/foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import parent.foo as blah + from parent.foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += blah.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_from_statement_plus_equals() { + let test = PublicTestBuilder::default() + .source("parent/__init__.py", "") + .source( + "parent/foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "from parent import foo + from parent.foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += foo.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_from_statement_nested_module_reference() { + let test = PublicTestBuilder::default() + .source("parent/__init__.py", "") + .source( + "parent/foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import parent.foo + from parent.foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += parent.foo.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_from_statement_extend() { + let test = PublicTestBuilder::default() + .source("parent/__init__.py", "") + .source( + "parent/foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "import parent.foo + from parent.foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__.extend(parent.foo.__all__) + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_from_statement_alias() { + let test = PublicTestBuilder::default() + .source("parent/__init__.py", "") + .source( + "parent/foo.py", + " + _ZQZQZQ = 1 + __all__ = ['_ZQZQZQ'] + ", + ) + .source( + "test.py", + "from parent import foo as blah + from parent.foo import * + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__ += blah.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZQZQZQ :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_cycle1() { + let test = PublicTestBuilder::default() + .source( + "a.py", + "from b import * + import b + _ZAZAZA = 1 + __all__ = ['_ZAZAZA'] + __all__ += b.__all__ + ", + ) + .source( + "b.py", + " + from a import * + import a + _ZBZBZB = 1 + __all__ = ['_ZBZBZB'] + __all__ += a.__all__ + ", + ) + .build(); + insta::assert_snapshot!( + test.exports_for("a.py"), + @r" + _ZBZBZB :: Constant + _ZAZAZA :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_statement_failure1() { + let test = PublicTestBuilder::default() + .source( + "foo.py", + " + _ZFZFZF = 1 + __all__ = ['_ZFZFZF'] + ", + ) + .source( + "bar.py", + " + _ZBZBZB = 1 + __all__ = ['_ZBZBZB'] + ", + ) + .source( + "test.py", + "import foo + import bar + from foo import * + from bar import * + + foo = bar + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__.extend(foo.__all__) + ", + ) + .build(); + // In this test, we resolve `foo.__all__` to the `__all__` + // attribute in module `foo` instead of in `bar`. This is + // because we don't track redefinitions of imports (as of + // 2025-12-11). Handling this correctly would mean exporting + // `_ZBZBZB` instead of `_ZFZFZF`. + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZFZFZF :: Constant + _ZYZYZY :: Constant + ", + ); + } + + #[test] + fn reexport_and_extend_from_submodule_import_statement_failure2() { + let test = PublicTestBuilder::default() + .source( + "parent/__init__.py", + "import parent.foo as foo + __all__ = ['foo'] + ", + ) + .source( + "parent/foo.py", + " + _ZFZFZF = 1 + __all__ = ['_ZFZFZF'] + ", + ) + .source( + "test.py", + "from parent.foo import * + from parent import * + + _ZYZYZY = 1 + __all__ = ['_ZYZYZY'] + __all__.extend(foo.__all__) + ", + ) + .build(); + // This is not quite right either because we end up + // considering the `__all__` in `test.py` to be invalid. + // Namely, we don't pick up the `foo` that is in scope + // from the `from parent import *` import. The correct + // answer should just be `_ZFZFZF` and `_ZYZYZY`. + insta::assert_snapshot!( + test.exports_for("test.py"), + @r" + _ZFZFZF :: Constant + foo :: Module + _ZYZYZY :: Constant + __all__ :: Variable + ", + ); + } + fn matches(query: &str, symbol: &str) -> bool { super::QueryPattern::fuzzy(query).is_match_symbol_name(symbol) } diff --git a/crates/ty_ide/src/workspace_symbols.rs b/crates/ty_ide/src/workspace_symbols.rs index 3224c50baf..d2b01e0c94 100644 --- a/crates/ty_ide/src/workspace_symbols.rs +++ b/crates/ty_ide/src/workspace_symbols.rs @@ -150,6 +150,62 @@ class Test: "); } + #[test] + fn ignore_all() { + let test = CursorTest::builder() + .source( + "utils.py", + " +__all__ = [] +class Test: + def from_path(): ... +", + ) + .build(); + + assert_snapshot!(test.workspace_symbols("from"), @r" + info[workspace-symbols]: WorkspaceSymbolInfo + --> utils.py:4:9 + | + 2 | __all__ = [] + 3 | class Test: + 4 | def from_path(): ... + | ^^^^^^^^^ + | + info: Method from_path + "); + } + + #[test] + fn ignore_imports() { + let test = CursorTest::builder() + .source( + "utils.py", + " +import re +import json as json +from collections import defaultdict +foo = 1 +", + ) + .build(); + + assert_snapshot!(test.workspace_symbols("foo"), @r" + info[workspace-symbols]: WorkspaceSymbolInfo + --> utils.py:5:1 + | + 3 | import json as json + 4 | from collections import defaultdict + 5 | foo = 1 + | ^^^ + | + info: Variable foo + "); + assert_snapshot!(test.workspace_symbols("re"), @"No symbols found"); + assert_snapshot!(test.workspace_symbols("json"), @"No symbols found"); + assert_snapshot!(test.workspace_symbols("default"), @"No symbols found"); + } + impl CursorTest { fn workspace_symbols(&self, query: &str) -> String { let symbols = workspace_symbols(&self.db, query); diff --git a/crates/ty_project/src/metadata/options.rs b/crates/ty_project/src/metadata/options.rs index 8fb75ab201..df667ed049 100644 --- a/crates/ty_project/src/metadata/options.rs +++ b/crates/ty_project/src/metadata/options.rs @@ -285,22 +285,6 @@ impl Options { roots.push(python); } - // Considering pytest test discovery conventions, - // we also include the `tests` directory if it exists and is not a package. - let tests_dir = project_root.join("tests"); - if system.is_directory(&tests_dir) - && !system.is_file(&tests_dir.join("__init__.py")) - && !system.is_file(&tests_dir.join("__init__.pyi")) - && !roots.contains(&tests_dir) - { - // If the `tests` directory exists and is not a package, include it as a source root. - tracing::debug!( - "Including `./tests` in `environment.root` because a `./tests` directory exists" - ); - - roots.push(tests_dir); - } - // The project root should always be included, and should always come // after any subdirectories such as `./src`, `./tests` and/or `./python`. roots.push(project_root.to_path_buf()); @@ -532,7 +516,7 @@ pub struct EnvironmentOptions { /// * if a `.//` directory exists, include `.` and `./` in the first party search path /// * otherwise, default to `.` (flat layout) /// - /// Besides, if a `./python` or `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file), + /// Additionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file), /// it will also be included in the first party search path. #[serde(skip_serializing_if = "Option::is_none")] #[option( @@ -674,7 +658,7 @@ pub struct SrcOptions { /// * if a `.//` directory exists, include `.` and `./` in the first party search path /// * otherwise, default to `.` (flat layout) /// - /// Besides, if a `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` file), + /// Additionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` file), /// it will also be included in the first party search path. #[serde(skip_serializing_if = "Option::is_none")] #[option( diff --git a/crates/ty_python_semantic/resources/corpus/cyclic_pep613_typevar.py b/crates/ty_python_semantic/resources/corpus/cyclic_pep613_typevar.py new file mode 100644 index 0000000000..5730c9f30b --- /dev/null +++ b/crates/ty_python_semantic/resources/corpus/cyclic_pep613_typevar.py @@ -0,0 +1,7 @@ +from typing import TypeAlias, TypeVar + +T = TypeVar("T", bound="A[0]") +A: TypeAlias = T +def _(x: A): + if x: + pass diff --git a/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound.py b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound.py new file mode 100644 index 0000000000..8d63530cf3 --- /dev/null +++ b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound.py @@ -0,0 +1 @@ +def _[T: (T if cond else U)[0], U](): pass diff --git a/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound2.py b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound2.py new file mode 100644 index 0000000000..5b3ab4e12a --- /dev/null +++ b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_bound2.py @@ -0,0 +1,3 @@ +def _[T: T[0]](x: T): + if x: + pass diff --git a/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_constraints.py b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_constraints.py new file mode 100644 index 0000000000..549470e214 --- /dev/null +++ b/crates/ty_python_semantic/resources/corpus/cyclic_pep695_typevars_invalid_constraints.py @@ -0,0 +1,4 @@ +class _[T: (0, T[0])]: + def _(x: T): + if x: + pass diff --git a/crates/ty_python_semantic/resources/mdtest/annotations/new_types.md b/crates/ty_python_semantic/resources/mdtest/annotations/new_types.md index 39a88cff49..ab55503691 100644 --- a/crates/ty_python_semantic/resources/mdtest/annotations/new_types.md +++ b/crates/ty_python_semantic/resources/mdtest/annotations/new_types.md @@ -146,9 +146,10 @@ Foo = NewType(name, int) reveal_type(Foo) # revealed: ``` -## The second argument must be a class type or another newtype +## The base must be a class type or another newtype -Other typing constructs like `Union` are not allowed. +Other typing constructs like `Union` are not _generally_ allowed. (However, see the next section for +a couple special cases.) ```py from typing_extensions import NewType @@ -167,6 +168,61 @@ on top of that: Foo = NewType("Foo", 42) ``` +## `float` and `complex` special cases + +`float` and `complex` are subject to a special case in the typing spec, which we currently interpret +to mean that `float` in type position is `int | float`, and `complex` in type position is +`int | float | complex`. This is awkward for `NewType`, because as we just tested above, unions +aren't generally valid `NewType` bases. However, `float` and `complex` _are_ valid `NewType` bases, +and we accept the unions they expand into. + +```py +from typing import NewType + +Foo = NewType("Foo", float) +Foo(3.14) +Foo(42) +Foo("hello") # error: [invalid-argument-type] "Argument is incorrect: Expected `int | float`, found `Literal["hello"]`" + +reveal_type(Foo(3.14).__class__) # revealed: type[int] | type[float] +reveal_type(Foo(42).__class__) # revealed: type[int] | type[float] + +Bar = NewType("Bar", complex) +Bar(1 + 2j) +Bar(3.14) +Bar(42) +Bar("goodbye") # error: [invalid-argument-type] + +reveal_type(Bar(1 + 2j).__class__) # revealed: type[int] | type[float] | type[complex] +reveal_type(Bar(3.14).__class__) # revealed: type[int] | type[float] | type[complex] +reveal_type(Bar(42).__class__) # revealed: type[int] | type[float] | type[complex] +``` + +We don't currently try to distinguish between an implicit union (e.g. `float`) and the equivalent +explicit union (e.g. `int | float`), so these two explicit unions are also allowed. But again, most +unions are not allowed: + +```py +Baz = NewType("Baz", int | float) +Baz = NewType("Baz", int | float | complex) +Baz = NewType("Baz", int | str) # error: [invalid-newtype] "invalid base for `typing.NewType`" +``` + +Similarly, a `NewType` of `float` or `complex` is valid as a `Callable` of the corresponding union +type: + +```py +from collections.abc import Callable + +def f(_: Callable[[int | float], Foo]): ... + +f(Foo) + +def g(_: Callable[[int | float | complex], Bar]): ... + +g(Bar) +``` + ## A `NewType` definition must be a simple variable assignment ```py @@ -179,7 +235,7 @@ N: NewType = NewType("N", int) # error: [invalid-newtype] "A `NewType` definiti Cyclic newtypes are kind of silly, but it's possible for the user to express them, and it's important that we don't go into infinite recursive loops and crash with a stack overflow. In fact, -this is *why* base type evaluation is deferred; otherwise Salsa itself would crash. +this is _why_ base type evaluation is deferred; otherwise Salsa itself would crash. ```py from typing_extensions import NewType, reveal_type, cast diff --git a/crates/ty_python_semantic/resources/mdtest/assignment/augmented.md b/crates/ty_python_semantic/resources/mdtest/assignment/augmented.md index cec8c6de43..fc4af5a52e 100644 --- a/crates/ty_python_semantic/resources/mdtest/assignment/augmented.md +++ b/crates/ty_python_semantic/resources/mdtest/assignment/augmented.md @@ -38,6 +38,8 @@ reveal_type(x) # revealed: int ## Unsupported types + + ```py class C: def __isub__(self, other: str) -> int: diff --git a/crates/ty_python_semantic/resources/mdtest/attributes.md b/crates/ty_python_semantic/resources/mdtest/attributes.md index f2eb886223..3c28431d58 100644 --- a/crates/ty_python_semantic/resources/mdtest/attributes.md +++ b/crates/ty_python_semantic/resources/mdtest/attributes.md @@ -2162,8 +2162,8 @@ Some attributes are special-cased, however: import types from ty_extensions import static_assert, TypeOf, is_subtype_of -reveal_type(f.__get__) # revealed: -reveal_type(f.__call__) # revealed: +reveal_type(f.__get__) # revealed: +reveal_type(f.__call__) # revealed: static_assert(is_subtype_of(TypeOf[f.__get__], types.MethodWrapperType)) static_assert(is_subtype_of(TypeOf[f.__call__], types.MethodWrapperType)) ``` diff --git a/crates/ty_python_semantic/resources/mdtest/binary/custom.md b/crates/ty_python_semantic/resources/mdtest/binary/custom.md index 9bd0852253..ad2b837195 100644 --- a/crates/ty_python_semantic/resources/mdtest/binary/custom.md +++ b/crates/ty_python_semantic/resources/mdtest/binary/custom.md @@ -79,31 +79,31 @@ reveal_type(Sub() & Sub()) # revealed: Literal["&"] reveal_type(Sub() // Sub()) # revealed: Literal["//"] # No does not implement any of the dunder methods. -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `No`" reveal_type(No() + No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `-` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `-` is not supported between two objects of type `No`" reveal_type(No() - No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `*` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `*` is not supported between two objects of type `No`" reveal_type(No() * No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `@` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `@` is not supported between two objects of type `No`" reveal_type(No() @ No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `/` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `/` is not supported between two objects of type `No`" reveal_type(No() / No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `%` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `%` is not supported between two objects of type `No`" reveal_type(No() % No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `**` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `**` is not supported between two objects of type `No`" reveal_type(No() ** No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `<<` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `<<` is not supported between two objects of type `No`" reveal_type(No() << No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `>>` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `>>` is not supported between two objects of type `No`" reveal_type(No() >> No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `|` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `|` is not supported between two objects of type `No`" reveal_type(No() | No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `^` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `^` is not supported between two objects of type `No`" reveal_type(No() ^ No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `&` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `&` is not supported between two objects of type `No`" reveal_type(No() & No()) # revealed: Unknown -# error: [unsupported-operator] "Operator `//` is not supported between objects of type `No` and `No`" +# error: [unsupported-operator] "Operator `//` is not supported between two objects of type `No`" reveal_type(No() // No()) # revealed: Unknown # Yes does not implement any of the reflected dunder methods. @@ -293,6 +293,8 @@ reveal_type(Yes() // No()) # revealed: Literal["//"] ## Classes + + Dunder methods defined in a class are available to instances of that class, but not to the class itself. (For these operators to work on the class itself, they would have to be defined on the class's type, i.e. `type`.) @@ -307,11 +309,11 @@ class Yes: class Sub(Yes): ... class No: ... -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `` and ``" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" reveal_type(Yes + Yes) # revealed: Unknown -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `` and ``" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" reveal_type(Sub + Sub) # revealed: Unknown -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `` and ``" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" reveal_type(No + No) # revealed: Unknown ``` @@ -336,11 +338,11 @@ def sub() -> type[Sub]: def no() -> type[No]: return No -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `type[Yes]` and `type[Yes]`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `type[Yes]`" reveal_type(yes() + yes()) # revealed: Unknown -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `type[Sub]` and `type[Sub]`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `type[Sub]`" reveal_type(sub() + sub()) # revealed: Unknown -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `type[No]` and `type[No]`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `type[No]`" reveal_type(no() + no()) # revealed: Unknown ``` @@ -350,30 +352,54 @@ reveal_type(no() + no()) # revealed: Unknown def f(): pass -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f + f) # revealed: Unknown -# error: [unsupported-operator] "Operator `-` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `-` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f - f) # revealed: Unknown -# error: [unsupported-operator] "Operator `*` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `*` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f * f) # revealed: Unknown -# error: [unsupported-operator] "Operator `@` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `@` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f @ f) # revealed: Unknown -# error: [unsupported-operator] "Operator `/` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `/` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f / f) # revealed: Unknown -# error: [unsupported-operator] "Operator `%` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `%` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f % f) # revealed: Unknown -# error: [unsupported-operator] "Operator `**` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `**` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f**f) # revealed: Unknown -# error: [unsupported-operator] "Operator `<<` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `<<` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f << f) # revealed: Unknown -# error: [unsupported-operator] "Operator `>>` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `>>` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f >> f) # revealed: Unknown -# error: [unsupported-operator] "Operator `|` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `|` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f | f) # revealed: Unknown -# error: [unsupported-operator] "Operator `^` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `^` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f ^ f) # revealed: Unknown -# error: [unsupported-operator] "Operator `&` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `&` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f & f) # revealed: Unknown -# error: [unsupported-operator] "Operator `//` is not supported between objects of type `def f() -> Unknown` and `def f() -> Unknown`" +# error: [unsupported-operator] "Operator `//` is not supported between two objects of type `def f() -> Unknown`" reveal_type(f // f) # revealed: Unknown ``` + +## Classes from different modules with the same name + +We use the fully qualified names in diagnostics if the two classes have the same unqualified name, +but are nonetheless different. + + + +`mod1.py`: + +```py +class A: ... +``` + +`mod2.py`: + +```py +import mod1 + +class A: ... + +# error: [unsupported-operator] "Operator `+` is not supported between objects of type `mod2.A` and `mod1.A`" +A() + mod1.A() +``` diff --git a/crates/ty_python_semantic/resources/mdtest/binary/instances.md b/crates/ty_python_semantic/resources/mdtest/binary/instances.md index c1cc6f924e..1106bfbb74 100644 --- a/crates/ty_python_semantic/resources/mdtest/binary/instances.md +++ b/crates/ty_python_semantic/resources/mdtest/binary/instances.md @@ -412,7 +412,7 @@ class A: def __init__(self): self.__add__ = add_impl -# error: [unsupported-operator] "Operator `+` is not supported between objects of type `A` and `A`" +# error: [unsupported-operator] "Operator `+` is not supported between two objects of type `A`" # revealed: Unknown reveal_type(A() + A()) ``` diff --git a/crates/ty_python_semantic/resources/mdtest/binary/unions.md b/crates/ty_python_semantic/resources/mdtest/binary/unions.md index 1b980170d4..c450d8d8de 100644 --- a/crates/ty_python_semantic/resources/mdtest/binary/unions.md +++ b/crates/ty_python_semantic/resources/mdtest/binary/unions.md @@ -18,7 +18,7 @@ cannot be added, because that would require addition of `int` and `str` or vice def f2(i: int, s: str, int_or_str: int | str): i + i s + s - # error: [unsupported-operator] "Operator `+` is not supported between objects of type `int | str` and `int | str`" + # error: [unsupported-operator] "Operator `+` is not supported between two objects of type `int | str`" reveal_type(int_or_str + int_or_str) # revealed: Unknown ``` diff --git a/crates/ty_python_semantic/resources/mdtest/call/methods.md b/crates/ty_python_semantic/resources/mdtest/call/methods.md index 0536ded1e6..a2c7d043b4 100644 --- a/crates/ty_python_semantic/resources/mdtest/call/methods.md +++ b/crates/ty_python_semantic/resources/mdtest/call/methods.md @@ -34,7 +34,8 @@ from inspect import getattr_static reveal_type(getattr_static(C, "f")) # revealed: def f(self, x: int) -> str -reveal_type(getattr_static(C, "f").__get__) # revealed: +# revealed: +reveal_type(getattr_static(C, "f").__get__) reveal_type(getattr_static(C, "f").__get__(None, C)) # revealed: def f(self, x: int) -> str reveal_type(getattr_static(C, "f").__get__(C(), C)) # revealed: bound method C.f(x: int) -> str @@ -258,7 +259,7 @@ class C: method_wrapper = getattr_static(C, "f").__get__ -reveal_type(method_wrapper) # revealed: +reveal_type(method_wrapper) # revealed: # All of these are fine: method_wrapper(C(), C) @@ -414,7 +415,8 @@ class C: def f(cls): ... reveal_type(getattr_static(C, "f")) # revealed: def f(cls) -> Unknown -reveal_type(getattr_static(C, "f").__get__) # revealed: +# revealed: +reveal_type(getattr_static(C, "f").__get__) ``` But we correctly model how the `classmethod` descriptor works: @@ -632,7 +634,7 @@ class MyClass: static_assert(is_assignable_to(types.FunctionType, Callable)) -# revealed: +# revealed: reveal_type(types.FunctionType.__get__) static_assert(is_assignable_to(TypeOf[types.FunctionType.__get__], Callable)) @@ -640,7 +642,7 @@ static_assert(is_assignable_to(TypeOf[types.FunctionType.__get__], Callable)) reveal_type(f) static_assert(is_assignable_to(TypeOf[f], Callable)) -# revealed: +# revealed: reveal_type(f.__get__) static_assert(is_assignable_to(TypeOf[f.__get__], Callable)) @@ -648,11 +650,11 @@ static_assert(is_assignable_to(TypeOf[f.__get__], Callable)) reveal_type(types.FunctionType.__call__) static_assert(is_assignable_to(TypeOf[types.FunctionType.__call__], Callable)) -# revealed: +# revealed: reveal_type(f.__call__) static_assert(is_assignable_to(TypeOf[f.__call__], Callable)) -# revealed: +# revealed: reveal_type(property.__get__) static_assert(is_assignable_to(TypeOf[property.__get__], Callable)) @@ -661,15 +663,15 @@ reveal_type(MyClass.my_property) static_assert(is_assignable_to(TypeOf[property], Callable)) static_assert(not is_assignable_to(TypeOf[MyClass.my_property], Callable)) -# revealed: +# revealed: reveal_type(MyClass.my_property.__get__) static_assert(is_assignable_to(TypeOf[MyClass.my_property.__get__], Callable)) -# revealed: +# revealed: reveal_type(property.__set__) static_assert(is_assignable_to(TypeOf[property.__set__], Callable)) -# revealed: +# revealed: reveal_type(MyClass.my_property.__set__) static_assert(is_assignable_to(TypeOf[MyClass.my_property.__set__], Callable)) @@ -677,7 +679,7 @@ static_assert(is_assignable_to(TypeOf[MyClass.my_property.__set__], Callable)) reveal_type(str.startswith) static_assert(is_assignable_to(TypeOf[str.startswith], Callable)) -# revealed: +# revealed: reveal_type("foo".startswith) static_assert(is_assignable_to(TypeOf["foo".startswith], Callable)) diff --git a/crates/ty_python_semantic/resources/mdtest/cycle.md b/crates/ty_python_semantic/resources/mdtest/cycle.md index 7d1686fb2d..d4cc2bd3ec 100644 --- a/crates/ty_python_semantic/resources/mdtest/cycle.md +++ b/crates/ty_python_semantic/resources/mdtest/cycle.md @@ -141,3 +141,18 @@ class C: # revealed: (*, kw_only=Unknown | ((*, kw_only=Unknown) -> Unknown)) -> Unknown reveal_type(self.d) ``` + +## Self-referential implicit attributes + +```py +class Cyclic: + def __init__(self, data: str | dict): + self.data = data + + def update(self): + if isinstance(self.data, str): + self.data = {"url": self.data} + +# revealed: Unknown | str | dict[Unknown, Unknown] | dict[Unknown | str, Unknown | str] +reveal_type(Cyclic("").data) +``` diff --git a/crates/ty_python_semantic/resources/mdtest/descriptor_protocol.md b/crates/ty_python_semantic/resources/mdtest/descriptor_protocol.md index 3b90696928..03110eac70 100644 --- a/crates/ty_python_semantic/resources/mdtest/descriptor_protocol.md +++ b/crates/ty_python_semantic/resources/mdtest/descriptor_protocol.md @@ -596,14 +596,14 @@ def f(x: object) -> str: return "a" reveal_type(f) # revealed: def f(x: object) -> str -reveal_type(f.__get__) # revealed: +reveal_type(f.__get__) # revealed: static_assert(is_subtype_of(TypeOf[f.__get__], types.MethodWrapperType)) reveal_type(f.__get__(None, type(f))) # revealed: def f(x: object) -> str reveal_type(f.__get__(None, type(f))(1)) # revealed: str wrapper_descriptor = getattr_static(f, "__get__") -reveal_type(wrapper_descriptor) # revealed: +reveal_type(wrapper_descriptor) # revealed: reveal_type(wrapper_descriptor(f, None, type(f))) # revealed: def f(x: object) -> str static_assert(is_subtype_of(TypeOf[wrapper_descriptor], types.WrapperDescriptorType)) diff --git a/crates/ty_python_semantic/resources/mdtest/generics/legacy/functions.md b/crates/ty_python_semantic/resources/mdtest/generics/legacy/functions.md index 15905b6c3b..c674f7a9a1 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/legacy/functions.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/legacy/functions.md @@ -277,7 +277,7 @@ T = TypeVar("T", int, str) def same_constrained_types(t1: T, t2: T) -> T: # TODO: no error - # error: [unsupported-operator] "Operator `+` is not supported between objects of type `T@same_constrained_types` and `T@same_constrained_types`" + # error: [unsupported-operator] "Operator `+` is not supported between two objects of type `T@same_constrained_types`" return t1 + t2 ``` @@ -287,7 +287,7 @@ and an `int` and a `str` cannot be added together: ```py def unions_are_different(t1: int | str, t2: int | str) -> int | str: - # error: [unsupported-operator] "Operator `+` is not supported between objects of type `int | str` and `int | str`" + # error: [unsupported-operator] "Operator `+` is not supported between two objects of type `int | str`" return t1 + t2 ``` diff --git a/crates/ty_python_semantic/resources/mdtest/generics/legacy/paramspec.md b/crates/ty_python_semantic/resources/mdtest/generics/legacy/paramspec.md index 201ce8d0e2..ec3d608506 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/legacy/paramspec.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/legacy/paramspec.md @@ -283,7 +283,7 @@ reveal_type(OnlyParamSpec[...]().attr) # revealed: (...) -> None def func(c: Callable[P2, None]): reveal_type(OnlyParamSpec[P2]().attr) # revealed: (**P2@func) -> None -# TODO: error: paramspec is unbound +# error: [invalid-type-arguments] "ParamSpec `P2` is unbound" reveal_type(OnlyParamSpec[P2]().attr) # revealed: (...) -> None # error: [invalid-type-arguments] "No type argument provided for required type variable `P1` of class `OnlyParamSpec`" @@ -327,15 +327,14 @@ reveal_type(TypeVarAndParamSpec[int, [int, str]]().attr) # revealed: (int, str, reveal_type(TypeVarAndParamSpec[int, [str]]().attr) # revealed: (str, /) -> int reveal_type(TypeVarAndParamSpec[int, ...]().attr) # revealed: (...) -> int -# TODO: We could still specialize for `T1` as the type is valid which would reveal `(...) -> int` -# TODO: error: paramspec is unbound -reveal_type(TypeVarAndParamSpec[int, P2]().attr) # revealed: (...) -> Unknown +# error: [invalid-type-arguments] "ParamSpec `P2` is unbound" +reveal_type(TypeVarAndParamSpec[int, P2]().attr) # revealed: (...) -> int +# error: [invalid-type-arguments] "Type argument for `ParamSpec` must be either a list of types, `ParamSpec`, `Concatenate`, or `...`" +reveal_type(TypeVarAndParamSpec[int, int]().attr) # revealed: (...) -> int # error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, int]().attr) # revealed: (...) -> Unknown +reveal_type(TypeVarAndParamSpec[int, ()]().attr) # revealed: (...) -> int # error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, ()]().attr) # revealed: (...) -> Unknown -# error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, (int, str)]().attr) # revealed: (...) -> Unknown +reveal_type(TypeVarAndParamSpec[int, (int, str)]().attr) # revealed: (...) -> int ``` Nor can they be omitted when there are more than one `ParamSpec`s. diff --git a/crates/ty_python_semantic/resources/mdtest/generics/legacy/variables.md b/crates/ty_python_semantic/resources/mdtest/generics/legacy/variables.md index c7db62281d..1cb30c699e 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/legacy/variables.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/legacy/variables.md @@ -104,6 +104,34 @@ S = TypeVar("S", **{"bound": int}) reveal_type(S) # revealed: TypeVar ``` +### No explicit specialization + +A type variable itself cannot be explicitly specialized; the result of the specialization is +`Unknown`. However, generic PEP 613 type aliases that point to type variables can be explicitly +specialized. + +```py +from typing import TypeVar, TypeAlias + +T = TypeVar("T") +ImplicitPositive = T +Positive: TypeAlias = T + +def _( + # error: [invalid-type-form] "A type variable itself cannot be specialized" + a: T[int], + # error: [invalid-type-form] "A type variable itself cannot be specialized" + b: T[T], + # error: [invalid-type-form] "A type variable itself cannot be specialized" + c: ImplicitPositive[int], + d: Positive[int], +): + reveal_type(a) # revealed: Unknown + reveal_type(b) # revealed: Unknown + reveal_type(c) # revealed: Unknown + reveal_type(d) # revealed: int +``` + ### Type variables with a default Note that the `__default__` property is only available in Python ≥3.13. diff --git a/crates/ty_python_semantic/resources/mdtest/generics/pep695/aliases.md b/crates/ty_python_semantic/resources/mdtest/generics/pep695/aliases.md index 490ae01fc6..4af89f9d2a 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/pep695/aliases.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/pep695/aliases.md @@ -68,13 +68,91 @@ reveal_type(C[int, int]) # revealed: And non-generic types cannot be specialized: ```py +from typing import TypeVar, Protocol, TypedDict + type B = ... # error: [non-subscriptable] "Cannot subscript non-generic type alias" reveal_type(B[int]) # revealed: Unknown # error: [non-subscriptable] "Cannot subscript non-generic type alias" -def _(b: B[int]): ... +def _(b: B[int]): + reveal_type(b) # revealed: Unknown + +type IntOrStr = int | str + +# error: [non-subscriptable] "Cannot subscript non-generic type alias" +def _(c: IntOrStr[int]): + reveal_type(c) # revealed: Unknown + +type ListOfInts = list[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `list[int]` is already specialized" +def _(l: ListOfInts[int]): + reveal_type(l) # revealed: Unknown + +type List[T] = list[T] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: Double specialization is not allowed" +def _(l: List[int][int]): + reveal_type(l) # revealed: Unknown + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +type DoubleSpecialization[T] = list[T][T] + +def _(d: DoubleSpecialization[int]): + reveal_type(d) # revealed: Unknown + +type Tuple = tuple[int, str] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `tuple[int, str]` is already specialized" +def _(doubly_specialized: Tuple[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +T = TypeVar("T") + +class LegacyProto(Protocol[T]): + pass + +type LegacyProtoInt = LegacyProto[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `LegacyProto[int]` is already specialized" +def _(x: LegacyProtoInt[int]): + reveal_type(x) # revealed: Unknown + +class Proto[T](Protocol): + pass + +type ProtoInt = Proto[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `Proto[int]` is already specialized" +def _(x: ProtoInt[int]): + reveal_type(x) # revealed: Unknown + +# TODO: TypedDict is just a function object at runtime, we should emit an error +class LegacyDict(TypedDict[T]): + x: T + +type LegacyDictInt = LegacyDict[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias" +def _(x: LegacyDictInt[int]): + reveal_type(x) # revealed: Unknown + +class Dict[T](TypedDict): + x: T + +type DictInt = Dict[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `Dict` is already specialized" +def _(x: DictInt[int]): + reveal_type(x) # revealed: Unknown + +type Union = list[str] | list[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `list[str] | list[int]` is already specialized" +def _(x: Union[int]): + reveal_type(x) # revealed: Unknown ``` If the type variable has an upper bound, the specialized type must satisfy that bound: @@ -98,6 +176,15 @@ reveal_type(BoundedByUnion[int]) # revealed: reveal_type(BoundedByUnion[IntSubclass]) # revealed: reveal_type(BoundedByUnion[str]) # revealed: reveal_type(BoundedByUnion[int | str]) # revealed: + +type TupleOfIntAndStr[T: int, U: str] = tuple[T, U] + +def _(x: TupleOfIntAndStr[int, str]): + reveal_type(x) # revealed: tuple[int, str] + +# error: [invalid-type-arguments] "Type `int` is not assignable to upper bound `str` of type variable `U@TupleOfIntAndStr`" +def _(x: TupleOfIntAndStr[int, int]): + reveal_type(x) # revealed: tuple[int, Unknown] ``` If the type variable is constrained, the specialized type must satisfy those constraints: @@ -119,6 +206,15 @@ reveal_type(Constrained[int | str]) # revealed: + +type TupleOfIntOrStr[T: (int, str), U: (int, str)] = tuple[T, U] + +def _(x: TupleOfIntOrStr[int, str]): + reveal_type(x) # revealed: tuple[int, str] + +# error: [invalid-type-arguments] "Type `object` does not satisfy constraints `int`, `str` of type variable `U@TupleOfIntOrStr`" +def _(x: TupleOfIntOrStr[int, object]): + reveal_type(x) # revealed: tuple[int, Unknown] ``` If the type variable has a default, it can be omitted: diff --git a/crates/ty_python_semantic/resources/mdtest/generics/pep695/functions.md b/crates/ty_python_semantic/resources/mdtest/generics/pep695/functions.md index 6026689798..a250253df7 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/pep695/functions.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/pep695/functions.md @@ -246,7 +246,7 @@ methods that are compatible with the return type, so the `return` expression is ```py def same_constrained_types[T: (int, str)](t1: T, t2: T) -> T: # TODO: no error - # error: [unsupported-operator] "Operator `+` is not supported between objects of type `T@same_constrained_types` and `T@same_constrained_types`" + # error: [unsupported-operator] "Operator `+` is not supported between two objects of type `T@same_constrained_types`" return t1 + t2 ``` @@ -256,7 +256,7 @@ and an `int` and a `str` cannot be added together: ```py def unions_are_different(t1: int | str, t2: int | str) -> int | str: - # error: [unsupported-operator] "Operator `+` is not supported between objects of type `int | str` and `int | str`" + # error: [unsupported-operator] "Operator `+` is not supported between two objects of type `int | str`" return t1 + t2 ``` diff --git a/crates/ty_python_semantic/resources/mdtest/generics/pep695/paramspec.md b/crates/ty_python_semantic/resources/mdtest/generics/pep695/paramspec.md index ad79682577..0aa0996e1e 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/pep695/paramspec.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/pep695/paramspec.md @@ -237,7 +237,7 @@ def func[**P2](c: Callable[P2, None]): P2 = ParamSpec("P2") -# TODO: error: paramspec is unbound +# error: [invalid-type-arguments] "ParamSpec `P2` is unbound" reveal_type(OnlyParamSpec[P2]().attr) # revealed: (...) -> None # error: [invalid-type-arguments] "No type argument provided for required type variable `P1` of class `OnlyParamSpec`" @@ -281,14 +281,14 @@ reveal_type(TypeVarAndParamSpec[int, [int, str]]().attr) # revealed: (int, str, reveal_type(TypeVarAndParamSpec[int, [str]]().attr) # revealed: (str, /) -> int reveal_type(TypeVarAndParamSpec[int, ...]().attr) # revealed: (...) -> int -# TODO: error: paramspec is unbound -reveal_type(TypeVarAndParamSpec[int, P2]().attr) # revealed: (...) -> Unknown +# error: [invalid-type-arguments] "ParamSpec `P2` is unbound" +reveal_type(TypeVarAndParamSpec[int, P2]().attr) # revealed: (...) -> int # error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, int]().attr) # revealed: (...) -> Unknown +reveal_type(TypeVarAndParamSpec[int, int]().attr) # revealed: (...) -> int # error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, ()]().attr) # revealed: (...) -> Unknown +reveal_type(TypeVarAndParamSpec[int, ()]().attr) # revealed: (...) -> int # error: [invalid-type-arguments] "Type argument for `ParamSpec` must be" -reveal_type(TypeVarAndParamSpec[int, (int, str)]().attr) # revealed: (...) -> Unknown +reveal_type(TypeVarAndParamSpec[int, (int, str)]().attr) # revealed: (...) -> int ``` Nor can they be omitted when there are more than one `ParamSpec`. diff --git a/crates/ty_python_semantic/resources/mdtest/generics/pep695/variables.md b/crates/ty_python_semantic/resources/mdtest/generics/pep695/variables.md index cd8343772c..067134abab 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/pep695/variables.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/pep695/variables.md @@ -98,6 +98,26 @@ def f[T: (int,)](): pass ``` +### No explicit specialization + +A type variable itself cannot be explicitly specialized; the result of the specialization is +`Unknown`. However, generic type aliases that point to type variables can be explicitly specialized. + +```py +type Positive[T] = T + +def _[T]( + # error: [invalid-type-form] "A type variable itself cannot be specialized" + a: T[int], + # error: [invalid-type-form] "A type variable itself cannot be specialized" + b: T[T], + c: Positive[int], +): + reveal_type(a) # revealed: Unknown + reveal_type(b) # revealed: Unknown + reveal_type(c) # revealed: int +``` + ## Invalid uses Note that many of the invalid uses of legacy typevars do not apply to PEP 695 typevars, since the diff --git a/crates/ty_python_semantic/resources/mdtest/generics/scoping.md b/crates/ty_python_semantic/resources/mdtest/generics/scoping.md index 31c04e0b37..bcc807e609 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/scoping.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/scoping.md @@ -102,7 +102,7 @@ class C[T]: return "a" reveal_type(getattr_static(C[int], "f")) # revealed: def f(self, x: int) -> str -reveal_type(getattr_static(C[int], "f").__get__) # revealed: +reveal_type(getattr_static(C[int], "f").__get__) # revealed: reveal_type(getattr_static(C[int], "f").__get__(None, C[int])) # revealed: def f(self, x: int) -> str # revealed: bound method C[int].f(x: int) -> str reveal_type(getattr_static(C[int], "f").__get__(C[int](), C[int])) diff --git a/crates/ty_python_semantic/resources/mdtest/generics/specialize_constrained.md b/crates/ty_python_semantic/resources/mdtest/generics/specialize_constrained.md index da4c5e7c49..32956cdfa8 100644 --- a/crates/ty_python_semantic/resources/mdtest/generics/specialize_constrained.md +++ b/crates/ty_python_semantic/resources/mdtest/generics/specialize_constrained.md @@ -16,7 +16,7 @@ An unbounded typevar can specialize to any type. We will specialize the typevar bound of all of the types that satisfy the constraint set. ```py -from typing import Never +from typing import Any, Never from ty_extensions import ConstraintSet, generic_context # fmt: off @@ -26,6 +26,8 @@ def unbounded[T](): reveal_type(generic_context(unbounded).specialize_constrained(ConstraintSet.always())) # revealed: ty_extensions.Specialization[T@unbounded = object] reveal_type(generic_context(unbounded).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: ty_extensions.Specialization[T@unbounded = Any] + reveal_type(generic_context(unbounded).specialize_constrained(ConstraintSet.range(Never, T, Any))) # revealed: None reveal_type(generic_context(unbounded).specialize_constrained(ConstraintSet.never())) @@ -68,6 +70,10 @@ class Unrelated: ... def bounded[T: Base](): # revealed: ty_extensions.Specialization[T@bounded = Base] reveal_type(generic_context(bounded).specialize_constrained(ConstraintSet.always())) + # revealed: ty_extensions.Specialization[T@bounded = Base] + reveal_type(generic_context(bounded).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: ty_extensions.Specialization[T@bounded = Base & Any] + reveal_type(generic_context(bounded).specialize_constrained(ConstraintSet.range(Never, T, Any))) # revealed: None reveal_type(generic_context(bounded).specialize_constrained(ConstraintSet.never())) @@ -94,11 +100,17 @@ def bounded_by_gradual[T: Any](): # TODO: revealed: ty_extensions.Specialization[T@bounded_by_gradual = Any] # revealed: ty_extensions.Specialization[T@bounded_by_gradual = object] reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.always())) + # revealed: ty_extensions.Specialization[T@bounded_by_gradual = object] + reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: ty_extensions.Specialization[T@bounded_by_gradual = Any] + reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Any))) # revealed: None reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.never())) # revealed: ty_extensions.Specialization[T@bounded_by_gradual = Base] reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Base))) + # revealed: ty_extensions.Specialization[T@bounded_by_gradual = object] + reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.range(Base, T, object))) # revealed: ty_extensions.Specialization[T@bounded_by_gradual = Unrelated] reveal_type(generic_context(bounded_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Unrelated))) @@ -106,14 +118,24 @@ def bounded_by_gradual[T: Any](): def bounded_by_gradual_list[T: list[Any]](): # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = Top[list[Any]]] reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.always())) + # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[object]] + reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[object]))) + # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[Any]] + reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Any]))) # revealed: None reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.never())) # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[Base]] reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Base]))) + # TODO: revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[Base]] + # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = Top[list[Any]]] + reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(list[Base], T, object))) # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[Unrelated]] reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Unrelated]))) + # TODO: revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = list[Unrelated]] + # revealed: ty_extensions.Specialization[T@bounded_by_gradual_list = Top[list[Any]]] + reveal_type(generic_context(bounded_by_gradual_list).specialize_constrained(ConstraintSet.range(list[Unrelated], T, object))) ``` ## Constrained typevar @@ -142,12 +164,21 @@ def constrained[T: (Base, Unrelated)](): # revealed: None reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.always())) # revealed: None + reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: None + reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Never, T, Any))) + # revealed: None reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.never())) # revealed: ty_extensions.Specialization[T@constrained = Base] reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Never, T, Base))) + # revealed: ty_extensions.Specialization[T@constrained = Base] + reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Base, T, object))) + # revealed: ty_extensions.Specialization[T@constrained = Unrelated] reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Never, T, Unrelated))) + # revealed: ty_extensions.Specialization[T@constrained = Unrelated] + reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Unrelated, T, object))) # revealed: ty_extensions.Specialization[T@constrained = Base] reveal_type(generic_context(constrained).specialize_constrained(ConstraintSet.range(Never, T, Super))) @@ -178,15 +209,25 @@ def constrained_by_gradual[T: (Base, Any)](): # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Base] reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, object))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Base & Any] + reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Any))) # revealed: None reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.never())) # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Base] reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Base))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Base] + reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Base, T, object))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Unrelated] reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Never, T, Unrelated))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual = object] + reveal_type(generic_context(constrained_by_gradual).specialize_constrained(ConstraintSet.range(Unrelated, T, object))) # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] # revealed: ty_extensions.Specialization[T@constrained_by_gradual = Base] @@ -206,6 +247,11 @@ def constrained_by_two_gradual[T: (Any, Any)](): # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = Any] # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual = object] reveal_type(generic_context(constrained_by_two_gradual).specialize_constrained(ConstraintSet.always())) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_two_gradual = Any] + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual = object] + reveal_type(generic_context(constrained_by_two_gradual).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual = Any] + reveal_type(generic_context(constrained_by_two_gradual).specialize_constrained(ConstraintSet.range(Never, T, Any))) # revealed: None reveal_type(generic_context(constrained_by_two_gradual).specialize_constrained(ConstraintSet.never())) @@ -233,14 +279,24 @@ def constrained_by_two_gradual[T: (Any, Any)](): def constrained_by_gradual_list[T: (list[Base], list[Any])](): # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Base]] reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.always())) + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[object]] + reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[object]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Any]] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Base] & list[Any]] + reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Any]))) # revealed: None reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.never())) # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Base]] reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Base]))) - # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Base]] + reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(list[Base], T, object))) + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Unrelated]] reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(Never, T, list[Unrelated]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Unrelated]] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = Top[list[Any]]] + reveal_type(generic_context(constrained_by_gradual_list).specialize_constrained(ConstraintSet.range(list[Unrelated], T, object))) # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list = list[Super]] @@ -257,14 +313,25 @@ def constrained_by_gradual_list[T: (list[Base], list[Any])](): def constrained_by_gradual_list_reverse[T: (list[Any], list[Base])](): # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Base]] reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.always())) + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[object]] + reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(Never, T, list[object]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Any]] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Base] & list[Any]] + reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(Never, T, list[Any]))) # revealed: None reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.never())) # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Base]] reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(Never, T, list[Base]))) + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Base]] + reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(list[Base], T, object))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Unrelated]] reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(Never, T, list[Unrelated]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Unrelated]] + # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = Top[list[Any]]] + reveal_type(generic_context(constrained_by_gradual_list_reverse).specialize_constrained(ConstraintSet.range(list[Unrelated], T, object))) # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_gradual_list_reverse = list[Super]] @@ -280,15 +347,26 @@ def constrained_by_two_gradual_lists[T: (list[Any], list[Any])](): # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = Top[list[Any]]] reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.always())) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = list[Any]] + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = Top[list[Any]]] + reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(Never, T, object))) + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = list[Any]] + reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(Never, T, list[Any]))) # revealed: None reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.never())) - # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = list[Base]] reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(Never, T, list[Base]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Base]] + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = Top[list[Any]]] + reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(list[Base], T, object))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = list[Unrelated]] reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(Never, T, list[Unrelated]))) + # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Unrelated]] + # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = Top[list[Any]]] + reveal_type(generic_context(constrained_by_two_gradual_lists).specialize_constrained(ConstraintSet.range(list[Unrelated], T, object))) # TODO: revealed: ty_extensions.Specialization[T@constrained_by_gradual = list[Any]] # revealed: ty_extensions.Specialization[T@constrained_by_two_gradual_lists = list[Super]] diff --git a/crates/ty_python_semantic/resources/mdtest/implicit_type_aliases.md b/crates/ty_python_semantic/resources/mdtest/implicit_type_aliases.md index 99a5de8aa9..977991611c 100644 --- a/crates/ty_python_semantic/resources/mdtest/implicit_type_aliases.md +++ b/crates/ty_python_semantic/resources/mdtest/implicit_type_aliases.md @@ -214,7 +214,7 @@ def _(int_or_int: IntOrInt, list_of_int_or_list_of_int: ListOfIntOrListOfInt): `NoneType` has no special or-operator behavior, so this is an error: ```py -None | None # error: [unsupported-operator] "Operator `|` is not supported between objects of type `None` and `None`" +None | None # error: [unsupported-operator] "Operator `|` is not supported between two objects of type `None`" ``` When constructing something nonsensical like `int | 1`, we emit a diagnostic for the expression @@ -414,6 +414,7 @@ def _( list_or_tuple_legacy: ListOrTupleLegacy[int], my_callable: MyCallable[[str, bytes], int], annotated_int: AnnotatedType[int], + # error: [invalid-type-form] "A type variable itself cannot be specialized" transparent_alias: TransparentAlias[int], optional_int: MyOptional[int], ): @@ -427,7 +428,7 @@ def _( reveal_type(list_or_tuple_legacy) # revealed: list[int] | tuple[int, ...] reveal_type(my_callable) # revealed: (str, bytes, /) -> int reveal_type(annotated_int) # revealed: int - reveal_type(transparent_alias) # revealed: int + reveal_type(transparent_alias) # revealed: Unknown reveal_type(optional_int) # revealed: int | None ``` @@ -653,13 +654,92 @@ def g(obj: Y[bool, range]): A generic alias that is already fully specialized cannot be specialized again: +```toml +[environment] +python-version = "3.12" +``` + ```py +from typing import Protocol, TypeVar, TypedDict + ListOfInts = list[int] -# error: [invalid-type-arguments] "Too many type arguments: expected 0, got 1" +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" def _(doubly_specialized: ListOfInts[int]): - # TODO: This should ideally be `list[Unknown]` or `Unknown` - reveal_type(doubly_specialized) # revealed: list[int] + reveal_type(doubly_specialized) # revealed: Unknown + +type ListOfInts2 = list[int] +# error: [non-subscriptable] "Cannot subscript non-generic type alias: `list[int]` is already specialized" +DoublySpecialized = ListOfInts2[int] + +def _(doubly_specialized: DoublySpecialized): + reveal_type(doubly_specialized) # revealed: Unknown + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +List = list[int][int] + +def _(doubly_specialized: List): + reveal_type(doubly_specialized) # revealed: Unknown + +Tuple = tuple[int, str] + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +def _(doubly_specialized: Tuple[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +T = TypeVar("T") + +class LegacyProto(Protocol[T]): + pass + +LegacyProtoInt = LegacyProto[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +def _(doubly_specialized: LegacyProtoInt[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +class Proto[T](Protocol): + pass + +ProtoInt = Proto[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +def _(doubly_specialized: ProtoInt[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +# TODO: TypedDict is just a function object at runtime, we should emit an error +class LegacyDict(TypedDict[T]): + x: T + +# TODO: should be a `non-subscriptable` error +LegacyDictInt = LegacyDict[int] + +# TODO: should be a `non-subscriptable` error +def _(doubly_specialized: LegacyDictInt[int]): + # TODO: should be `Unknown` + reveal_type(doubly_specialized) # revealed: @Todo(Inference of subscript on special form) + +class Dict[T](TypedDict): + x: T + +DictInt = Dict[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +def _(doubly_specialized: DictInt[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +Union = list[str] | list[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type: `` is already specialized" +def _(doubly_specialized: Union[int]): + reveal_type(doubly_specialized) # revealed: Unknown + +type MyListAlias[T] = list[T] +MyListOfInts = MyListAlias[int] + +# error: [non-subscriptable] "Cannot subscript non-generic type alias: Double specialization is not allowed" +def _(doubly_specialized: MyListOfInts[int]): + reveal_type(doubly_specialized) # revealed: Unknown ``` Specializing a generic implicit type alias with an incorrect number of type arguments also results @@ -695,23 +775,21 @@ def this_does_not_work() -> TypeOf[IntOrStr]: raise NotImplementedError() def _( - # TODO: Better error message (of kind `invalid-type-form`)? - # error: [invalid-type-arguments] "Too many type arguments: expected 0, got 1" + # error: [non-subscriptable] "Cannot subscript non-generic type" specialized: this_does_not_work()[int], ): - reveal_type(specialized) # revealed: int | str + reveal_type(specialized) # revealed: Unknown ``` Similarly, if you try to specialize a union type without a binding context, we emit an error: ```py -# TODO: Better error message (of kind `invalid-type-form`)? -# error: [invalid-type-arguments] "Too many type arguments: expected 0, got 1" +# error: [non-subscriptable] "Cannot subscript non-generic type" x: (list[T] | set[T])[int] def _(): # TODO: `list[Unknown] | set[Unknown]` might be better - reveal_type(x) # revealed: list[typing.TypeVar] | set[typing.TypeVar] + reveal_type(x) # revealed: Unknown ``` ### Multiple definitions diff --git a/crates/ty_python_semantic/resources/mdtest/import/workspaces.md b/crates/ty_python_semantic/resources/mdtest/import/workspaces.md index 95003765b8..44d6ed3486 100644 --- a/crates/ty_python_semantic/resources/mdtest/import/workspaces.md +++ b/crates/ty_python_semantic/resources/mdtest/import/workspaces.md @@ -8,12 +8,87 @@ two projects in a monorepo have conflicting definitions (but we want to analyze In practice these tests cover what we call "desperate module resolution" which, when an import fails, results in us walking up the ancestor directories of the importing file and trying those as -"desperate search-paths". +"desperate search-paths" until one works. Currently desperate search-paths are restricted to subdirectories of the first-party search-path -(the directory you're running `ty` in). Currently we only consider one desperate search-path: the -closest ancestor directory containing a `pyproject.toml`. In the future we may want to try every -ancestor `pyproject.toml` or every ancestor directory. +(typically, the directory you're running `ty` in). + +There are two styles of desperate search-path we consider: "absolute" and "relative". Absolute +desperate search-paths are used for resolving absolute imports (`import a.b.c`) while relative +desperate search-paths are used for resolving relative imports (`from .c import x`). + +Only the closest directory that contains either a `pyproject.toml` or `ty.toml` is a valid relative +desperate search-path. + +All ancestor directories that *do not* contain an `__init__.py(i)` are valid absolute desperate +search-paths. + +(Distracting detail: to ensure relative desperate search-paths are always valid absolute desperate +search-paths, a directory that contains an `__init__.py(i)` *and* either a `pyproject.toml` or +`ty.toml` is also a valid absolute search-path, but this shouldn't matter in practice, as you do not +typically have those two kinds of file in the same directory.) + +## Relative Desperate Search-Paths + +We do not directly resolve relative imports. Instead we have a two-phase process: + +1. Convert the relative module name `.c` to an absolute one `a.b.c` +1. Resolve the absolute import `a.b.c` + +(This allows us to transparently handle packaging semantics that mandate separate directories should +be "logically combined" into a single directory, like namespace packages and stub packages.) + +Relative desperate search-paths only appear in step 1, where we compute the module name of the +importing file as the first step in resolving `.` to an absolute module name. + +In practice, relative desperate search-paths are rarely needed because it usually doesn't matter if +we think `.` is `a.b` or `b` when resolving `.c`: the fact that we computed `a.b` using our +search-paths means `a.b.c` is what will resolve with those search-paths! + +There are three caveats to this: + +- If the module name we compute is *too short* then too many relative levels will fail to resolve + (`..c` resolves in `a.b` but not `b`). +- If the module name is *too long* then we may encounter directories that aren't valid module names, + and reject the import (`my-proj.a.b.c` is not a valid module name). +- Sloppiness will break relative imports in any kind of packaging situation where different + directories are supposed to be "logically combined". + +The fact that we restrict desperate resolution to the first-party search-path ("the project you're +working on") allows us to largely dismiss the last concern for the purposes of this discussion. The +remaining two concerns encourage us to find "the longest possible module name without stumbling into +random nonsense directories". When we need relative desperate search-paths we are usually running +into the "too long" problem and "snap to the parent `pyproject.toml` (or `ty.toml`)" tends to +resolve it well! + +As a more aesthetic concern, this approach also ensures that all the files under a given +`pyproject.toml` will, when faced with desperation, agree on eachother's relative module names. This +may or may not be important, but it's definitely *reassuring* and *satisfying*! + +## Absolute Desperate Search-Paths + +Absolute desperate search-paths are much more load-bearing, because if we're handed the absolute +import `a.b.c` then there is only one possible search-path that will properly resolve this the way +the user wants, and if that search-path isn't configured we will fail. + +Basic heuristics like checking for `/src/` and resolving editables in the local `.venv` +work well in most cases, but desperate resolution is needed in a couple key scenarios: + +- Test or script directories have a tendency to assume extra search-paths that aren't structurally + obvious ([notably pytest](https://docs.pytest.org/en/stable/explanation/pythonpath.html)) +- If you open the root of a monorepo in an IDE, you will often have many separate projects but no + configuration explaining this. Absolute imports within each project should resolve things in + that project. + +The latter case is often handled reasonably well by the the `pyproject.toml` rule that relative +desperate search-paths have. However the more complex testing/scripting scenarios tend to fall over +here -- in the limit pytest will add literally every ancestor to the search-path, and so we simply +need to try every single one and hope *one* works for every absolute import (and it might be a +different one for different imports). + +We exclude directories that contain an `__init__.py(i)` because there shouldn't be any reasonable +scenario where we need to "truncate" a regular package like that (and pytest's Exciting behaviour +here is explicitly disabled by `__init__.py`). ## Invalid Names @@ -134,13 +209,11 @@ from .mod1 import x # error: [unresolved-import] from . import mod2 - -# error: [unresolved-import] import mod3 reveal_type(x) # revealed: Unknown reveal_type(mod2.y) # revealed: Unknown -reveal_type(mod3.z) # revealed: Unknown +reveal_type(mod3.z) # revealed: int ``` `my-proj/tests/mod1.py`: @@ -338,21 +411,6 @@ create, and we are now very sensitive to precise search-path ordering.** Here the use of editables means that `a/` has higher priority than `a/src/a/`. -Somehow this results in `a/tests/test1.py` being able to resolve `.setup` but not `.`. - -My best guess is that in this state we can resolve regular modules in `a/tests/` but not namespace -packages because we have some extra validation for namespace packages conflicted by regular -packages, but that validation isn't applied when we successfully resolve a submodule of the -namespace package. - -In this case, as we find that `a/tests/test1.py` matches on the first-party path as `a.tests.test1` -and is syntactically valid. We then resolve `a.tests.test1` and because the namespace package -(`/a/`) comes first we succeed. We then syntactically compute `.` to be `a.tests`. - -When we go to lookup `a.tests.setup`, whatever grace that allowed `a.tests.test1` to resolve still -works so it resolves too. However when we try to resolve `a.tests` on its own some additional -validation rejects the namespace package conflicting with the regular package. - ```toml [environment] # Setup a venv with editables for a/src/ and b/src/ @@ -385,17 +443,13 @@ b/src/ `a/tests/test1.py`: ```py -# TODO: there should be no errors in this file. - from .setup import x - -# error: [unresolved-import] from . import setup from a import y import a reveal_type(x) # revealed: int -reveal_type(setup.x) # revealed: Unknown +reveal_type(setup.x) # revealed: int reveal_type(y) # revealed: int reveal_type(a.y) # revealed: int ``` @@ -422,17 +476,13 @@ y: int = 10 `b/tests/test1.py`: ```py -# TODO: there should be no errors in this file - from .setup import x - -# error: [unresolved-import] from . import setup from b import y import b reveal_type(x) # revealed: str -reveal_type(setup.x) # revealed: Unknown +reveal_type(setup.x) # revealed: str reveal_type(y) # revealed: str reveal_type(b.y) # revealed: str ``` diff --git a/crates/ty_python_semantic/resources/mdtest/properties.md b/crates/ty_python_semantic/resources/mdtest/properties.md index 6f1e2215ef..f0f88ae050 100644 --- a/crates/ty_python_semantic/resources/mdtest/properties.md +++ b/crates/ty_python_semantic/resources/mdtest/properties.md @@ -271,8 +271,8 @@ method, which means that it is a *data* descriptor (if there is no setter, `__se available but yields an `AttributeError` at runtime). ```py -reveal_type(type(attr_property).__get__) # revealed: -reveal_type(type(attr_property).__set__) # revealed: +reveal_type(type(attr_property).__get__) # revealed: +reveal_type(type(attr_property).__set__) # revealed: ``` When we access `c.attr`, the `__get__` method of the `property` class is called, passing the diff --git a/crates/ty_python_semantic/resources/mdtest/snapshots/annotations.md_-_Assignment_with_anno…_-_PEP-604_in_non-type-…_-_Earlier_versions_(f2859c9800f37c7).snap b/crates/ty_python_semantic/resources/mdtest/snapshots/annotations.md_-_Assignment_with_anno…_-_PEP-604_in_non-type-…_-_Earlier_versions_(f2859c9800f37c7).snap index 83b964676a..4435a4f727 100644 --- a/crates/ty_python_semantic/resources/mdtest/snapshots/annotations.md_-_Assignment_with_anno…_-_PEP-604_in_non-type-…_-_Earlier_versions_(f2859c9800f37c7).snap +++ b/crates/ty_python_semantic/resources/mdtest/snapshots/annotations.md_-_Assignment_with_anno…_-_PEP-604_in_non-type-…_-_Earlier_versions_(f2859c9800f37c7).snap @@ -19,12 +19,15 @@ mdtest path: crates/ty_python_semantic/resources/mdtest/assignment/annotations.m # Diagnostics ``` -error[unsupported-operator]: Operator `|` is not supported between objects of type `` and `` +error[unsupported-operator]: Unsupported `|` operation --> src/mdtest_snippet.py:2:12 | 1 | # error: [unsupported-operator] 2 | IntOrStr = int | str - | ^^^^^^^^^ + | ---^^^--- + | | | + | | Has type `` + | Has type `` | info: Note that `X | Y` PEP 604 union syntax is only available in Python 3.10 and later info: Python 3.9 was assumed when resolving types because it was specified on the command line diff --git a/crates/ty_python_semantic/resources/mdtest/snapshots/augmented.md_-_Augmented_assignment_-_Unsupported_types_(a041d9e40c83a8ac).snap b/crates/ty_python_semantic/resources/mdtest/snapshots/augmented.md_-_Augmented_assignment_-_Unsupported_types_(a041d9e40c83a8ac).snap new file mode 100644 index 0000000000..0093cf5e4f --- /dev/null +++ b/crates/ty_python_semantic/resources/mdtest/snapshots/augmented.md_-_Augmented_assignment_-_Unsupported_types_(a041d9e40c83a8ac).snap @@ -0,0 +1,44 @@ +--- +source: crates/ty_test/src/lib.rs +expression: snapshot +--- +--- +mdtest name: augmented.md - Augmented assignment - Unsupported types +mdtest path: crates/ty_python_semantic/resources/mdtest/assignment/augmented.md +--- + +# Python source files + +## mdtest_snippet.py + +``` +1 | class C: +2 | def __isub__(self, other: str) -> int: +3 | return 42 +4 | +5 | x = C() +6 | # error: [unsupported-operator] "Operator `-=` is not supported between objects of type `C` and `Literal[1]`" +7 | x -= 1 +8 | +9 | reveal_type(x) # revealed: int +``` + +# Diagnostics + +``` +error[unsupported-operator]: Unsupported `-=` operation + --> src/mdtest_snippet.py:7:1 + | +5 | x = C() +6 | # error: [unsupported-operator] "Operator `-=` is not supported between objects of type `C` and `Literal[1]`" +7 | x -= 1 + | -^^^^- + | | | + | | Has type `Literal[1]` + | Has type `C` +8 | +9 | reveal_type(x) # revealed: int + | +info: rule `unsupported-operator` is enabled by default + +``` diff --git a/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_(93f2f1c488e06f53).snap b/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_(93f2f1c488e06f53).snap new file mode 100644 index 0000000000..038ac1c411 --- /dev/null +++ b/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_(93f2f1c488e06f53).snap @@ -0,0 +1,80 @@ +--- +source: crates/ty_test/src/lib.rs +expression: snapshot +--- +--- +mdtest name: custom.md - Custom binary operations - Classes +mdtest path: crates/ty_python_semantic/resources/mdtest/binary/custom.md +--- + +# Python source files + +## mdtest_snippet.py + +``` + 1 | from typing import Literal + 2 | + 3 | class Yes: + 4 | def __add__(self, other) -> Literal["+"]: + 5 | return "+" + 6 | + 7 | class Sub(Yes): ... + 8 | class No: ... + 9 | +10 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +11 | reveal_type(Yes + Yes) # revealed: Unknown +12 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +13 | reveal_type(Sub + Sub) # revealed: Unknown +14 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +15 | reveal_type(No + No) # revealed: Unknown +``` + +# Diagnostics + +``` +error[unsupported-operator]: Unsupported `+` operation + --> src/mdtest_snippet.py:11:13 + | +10 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +11 | reveal_type(Yes + Yes) # revealed: Unknown + | ---^^^--- + | | + | Both operands have type `` +12 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +13 | reveal_type(Sub + Sub) # revealed: Unknown + | +info: rule `unsupported-operator` is enabled by default + +``` + +``` +error[unsupported-operator]: Unsupported `+` operation + --> src/mdtest_snippet.py:13:13 + | +11 | reveal_type(Yes + Yes) # revealed: Unknown +12 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +13 | reveal_type(Sub + Sub) # revealed: Unknown + | ---^^^--- + | | + | Both operands have type `` +14 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +15 | reveal_type(No + No) # revealed: Unknown + | +info: rule `unsupported-operator` is enabled by default + +``` + +``` +error[unsupported-operator]: Unsupported `+` operation + --> src/mdtest_snippet.py:15:13 + | +13 | reveal_type(Sub + Sub) # revealed: Unknown +14 | # error: [unsupported-operator] "Operator `+` is not supported between two objects of type ``" +15 | reveal_type(No + No) # revealed: Unknown + | --^^^-- + | | + | Both operands have type `` + | +info: rule `unsupported-operator` is enabled by default + +``` diff --git a/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_from_differe…_(2890e4875c9b9c1e).snap b/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_from_differe…_(2890e4875c9b9c1e).snap new file mode 100644 index 0000000000..5591be03d7 --- /dev/null +++ b/crates/ty_python_semantic/resources/mdtest/snapshots/custom.md_-_Custom_binary_operat…_-_Classes_from_differe…_(2890e4875c9b9c1e).snap @@ -0,0 +1,44 @@ +--- +source: crates/ty_test/src/lib.rs +expression: snapshot +--- +--- +mdtest name: custom.md - Custom binary operations - Classes from different modules with the same name +mdtest path: crates/ty_python_semantic/resources/mdtest/binary/custom.md +--- + +# Python source files + +## mod1.py + +``` +1 | class A: ... +``` + +## mod2.py + +``` +1 | import mod1 +2 | +3 | class A: ... +4 | +5 | # error: [unsupported-operator] "Operator `+` is not supported between objects of type `mod2.A` and `mod1.A`" +6 | A() + mod1.A() +``` + +# Diagnostics + +``` +error[unsupported-operator]: Unsupported `+` operation + --> src/mod2.py:6:1 + | +5 | # error: [unsupported-operator] "Operator `+` is not supported between objects of type `mod2.A` and `mod1.A`" +6 | A() + mod1.A() + | ---^^^-------- + | | | + | | Has type `mod1.A` + | Has type `mod2.A` + | +info: rule `unsupported-operator` is enabled by default + +``` diff --git a/crates/ty_python_semantic/resources/mdtest/unary/custom.md b/crates/ty_python_semantic/resources/mdtest/unary/custom.md index 2b2eb3a619..c471ff509f 100644 --- a/crates/ty_python_semantic/resources/mdtest/unary/custom.md +++ b/crates/ty_python_semantic/resources/mdtest/unary/custom.md @@ -24,11 +24,11 @@ reveal_type(+Sub()) # revealed: bool reveal_type(-Sub()) # revealed: str reveal_type(~Sub()) # revealed: int -# error: [unsupported-operator] "Unary operator `+` is not supported for type `No`" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type `No`" reveal_type(+No()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type `No`" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type `No`" reveal_type(-No()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type `No`" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type `No`" reveal_type(~No()) # revealed: Unknown ``` @@ -52,25 +52,25 @@ class Yes: class Sub(Yes): ... class No: ... -# error: [unsupported-operator] "Unary operator `+` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type ``" reveal_type(+Yes) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type ``" reveal_type(-Yes) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type ``" reveal_type(~Yes) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `+` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type ``" reveal_type(+Sub) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type ``" reveal_type(-Sub) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type ``" reveal_type(~Sub) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `+` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type ``" reveal_type(+No) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type ``" reveal_type(-No) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type ``" reveal_type(~No) # revealed: Unknown ``` @@ -80,11 +80,11 @@ reveal_type(~No) # revealed: Unknown def f(): pass -# error: [unsupported-operator] "Unary operator `+` is not supported for type `def f() -> Unknown`" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type `def f() -> Unknown`" reveal_type(+f) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type `def f() -> Unknown`" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type `def f() -> Unknown`" reveal_type(-f) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type `def f() -> Unknown`" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type `def f() -> Unknown`" reveal_type(~f) # revealed: Unknown ``` @@ -113,25 +113,25 @@ def sub() -> type[Sub]: def no() -> type[No]: return No -# error: [unsupported-operator] "Unary operator `+` is not supported for type `type[Yes]`" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type `type[Yes]`" reveal_type(+yes()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type `type[Yes]`" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type `type[Yes]`" reveal_type(-yes()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type `type[Yes]`" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type `type[Yes]`" reveal_type(~yes()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `+` is not supported for type `type[Sub]`" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type `type[Sub]`" reveal_type(+sub()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type `type[Sub]`" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type `type[Sub]`" reveal_type(-sub()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type `type[Sub]`" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type `type[Sub]`" reveal_type(~sub()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `+` is not supported for type `type[No]`" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type `type[No]`" reveal_type(+no()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type `type[No]`" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type `type[No]`" reveal_type(-no()) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type `type[No]`" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type `type[No]`" reveal_type(~no()) # revealed: Unknown ``` @@ -160,10 +160,10 @@ reveal_type(+Sub) # revealed: bool reveal_type(-Sub) # revealed: str reveal_type(~Sub) # revealed: int -# error: [unsupported-operator] "Unary operator `+` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `+` is not supported for object of type ``" reveal_type(+No) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `-` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `-` is not supported for object of type ``" reveal_type(-No) # revealed: Unknown -# error: [unsupported-operator] "Unary operator `~` is not supported for type ``" +# error: [unsupported-operator] "Unary operator `~` is not supported for object of type ``" reveal_type(~No) # revealed: Unknown ``` diff --git a/crates/ty_python_semantic/resources/mdtest/unary/invert_add_usub.md b/crates/ty_python_semantic/resources/mdtest/unary/invert_add_usub.md index 100176e1cb..53b4ca6366 100644 --- a/crates/ty_python_semantic/resources/mdtest/unary/invert_add_usub.md +++ b/crates/ty_python_semantic/resources/mdtest/unary/invert_add_usub.md @@ -27,7 +27,7 @@ reveal_type(~a) # revealed: Literal[True] class NoDunder: ... b = NoDunder() -+b # error: [unsupported-operator] "Unary operator `+` is not supported for type `NoDunder`" --b # error: [unsupported-operator] "Unary operator `-` is not supported for type `NoDunder`" -~b # error: [unsupported-operator] "Unary operator `~` is not supported for type `NoDunder`" ++b # error: [unsupported-operator] "Unary operator `+` is not supported for object of type `NoDunder`" +-b # error: [unsupported-operator] "Unary operator `-` is not supported for object of type `NoDunder`" +~b # error: [unsupported-operator] "Unary operator `~` is not supported for object of type `NoDunder`" ``` diff --git a/crates/ty_python_semantic/src/module_resolver/resolver.rs b/crates/ty_python_semantic/src/module_resolver/resolver.rs index 60b565a564..4be43b4453 100644 --- a/crates/ty_python_semantic/src/module_resolver/resolver.rs +++ b/crates/ty_python_semantic/src/module_resolver/resolver.rs @@ -336,7 +336,14 @@ pub(crate) fn file_to_module(db: &dyn Db, file: File) -> Option> { path, search_paths(db, ModuleResolveMode::StubsAllowed), ) - .or_else(|| file_to_module_impl(db, file, path, desperate_search_paths(db, file).iter())) + .or_else(|| { + file_to_module_impl( + db, + file, + path, + relative_desperate_search_paths(db, file).iter(), + ) + }) } fn file_to_module_impl<'db, 'a>( @@ -388,11 +395,81 @@ pub(crate) fn search_paths(db: &dyn Db, resolve_mode: ModuleResolveMode) -> Sear Program::get(db).search_paths(db).iter(db, resolve_mode) } -/// Get the search-paths that should be used for desperate resolution of imports in this file +/// Get the search-paths for desperate resolution of absolute imports in this file. /// -/// Currently this is "the closest ancestor dir that contains a pyproject.toml", which is -/// a completely arbitrary decision. We could potentially change this to return an iterator -/// of every ancestor with a pyproject.toml or every ancestor. +/// Currently this is "all ancestor directories that don't contain an `__init__.py(i)`" +/// (from closest-to-importing-file to farthest). +/// +/// (For paranoia purposes, all relative desperate search-paths are also absolute +/// valid desperate search-paths, but don't worry about that.) +/// +/// We exclude `__init__.py(i)` dirs to avoid truncating packages. +#[salsa::tracked(heap_size=ruff_memory_usage::heap_size)] +fn absolute_desperate_search_paths(db: &dyn Db, importing_file: File) -> Option> { + let system = db.system(); + let importing_path = importing_file.path(db).as_system_path()?; + + // Only allow this if the importing_file is under the first-party search path + let (base_path, rel_path) = + search_paths(db, ModuleResolveMode::StubsAllowed).find_map(|search_path| { + if !search_path.is_first_party() { + return None; + } + Some(( + search_path.as_system_path()?, + search_path.relativize_system_path_only(importing_path)?, + )) + })?; + + // Read the revision on the corresponding file root to + // register an explicit dependency on this directory. When + // the revision gets bumped, the cache that Salsa creates + // for this routine will be invalidated. + // + // (This is conditional because ruff uses this code too and doesn't set roots) + if let Some(root) = db.files().root(db, base_path) { + let _ = root.revision(db); + } + + // Only allow searching up to the first-party path's root + let mut search_paths = Vec::new(); + for rel_dir in rel_path.ancestors() { + let candidate_path = base_path.join(rel_dir); + if !system.is_directory(&candidate_path) { + continue; + } + // Any dir that isn't a proper package is plausibly some test/script dir that could be + // added as a search-path at runtime. Notably this reflects pytest's default mode where + // it adds every dir with a .py to the search-paths (making all test files root modules), + // unless they see an `__init__.py`, in which case they assume you don't want that. + let isnt_regular_package = !system.is_file(&candidate_path.join("__init__.py")) + && !system.is_file(&candidate_path.join("__init__.pyi")); + // Any dir with a pyproject.toml or ty.toml is a valid relative desperate search-path and + // we want all of those to also be valid absolute desperate search-paths. It doesn't + // make any sense for a folder to have `pyproject.toml` and `__init__.py` but let's + // not let something cursed and spooky happen, ok? d + if isnt_regular_package + || system.is_file(&candidate_path.join("pyproject.toml")) + || system.is_file(&candidate_path.join("ty.toml")) + { + let search_path = SearchPath::first_party(system, candidate_path).ok()?; + search_paths.push(search_path); + } + } + + if search_paths.is_empty() { + None + } else { + Some(search_paths) + } +} + +/// Get the search-paths for desperate resolution of relative imports in this file. +/// +/// Currently this is "the closest ancestor dir that contains a pyproject.toml (or ty.toml)", +/// which is a completely arbitrary decision. However it's farily important that relative +/// desperate search-paths pick a single "best" answer because every one is *valid* but one +/// that's too long or too short may cause problems. /// /// For now this works well in common cases where we have some larger workspace that contains /// one or more python projects in sub-directories, and those python projects assume that @@ -402,7 +479,7 @@ pub(crate) fn search_paths(db: &dyn Db, resolve_mode: ModuleResolveMode) -> Sear /// chaotic things. In particular, all files under a given pyproject.toml will currently /// agree on this being their desperate search-path, which is really nice. #[salsa::tracked(heap_size=ruff_memory_usage::heap_size)] -fn desperate_search_paths(db: &dyn Db, importing_file: File) -> Option { +fn relative_desperate_search_paths(db: &dyn Db, importing_file: File) -> Option { let system = db.system(); let importing_path = importing_file.path(db).as_system_path()?; @@ -431,13 +508,15 @@ fn desperate_search_paths(db: &dyn Db, importing_file: File) -> Option Option { - let search_paths = desperate_search_paths(db, importing_file); - resolve_name_impl(db, name, mode, search_paths.iter()) + let search_paths = absolute_desperate_search_paths(db, importing_file); + resolve_name_impl(db, name, mode, search_paths.iter().flatten()) } fn resolve_name_impl<'a>( diff --git a/crates/ty_python_semantic/src/types.rs b/crates/ty_python_semantic/src/types.rs index a746d1bb68..87bd78009a 100644 --- a/crates/ty_python_semantic/src/types.rs +++ b/crates/ty_python_semantic/src/types.rs @@ -935,7 +935,30 @@ impl<'db> Type<'db> { // type for each overload of each function definition. (Type::FunctionLiteral(_), Type::FunctionLiteral(_)) => self, - _ => UnionType::from_elements_cycle_recovery(db, [self, previous]), + _ => { + // Also avoid unioning in a previous type which contains a Divergent from the + // current cycle, if the most-recent type does not. This cannot cause an + // oscillation, since Divergent is only introduced at the start of fixpoint + // iteration. + let has_divergent_type_in_cycle = |ty| { + any_over_type( + db, + ty, + &|nested_ty| { + matches!( + nested_ty, + Type::Dynamic(DynamicType::Divergent(DivergentType { id })) + if cycle.head_ids().contains(&id)) + }, + false, + ) + }; + if has_divergent_type_in_cycle(previous) && !has_divergent_type_in_cycle(self) { + self + } else { + UnionType::from_elements_cycle_recovery(db, [self, previous]) + } + } } .recursive_type_normalized(db, cycle) } @@ -1002,6 +1025,41 @@ impl<'db> Type<'db> { matches!(self, Type::GenericAlias(_)) } + /// Returns whether the definition of this type is generic + /// (this is different from whether this type *is* a generic type; a type that is already fully specialized is not a generic type). + pub(crate) fn is_definition_generic(self, db: &'db dyn Db) -> bool { + match self { + Type::Union(union) => union + .elements(db) + .iter() + .any(|ty| ty.is_definition_generic(db)), + Type::Intersection(intersection) => { + intersection + .positive(db) + .iter() + .any(|ty| ty.is_definition_generic(db)) + || intersection + .negative(db) + .iter() + .any(|ty| ty.is_definition_generic(db)) + } + Type::NominalInstance(instance_type) => instance_type.is_definition_generic(), + Type::ProtocolInstance(protocol) => { + matches!(protocol.inner, Protocol::FromClass(class) if class.is_generic()) + } + Type::TypedDict(typed_dict) => typed_dict + .defining_class() + .is_some_and(ClassType::is_generic), + Type::Dynamic(dynamic) => { + matches!(dynamic, DynamicType::UnknownGeneric(_)) + } + // Due to inheritance rules, enums cannot be generic. + Type::EnumLiteral(_) => false, + // Once generic NewType is officially specified, handle it. + _ => false, + } + } + const fn is_dynamic(&self) -> bool { matches!(self, Type::Dynamic(_)) } @@ -1798,7 +1856,7 @@ impl<'db> Type<'db> { Type::GenericAlias(alias) => Some(ClassType::Generic(alias).into_callable(db)), Type::NewTypeInstance(newtype) => { - Type::instance(db, newtype.base_class_type(db)).try_upcast_to_callable(db) + newtype.concrete_base_type(db).try_upcast_to_callable(db) } // TODO: This is unsound so in future we can consider an opt-in option to disable it. @@ -2018,21 +2076,9 @@ impl<'db> Type<'db> { // only has to hold when the typevar has a valid specialization (i.e., one that // satisfies the upper bound/constraints). if let Type::TypeVar(bound_typevar) = self { - return ConstraintSet::constrain_typevar( - db, - bound_typevar, - Type::Never, - target, - relation, - ); + return ConstraintSet::constrain_typevar(db, bound_typevar, Type::Never, target); } else if let Type::TypeVar(bound_typevar) = target { - return ConstraintSet::constrain_typevar( - db, - bound_typevar, - self, - Type::object(), - relation, - ); + return ConstraintSet::constrain_typevar(db, bound_typevar, self, Type::object()); } } @@ -2975,17 +3021,16 @@ impl<'db> Type<'db> { self_newtype.has_relation_to_impl(db, target_newtype) } - ( - Type::NewTypeInstance(self_newtype), - Type::NominalInstance(target_nominal_instance), - ) => self_newtype.base_class_type(db).has_relation_to_impl( - db, - target_nominal_instance.class(db), - inferable, - relation, - relation_visitor, - disjointness_visitor, - ), + (Type::NewTypeInstance(self_newtype), _) => { + self_newtype.concrete_base_type(db).has_relation_to_impl( + db, + target, + inferable, + relation, + relation_visitor, + disjointness_visitor, + ) + } (Type::PropertyInstance(_), _) => { KnownClass::Property.to_instance(db).has_relation_to_impl( @@ -3006,10 +3051,9 @@ impl<'db> Type<'db> { disjointness_visitor, ), - // Other than the special cases enumerated above, nominal-instance types, and - // newtype-instance types are never subtypes of any other variants + // Other than the special cases enumerated above, nominal-instance types are never + // subtypes of any other variants (Type::NominalInstance(_), _) => ConstraintSet::from(false), - (Type::NewTypeInstance(_), _) => ConstraintSet::from(false), } } @@ -3938,7 +3982,7 @@ impl<'db> Type<'db> { left.is_disjoint_from_impl(db, right) } (Type::NewTypeInstance(newtype), other) | (other, Type::NewTypeInstance(newtype)) => { - Type::instance(db, newtype.base_class_type(db)).is_disjoint_from_impl( + newtype.concrete_base_type(db).is_disjoint_from_impl( db, other, inferable, @@ -4169,9 +4213,7 @@ impl<'db> Type<'db> { Type::TypeIs(type_is) => type_is.is_bound(db), Type::TypedDict(_) => false, Type::TypeAlias(alias) => alias.value_type(db).is_singleton(db), - Type::NewTypeInstance(newtype) => { - Type::instance(db, newtype.base_class_type(db)).is_singleton(db) - } + Type::NewTypeInstance(newtype) => newtype.concrete_base_type(db).is_singleton(db), } } @@ -4222,9 +4264,7 @@ impl<'db> Type<'db> { } Type::NominalInstance(instance) => instance.is_single_valued(db), - Type::NewTypeInstance(newtype) => { - Type::instance(db, newtype.base_class_type(db)).is_single_valued(db) - } + Type::NewTypeInstance(newtype) => newtype.concrete_base_type(db).is_single_valued(db), Type::BoundSuper(_) => { // At runtime two super instances never compare equal, even if their arguments are identical. @@ -4476,7 +4516,9 @@ impl<'db> Type<'db> { Type::Dynamic(_) | Type::Never => Place::bound(self).into(), Type::NominalInstance(instance) => instance.class(db).instance_member(db, name), - Type::NewTypeInstance(newtype) => newtype.base_class_type(db).instance_member(db, name), + Type::NewTypeInstance(newtype) => { + newtype.concrete_base_type(db).instance_member(db, name) + } Type::ProtocolInstance(protocol) => protocol.instance_member(db, name), @@ -5592,8 +5634,11 @@ impl<'db> Type<'db> { .value_type(db) .try_bool_impl(db, allow_short_circuit, visitor) })?, - Type::NewTypeInstance(newtype) => Type::instance(db, newtype.base_class_type(db)) - .try_bool_impl(db, allow_short_circuit, visitor)?, + Type::NewTypeInstance(newtype) => { + newtype + .concrete_base_type(db) + .try_bool_impl(db, allow_short_circuit, visitor)? + } }; Ok(truthiness) @@ -6561,7 +6606,7 @@ impl<'db> Type<'db> { match ty { Type::NominalInstance(nominal) => nominal.tuple_spec(db), - Type::NewTypeInstance(newtype) => non_async_special_case(db, Type::instance(db, newtype.base_class_type(db))), + Type::NewTypeInstance(newtype) => non_async_special_case(db, newtype.concrete_base_type(db)), Type::GenericAlias(alias) if alias.origin(db).is_tuple(db) => { Some(Cow::Owned(TupleSpec::homogeneous(todo_type!( "*tuple[] annotations" @@ -7293,29 +7338,12 @@ impl<'db> Type<'db> { // https://typing.python.org/en/latest/spec/special-types.html#special-cases-for-float-and-complex Type::ClassLiteral(class) => { let ty = match class.known(db) { - Some(KnownClass::Complex) => UnionType::from_elements( - db, - [ - KnownClass::Int.to_instance(db), - KnownClass::Float.to_instance(db), - KnownClass::Complex.to_instance(db), - ], - ), - Some(KnownClass::Float) => UnionType::from_elements( - db, - [ - KnownClass::Int.to_instance(db), - KnownClass::Float.to_instance(db), - ], - ), - _ if class.is_typed_dict(db) => { - Type::typed_dict(class.default_specialization(db)) - } + Some(KnownClass::Complex) => KnownUnion::Complex.to_type(db), + Some(KnownClass::Float) => KnownUnion::Float.to_type(db), _ => Type::instance(db, class.default_specialization(db)), }; Ok(ty) } - Type::GenericAlias(alias) if alias.is_typed_dict(db) => Ok(Type::typed_dict(*alias)), Type::GenericAlias(alias) => Ok(Type::instance(db, ClassType::from(*alias))), Type::SubclassOf(_) @@ -7674,7 +7702,7 @@ impl<'db> Type<'db> { ), }, Type::TypeAlias(alias) => alias.value_type(db).to_meta_type(db), - Type::NewTypeInstance(newtype) => Type::from(newtype.base_class_type(db)), + Type::NewTypeInstance(newtype) => newtype.concrete_base_type(db).to_meta_type(db), } } @@ -8023,7 +8051,7 @@ impl<'db> Type<'db> { ) { let matching_typevar = |bound_typevar: &BoundTypeVarInstance<'db>| { match bound_typevar.typevar(db).kind(db) { - TypeVarKind::Legacy | TypeVarKind::TypingSelf + TypeVarKind::Legacy | TypeVarKind::Pep613Alias | TypeVarKind::TypingSelf if binding_context.is_none_or(|binding_context| { bound_typevar.binding_context(db) == BindingContext::Definition(binding_context) @@ -8343,6 +8371,7 @@ impl<'db> Type<'db> { KnownInstanceType::TypeAliasType(type_alias) => { type_alias.definition(db).map(TypeDefinition::TypeAlias) } + KnownInstanceType::NewType(newtype) => Some(TypeDefinition::NewType(newtype.definition(db))), _ => None, }, @@ -8880,9 +8909,7 @@ fn walk_known_instance_type<'db, V: visitor::TypeVisitor<'db> + ?Sized>( visitor.visit_callable_type(db, callable); } KnownInstanceType::NewType(newtype) => { - if let ClassType::Generic(generic_alias) = newtype.base_class_type(db) { - visitor.visit_generic_alias_type(db, generic_alias); - } + visitor.visit_type(db, newtype.concrete_base_type(db)); } } } @@ -9502,6 +9529,8 @@ pub enum TypeVarKind { ParamSpec, /// `def foo[**P]() -> None: ...` Pep695ParamSpec, + /// `Alias: typing.TypeAlias = T` + Pep613Alias, } impl TypeVarKind { @@ -14032,6 +14061,61 @@ impl<'db> UnionType<'db> { ConstraintSet::from(sorted_self == other.normalized(db)) } + + /// Identify some specific unions of known classes, currently the ones that `float` and + /// `complex` expand into in type position. + pub(crate) fn known(self, db: &'db dyn Db) -> Option { + let mut has_int = false; + let mut has_float = false; + let mut has_complex = false; + for element in self.elements(db) { + if let Type::NominalInstance(nominal) = element + && let Some(known) = nominal.known_class(db) + { + match known { + KnownClass::Int => has_int = true, + KnownClass::Float => has_float = true, + KnownClass::Complex => has_complex = true, + _ => return None, + } + } else { + return None; + } + } + match (has_int, has_float, has_complex) { + (true, true, false) => Some(KnownUnion::Float), + (true, true, true) => Some(KnownUnion::Complex), + _ => None, + } + } +} + +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +pub(crate) enum KnownUnion { + Float, // `int | float` + Complex, // `int | float | complex` +} + +impl KnownUnion { + pub(crate) fn to_type(self, db: &dyn Db) -> Type<'_> { + match self { + KnownUnion::Float => UnionType::from_elements( + db, + [ + KnownClass::Int.to_instance(db), + KnownClass::Float.to_instance(db), + ], + ), + KnownUnion::Complex => UnionType::from_elements( + db, + [ + KnownClass::Int.to_instance(db), + KnownClass::Float.to_instance(db), + KnownClass::Complex.to_instance(db), + ], + ), + } + } } #[salsa::interned(debug, heap_size=IntersectionType::heap_size)] diff --git a/crates/ty_python_semantic/src/types/bound_super.rs b/crates/ty_python_semantic/src/types/bound_super.rs index 442ae0d0b9..cea3bc3e54 100644 --- a/crates/ty_python_semantic/src/types/bound_super.rs +++ b/crates/ty_python_semantic/src/types/bound_super.rs @@ -429,7 +429,7 @@ impl<'db> BoundSuperType<'db> { ); } Type::NewTypeInstance(newtype) => { - return delegate_to(Type::instance(db, newtype.base_class_type(db))); + return delegate_to(newtype.concrete_base_type(db)); } Type::Callable(callable) if callable.is_function_like(db) => { return delegate_to(KnownClass::FunctionType.to_instance(db)); diff --git a/crates/ty_python_semantic/src/types/builder.rs b/crates/ty_python_semantic/src/types/builder.rs index 36977078e9..ae2c21759b 100644 --- a/crates/ty_python_semantic/src/types/builder.rs +++ b/crates/ty_python_semantic/src/types/builder.rs @@ -668,6 +668,7 @@ pub(crate) struct IntersectionBuilder<'db> { // but if a union is added to the intersection, we'll distribute ourselves over that union and // create a union of intersections. intersections: Vec>, + order_elements: bool, db: &'db dyn Db, } @@ -675,6 +676,7 @@ impl<'db> IntersectionBuilder<'db> { pub(crate) fn new(db: &'db dyn Db) -> Self { Self { db, + order_elements: false, intersections: vec![InnerIntersectionBuilder::default()], } } @@ -682,14 +684,25 @@ impl<'db> IntersectionBuilder<'db> { fn empty(db: &'db dyn Db) -> Self { Self { db, + order_elements: false, intersections: vec![], } } + pub(crate) fn order_elements(mut self, val: bool) -> Self { + self.order_elements = val; + self + } + pub(crate) fn add_positive(self, ty: Type<'db>) -> Self { self.add_positive_impl(ty, &mut vec![]) } + pub(crate) fn add_positive_in_place(&mut self, ty: Type<'db>) { + let updated = std::mem::replace(self, Self::empty(self.db)).add_positive(ty); + *self = updated; + } + pub(crate) fn add_positive_impl( mut self, ty: Type<'db>, @@ -898,13 +911,16 @@ impl<'db> IntersectionBuilder<'db> { pub(crate) fn build(mut self) -> Type<'db> { // Avoid allocating the UnionBuilder unnecessarily if we have just one intersection: if self.intersections.len() == 1 { - self.intersections.pop().unwrap().build(self.db) + self.intersections + .pop() + .unwrap() + .build(self.db, self.order_elements) } else { UnionType::from_elements( self.db, self.intersections .into_iter() - .map(|inner| inner.build(self.db)), + .map(|inner| inner.build(self.db, self.order_elements)), ) } } @@ -1238,7 +1254,7 @@ impl<'db> InnerIntersectionBuilder<'db> { } } - fn build(mut self, db: &'db dyn Db) -> Type<'db> { + fn build(mut self, db: &'db dyn Db, order_elements: bool) -> Type<'db> { self.simplify_constrained_typevars(db); // If any typevars are in `self.positive`, speculatively solve all bounded type variables @@ -1279,6 +1295,12 @@ impl<'db> InnerIntersectionBuilder<'db> { _ => { self.positive.shrink_to_fit(); self.negative.shrink_to_fit(); + if order_elements { + self.positive + .sort_unstable_by(|l, r| union_or_intersection_elements_ordering(db, l, r)); + self.negative + .sort_unstable_by(|l, r| union_or_intersection_elements_ordering(db, l, r)); + } Type::Intersection(IntersectionType::new(db, self.positive, self.negative)) } } diff --git a/crates/ty_python_semantic/src/types/class_base.rs b/crates/ty_python_semantic/src/types/class_base.rs index c5ce573d3b..26b490fa3b 100644 --- a/crates/ty_python_semantic/src/types/class_base.rs +++ b/crates/ty_python_semantic/src/types/class_base.rs @@ -152,11 +152,9 @@ impl<'db> ClassBase<'db> { Type::TypeAlias(alias) => Self::try_from_type(db, alias.value_type(db), subclass), - Type::NewTypeInstance(newtype) => ClassBase::try_from_type( - db, - Type::instance(db, newtype.base_class_type(db)), - subclass, - ), + Type::NewTypeInstance(newtype) => { + ClassBase::try_from_type(db, newtype.concrete_base_type(db), subclass) + } Type::PropertyInstance(_) | Type::BooleanLiteral(_) diff --git a/crates/ty_python_semantic/src/types/constraints.rs b/crates/ty_python_semantic/src/types/constraints.rs index 4c9a55f6ed..364f8e5163 100644 --- a/crates/ty_python_semantic/src/types/constraints.rs +++ b/crates/ty_python_semantic/src/types/constraints.rs @@ -80,8 +80,8 @@ use crate::types::visitor::{ TypeCollector, TypeVisitor, any_over_type, walk_type_with_recursion_guard, }; use crate::types::{ - BoundTypeVarIdentity, BoundTypeVarInstance, IntersectionType, Type, TypeRelation, - TypeVarBoundOrConstraints, UnionType, walk_bound_type_var_type, + BoundTypeVarIdentity, BoundTypeVarInstance, IntersectionBuilder, IntersectionType, Type, + TypeVarBoundOrConstraints, UnionBuilder, UnionType, walk_bound_type_var_type, }; use crate::{Db, FxOrderSet}; @@ -200,21 +200,7 @@ impl<'db> ConstraintSet<'db> { typevar: BoundTypeVarInstance<'db>, lower: Type<'db>, upper: Type<'db>, - relation: TypeRelation<'db>, ) -> Self { - let (lower, upper) = match relation { - TypeRelation::Subtyping - | TypeRelation::Redundancy - | TypeRelation::SubtypingAssuming(_) => ( - lower.top_materialization(db), - upper.bottom_materialization(db), - ), - TypeRelation::Assignability | TypeRelation::ConstraintSetAssignability => ( - lower.bottom_materialization(db), - upper.top_materialization(db), - ), - }; - Self { node: ConstrainedTypeVar::new_node(db, typevar, lower, upper), } @@ -446,7 +432,7 @@ impl<'db> ConstraintSet<'db> { typevar: BoundTypeVarInstance<'db>, upper: Type<'db>, ) -> Self { - Self::constrain_typevar(db, typevar, lower, upper, TypeRelation::Assignability) + Self::constrain_typevar(db, typevar, lower, upper) } #[expect(dead_code)] // Keep this around for debugging purposes @@ -517,9 +503,6 @@ impl<'db> ConstrainedTypeVar<'db> { mut lower: Type<'db>, mut upper: Type<'db>, ) -> Node<'db> { - debug_assert_eq!(lower, lower.bottom_materialization(db)); - debug_assert_eq!(upper, upper.top_materialization(db)); - // It's not useful for an upper bound to be an intersection type, or for a lower bound to // be a union type. Because the following equivalences hold, we can break these bounds // apart and create an equivalent BDD with more nodes but simpler constraints. (Fewer, @@ -3508,8 +3491,8 @@ impl<'db> GenericContext<'db> { // do with that, so instead we just report the ambiguity as a specialization failure. let mut satisfied = false; let mut unconstrained = false; - let mut greatest_lower_bound = Type::Never; - let mut least_upper_bound = Type::object(); + let mut greatest_lower_bound = UnionBuilder::new(db).order_elements(true); + let mut least_upper_bound = IntersectionBuilder::new(db).order_elements(true); let identity = bound_typevar.identity(db); tracing::trace!( target: "ty_python_semantic::types::constraints::specialize_constrained", @@ -3528,10 +3511,8 @@ impl<'db> GenericContext<'db> { upper_bound = %upper_bound.display(db), "found representative type", ); - greatest_lower_bound = - UnionType::from_elements(db, [greatest_lower_bound, lower_bound]); - least_upper_bound = - IntersectionType::from_elements(db, [least_upper_bound, upper_bound]); + greatest_lower_bound.add_in_place(lower_bound); + least_upper_bound.add_positive_in_place(upper_bound); } None => { unconstrained = true; @@ -3565,6 +3546,8 @@ impl<'db> GenericContext<'db> { // If `lower ≰ upper`, then there is no type that satisfies all of the paths in the // BDD. That's an ambiguous specialization, as described above. + let greatest_lower_bound = greatest_lower_bound.build(); + let least_upper_bound = least_upper_bound.build(); if !greatest_lower_bound.is_constraint_set_assignable_to(db, least_upper_bound) { tracing::debug!( target: "ty_python_semantic::types::constraints::specialize_constrained", diff --git a/crates/ty_python_semantic/src/types/diagnostic.rs b/crates/ty_python_semantic/src/types/diagnostic.rs index 23bb5b1a16..dcc2f6b3c5 100644 --- a/crates/ty_python_semantic/src/types/diagnostic.rs +++ b/crates/ty_python_semantic/src/types/diagnostic.rs @@ -40,7 +40,7 @@ use ruff_db::{ use ruff_diagnostics::{Edit, Fix}; use ruff_python_ast::name::Name; use ruff_python_ast::token::parentheses_iterator; -use ruff_python_ast::{self as ast, AnyNodeRef, StringFlags}; +use ruff_python_ast::{self as ast, AnyNodeRef, PythonVersion, StringFlags}; use ruff_text_size::{Ranged, TextRange}; use rustc_hash::FxHashSet; use std::fmt::{self, Formatter}; @@ -4155,6 +4155,120 @@ pub(super) fn report_unsupported_comparison<'db>( } } +pub(super) fn report_unsupported_augmented_assignment<'db>( + context: &InferContext<'db, '_>, + stmt: &ast::StmtAugAssign, + left_ty: Type<'db>, + right_ty: Type<'db>, +) { + report_unsupported_binary_operation_impl( + context, + stmt.range(), + &stmt.target, + &stmt.value, + left_ty, + right_ty, + OperatorDisplay { + operator: stmt.op, + is_augmented_assignment: true, + }, + ); +} + +pub(super) fn report_unsupported_binary_operation<'db>( + context: &InferContext<'db, '_>, + binary_expression: &ast::ExprBinOp, + left_ty: Type<'db>, + right_ty: Type<'db>, + operator: ast::Operator, +) { + let Some(mut diagnostic) = report_unsupported_binary_operation_impl( + context, + binary_expression.range(), + &binary_expression.left, + &binary_expression.right, + left_ty, + right_ty, + OperatorDisplay { + operator, + is_augmented_assignment: false, + }, + ) else { + return; + }; + let db = context.db(); + if operator == ast::Operator::BitOr + && (left_ty.is_subtype_of(db, KnownClass::Type.to_instance(db)) + || right_ty.is_subtype_of(db, KnownClass::Type.to_instance(db))) + && Program::get(db).python_version(db) < PythonVersion::PY310 + { + diagnostic.info( + "Note that `X | Y` PEP 604 union syntax is only available in Python 3.10 and later", + ); + add_inferred_python_version_hint_to_diagnostic(db, &mut diagnostic, "resolving types"); + } +} + +#[derive(Debug, Copy, Clone)] +struct OperatorDisplay { + operator: ast::Operator, + is_augmented_assignment: bool, +} + +impl std::fmt::Display for OperatorDisplay { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + if self.is_augmented_assignment { + write!(f, "{}=", self.operator) + } else { + write!(f, "{}", self.operator) + } + } +} + +fn report_unsupported_binary_operation_impl<'a>( + context: &'a InferContext<'a, 'a>, + range: TextRange, + left: &ast::Expr, + right: &ast::Expr, + left_ty: Type<'a>, + right_ty: Type<'a>, + operator: OperatorDisplay, +) -> Option> { + let db = context.db(); + let diagnostic_builder = context.report_lint(&UNSUPPORTED_OPERATOR, range)?; + let display_settings = DisplaySettings::from_possibly_ambiguous_types(db, [left_ty, right_ty]); + + let mut diagnostic = + diagnostic_builder.into_diagnostic(format_args!("Unsupported `{operator}` operation")); + + if left_ty == right_ty { + diagnostic.set_primary_message(format_args!( + "Both operands have type `{}`", + left_ty.display_with(db, display_settings.clone()) + )); + diagnostic.annotate(context.secondary(left)); + diagnostic.annotate(context.secondary(right)); + diagnostic.set_concise_message(format_args!( + "Operator `{operator}` is not supported between two objects of type `{}`", + left_ty.display_with(db, display_settings.clone()) + )); + } else { + for (ty, expr) in [(left_ty, left), (right_ty, right)] { + diagnostic.annotate(context.secondary(expr).message(format_args!( + "Has type `{}`", + ty.display_with(db, display_settings.clone()) + ))); + } + diagnostic.set_concise_message(format_args!( + "Operator `{operator}` is not supported between objects of type `{}` and `{}`", + left_ty.display_with(db, display_settings.clone()), + right_ty.display_with(db, display_settings.clone()) + )); + } + + Some(diagnostic) +} + /// This function receives an unresolved `from foo import bar` import, /// where `foo` can be resolved to a module but that module does not /// have a `bar` member or submodule. diff --git a/crates/ty_python_semantic/src/types/display.rs b/crates/ty_python_semantic/src/types/display.rs index 39e5a1caee..f6bee388f5 100644 --- a/crates/ty_python_semantic/src/types/display.rs +++ b/crates/ty_python_semantic/src/types/display.rs @@ -14,6 +14,7 @@ use ruff_text_size::{TextLen, TextRange, TextSize}; use rustc_hash::{FxHashMap, FxHashSet}; use crate::Db; +use crate::place::Place; use crate::types::class::{ClassLiteral, ClassType, GenericAlias}; use crate::types::function::{FunctionType, OverloadLiteral}; use crate::types::generics::{GenericContext, Specialization}; @@ -642,11 +643,13 @@ impl<'db> FmtDetailed<'db> for DisplayRepresentation<'db> { Type::PropertyInstance(_) => f.with_type(self.ty).write_str("property"), Type::ModuleLiteral(module) => { f.set_invalid_syntax(); - write!( - f.with_type(self.ty), - "", - module.module(self.db).name(self.db) - ) + f.write_char('<')?; + f.with_type(KnownClass::ModuleType.to_class_literal(self.db)) + .write_str("module")?; + f.write_str(" '")?; + f.with_type(self.ty) + .write_str(module.module(self.db).name(self.db))?; + f.write_str("'>") } Type::ClassLiteral(class) => { f.set_invalid_syntax(); @@ -692,11 +695,17 @@ impl<'db> FmtDetailed<'db> for DisplayRepresentation<'db> { write!(f.with_type(Type::Dynamic(dynamic)), "{dynamic}")?; f.write_char(']') } - SubclassOfInner::TypeVar(bound_typevar) => write!( - f, - "type[{}]", - bound_typevar.identity(self.db).display(self.db) - ), + SubclassOfInner::TypeVar(bound_typevar) => { + f.with_type(KnownClass::Type.to_class_literal(self.db)) + .write_str("type")?; + f.write_char('[')?; + write!( + f.with_type(Type::TypeVar(bound_typevar)), + "{}", + bound_typevar.identity(self.db).display(self.db) + )?; + f.write_char(']') + } }, Type::SpecialForm(special_form) => { f.set_invalid_syntax(); @@ -763,61 +772,115 @@ impl<'db> FmtDetailed<'db> for DisplayRepresentation<'db> { } Type::KnownBoundMethod(method_type) => { f.set_invalid_syntax(); - match method_type { - KnownBoundMethodType::FunctionTypeDunderGet(function) => { - write!( - f, - "", - function = function.name(self.db), - ) - } - KnownBoundMethodType::FunctionTypeDunderCall(function) => { - write!( - f, - "", - function = function.name(self.db), - ) - } - KnownBoundMethodType::PropertyDunderGet(_) => { - f.write_str("") - } - KnownBoundMethodType::PropertyDunderSet(_) => { - f.write_str("") - } - KnownBoundMethodType::StrStartswith(_) => { - f.write_str("") - } + let (cls, member_name, cls_name, ty, ty_name) = match method_type { + KnownBoundMethodType::FunctionTypeDunderGet(function) => ( + KnownClass::FunctionType, + "__get__", + "function", + Type::FunctionLiteral(function), + Some(&**function.name(self.db)), + ), + KnownBoundMethodType::FunctionTypeDunderCall(function) => ( + KnownClass::FunctionType, + "__call__", + "function", + Type::FunctionLiteral(function), + Some(&**function.name(self.db)), + ), + KnownBoundMethodType::PropertyDunderGet(property) => ( + KnownClass::Property, + "__get__", + "property", + Type::PropertyInstance(property), + property + .getter(self.db) + .and_then(Type::as_function_literal) + .map(|getter| &**getter.name(self.db)), + ), + KnownBoundMethodType::PropertyDunderSet(property) => ( + KnownClass::Property, + "__set__", + "property", + Type::PropertyInstance(property), + property + .getter(self.db) + .and_then(Type::as_function_literal) + .map(|getter| &**getter.name(self.db)), + ), + KnownBoundMethodType::StrStartswith(literal) => ( + KnownClass::Property, + "startswith", + "string", + Type::StringLiteral(literal), + Some(literal.value(self.db)), + ), KnownBoundMethodType::ConstraintSetRange => { - f.write_str("bound method `ConstraintSet.range`") + return f.write_str("bound method `ConstraintSet.range`"); } KnownBoundMethodType::ConstraintSetAlways => { - f.write_str("bound method `ConstraintSet.always`") + return f.write_str("bound method `ConstraintSet.always`"); } KnownBoundMethodType::ConstraintSetNever => { - f.write_str("bound method `ConstraintSet.never`") + return f.write_str("bound method `ConstraintSet.never`"); } KnownBoundMethodType::ConstraintSetImpliesSubtypeOf(_) => { - f.write_str("bound method `ConstraintSet.implies_subtype_of`") + return f.write_str("bound method `ConstraintSet.implies_subtype_of`"); } KnownBoundMethodType::ConstraintSetSatisfies(_) => { - f.write_str("bound method `ConstraintSet.satisfies`") + return f.write_str("bound method `ConstraintSet.satisfies`"); } KnownBoundMethodType::ConstraintSetSatisfiedByAllTypeVars(_) => { - f.write_str("bound method `ConstraintSet.satisfied_by_all_typevars`") + return f + .write_str("bound method `ConstraintSet.satisfied_by_all_typevars`"); } KnownBoundMethodType::GenericContextSpecializeConstrained(_) => { - f.write_str("bound method `GenericContext.specialize_constrained`") + return f.write_str("bound method `GenericContext.specialize_constrained`"); } + }; + + let class_ty = cls.to_class_literal(self.db); + f.write_char('<')?; + f.with_type(KnownClass::MethodWrapperType.to_class_literal(self.db)) + .write_str("method-wrapper")?; + f.write_str(" '")?; + if let Place::Defined(member_ty, _, _) = class_ty.member(self.db, member_name).place + { + f.with_type(member_ty).write_str(member_name)?; + } else { + f.write_str(member_name)?; + } + f.write_str("' of ")?; + f.with_type(class_ty).write_str(cls_name)?; + if let Some(name) = ty_name { + f.write_str(" '")?; + f.with_type(ty).write_str(name)?; + f.write_str("'>") + } else { + f.write_str("' object>") } } Type::WrapperDescriptor(kind) => { f.set_invalid_syntax(); - let (method, object) = match kind { - WrapperDescriptorKind::FunctionTypeDunderGet => ("__get__", "function"), - WrapperDescriptorKind::PropertyDunderGet => ("__get__", "property"), - WrapperDescriptorKind::PropertyDunderSet => ("__set__", "property"), + let (method, object, cls) = match kind { + WrapperDescriptorKind::FunctionTypeDunderGet => { + ("__get__", "function", KnownClass::FunctionType) + } + WrapperDescriptorKind::PropertyDunderGet => { + ("__get__", "property", KnownClass::Property) + } + WrapperDescriptorKind::PropertyDunderSet => { + ("__set__", "property", KnownClass::Property) + } }; - write!(f, "") + f.write_char('<')?; + f.with_type(KnownClass::WrapperDescriptorType.to_class_literal(self.db)) + .write_str("wrapper-descriptor")?; + f.write_str(" '")?; + f.write_str(method)?; + f.write_str("' of '")?; + f.with_type(cls.to_class_literal(self.db)) + .write_str(object)?; + f.write_str("' objects>") } Type::DataclassDecorator(_) => { f.set_invalid_syntax(); @@ -907,7 +970,10 @@ impl<'db> FmtDetailed<'db> for DisplayRepresentation<'db> { .fmt_detailed(f), Type::TypedDict(TypedDictType::Synthesized(synthesized)) => { f.set_invalid_syntax(); - f.write_str(" DisplayGenericContext<'_, 'db> { f.set_invalid_syntax(); let typevar = bound_typevar.typevar(self.db); if typevar.is_paramspec(self.db) { - write!(f, "**{}", typevar.name(self.db))?; - } else { - f.write_str(typevar.name(self.db))?; + f.write_str("**")?; } + write!( + f.with_type(Type::TypeVar(*bound_typevar)), + "{}", + typevar.name(self.db) + )?; } f.write_char(']') } @@ -1334,7 +1403,11 @@ impl<'db> DisplayGenericContext<'_, 'db> { f.write_str(", ")?; } f.set_invalid_syntax(); - write!(f, "{}", bound_typevar.identity(self.db).display(self.db))?; + write!( + f.with_type(Type::TypeVar(bound_typevar)), + "{}", + bound_typevar.identity(self.db).display(self.db) + )?; } f.write_char(']') } @@ -2262,15 +2335,17 @@ impl<'db> FmtDetailed<'db> for DisplayKnownInstanceRepr<'db> { KnownInstanceType::SubscriptedProtocol(generic_context) => { f.set_invalid_syntax(); f.write_str("") } KnownInstanceType::SubscriptedGeneric(generic_context) => { f.set_invalid_syntax(); f.write_str("") } KnownInstanceType::TypeAliasType(alias) => { @@ -2278,15 +2353,9 @@ impl<'db> FmtDetailed<'db> for DisplayKnownInstanceRepr<'db> { f.set_invalid_syntax(); f.write_str("") } else { f.with_type(ty).write_str("typing.TypeAliasType") @@ -2306,7 +2375,9 @@ impl<'db> FmtDetailed<'db> for DisplayKnownInstanceRepr<'db> { KnownInstanceType::Field(field) => { f.with_type(ty).write_str("dataclasses.Field")?; if let Some(default_ty) = field.default_type(self.db) { - write!(f, "[{}]", default_ty.display(self.db))?; + f.write_char('[')?; + write!(f.with_type(default_ty), "{}", default_ty.display(self.db))?; + f.write_char(']')?; } Ok(()) } @@ -2325,51 +2396,58 @@ impl<'db> FmtDetailed<'db> for DisplayKnownInstanceRepr<'db> { KnownInstanceType::UnionType(union) => { f.set_invalid_syntax(); f.write_char('<')?; - f.with_type(ty).write_str("types.UnionType")?; + f.with_type(KnownClass::UnionType.to_class_literal(self.db)) + .write_str("types.UnionType")?; f.write_str(" special form")?; if let Ok(ty) = union.union_type(self.db) { - write!(f, " '{}'", ty.display(self.db))?; + f.write_str(" '")?; + ty.display(self.db).fmt_detailed(f)?; + f.write_char('\'')?; } f.write_char('>') } KnownInstanceType::Literal(inner) => { f.set_invalid_syntax(); - write!( - f, - "", - inner.inner(self.db).display(self.db) - ) + f.write_str("") } KnownInstanceType::Annotated(inner) => { f.set_invalid_syntax(); f.write_str("]'>", - inner.inner(self.db).display(self.db) - ) + f.with_type(Type::SpecialForm(SpecialFormType::Annotated)) + .write_str("typing.Annotated")?; + f.write_char('[')?; + inner.inner(self.db).display(self.db).fmt_detailed(f)?; + f.write_str(", ]'>") } KnownInstanceType::Callable(callable) => { f.set_invalid_syntax(); f.write_char('<')?; - f.with_type(ty).write_str("typing.Callable")?; - write!(f, " special form '{}'>", callable.display(self.db)) + f.with_type(Type::SpecialForm(SpecialFormType::Callable)) + .write_str("typing.Callable")?; + f.write_str(" special form '")?; + callable.display(self.db).fmt_detailed(f)?; + f.write_str("'>") } KnownInstanceType::TypeGenericAlias(inner) => { f.set_invalid_syntax(); f.write_str("") + f.with_type(KnownClass::Type.to_class_literal(self.db)) + .write_str("type")?; + f.write_char('[')?; + inner.inner(self.db).display(self.db).fmt_detailed(f)?; + f.write_str("]'>") } - KnownInstanceType::LiteralStringAlias(_) => f.write_str("str"), + KnownInstanceType::LiteralStringAlias(_) => f + .with_type(KnownClass::Str.to_class_literal(self.db)) + .write_str("str"), KnownInstanceType::NewType(declaration) => { f.set_invalid_syntax(); - f.write_str("") } diff --git a/crates/ty_python_semantic/src/types/function.rs b/crates/ty_python_semantic/src/types/function.rs index 6b61316a69..e727e6663b 100644 --- a/crates/ty_python_semantic/src/types/function.rs +++ b/crates/ty_python_semantic/src/types/function.rs @@ -1247,10 +1247,9 @@ fn is_instance_truthiness<'db>( Type::NominalInstance(..) => always_true_if(is_instance(&ty)), - Type::NewTypeInstance(newtype) => always_true_if(is_instance(&Type::instance( - db, - newtype.base_class_type(db), - ))), + Type::NewTypeInstance(newtype) => { + always_true_if(is_instance(&newtype.concrete_base_type(db))) + } Type::BooleanLiteral(..) | Type::BytesLiteral(..) diff --git a/crates/ty_python_semantic/src/types/ide_support.rs b/crates/ty_python_semantic/src/types/ide_support.rs index 4087d125c6..8de1d00d28 100644 --- a/crates/ty_python_semantic/src/types/ide_support.rs +++ b/crates/ty_python_semantic/src/types/ide_support.rs @@ -7,8 +7,9 @@ use crate::semantic_index::definition::DefinitionKind; use crate::semantic_index::{attribute_scopes, global_scope, semantic_index, use_def_map}; use crate::types::call::{CallArguments, MatchedArgument}; use crate::types::signatures::{ParameterKind, Signature}; -use crate::types::{CallDunderError, UnionType}; -use crate::types::{CallableTypes, ClassBase, KnownClass, Type, TypeContext}; +use crate::types::{ + CallDunderError, CallableTypes, ClassBase, KnownUnion, Type, TypeContext, UnionType, +}; use crate::{Db, DisplaySettings, HasType, SemanticModel}; use ruff_db::files::FileRange; use ruff_db::parsed::parsed_module; @@ -193,21 +194,8 @@ pub fn definitions_for_name<'db>( fn is_float_or_complex_annotation(db: &dyn Db, ty: UnionType, name: &str) -> bool { let float_or_complex_ty = match name { - "float" => UnionType::from_elements( - db, - [ - KnownClass::Int.to_instance(db), - KnownClass::Float.to_instance(db), - ], - ), - "complex" => UnionType::from_elements( - db, - [ - KnownClass::Int.to_instance(db), - KnownClass::Float.to_instance(db), - KnownClass::Complex.to_instance(db), - ], - ), + "float" => KnownUnion::Float.to_type(db), + "complex" => KnownUnion::Complex.to_type(db), _ => return false, } .expect_union(); diff --git a/crates/ty_python_semantic/src/types/infer/builder.rs b/crates/ty_python_semantic/src/types/infer/builder.rs index 00141d4ca8..1b78a02c32 100644 --- a/crates/ty_python_semantic/src/types/infer/builder.rs +++ b/crates/ty_python_semantic/src/types/infer/builder.rs @@ -80,7 +80,8 @@ use crate::types::diagnostic::{ report_invalid_type_checking_constant, report_named_tuple_field_with_leading_underscore, report_namedtuple_field_without_default_after_field_with_default, report_non_subscriptable, report_possibly_missing_attribute, report_possibly_unresolved_reference, - report_rebound_typevar, report_slice_step_size_zero, report_unsupported_comparison, + report_rebound_typevar, report_slice_step_size_zero, report_unsupported_augmented_assignment, + report_unsupported_binary_operation, report_unsupported_comparison, }; use crate::types::function::{ FunctionDecorators, FunctionLiteral, FunctionType, KnownFunction, OverloadLiteral, @@ -104,13 +105,13 @@ use crate::types::visitor::any_over_type; use crate::types::{ BoundTypeVarInstance, CallDunderError, CallableBinding, CallableType, CallableTypeKind, ClassLiteral, ClassType, DataclassParams, DynamicType, InternedType, IntersectionBuilder, - IntersectionType, KnownClass, KnownInstanceType, LintDiagnosticGuard, MemberLookupPolicy, - MetaclassCandidate, PEP695TypeAliasType, ParamSpecAttrKind, Parameter, ParameterForm, - Parameters, Signature, SpecialFormType, SubclassOfType, TrackedConstraintSet, Truthiness, Type, - TypeAliasType, TypeAndQualifiers, TypeContext, TypeQualifiers, TypeVarBoundOrConstraints, - TypeVarBoundOrConstraintsEvaluation, TypeVarDefaultEvaluation, TypeVarIdentity, - TypeVarInstance, TypeVarKind, TypeVarVariance, TypedDictType, UnionBuilder, UnionType, - UnionTypeInstance, binding_type, infer_scope_types, todo_type, + IntersectionType, KnownClass, KnownInstanceType, KnownUnion, LintDiagnosticGuard, + MemberLookupPolicy, MetaclassCandidate, PEP695TypeAliasType, ParamSpecAttrKind, Parameter, + ParameterForm, Parameters, Signature, SpecialFormType, SubclassOfType, TrackedConstraintSet, + Truthiness, Type, TypeAliasType, TypeAndQualifiers, TypeContext, TypeQualifiers, + TypeVarBoundOrConstraints, TypeVarBoundOrConstraintsEvaluation, TypeVarDefaultEvaluation, + TypeVarIdentity, TypeVarInstance, TypeVarKind, TypeVarVariance, TypedDictType, UnionBuilder, + UnionType, UnionTypeInstance, binding_type, infer_scope_types, todo_type, }; use crate::types::{CallableTypes, overrides}; use crate::types::{ClassBase, add_inferred_python_version_hint_to_diagnostic}; @@ -3541,10 +3542,17 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { return Ok(param_type); } - Type::KnownInstance(known_instance) + Type::KnownInstance(known_instance @ KnownInstanceType::TypeVar(typevar)) if known_instance.class(self.db()) == KnownClass::ParamSpec => { - // TODO: Emit diagnostic: "ParamSpec "P" is unbound" + if let Some(diagnostic_builder) = + self.context.report_lint(&INVALID_TYPE_ARGUMENTS, expr) + { + diagnostic_builder.into_diagnostic(format_args!( + "ParamSpec `{}` is unbound", + typevar.name(self.db()) + )); + } return Err(()); } @@ -5629,28 +5637,35 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { // Infer the deferred base type of a NewType. fn infer_newtype_assignment_deferred(&mut self, arguments: &ast::Arguments) { - match self.infer_type_expression(&arguments.args[1]) { - Type::NominalInstance(_) | Type::NewTypeInstance(_) => {} + let inferred = self.infer_type_expression(&arguments.args[1]); + match inferred { + Type::NominalInstance(_) | Type::NewTypeInstance(_) => return, + // There are exactly two union types allowed as bases for NewType: `int | float` and + // `int | float | complex`. These are allowed because that's what `float` and `complex` + // expand into in type position. We don't currently ask whether the union was implicit + // or explicit, so the explicit version is also allowed. + Type::Union(union_ty) => { + if let Some(KnownUnion::Float | KnownUnion::Complex) = union_ty.known(self.db()) { + return; + } + } // `Unknown` is likely to be the result of an unresolved import or a typo, which will // already get a diagnostic, so don't pile on an extra diagnostic here. - Type::Dynamic(DynamicType::Unknown) => {} - other_type => { - if let Some(builder) = self - .context - .report_lint(&INVALID_NEWTYPE, &arguments.args[1]) - { - let mut diag = builder.into_diagnostic("invalid base for `typing.NewType`"); - diag.set_primary_message(format!("type `{}`", other_type.display(self.db()))); - if matches!(other_type, Type::ProtocolInstance(_)) { - diag.info("The base of a `NewType` is not allowed to be a protocol class."); - } else if matches!(other_type, Type::TypedDict(_)) { - diag.info("The base of a `NewType` is not allowed to be a `TypedDict`."); - } else { - diag.info( - "The base of a `NewType` must be a class type or another `NewType`.", - ); - } - } + Type::Dynamic(DynamicType::Unknown) => return, + _ => {} + } + if let Some(builder) = self + .context + .report_lint(&INVALID_NEWTYPE, &arguments.args[1]) + { + let mut diag = builder.into_diagnostic("invalid base for `typing.NewType`"); + diag.set_primary_message(format!("type `{}`", inferred.display(self.db()))); + if matches!(inferred, Type::ProtocolInstance(_)) { + diag.info("The base of a `NewType` is not allowed to be a protocol class."); + } else if matches!(inferred, Type::TypedDict(_)) { + diag.info("The base of a `NewType` is not allowed to be a `TypedDict`."); + } else { + diag.info("The base of a `NewType` must be a class type or another `NewType`."); } } } @@ -5851,6 +5866,24 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { }; if is_pep_613_type_alias { + let inferred_ty = + if let Type::KnownInstance(KnownInstanceType::TypeVar(typevar)) = inferred_ty { + let identity = TypeVarIdentity::new( + self.db(), + typevar.identity(self.db()).name(self.db()), + typevar.identity(self.db()).definition(self.db()), + TypeVarKind::Pep613Alias, + ); + Type::KnownInstance(KnownInstanceType::TypeVar(TypeVarInstance::new( + self.db(), + identity, + typevar._bound_or_constraints(self.db()), + typevar.explicit_variance(self.db()), + typevar._default(self.db()), + ))) + } else { + inferred_ty + }; self.add_declaration_with_binding( target.into(), definition, @@ -5911,22 +5944,16 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { let op = assignment.op; let db = self.db(); - let report_unsupported_augmented_op = |ctx: &mut InferContext| { - let Some(builder) = ctx.report_lint(&UNSUPPORTED_OPERATOR, assignment) else { - return; - }; - builder.into_diagnostic(format_args!( - "Operator `{op}=` is not supported between objects of type `{}` and `{}`", - target_type.display(db), - value_type.display(db) - )); - }; - // Fall back to non-augmented binary operator inference. let mut binary_return_ty = || { self.infer_binary_expression_type(assignment.into(), false, target_type, value_type, op) .unwrap_or_else(|| { - report_unsupported_augmented_op(&mut self.context); + report_unsupported_augmented_assignment( + &self.context, + assignment, + target_type, + value_type, + ); Type::unknown() }) }; @@ -5950,7 +5977,12 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { UnionType::from_elements(db, [outcome.return_type(db), binary_return_ty()]) } Err(CallDunderError::CallError(_, bindings)) => { - report_unsupported_augmented_op(&mut self.context); + report_unsupported_augmented_assignment( + &self.context, + assignment, + target_type, + value_type, + ); bindings.return_type(db) } } @@ -8150,10 +8182,10 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { value, } = named; - self.infer_expression(target, TypeContext::default()); - self.add_binding(named.target.as_ref().into(), definition, |builder, tcx| { - builder.infer_expression(value, tcx) + let ty = builder.infer_expression(value, tcx); + builder.store_expression_type(target, ty); + ty }) } @@ -9685,7 +9717,7 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { self.context.report_lint(&UNSUPPORTED_OPERATOR, unary) { builder.into_diagnostic(format_args!( - "Unary operator `{op}` is not supported for type `{}`", + "Unary operator `{op}` is not supported for object of type `{}`", operand_type.display(self.db()), )); } @@ -9718,26 +9750,7 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { self.infer_binary_expression_type(binary.into(), false, left_ty, right_ty, *op) .unwrap_or_else(|| { - let db = self.db(); - - if let Some(builder) = self.context.report_lint(&UNSUPPORTED_OPERATOR, binary) { - let mut diag = builder.into_diagnostic(format_args!( - "Operator `{op}` is not supported between objects of type `{}` and `{}`", - left_ty.display(db), - right_ty.display(db) - )); - - if op == &ast::Operator::BitOr - && (left_ty.is_subtype_of(db, KnownClass::Type.to_instance(db)) - || right_ty.is_subtype_of(db, KnownClass::Type.to_instance(db))) - && Program::get(db).python_version(db) < PythonVersion::PY310 - { - diag.info( - "Note that `X | Y` PEP 604 union syntax is only available in Python 3.10 and later", - ); - add_inferred_python_version_hint_to_diagnostic(db, &mut diag, "resolving types"); - } - } + report_unsupported_binary_operation(&self.context, binary, left_ty, right_ty, *op); Type::unknown() }) } @@ -11629,6 +11642,17 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { generic_context: GenericContext<'db>, specialize: impl FnOnce(&[Option>]) -> Type<'db>, ) -> Type<'db> { + enum ExplicitSpecializationError { + InvalidParamSpec, + UnsatisfiedBound, + UnsatisfiedConstraints, + /// These two errors override the errors above, causing all specializations to be `Unknown`. + MissingTypeVars, + TooManyArguments, + /// This error overrides the errors above, causing the type itself to be `Unknown`. + NonGeneric, + } + fn add_typevar_definition<'db>( db: &'db dyn Db, diagnostic: &mut Diagnostic, @@ -11681,7 +11705,7 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { } }; - let mut has_error = false; + let mut error: Option = None; for (index, item) in typevars.zip_longest(type_arguments.iter()).enumerate() { match item { @@ -11697,8 +11721,8 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { ) { Ok(paramspec_value) => paramspec_value, Err(()) => { - has_error = true; - Type::unknown() + error = Some(ExplicitSpecializationError::InvalidParamSpec); + Type::paramspec_value_callable(db, Parameters::unknown()) } } } else { @@ -11730,8 +11754,10 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { )); add_typevar_definition(db, &mut diagnostic, typevar); } - has_error = true; - continue; + error = Some(ExplicitSpecializationError::UnsatisfiedBound); + specialization_types.push(Some(Type::unknown())); + } else { + specialization_types.push(Some(provided_type)); } } Some(TypeVarBoundOrConstraints::Constraints(constraints)) => { @@ -11764,14 +11790,16 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { )); add_typevar_definition(db, &mut diagnostic, typevar); } - has_error = true; - continue; + error = Some(ExplicitSpecializationError::UnsatisfiedConstraints); + specialization_types.push(Some(Type::unknown())); + } else { + specialization_types.push(Some(provided_type)); } } - None => {} + None => { + specialization_types.push(Some(provided_type)); + } } - - specialization_types.push(Some(provided_type)); } EitherOrBoth::Left(typevar) => { if typevar.default_type(db).is_none() { @@ -11806,33 +11834,57 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { } )); } - has_error = true; + error = Some(ExplicitSpecializationError::MissingTypeVars); } if let Some(first_excess_type_argument_index) = first_excess_type_argument_index { - let node = get_node(first_excess_type_argument_index); - if let Some(builder) = self.context.report_lint(&INVALID_TYPE_ARGUMENTS, node) { - let description = CallableDescription::new(db, value_ty); - builder.into_diagnostic(format_args!( - "Too many type arguments{}: expected {}, got {}", - if let Some(CallableDescription { kind, name }) = description { - format!(" to {kind} `{name}`") - } else { - String::new() - }, - if typevar_with_defaults == 0 { - format!("{typevars_len}") - } else { - format!( - "between {} and {}", - typevars_len - typevar_with_defaults, - typevars_len - ) - }, - type_arguments.len(), - )); + if typevars_len == 0 { + // Type parameter list cannot be empty, so if we reach here, `value_ty` is not a generic type. + if let Some(builder) = self + .context + .report_lint(&NON_SUBSCRIPTABLE, &*subscript.value) + { + let mut diagnostic = + builder.into_diagnostic("Cannot subscript non-generic type"); + if match value_ty { + Type::GenericAlias(_) => true, + Type::KnownInstance(KnownInstanceType::UnionType(union)) => union + .value_expression_types(db) + .is_ok_and(|mut tys| tys.any(|ty| ty.is_generic_alias())), + _ => false, + } { + diagnostic.set_primary_message(format_args!( + "`{}` is already specialized", + value_ty.display(db) + )); + } + } + error = Some(ExplicitSpecializationError::NonGeneric); + } else { + let node = get_node(first_excess_type_argument_index); + if let Some(builder) = self.context.report_lint(&INVALID_TYPE_ARGUMENTS, node) { + let description = CallableDescription::new(db, value_ty); + builder.into_diagnostic(format_args!( + "Too many type arguments{}: expected {}, got {}", + if let Some(CallableDescription { kind, name }) = description { + format!(" to {kind} `{name}`") + } else { + String::new() + }, + if typevar_with_defaults == 0 { + format!("{typevars_len}") + } else { + format!( + "between {} and {}", + typevars_len - typevar_with_defaults, + typevars_len + ) + }, + type_arguments.len(), + )); + } + error = Some(ExplicitSpecializationError::TooManyArguments); } - has_error = true; } if store_inferred_type_arguments { @@ -11842,21 +11894,31 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { ); } - if has_error { - let unknowns = generic_context - .variables(self.db()) - .map(|typevar| { - Some(if typevar.is_paramspec(db) { - Type::paramspec_value_callable(db, Parameters::unknown()) - } else { - Type::unknown() + match error { + Some(ExplicitSpecializationError::NonGeneric) => Type::unknown(), + Some( + ExplicitSpecializationError::MissingTypeVars + | ExplicitSpecializationError::TooManyArguments, + ) => { + let unknowns = generic_context + .variables(self.db()) + .map(|typevar| { + Some(if typevar.is_paramspec(db) { + Type::paramspec_value_callable(db, Parameters::unknown()) + } else { + Type::unknown() + }) }) - }) - .collect::>(); - return specialize(&unknowns); + .collect::>(); + specialize(&unknowns) + } + Some( + ExplicitSpecializationError::UnsatisfiedBound + | ExplicitSpecializationError::UnsatisfiedConstraints + | ExplicitSpecializationError::InvalidParamSpec, + ) + | None => specialize(&specialization_types), } - - specialize(&specialization_types) } fn infer_subscript_expression_types( @@ -12037,9 +12099,17 @@ impl<'db, 'ast> TypeInferenceBuilder<'db, 'ast> { Type::KnownInstance(KnownInstanceType::TypeAliasType(TypeAliasType::PEP695(alias))), _, ) if alias.generic_context(db).is_none() => { + debug_assert!(alias.specialization(db).is_none()); if let Some(builder) = self.context.report_lint(&NON_SUBSCRIPTABLE, subscript) { - builder - .into_diagnostic(format_args!("Cannot subscript non-generic type alias")); + let value_type = alias.raw_value_type(db); + let mut diagnostic = + builder.into_diagnostic("Cannot subscript non-generic type alias"); + if value_type.is_definition_generic(db) { + diagnostic.set_primary_message(format_args!( + "`{}` is already specialized", + value_type.display(db) + )); + } } Some(Type::unknown()) diff --git a/crates/ty_python_semantic/src/types/infer/builder/type_expression.rs b/crates/ty_python_semantic/src/types/infer/builder/type_expression.rs index 626225cdc8..d4c5701f1d 100644 --- a/crates/ty_python_semantic/src/types/infer/builder/type_expression.rs +++ b/crates/ty_python_semantic/src/types/infer/builder/type_expression.rs @@ -16,8 +16,8 @@ use crate::types::tuple::{TupleSpecBuilder, TupleType}; use crate::types::{ BindingContext, CallableType, DynamicType, GenericContext, IntersectionBuilder, KnownClass, KnownInstanceType, LintDiagnosticGuard, Parameter, Parameters, SpecialFormType, SubclassOfType, - Type, TypeAliasType, TypeContext, TypeIsType, TypeMapping, UnionBuilder, UnionType, - any_over_type, todo_type, + Type, TypeAliasType, TypeContext, TypeIsType, TypeMapping, TypeVarKind, UnionBuilder, + UnionType, any_over_type, todo_type, }; /// Type expressions @@ -919,6 +919,16 @@ impl<'db> TypeInferenceBuilder<'db, '_> { Type::unknown() } KnownInstanceType::TypeAliasType(type_alias @ TypeAliasType::PEP695(_)) => { + if type_alias.specialization(self.db()).is_some() { + if let Some(builder) = + self.context.report_lint(&NON_SUBSCRIPTABLE, subscript) + { + let mut diagnostic = + builder.into_diagnostic("Cannot subscript non-generic type alias"); + diagnostic.set_primary_message("Double specialization is not allowed"); + } + return Type::unknown(); + } match type_alias.generic_context(self.db()) { Some(generic_context) => { let specialized_type_alias = self @@ -943,9 +953,15 @@ impl<'db> TypeInferenceBuilder<'db, '_> { if let Some(builder) = self.context.report_lint(&NON_SUBSCRIPTABLE, subscript) { - builder.into_diagnostic(format_args!( - "Cannot subscript non-generic type alias" - )); + let value_type = type_alias.raw_value_type(self.db()); + let mut diagnostic = builder + .into_diagnostic("Cannot subscript non-generic type alias"); + if value_type.is_definition_generic(self.db()) { + diagnostic.set_primary_message(format_args!( + "`{}` is already specialized", + value_type.display(self.db()), + )); + } } Type::unknown() @@ -979,8 +995,26 @@ impl<'db> TypeInferenceBuilder<'db, '_> { } Type::unknown() } - KnownInstanceType::TypeVar(_) => { - self.infer_explicit_type_alias_specialization(subscript, value_ty, false) + KnownInstanceType::TypeVar(typevar) => { + // The type variable designated as a generic type alias by `typing.TypeAlias` can be explicitly specialized. + // ```py + // from typing import TypeVar, TypeAlias + // T = TypeVar('T') + // Annotated: TypeAlias = T + // _: Annotated[int] = 1 # valid + // ``` + if typevar.identity(self.db()).kind(self.db()) == TypeVarKind::Pep613Alias { + self.infer_explicit_type_alias_specialization(subscript, value_ty, false) + } else { + if let Some(builder) = + self.context.report_lint(&INVALID_TYPE_FORM, subscript) + { + builder.into_diagnostic(format_args!( + "A type variable itself cannot be specialized", + )); + } + Type::unknown() + } } KnownInstanceType::UnionType(_) diff --git a/crates/ty_python_semantic/src/types/instance.rs b/crates/ty_python_semantic/src/types/instance.rs index fb53f10ef4..9e674065b9 100644 --- a/crates/ty_python_semantic/src/types/instance.rs +++ b/crates/ty_python_semantic/src/types/instance.rs @@ -304,6 +304,14 @@ impl<'db> NominalInstanceType<'db> { matches!(self.0, NominalInstanceInner::Object) } + pub(super) fn is_definition_generic(self) -> bool { + match self.0 { + NominalInstanceInner::NonTuple(class) => class.is_generic(), + NominalInstanceInner::ExactTuple(_) => true, + NominalInstanceInner::Object => false, + } + } + /// If this type is an *exact* tuple type (*not* a subclass of `tuple`), returns the /// tuple spec. /// diff --git a/crates/ty_python_semantic/src/types/list_members.rs b/crates/ty_python_semantic/src/types/list_members.rs index a93438a596..4e4a32c294 100644 --- a/crates/ty_python_semantic/src/types/list_members.rs +++ b/crates/ty_python_semantic/src/types/list_members.rs @@ -187,7 +187,7 @@ impl<'db> AllMembers<'db> { } Type::NewTypeInstance(newtype) => { - self.extend_with_type(db, Type::instance(db, newtype.base_class_type(db))); + self.extend_with_type(db, newtype.concrete_base_type(db)); } Type::ClassLiteral(class_literal) if class_literal.is_typed_dict(db) => { diff --git a/crates/ty_python_semantic/src/types/newtype.rs b/crates/ty_python_semantic/src/types/newtype.rs index 84a6e18f50..906999a9f2 100644 --- a/crates/ty_python_semantic/src/types/newtype.rs +++ b/crates/ty_python_semantic/src/types/newtype.rs @@ -3,7 +3,7 @@ use std::collections::BTreeSet; use crate::Db; use crate::semantic_index::definition::{Definition, DefinitionKind}; use crate::types::constraints::ConstraintSet; -use crate::types::{ClassType, Type, definition_expression_type, visitor}; +use crate::types::{ClassType, KnownUnion, Type, definition_expression_type, visitor}; use ruff_db::parsed::parsed_module; use ruff_python_ast as ast; @@ -80,8 +80,15 @@ impl<'db> NewType<'db> { NewTypeBase::ClassType(nominal_instance_type.class(db)) } Type::NewTypeInstance(newtype) => NewTypeBase::NewType(newtype), - // This branch includes bases that are other typing constructs besides classes and - // other newtypes, for example unions. `NewType("Foo", int | str)` is not allowed. + // There are exactly two union types allowed as bases for NewType: `int | float` and + // `int | float | complex`. These are allowed because that's what `float` and `complex` + // expand into in type position. We don't currently ask whether the union was implicit + // or explicit, so the explicit version is also allowed. + Type::Union(union_type) => match union_type.known(db) { + Some(KnownUnion::Float) => NewTypeBase::Float, + Some(KnownUnion::Complex) => NewTypeBase::Complex, + _ => object_fallback, + }, _ => object_fallback, } } @@ -94,15 +101,16 @@ impl<'db> NewType<'db> { } } - // Walk the `NewTypeBase` chain to find the underlying `ClassType`. There might not be a - // `ClassType` if this `NewType` is cyclical, and we fall back to `object` in that case. - pub fn base_class_type(self, db: &'db dyn Db) -> ClassType<'db> { + // Walk the `NewTypeBase` chain to find the underlying non-newtype `Type`. There might not be + // one if this `NewType` is cyclical, and we fall back to `object` in that case. + pub fn concrete_base_type(self, db: &'db dyn Db) -> Type<'db> { for base in self.iter_bases(db) { - if let NewTypeBase::ClassType(class_type) = base { - return class_type; + match base { + NewTypeBase::NewType(_) => continue, + concrete => return concrete.instance_type(db), } } - ClassType::object(db) + Type::object() } pub(crate) fn is_equivalent_to_impl(self, db: &'db dyn Db, other: Self) -> bool { @@ -179,10 +187,14 @@ impl<'db> NewType<'db> { Some(mapped_base), )); } + // Mapping base class types is used for normalization and applying type mappings, + // neither of which have any effect on `float` or `complex` (which are already + // fully normalized and non-generic), so we don't need to bother calling `f`. + NewTypeBase::Float | NewTypeBase::Complex => {} } } - // If we get here, there is no `ClassType` (because this newtype is cyclic), and we don't - // call `f` at all. + // If we get here, there is no `ClassType` (because this newtype is either float/complex or + // cyclic), and we don't call `f` at all. Some(self) } @@ -209,6 +221,12 @@ pub(crate) fn walk_newtype_instance_type<'db, V: visitor::TypeVisitor<'db> + ?Si pub enum NewTypeBase<'db> { ClassType(ClassType<'db>), NewType(NewType<'db>), + // `float` and `complex` are special-cased in type position, where they refer to `int | float` + // and `int | float | complex` respectively. As an extension of that special case, we allow + // them in `NewType` bases, even though unions and other typing constructs normally aren't + // allowed. + Float, + Complex, } impl<'db> NewTypeBase<'db> { @@ -216,6 +234,8 @@ impl<'db> NewTypeBase<'db> { match self { NewTypeBase::ClassType(class_type) => Type::instance(db, class_type), NewTypeBase::NewType(newtype) => Type::NewTypeInstance(newtype), + NewTypeBase::Float => KnownUnion::Float.to_type(db), + NewTypeBase::Complex => KnownUnion::Complex.to_type(db), } } } @@ -246,10 +266,6 @@ impl<'db> Iterator for NewTypeBaseIter<'db> { fn next(&mut self) -> Option { let current = self.current?; match current.base(self.db) { - NewTypeBase::ClassType(base_class_type) => { - self.current = None; - Some(NewTypeBase::ClassType(base_class_type)) - } NewTypeBase::NewType(base_newtype) => { // Doing the insertion only in this branch avoids allocating in the common case. self.seen_before.insert(current); @@ -262,6 +278,10 @@ impl<'db> Iterator for NewTypeBaseIter<'db> { Some(NewTypeBase::NewType(base_newtype)) } } + concrete_base => { + self.current = None; + Some(concrete_base) + } } } } diff --git a/crates/ty_python_semantic/src/types/signatures.rs b/crates/ty_python_semantic/src/types/signatures.rs index dabbab7239..2c09ec8166 100644 --- a/crates/ty_python_semantic/src/types/signatures.rs +++ b/crates/ty_python_semantic/src/types/signatures.rs @@ -396,7 +396,6 @@ impl<'db> CallableSignature<'db> { self_bound_typevar, Type::TypeVar(other_bound_typevar), Type::TypeVar(other_bound_typevar), - relation, ); let return_types_match = self_return_type.zip(other_return_type).when_some_and( |(self_return_type, other_return_type)| { @@ -427,7 +426,6 @@ impl<'db> CallableSignature<'db> { self_bound_typevar, Type::Never, upper, - relation, ); let return_types_match = self_return_type.when_some_and(|self_return_type| { other_signatures @@ -461,7 +459,6 @@ impl<'db> CallableSignature<'db> { other_bound_typevar, lower, Type::object(), - relation, ); let return_types_match = other_return_type.when_some_and(|other_return_type| { self_signatures diff --git a/crates/ty_python_semantic/src/types/subclass_of.rs b/crates/ty_python_semantic/src/types/subclass_of.rs index c6bb9d0378..eb016199a5 100644 --- a/crates/ty_python_semantic/src/types/subclass_of.rs +++ b/crates/ty_python_semantic/src/types/subclass_of.rs @@ -119,7 +119,7 @@ impl<'db> SubclassOfType<'db> { subclass_of.is_type_var() } - pub(crate) const fn into_type_var(self) -> Option> { + pub const fn into_type_var(self) -> Option> { self.subclass_of.into_type_var() } diff --git a/crates/ty_server/src/capabilities.rs b/crates/ty_server/src/capabilities.rs index 60b5298280..e08ca6ef00 100644 --- a/crates/ty_server/src/capabilities.rs +++ b/crates/ty_server/src/capabilities.rs @@ -34,9 +34,8 @@ bitflags::bitflags! { const RELATIVE_FILE_WATCHER_SUPPORT = 1 << 13; const DIAGNOSTIC_DYNAMIC_REGISTRATION = 1 << 14; const WORKSPACE_CONFIGURATION = 1 << 15; - const RENAME_DYNAMIC_REGISTRATION = 1 << 16; - const COMPLETION_ITEM_LABEL_DETAILS_SUPPORT = 1 << 17; - const DIAGNOSTIC_RELATED_INFORMATION = 1 << 18; + const COMPLETION_ITEM_LABEL_DETAILS_SUPPORT = 1 << 16; + const DIAGNOSTIC_RELATED_INFORMATION = 1 << 17; } } @@ -169,11 +168,6 @@ impl ResolvedClientCapabilities { self.contains(Self::DIAGNOSTIC_RELATED_INFORMATION) } - /// Returns `true` if the client supports dynamic registration for rename capabilities. - pub(crate) const fn supports_rename_dynamic_registration(self) -> bool { - self.contains(Self::RENAME_DYNAMIC_REGISTRATION) - } - /// Returns `true` if the client supports "label details" in completion items. pub(crate) const fn supports_completion_item_label_details(self) -> bool { self.contains(Self::COMPLETION_ITEM_LABEL_DETAILS_SUPPORT) @@ -326,13 +320,6 @@ impl ResolvedClientCapabilities { flags |= Self::HIERARCHICAL_DOCUMENT_SYMBOL_SUPPORT; } - if text_document - .and_then(|text_document| text_document.rename.as_ref()?.dynamic_registration) - .unwrap_or_default() - { - flags |= Self::RENAME_DYNAMIC_REGISTRATION; - } - if client_capabilities .window .as_ref() @@ -373,16 +360,6 @@ pub(crate) fn server_capabilities( )) }; - let rename_provider = if resolved_client_capabilities.supports_rename_dynamic_registration() { - // If the client supports dynamic registration, we will register the rename capabilities - // dynamically based on the `ty.experimental.rename` setting. - None - } else { - // Otherwise, we always register the rename provider and bail out in `prepareRename` if - // the feature is disabled. - Some(OneOf::Right(server_rename_options())) - }; - ServerCapabilities { position_encoding: Some(position_encoding.into()), code_action_provider: Some(types::CodeActionProviderCapability::Options( @@ -413,7 +390,7 @@ pub(crate) fn server_capabilities( definition_provider: Some(OneOf::Left(true)), declaration_provider: Some(DeclarationCapability::Simple(true)), references_provider: Some(OneOf::Left(true)), - rename_provider, + rename_provider: Some(OneOf::Right(server_rename_options())), document_highlight_provider: Some(OneOf::Left(true)), hover_provider: Some(HoverProviderCapability::Simple(true)), signature_help_provider: Some(SignatureHelpOptions { diff --git a/crates/ty_server/src/server/api.rs b/crates/ty_server/src/server/api.rs index a5c54e4518..e369717824 100644 --- a/crates/ty_server/src/server/api.rs +++ b/crates/ty_server/src/server/api.rs @@ -299,7 +299,9 @@ where } if let Err(error) = ruff_db::panic::catch_unwind(|| { - R::handle_request(&id, &db, document, client, params); + salsa::attach(&db, || { + R::handle_request(&id, &db, document, client, params); + }); }) { panic_response::(&id, client, &error, retry); } diff --git a/crates/ty_server/src/server/api/notifications/did_change.rs b/crates/ty_server/src/server/api/notifications/did_change.rs index 6c01fa2214..ef0631f772 100644 --- a/crates/ty_server/src/server/api/notifications/did_change.rs +++ b/crates/ty_server/src/server/api/notifications/did_change.rs @@ -26,7 +26,7 @@ impl SyncNotificationHandler for DidChangeTextDocumentHandler { content_changes, } = params; - let document = session + let mut document = session .document_handle(&uri) .with_failure_code(ErrorCode::InternalError)?; diff --git a/crates/ty_server/src/server/api/notifications/did_change_notebook.rs b/crates/ty_server/src/server/api/notifications/did_change_notebook.rs index 736a351e40..36490412b3 100644 --- a/crates/ty_server/src/server/api/notifications/did_change_notebook.rs +++ b/crates/ty_server/src/server/api/notifications/did_change_notebook.rs @@ -24,7 +24,7 @@ impl SyncNotificationHandler for DidChangeNotebookHandler { change: types::NotebookDocumentChangeEvent { cells, metadata }, }: types::DidChangeNotebookDocumentParams, ) -> Result<()> { - let document = session + let mut document = session .document_handle(&uri) .with_failure_code(ErrorCode::InternalError)?; diff --git a/crates/ty_server/src/server/api/requests/prepare_rename.rs b/crates/ty_server/src/server/api/requests/prepare_rename.rs index 8601aa2995..2fd8228201 100644 --- a/crates/ty_server/src/server/api/requests/prepare_rename.rs +++ b/crates/ty_server/src/server/api/requests/prepare_rename.rs @@ -32,7 +32,6 @@ impl BackgroundDocumentRequestHandler for PrepareRenameRequestHandler { if snapshot .workspace_settings() .is_language_services_disabled() - || !snapshot.global_settings().is_rename_enabled() { return Ok(None); } diff --git a/crates/ty_server/src/session.rs b/crates/ty_server/src/session.rs index 4ebfe7ead0..18b211a8cc 100644 --- a/crates/ty_server/src/session.rs +++ b/crates/ty_server/src/session.rs @@ -9,7 +9,7 @@ use anyhow::{Context, anyhow}; use lsp_server::{Message, RequestId}; use lsp_types::notification::{DidChangeWatchedFiles, Exit, Notification}; use lsp_types::request::{ - DocumentDiagnosticRequest, RegisterCapability, Rename, Request, Shutdown, UnregisterCapability, + DocumentDiagnosticRequest, RegisterCapability, Request, Shutdown, UnregisterCapability, WorkspaceDiagnosticRequest, }; use lsp_types::{ @@ -32,9 +32,7 @@ use options::GlobalOptions; pub(crate) use self::options::InitializationOptions; pub use self::options::{ClientOptions, DiagnosticMode}; pub(crate) use self::settings::{GlobalSettings, WorkspaceSettings}; -use crate::capabilities::{ - ResolvedClientCapabilities, server_diagnostic_options, server_rename_options, -}; +use crate::capabilities::{ResolvedClientCapabilities, server_diagnostic_options}; use crate::document::{DocumentKey, DocumentVersion, NotebookDocument}; use crate::server::{Action, publish_settings_diagnostics}; use crate::session::client::Client; @@ -583,7 +581,6 @@ impl Session { /// `ty.experimental.rename` global setting. fn register_capabilities(&mut self, client: &Client) { static DIAGNOSTIC_REGISTRATION_ID: &str = "ty/textDocument/diagnostic"; - static RENAME_REGISTRATION_ID: &str = "ty/textDocument/rename"; static FILE_WATCHER_REGISTRATION_ID: &str = "ty/workspace/didChangeWatchedFiles"; let mut registrations = vec![]; @@ -625,31 +622,6 @@ impl Session { }); } - if self - .resolved_client_capabilities - .supports_rename_dynamic_registration() - { - let is_rename_enabled = self.global_settings.is_rename_enabled(); - - if !is_rename_enabled { - tracing::debug!("Rename capability is disabled in the resolved global settings"); - if self.registrations.contains(Rename::METHOD) { - unregistrations.push(Unregistration { - id: RENAME_REGISTRATION_ID.into(), - method: Rename::METHOD.into(), - }); - } - } - - if is_rename_enabled { - registrations.push(Registration { - id: RENAME_REGISTRATION_ID.into(), - method: Rename::METHOD.into(), - register_options: Some(serde_json::to_value(server_rename_options()).unwrap()), - }); - } - } - if let Some(register_options) = self.file_watcher_registration_options() { if self.registrations.contains(DidChangeWatchedFiles::METHOD) { unregistrations.push(Unregistration { @@ -1020,6 +992,7 @@ impl DocumentSnapshot { } /// Returns the client settings for all workspaces. + #[expect(unused)] pub(crate) fn global_settings(&self) -> &GlobalSettings { &self.global_settings } @@ -1451,7 +1424,7 @@ impl DocumentHandle { } pub(crate) fn update_text_document( - &self, + &mut self, session: &mut Session, content_changes: Vec, new_version: DocumentVersion, @@ -1471,6 +1444,8 @@ impl DocumentHandle { } else { document.apply_changes(content_changes, new_version, position_encoding); } + + self.set_version(document.version()); } self.update_in_db(session); @@ -1479,7 +1454,7 @@ impl DocumentHandle { } pub(crate) fn update_notebook_document( - &self, + &mut self, session: &mut Session, cells: Option, metadata: Option, @@ -1496,6 +1471,8 @@ impl DocumentHandle { new_version, position_encoding, )?; + + self.set_version(new_version); } self.update_in_db(session); @@ -1516,6 +1493,16 @@ impl DocumentHandle { session.apply_changes(path, changes); } + fn set_version(&mut self, version: DocumentVersion) { + let self_version = match self { + DocumentHandle::Text { version, .. } + | DocumentHandle::Notebook { version, .. } + | DocumentHandle::Cell { version, .. } => version, + }; + + *self_version = version; + } + /// De-registers a document, specified by its key. /// Calling this multiple times for the same document is a logic error. /// diff --git a/crates/ty_server/src/session/options.rs b/crates/ty_server/src/session/options.rs index b202270aae..cc02037d0c 100644 --- a/crates/ty_server/src/session/options.rs +++ b/crates/ty_server/src/session/options.rs @@ -116,12 +116,6 @@ impl ClientOptions { self } - #[must_use] - pub fn with_experimental_rename(mut self, enabled: bool) -> Self { - self.global.experimental.get_or_insert_default().rename = Some(enabled); - self - } - #[must_use] pub fn with_auto_import(mut self, enabled: bool) -> Self { self.workspace @@ -156,9 +150,7 @@ impl GlobalOptions { pub(crate) fn into_settings(self) -> GlobalSettings { let experimental = self .experimental - .map(|experimental| ExperimentalSettings { - rename: experimental.rename.unwrap_or(false), - }) + .map(Experimental::into_settings) .unwrap_or_default(); GlobalSettings { @@ -326,9 +318,13 @@ impl Combine for DiagnosticMode { #[derive(Clone, Combine, Debug, Serialize, Deserialize, Default)] #[serde(rename_all = "camelCase")] -pub(crate) struct Experimental { - /// Whether to enable the experimental symbol rename feature. - pub(crate) rename: Option, +pub(crate) struct Experimental; + +impl Experimental { + #[expect(clippy::unused_self)] + fn into_settings(self) -> ExperimentalSettings { + ExperimentalSettings {} + } } #[derive(Clone, Debug, Serialize, Deserialize, Default)] diff --git a/crates/ty_server/src/session/settings.rs b/crates/ty_server/src/session/settings.rs index 5e73df0102..3b88c2d1f0 100644 --- a/crates/ty_server/src/session/settings.rs +++ b/crates/ty_server/src/session/settings.rs @@ -10,12 +10,6 @@ pub(crate) struct GlobalSettings { pub(super) experimental: ExperimentalSettings, } -impl GlobalSettings { - pub(crate) fn is_rename_enabled(&self) -> bool { - self.experimental.rename - } -} - impl GlobalSettings { pub(crate) fn diagnostic_mode(&self) -> DiagnosticMode { self.diagnostic_mode @@ -23,9 +17,7 @@ impl GlobalSettings { } #[derive(Clone, Default, Debug, PartialEq)] -pub(crate) struct ExperimentalSettings { - pub(super) rename: bool, -} +pub(crate) struct ExperimentalSettings; /// Resolved client settings for a specific workspace. /// diff --git a/crates/ty_server/tests/e2e/initialize.rs b/crates/ty_server/tests/e2e/initialize.rs index 8611afdccd..fb715bf929 100644 --- a/crates/ty_server/tests/e2e/initialize.rs +++ b/crates/ty_server/tests/e2e/initialize.rs @@ -434,96 +434,21 @@ fn unknown_options_in_workspace_configuration() -> Result<()> { Ok(()) } -/// Tests that the server sends a registration request for the rename capability if the client -/// setting is set to true and dynamic registration is enabled. -#[test] -fn register_rename_capability_when_enabled() -> Result<()> { - let workspace_root = SystemPath::new("foo"); - let mut server = TestServerBuilder::new()? - .with_workspace(workspace_root, None)? - .with_initialization_options(ClientOptions::default().with_experimental_rename(true)) - .enable_rename_dynamic_registration(true) - .build() - .wait_until_workspaces_are_initialized(); - - let (_, params) = server.await_request::(); - let [registration] = params.registrations.as_slice() else { - panic!( - "Expected a single registration, got: {:#?}", - params.registrations - ); - }; - - insta::assert_json_snapshot!(registration, @r#" - { - "id": "ty/textDocument/rename", - "method": "textDocument/rename", - "registerOptions": { - "prepareProvider": true - } - } - "#); - - Ok(()) -} - -/// Tests that rename capability is statically registered during initialization if the client -/// doesn't support dynamic registration, but the server is configured to support it. -#[test] -fn rename_available_without_dynamic_registration() -> Result<()> { - let workspace_root = SystemPath::new("foo"); - - let server = TestServerBuilder::new()? - .with_workspace(workspace_root, None)? - .with_initialization_options(ClientOptions::default().with_experimental_rename(true)) - .enable_rename_dynamic_registration(false) - .build() - .wait_until_workspaces_are_initialized(); - - let initialization_result = server.initialization_result().unwrap(); - insta::assert_json_snapshot!(initialization_result.capabilities.rename_provider, @r#" - { - "prepareProvider": true - } - "#); - - Ok(()) -} - -/// Tests that the server does not send a registration request for the rename capability if the -/// client setting is set to false and dynamic registration is enabled. -#[test] -fn not_register_rename_capability_when_disabled() -> Result<()> { - let workspace_root = SystemPath::new("foo"); - - TestServerBuilder::new()? - .with_workspace(workspace_root, None)? - .with_initialization_options(ClientOptions::default().with_experimental_rename(false)) - .enable_rename_dynamic_registration(true) - .build() - .wait_until_workspaces_are_initialized(); - - // The `Drop` implementation will make sure that the client did not receive any registration - // request. - - Ok(()) -} - /// Tests that the server can register multiple capabilities at once. /// /// This test would need to be updated when the server supports additional capabilities in the /// future. +/// +/// TODO: This test currently only verifies a single capability. It should be +/// updated with more dynamic capabilities when the server supports it. #[test] fn register_multiple_capabilities() -> Result<()> { let workspace_root = SystemPath::new("foo"); let mut server = TestServerBuilder::new()? .with_workspace(workspace_root, None)? .with_initialization_options( - ClientOptions::default() - .with_experimental_rename(true) - .with_diagnostic_mode(DiagnosticMode::Workspace), + ClientOptions::default().with_diagnostic_mode(DiagnosticMode::Workspace), ) - .enable_rename_dynamic_registration(true) .enable_diagnostic_dynamic_registration(true) .build() .wait_until_workspaces_are_initialized(); @@ -531,8 +456,6 @@ fn register_multiple_capabilities() -> Result<()> { let (_, params) = server.await_request::(); let registrations = params.registrations; - assert_eq!(registrations.len(), 2); - insta::assert_json_snapshot!(registrations, @r#" [ { @@ -545,13 +468,6 @@ fn register_multiple_capabilities() -> Result<()> { "workDoneProgress": true, "workspaceDiagnostics": true } - }, - { - "id": "ty/textDocument/rename", - "method": "textDocument/rename", - "registerOptions": { - "prepareProvider": true - } } ] "#); diff --git a/crates/ty_server/tests/e2e/main.rs b/crates/ty_server/tests/e2e/main.rs index 579e730129..d0ac098527 100644 --- a/crates/ty_server/tests/e2e/main.rs +++ b/crates/ty_server/tests/e2e/main.rs @@ -35,6 +35,7 @@ mod inlay_hints; mod notebook; mod publish_diagnostics; mod pull_diagnostics; +mod rename; use std::collections::{BTreeMap, HashMap, VecDeque}; use std::num::NonZeroUsize; @@ -52,8 +53,8 @@ use lsp_types::notification::{ Initialized, Notification, }; use lsp_types::request::{ - Completion, DocumentDiagnosticRequest, HoverRequest, Initialize, InlayHintRequest, Request, - Shutdown, WorkspaceConfiguration, WorkspaceDiagnosticRequest, + Completion, DocumentDiagnosticRequest, HoverRequest, Initialize, InlayHintRequest, + PrepareRenameRequest, Request, Shutdown, WorkspaceConfiguration, WorkspaceDiagnosticRequest, }; use lsp_types::{ ClientCapabilities, CompletionItem, CompletionParams, CompletionResponse, @@ -67,12 +68,11 @@ use lsp_types::{ TextDocumentContentChangeEvent, TextDocumentIdentifier, TextDocumentItem, TextDocumentPositionParams, Url, VersionedTextDocumentIdentifier, WorkDoneProgressParams, WorkspaceClientCapabilities, WorkspaceDiagnosticParams, WorkspaceDiagnosticReportResult, - WorkspaceFolder, + WorkspaceEdit, WorkspaceFolder, }; use ruff_db::system::{OsSystem, SystemPath, SystemPathBuf, TestSystem}; use rustc_hash::FxHashMap; use tempfile::TempDir; - use ty_server::{ClientOptions, LogLevel, Server, init_logging}; /// Number of times to retry receiving a message before giving up @@ -420,6 +420,16 @@ impl TestServer { .unwrap_or_else(|err| panic!("Failed to receive response for request {id}: {err}")) } + #[track_caller] + pub(crate) fn send_request_await(&mut self, params: R::Params) -> R::Result + where + R: Request, + { + let id = self.send_request::(params); + self.try_await_response::(&id, None) + .unwrap_or_else(|err| panic!("Failed to receive response for request {id}: {err}")) + } + /// Wait for a server response corresponding to the given request ID. /// /// This should only be called if a request was already sent to the server via [`send_request`] @@ -802,6 +812,38 @@ impl TestServer { self.send_notification::(params); } + pub(crate) fn rename( + &mut self, + document: &Url, + position: lsp_types::Position, + new_name: &str, + ) -> Result, ()> { + if self + .send_request_await::(lsp_types::TextDocumentPositionParams { + text_document: TextDocumentIdentifier { + uri: document.clone(), + }, + position, + }) + .is_none() + { + return Err(()); + } + + Ok( + self.send_request_await::(lsp_types::RenameParams { + text_document_position: TextDocumentPositionParams { + text_document: TextDocumentIdentifier { + uri: document.clone(), + }, + position, + }, + new_name: new_name.to_string(), + work_done_progress_params: WorkDoneProgressParams::default(), + }), + ) + } + /// Send a `textDocument/diagnostic` request for the document at the given path. pub(crate) fn document_diagnostic_request( &mut self, @@ -1082,17 +1124,6 @@ impl TestServerBuilder { self } - /// Enable or disable dynamic registration of rename capability - pub(crate) fn enable_rename_dynamic_registration(mut self, enabled: bool) -> Self { - self.client_capabilities - .text_document - .get_or_insert_default() - .rename - .get_or_insert_default() - .dynamic_registration = Some(enabled); - self - } - /// Enable or disable workspace configuration capability pub(crate) fn enable_workspace_configuration(mut self, enabled: bool) -> Self { self.client_capabilities diff --git a/crates/ty_server/tests/e2e/publish_diagnostics.rs b/crates/ty_server/tests/e2e/publish_diagnostics.rs index bbe7094325..aea31db40c 100644 --- a/crates/ty_server/tests/e2e/publish_diagnostics.rs +++ b/crates/ty_server/tests/e2e/publish_diagnostics.rs @@ -33,6 +33,42 @@ def foo() -> str: Ok(()) } +#[test] +fn on_did_change() -> Result<()> { + let workspace_root = SystemPath::new("src"); + let foo = SystemPath::new("src/foo.py"); + let foo_content = "\ +def foo() -> str: + return 42 +"; + + let mut server = TestServerBuilder::new()? + .with_workspace(workspace_root, None)? + .with_file(foo, foo_content)? + .enable_pull_diagnostics(false) + .build() + .wait_until_workspaces_are_initialized(); + + server.open_text_document(foo, foo_content, 1); + let _ = server.await_notification::(); + + let changes = vec![lsp_types::TextDocumentContentChangeEvent { + range: None, + range_length: None, + text: "def foo() -> int: return 42".to_string(), + }]; + + server.change_text_document(foo, changes, 2); + + let diagnostics = server.await_notification::(); + + assert_eq!(diagnostics.version, Some(2)); + + insta::assert_debug_snapshot!(diagnostics); + + Ok(()) +} + #[test] fn message_without_related_information_support() -> Result<()> { let workspace_root = SystemPath::new("src"); diff --git a/crates/ty_server/tests/e2e/rename.rs b/crates/ty_server/tests/e2e/rename.rs new file mode 100644 index 0000000000..56737686a2 --- /dev/null +++ b/crates/ty_server/tests/e2e/rename.rs @@ -0,0 +1,84 @@ +use crate::TestServerBuilder; +use crate::notebook::NotebookBuilder; +use insta::assert_json_snapshot; + +#[test] +fn text_document() -> anyhow::Result<()> { + let mut server = TestServerBuilder::new()? + .with_file("foo.py", "")? + .enable_pull_diagnostics(true) + .build() + .wait_until_workspaces_are_initialized(); + + server.open_text_document( + "foo.py", + r#"def test(): ... + +test() +"#, + 1, + ); + + let edits = server + .rename( + &server.file_uri("foo.py"), + lsp_types::Position { + line: 0, + character: 5, + }, + "new_name", + ) + .expect("Can rename `test` function"); + + assert_json_snapshot!(edits); + + Ok(()) +} + +#[test] +fn notebook() -> anyhow::Result<()> { + let mut server = TestServerBuilder::new()? + .with_file("test.ipynb", "")? + .enable_pull_diagnostics(true) + .build() + .wait_until_workspaces_are_initialized(); + + let mut builder = NotebookBuilder::virtual_file("test.ipynb"); + builder.add_python_cell( + r#"from typing import Literal + +type Style = Literal["italic", "bold", "underline"]"#, + ); + + let cell2 = builder.add_python_cell( + r#"def with_style(line: str, word, style: Style) -> str: + if style == "italic": + return line.replace(word, f"*{word}*") + elif style == "bold": + return line.replace(word, f"__{word}__") + + position = line.find(word) + output = line + "\n" + output += " " * position + output += "-" * len(word) +"#, + ); + + builder.open(&mut server); + + let edits = server + .rename( + &cell2, + lsp_types::Position { + line: 0, + character: 16, + }, + "text", + ) + .expect("Can rename `line` parameter"); + + assert_json_snapshot!(edits); + + server.collect_publish_diagnostic_notifications(2); + Ok(()) +} diff --git a/crates/ty_server/tests/e2e/snapshots/e2e__commands__debug_command.snap b/crates/ty_server/tests/e2e/snapshots/e2e__commands__debug_command.snap index 762b91f71c..21c4b05014 100644 --- a/crates/ty_server/tests/e2e/snapshots/e2e__commands__debug_command.snap +++ b/crates/ty_server/tests/e2e/snapshots/e2e__commands__debug_command.snap @@ -8,9 +8,7 @@ Client capabilities: ResolvedClientCapabilities( Position encoding: UTF16 Global settings: GlobalSettings { diagnostic_mode: OpenFilesOnly, - experimental: ExperimentalSettings { - rename: false, - }, + experimental: ExperimentalSettings, } Open text documents: 0 diff --git a/crates/ty_server/tests/e2e/snapshots/e2e__publish_diagnostics__on_did_change.snap b/crates/ty_server/tests/e2e/snapshots/e2e__publish_diagnostics__on_did_change.snap new file mode 100644 index 0000000000..02ea49ca92 --- /dev/null +++ b/crates/ty_server/tests/e2e/snapshots/e2e__publish_diagnostics__on_did_change.snap @@ -0,0 +1,21 @@ +--- +source: crates/ty_server/tests/e2e/publish_diagnostics.rs +expression: diagnostics +--- +PublishDiagnosticsParams { + uri: Url { + scheme: "file", + cannot_be_a_base: false, + username: "", + password: None, + host: None, + port: None, + path: "/src/foo.py", + query: None, + fragment: None, + }, + diagnostics: [], + version: Some( + 2, + ), +} diff --git a/crates/ty_server/tests/e2e/snapshots/e2e__rename__notebook.snap b/crates/ty_server/tests/e2e/snapshots/e2e__rename__notebook.snap new file mode 100644 index 0000000000..997c0bf686 --- /dev/null +++ b/crates/ty_server/tests/e2e/snapshots/e2e__rename__notebook.snap @@ -0,0 +1,75 @@ +--- +source: crates/ty_server/tests/e2e/rename.rs +expression: edits +--- +{ + "changes": { + "vscode-notebook-cell://test.ipynb#1": [ + { + "range": { + "start": { + "line": 0, + "character": 15 + }, + "end": { + "line": 0, + "character": 19 + } + }, + "newText": "text" + }, + { + "range": { + "start": { + "line": 2, + "character": 15 + }, + "end": { + "line": 2, + "character": 19 + } + }, + "newText": "text" + }, + { + "range": { + "start": { + "line": 4, + "character": 15 + }, + "end": { + "line": 4, + "character": 19 + } + }, + "newText": "text" + }, + { + "range": { + "start": { + "line": 6, + "character": 15 + }, + "end": { + "line": 6, + "character": 19 + } + }, + "newText": "text" + }, + { + "range": { + "start": { + "line": 7, + "character": 13 + }, + "end": { + "line": 7, + "character": 17 + } + }, + "newText": "text" + } + ] + } +} diff --git a/crates/ty_server/tests/e2e/snapshots/e2e__rename__text_document.snap b/crates/ty_server/tests/e2e/snapshots/e2e__rename__text_document.snap new file mode 100644 index 0000000000..fbd47699f5 --- /dev/null +++ b/crates/ty_server/tests/e2e/snapshots/e2e__rename__text_document.snap @@ -0,0 +1,36 @@ +--- +source: crates/ty_server/tests/e2e/rename.rs +expression: edits +--- +{ + "changes": { + "file:///foo.py": [ + { + "range": { + "start": { + "line": 0, + "character": 4 + }, + "end": { + "line": 0, + "character": 8 + } + }, + "newText": "new_name" + }, + { + "range": { + "start": { + "line": 2, + "character": 0 + }, + "end": { + "line": 2, + "character": 4 + } + }, + "newText": "new_name" + } + ] + } +} diff --git a/docs/formatter/black.md b/docs/formatter/black.md index 9b18bf5443..8849a6d5fd 100644 --- a/docs/formatter/black.md +++ b/docs/formatter/black.md @@ -722,7 +722,7 @@ with tempfile.TemporaryDirectory() as d1: ### Preserving parentheses around single-element lists -Ruff preserves at least one parentheses around list elements, even if the list only contains a single element. The Black 2025 or newer, on the other hand, removes the parentheses +Ruff preserves at least one set of parentheses around list elements, even if the list only contains a single element. The Black 2025 style or newer, on the other hand, removes the parentheses for single-element lists if they aren't multiline and doing so does not change semantics: ```python @@ -742,3 +742,98 @@ items = [(True)] items = {(123)} ``` + +### Long lambda expressions + +In [preview](../preview.md), Ruff will keep lambda parameters on a single line, +just like Black: + +```python +# Input +def a(): + return b( + c, + d, + e, + f=lambda self, *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ), + ) + +# Ruff Stable +def a(): + return b( + c, + d, + e, + f=lambda self, + *args, + **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs), + ) + +# Black and Ruff Preview +def a(): + return b( + c, + d, + e, + f=lambda self, *args, **kwargs: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ), + ) +``` + +However, if the body expression exceeds the configured line length, Ruff will +additionally add parentheses around the lambda body and break it over multiple +lines: + +```python +# Input +def a(): + return b( + c, + d, + e, + # Additional `b` character pushes this over the line length + f=lambda self, *args, **kwargs: baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ), + # More complex expressions also trigger wrapping + g=lambda self, *args, **kwargs: baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ) + 1, + ) + +# Black +def a(): + return b( + c, + d, + e, + # Additional `b` character pushes this over the line length + f=lambda self, *args, **kwargs: baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ), + # More complex expressions also trigger wrapping + g=lambda self, *args, **kwargs: baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( + *args, **kwargs + ) + + 1, + ) + +# Ruff Preview +def a(): + return b( + c, + d, + e, + # Additional `b` character pushes this over the line length + f=lambda self, *args, **kwargs: ( + baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + ), + # More complex expressions also trigger wrapping + g=lambda self, *args, **kwargs: ( + baaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa(*args, **kwargs) + 1 + ), + ) +``` diff --git a/docs/integrations.md b/docs/integrations.md index d92c785c76..d459ea6959 100644 --- a/docs/integrations.md +++ b/docs/integrations.md @@ -80,7 +80,7 @@ You can add the following configuration to `.gitlab-ci.yml` to run a `ruff forma stage: build interruptible: true image: - name: ghcr.io/astral-sh/ruff:0.14.8-alpine + name: ghcr.io/astral-sh/ruff:0.14.9-alpine before_script: - cd $CI_PROJECT_DIR - ruff --version @@ -106,7 +106,7 @@ Ruff can be used as a [pre-commit](https://pre-commit.com) hook via [`ruff-pre-c ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.14.8 + rev: v0.14.9 hooks: # Run the linter. - id: ruff-check @@ -119,7 +119,7 @@ To enable lint fixes, add the `--fix` argument to the lint hook: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.14.8 + rev: v0.14.9 hooks: # Run the linter. - id: ruff-check @@ -133,7 +133,7 @@ To avoid running on Jupyter Notebooks, remove `jupyter` from the list of allowed ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.14.8 + rev: v0.14.9 hooks: # Run the linter. - id: ruff-check diff --git a/docs/tutorial.md b/docs/tutorial.md index 59b64e52e1..04169bc1f4 100644 --- a/docs/tutorial.md +++ b/docs/tutorial.md @@ -369,7 +369,7 @@ This tutorial has focused on Ruff's command-line interface, but Ruff can also be ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.14.8 + rev: v0.14.9 hooks: # Run the linter. - id: ruff-check diff --git a/pyproject.toml b/pyproject.toml index 5159682235..96f840d03b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "maturin" [project] name = "ruff" -version = "0.14.8" +version = "0.14.9" description = "An extremely fast Python linter and code formatter, written in Rust." authors = [{ name = "Astral Software Inc.", email = "hey@astral.sh" }] readme = "README.md" diff --git a/scripts/benchmarks/pyproject.toml b/scripts/benchmarks/pyproject.toml index e9bad66935..55a526eb3b 100644 --- a/scripts/benchmarks/pyproject.toml +++ b/scripts/benchmarks/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "scripts" -version = "0.14.8" +version = "0.14.9" description = "" authors = ["Charles Marsh "] diff --git a/scripts/ty_benchmark/snapshots/black_Pyrefly.txt b/scripts/ty_benchmark/snapshots/black_Pyrefly.txt index 2d96ba56fd..b3de7dfbcf 100644 --- a/scripts/ty_benchmark/snapshots/black_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/black_Pyrefly.txt @@ -29,7 +29,6 @@ ERROR src/black/trans.py:544:10-23: `type[Err[CannotTransform] | Ok[TypeVar[T]]] ERROR src/black/trans.py:752:55-68: `type[Err[CannotTransform] | Ok[TypeVar[T]]]` is not subscriptable [unsupported-operation] ERROR src/black/trans.py:985:19-32: `type[Err[CannotTransform] | Ok[TypeVar[T]]]` is not subscriptable [unsupported-operation] ERROR src/black/trans.py:1111:57-70: `type[Err[CannotTransform] | Ok[TypeVar[T]]]` is not subscriptable [unsupported-operation] -ERROR src/black/trans.py:1349:17-1350:27: `int` is not assignable to `int` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR src/black/trans.py:1480:19-32: `type[Err[CannotTransform] | Ok[TypeVar[T]]]` is not subscriptable [unsupported-operation] ERROR src/black/trans.py:1630:25-31: `csplit` may be uninitialized [unbound-name] ERROR src/black/trans.py:2162:19-32: `type[Err[CannotTransform] | Ok[TypeVar[T]]]` is not subscriptable [unsupported-operation] @@ -43,4 +42,4 @@ ERROR src/blib2to3/pytree.py:670:24-34: `newcontent` may be uninitialized [unbou ERROR src/blib2to3/pytree.py:756:24-39: `wrapped_content` may be uninitialized [unbound-name] ERROR src/blib2to3/pytree.py:847:34-45: `save_stderr` may be uninitialized [unbound-name] INFO Checking project configured at `/pyrefly.toml` - INFO 44 errors (2 suppressed) + INFO 43 errors (2 suppressed) diff --git a/scripts/ty_benchmark/snapshots/discord.py_Pyrefly.txt b/scripts/ty_benchmark/snapshots/discord.py_Pyrefly.txt index dc164a445e..5410c24c2b 100644 --- a/scripts/ty_benchmark/snapshots/discord.py_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/discord.py_Pyrefly.txt @@ -12,7 +12,7 @@ ERROR discord/activity.py:286:9-16: Class member `Activity.to_dict` overrides pa ERROR discord/activity.py:455:9-16: Class member `Game.to_dict` overrides parent class `BaseActivity` in an inconsistent manner [bad-override] ERROR discord/activity.py:566:9-16: Class member `Streaming.to_dict` overrides parent class `BaseActivity` in an inconsistent manner [bad-override] ERROR discord/activity.py:822:9-16: Class member `CustomActivity.to_dict` overrides parent class `BaseActivity` in an inconsistent manner [bad-override] -ERROR discord/activity.py:836:26-46: Cannot set item in `dict[str, int | str | None]` [unsupported-operation] +ERROR discord/activity.py:836:26-46: `Emoji` is not assignable to TypedDict key `emoji` with type `int | str | None` [bad-typed-dict-key] ERROR discord/app_commands/checks.py:390:64-71: Argument `((Interaction[Any]) -> Cooldown | None) | ((Interaction[Any]) -> Coroutine[Any, Any, Cooldown | None])` is not assignable to parameter with type `(Interaction[Any]) -> MaybeAwaitable` in function `discord.utils.maybe_coroutine` [bad-argument-type] ERROR discord/app_commands/commands.py:235:9-38: Object of class `FunctionType` has no attribute `pass_command_binding` [missing-attribute] ERROR discord/app_commands/commands.py:393:29-76: Object of class `FunctionType` has no attribute `__discord_app_commands_param_description__` [missing-attribute] @@ -34,7 +34,7 @@ ERROR discord/app_commands/models.py:370:57-89: Cannot set item in `dict[str, st ERROR discord/app_commands/models.py:372:57-61: Cannot set item in `dict[str, str]` [unsupported-operation] ERROR discord/app_commands/models.py:375:40-53: Cannot set item in `dict[str, str]` [unsupported-operation] ERROR discord/app_commands/models.py:378:34-74: Cannot set item in `dict[str, str]` [unsupported-operation] -ERROR discord/app_commands/models.py:539:42-97: Cannot set item in `dict[str, str | ChoiceT]` [unsupported-operation] +ERROR discord/app_commands/models.py:539:42-97: `dict[str, str]` is not assignable to TypedDict key `name_localizations` with type `str | ChoiceT` [bad-typed-dict-key] ERROR discord/app_commands/models.py:926:16-67: Returned type `Guild | Member | None` is not assignable to declared return type `Member | None` [bad-return] ERROR discord/app_commands/models.py:1057:31-58: `bool | object` is not assignable to attribute `required` with type `bool` [bad-assignment] ERROR discord/app_commands/models.py:1058:55-76: `float | int | object | None` is not assignable to attribute `min_value` with type `float | int | None` [bad-assignment] @@ -50,10 +50,12 @@ ERROR discord/app_commands/models.py:1168:16-1175:10: Returned type `dict[str, d ERROR discord/app_commands/models.py:1235:21-36: `int` is not assignable to TypedDict key `type` with type `Literal[1, 2, 3]` [bad-typed-dict-key] ERROR discord/app_commands/transformers.py:110:67-73: Argument `locale_str | str` is not assignable to parameter `string` with type `locale_str` in function `discord.app_commands.translator.Translator._checked_translate` [bad-argument-type] ERROR discord/app_commands/transformers.py:115:67-78: Argument `locale_str | str` is not assignable to parameter `string` with type `locale_str` in function `discord.app_commands.translator.Translator._checked_translate` [bad-argument-type] -ERROR discord/app_commands/transformers.py:139:31-76: Cannot set item in `dict[str, bool | int | str]` [unsupported-operation] -ERROR discord/app_commands/transformers.py:141:37-74: Cannot set item in `dict[str, bool | int | str]` [unsupported-operation] -ERROR discord/app_commands/transformers.py:149:29-43: Cannot set item in `dict[str, bool | int | str]` [unsupported-operation] -ERROR discord/app_commands/transformers.py:151:29-43: Cannot set item in `dict[str, bool | int | str]` [unsupported-operation] +ERROR discord/app_commands/transformers.py:139:31-76: `list[dict[str, Any]]` is not assignable to TypedDict key `choices` with type `bool | int | str` [bad-typed-dict-key] +ERROR discord/app_commands/transformers.py:141:37-74: `list[int]` is not assignable to TypedDict key `channel_types` with type `bool | int | str` [bad-typed-dict-key] +ERROR discord/app_commands/transformers.py:149:29-43: `float | int` is not assignable to TypedDict key `min_length` with type `bool | int | str` [bad-typed-dict-key] +ERROR discord/app_commands/transformers.py:149:29-43: `float | int` is not assignable to TypedDict key `min_value` with type `bool | int | str` [bad-typed-dict-key] +ERROR discord/app_commands/transformers.py:151:29-43: `float | int` is not assignable to TypedDict key `max_length` with type `bool | int | str` [bad-typed-dict-key] +ERROR discord/app_commands/transformers.py:151:29-43: `float | int` is not assignable to TypedDict key `max_value` with type `bool | int | str` [bad-typed-dict-key] ERROR discord/app_commands/transformers.py:238:22-26: Expected a type form, got instance of `Self@Transformer` [not-a-type] ERROR discord/app_commands/translator.py:119:61-85: Expected a type form, got instance of `Literal['Command[Any, ..., Any]']` [not-a-type] ERROR discord/app_commands/translator.py:119:87-100: Expected a type form, got instance of `Literal['ContextMenu']` [not-a-type] @@ -127,16 +129,10 @@ ERROR discord/channel.py:2082:9-13: Class member `CategoryChannel.type` override ERROR discord/channel.py:2478:9-16: Class member `ForumChannel._update` overrides parent class `GuildChannel` in an inconsistent manner [bad-override] ERROR discord/channel.py:2512:9-13: Class member `ForumChannel.type` overrides parent class `GuildChannel` in an inconsistent manner [bad-override] ERROR discord/channel.py:2619:15-20: Class member `ForumChannel.clone` overrides parent class `GuildChannel` in an inconsistent manner [bad-override] -ERROR discord/channel.py:2637:46-97: Cannot set item in `dict[str, bool | int | list[dict[str, Any]] | str | None]` [unsupported-operation] -ERROR discord/channel.py:3036:47-84: Cannot set item in `dict[str, int | str | None]` [unsupported-operation] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `initial` with type `bool` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `gateway` with type `URL | None` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `session` with type `str | None` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `resume` with type `bool` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `encoding` with type `str` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] -ERROR discord/client.py:723:59-70: Unpacked keyword argument `bool | int | None` is not assignable to parameter `compress` with type `bool` in function `discord.gateway.DiscordWebSocket.from_client` [bad-argument-type] +ERROR discord/channel.py:2637:46-97: `dict[str, Any]` is not assignable to TypedDict key `default_reaction_emoji` with type `bool | int | list[dict[str, Any]] | str | None` [bad-typed-dict-key] +ERROR discord/channel.py:3036:47-84: `list[str]` is not assignable to TypedDict key `applied_tags` with type `int | str | None` [bad-typed-dict-key] ERROR discord/client.py:731:33-105: No matching overload found for function `typing.MutableMapping.update` called with arguments: (sequence=int | None, resume=bool, session=str | None) [no-matching-overload] -ERROR discord/client.py:733:44-59: Cannot set item in `dict[str, bool | int | None]` [unsupported-operation] +ERROR discord/client.py:733:44-59: `URL` is not assignable to TypedDict key `gateway` with type `bool | int | None` [bad-typed-dict-key] ERROR discord/client.py:756:37-762:22: No matching overload found for function `typing.MutableMapping.update` called with arguments: (sequence=int | None, gateway=URL, initial=Literal[False], resume=Literal[True], session=str | None) [no-matching-overload] ERROR discord/client.py:782:33-787:18: No matching overload found for function `typing.MutableMapping.update` called with arguments: (sequence=int | None, gateway=URL, resume=Literal[True], session=str | None) [no-matching-overload] ERROR discord/client.py:2975:83-99: Argument `int` is not assignable to parameter `owner_type` with type `Literal[1, 2]` in function `discord.http.HTTPClient.create_entitlement` [bad-argument-type] @@ -158,10 +154,7 @@ ERROR discord/components.py:1324:21-36: `int` is not assignable to TypedDict key ERROR discord/components.py:1326:27-63: `list[Component]` is not assignable to TypedDict key `components` with type `list[ContainerChildComponent]` [bad-typed-dict-key] ERROR discord/components.py:1380:21-36: `int` is not assignable to TypedDict key `type` with type `Literal[18]` [bad-typed-dict-key] ERROR discord/components.py:1444:21-36: `int` is not assignable to TypedDict key `type` with type `Literal[19]` [bad-typed-dict-key] -ERROR discord/embeds.py:246:28-55: `Colour` is not assignable to attribute `_colour` with type `None` [bad-assignment] ERROR discord/embeds.py:308:9-15: Class member `Embed.__eq__` overrides parent class `object` in an inconsistent manner [bad-override] -ERROR discord/embeds.py:343:28-33: `Colour` is not assignable to attribute `_colour` with type `None` [bad-assignment] -ERROR discord/embeds.py:345:28-47: `Colour` is not assignable to attribute `_colour` with type `None` [bad-assignment] ERROR discord/embeds.py:362:31-35: `None` is not assignable to attribute `_timestamp` with type `datetime` [bad-assignment] ERROR discord/emoji.py:119:14-20: Class member `Emoji._state` overrides parent class `AssetMixin` in an inconsistent manner [bad-override] ERROR discord/emoji.py:166:9-12: Class member `Emoji.url` overrides parent class `AssetMixin` in an inconsistent manner [bad-override] @@ -283,38 +276,20 @@ ERROR discord/ext/commands/parameters.py:115:9-16: Class member `Parameter.repla ERROR discord/ext/commands/parameters.py:324:5-15: Class member `Signature.parameters` overrides parent class `Signature` in an inconsistent manner [bad-override] ERROR discord/ext/commands/view.py:151:53-64: Argument `str | None` is not assignable to parameter `close_quote` with type `str` in function `discord.ext.commands.errors.ExpectedClosingQuoteError.__init__` [bad-argument-type] ERROR discord/ext/commands/view.py:162:57-68: Argument `str | None` is not assignable to parameter `close_quote` with type `str` in function `discord.ext.commands.errors.ExpectedClosingQuoteError.__init__` [bad-argument-type] -ERROR discord/ext/tasks/__init__.py:212:36-63: `datetime` is not assignable to attribute `_next_iteration` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:214:36-80: `datetime` is not assignable to attribute `_next_iteration` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:222:49-69: Argument `None` is not assignable to parameter `dt` with type `datetime` in function `Loop._try_sleep_until` [bad-argument-type] -ERROR discord/ext/tasks/__init__.py:224:44-64: `None` is not assignable to attribute `_last_iteration` with type `datetime` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:225:44-71: `datetime` is not assignable to attribute `_next_iteration` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:231:56-100: `<=` is not supported between `None` and `datetime` [unsupported-operation] -ERROR discord/ext/tasks/__init__.py:242:53-73: Argument `None` is not assignable to parameter `dt` with type `datetime` in function `Loop._try_sleep_until` [bad-argument-type] -ERROR discord/ext/tasks/__init__.py:243:48-75: `datetime` is not assignable to attribute `_next_iteration` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:266:53-73: Argument `None` is not assignable to parameter `dt` with type `datetime` in function `Loop._try_sleep_until` [bad-argument-type] -ERROR discord/ext/tasks/__init__.py:301:26-29: `T` is not assignable to attribute `_injected` with type `None` [bad-assignment] ERROR discord/ext/tasks/__init__.py:500:33-70: `tuple[type[OSError], type[GatewayNotFound], type[ConnectionClosed], type[ClientError], type[TimeoutError], *tuple[type[BaseException], ...]]` is not assignable to attribute `_valid_exception` with type `tuple[type[OSError], type[GatewayNotFound], type[ConnectionClosed], type[ClientError], type[TimeoutError]]` [bad-assignment] ERROR discord/ext/tasks/__init__.py:509:33-35: `tuple[()]` is not assignable to attribute `_valid_exception` with type `tuple[type[OSError], type[GatewayNotFound], type[ConnectionClosed], type[ClientError], type[TimeoutError]]` [bad-assignment] ERROR discord/ext/tasks/__init__.py:525:33-95: `tuple[type[ClientError] | type[ConnectionClosed] | type[GatewayNotFound] | type[OSError] | type[TimeoutError], ...]` is not assignable to attribute `_valid_exception` with type `tuple[type[OSError], type[GatewayNotFound], type[ConnectionClosed], type[ClientError], type[TimeoutError]]` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:579:29-33: `FT` is not assignable to attribute `_before_loop` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:607:28-32: `FT` is not assignable to attribute `_after_loop` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:774:36-63: `datetime` is not assignable to attribute `_next_iteration` with type `None` [bad-assignment] -ERROR discord/ext/tasks/__init__.py:777:42-62: Argument `None` is not assignable to parameter `dt` with type `datetime` in function `SleepHandle.recalculate` [bad-argument-type] ERROR discord/file.py:93:42-44: `(IOBase & PathLike[Any]) | (IOBase & bytes) | (IOBase & str) | BufferedIOBase` is not assignable to attribute `fp` with type `BufferedIOBase` [bad-assignment] + WARN discord/flags.py:234:24-29: Identity comparison `False is False` is always True [unnecessary-comparison] + WARN discord/flags.py:324:24-29: Identity comparison `False is False` is always True [unnecessary-comparison] ERROR discord/flags.py:1784:9-20: Class member `ArrayFlags._from_value` overrides parent class `BaseFlags` in an inconsistent manner [bad-override] ERROR discord/flags.py:1881:9-17: Class member `AutoModPresets.to_array` overrides parent class `ArrayFlags` in an inconsistent manner [bad-override] ERROR discord/gateway.py:137:48-57: Multiple values for argument `name` in function `threading.Thread.__init__` [bad-keyword-argument] ERROR discord/gateway.py:218:9-11: Class member `VoiceKeepAliveHandler.ws` overrides parent class `KeepAliveHandler` in an inconsistent manner [bad-override] -ERROR discord/gateway.py:466:13-34: Cannot set item in `int` [unsupported-operation] ERROR discord/gateway.py:466:37-70: Cannot set item in `dict[str, bool | dict[str, str] | int | str | None]` [unsupported-operation] -ERROR discord/gateway.py:470:13-37: Cannot set item in `int` [unsupported-operation] ERROR discord/gateway.py:470:40-475:14: Cannot set item in `dict[str, bool | dict[str, str] | int | str | None]` [unsupported-operation] -ERROR discord/gateway.py:478:13-36: Cannot set item in `int` [unsupported-operation] -ERROR discord/gateway.py:735:13-34: Cannot set item in `int` [unsupported-operation] ERROR discord/gateway.py:735:37-42: Cannot set item in `dict[str, bool | int]` [unsupported-operation] -ERROR discord/gateway.py:738:13-37: Cannot set item in `int` [unsupported-operation] ERROR discord/gateway.py:738:40-48: Cannot set item in `dict[str, bool | int]` [unsupported-operation] -ERROR discord/gateway.py:741:13-34: Cannot set item in `int` [unsupported-operation] ERROR discord/gateway.py:741:37-42: Cannot set item in `dict[str, bool | int]` [unsupported-operation] ERROR discord/guild.py:617:53-95: `object | None` is not assignable to attribute `max_stage_video_users` with type `int | None` [bad-assignment] ERROR discord/guild.py:631:58-97: `object | None` is not assignable to attribute `approximate_presence_count` with type `int | None` [bad-assignment] @@ -367,24 +342,6 @@ ERROR discord/http.py:404:34-45: Object of class `reify` has no attribute `get` ERROR discord/http.py:407:23-34: Object of class `reify` has no attribute `get` [missing-attribute] ERROR discord/http.py:411:59-87: Cannot index into `reify` [bad-index] ERROR discord/http.py:411:59-87: Cannot index into `reify[CIMultiDictProxy[str]]` [bad-index] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `method` with type `str` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `protocols` with type `Iterable[str]` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `timeout` with type `float` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `receive_timeout` with type `float | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `autoclose` with type `bool` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `autoping` with type `bool` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `heartbeat` with type `float | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `origin` with type `str | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `params` with type `Mapping[str, QueryVariable] | Sequence[tuple[str, QueryVariable]] | str | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `headers` with type `CIMultiDict[str] | CIMultiDictProxy[str] | Iterable[tuple[istr | str, str]] | Mapping[istr, str] | Mapping[str, str] | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `proxy` with type `URL | str | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `ssl` with type `Fingerprint | SSLContext | bool` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `verify_ssl` with type `bool | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `fingerprint` with type `bytes | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `ssl_context` with type `SSLContext | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `proxy_headers` with type `CIMultiDict[str] | CIMultiDictProxy[str] | Iterable[tuple[istr | str, str]] | Mapping[istr, str] | Mapping[str, str] | None` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `compress` with type `int` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] -ERROR discord/http.py:566:53-61: Unpacked keyword argument `BasicAuth | bool | dict[str, str] | float | int | str | None` is not assignable to parameter `max_msg_size` with type `int` in function `aiohttp.client.ClientSession.ws_connect` [bad-argument-type] ERROR discord/http.py:640:20-29: Cannot use `Ratelimit` as a context manager [bad-context-manager] ERROR discord/http.py:661:40-60: Object of class `reify` has no attribute `get` [missing-attribute] ERROR discord/http.py:664:49-92: `in` is not supported between `Literal['X-Ratelimit-Remaining']` and `reify` [not-iterable] @@ -392,8 +349,8 @@ ERROR discord/http.py:664:49-92: `in` is not supported between `Literal['X-Ratel ERROR discord/http.py:707:36-56: Object of class `reify` has no attribute `get` [missing-attribute] ERROR discord/http.py:801:44-52: Unpacked keyword argument `str` is not assignable to parameter `allow_redirects` with type `bool` in function `aiohttp.client.ClientSession.get` [bad-argument-type] ERROR discord/http.py:1075:31-36: Cannot set item in `dict[str, str]` [unsupported-operation] -ERROR discord/http.py:1866:41-55: Cannot set item in `dict[str, bool | int]` [unsupported-operation] -ERROR discord/http.py:1869:48-74: Cannot set item in `dict[str, bool | int]` [unsupported-operation] +ERROR discord/http.py:1866:41-55: `int | str` is not assignable to TypedDict key `target_user_id` with type `bool | int` [bad-typed-dict-key] +ERROR discord/http.py:1869:48-74: `str` is not assignable to TypedDict key `target_application_id` with type `bool | int` [bad-typed-dict-key] ERROR discord/http.py:2574:46-65: Cannot set item in `dict[str, list[Prompt]]` [unsupported-operation] ERROR discord/http.py:2577:34-41: Cannot set item in `dict[str, list[Prompt]]` [unsupported-operation] ERROR discord/http.py:2580:31-35: Cannot set item in `dict[str, list[Prompt]]` [unsupported-operation] @@ -620,4 +577,4 @@ ERROR discord/welcome_screen.py:104:33-48: Object of class `_EmojiTag` has no at ERROR discord/welcome_screen.py:211:37-48: Cannot set item in `dict[str, list[Unknown]]` [unsupported-operation] ERROR discord/welcome_screen.py:214:33-40: Cannot set item in `dict[str, list[Unknown]]` [unsupported-operation] INFO Checking project configured at `/pyrefly.toml` - INFO 617 errors (519 suppressed) + INFO 572 errors (518 suppressed) diff --git a/scripts/ty_benchmark/snapshots/discord.py_mypy.txt b/scripts/ty_benchmark/snapshots/discord.py_mypy.txt index 2475975379..f7adc63f66 100644 --- a/scripts/ty_benchmark/snapshots/discord.py_mypy.txt +++ b/scripts/ty_benchmark/snapshots/discord.py_mypy.txt @@ -698,9 +698,9 @@ discord/abc.py:687: error: Incompatible types in assignment (expression has type discord/abc.py:694: error: Incompatible return value type (got "Dict[Optional[Role], PermissionOverwrite]", expected "Dict[Union[Role, Member, Object], PermissionOverwrite]") [return-value] discord/abc.py:1031: error: Argument 5 to "edit_channel_permissions" of "HTTPClient" has incompatible type "int"; expected "Literal[0, 1]" [arg-type] discord/abc.py:1269: error: Unexpected keyword argument "parent_id" for "update" of "TypedDict" [call-arg] -_/venv/lib/python3.8/site-packages/mypy/typeshed/stdlib/typing.pyi:960: note: "update" of "TypedDict" defined here +venv/lib/python3.8/site-packages/mypy/typeshed/stdlib/typing.pyi:960: note: "update" of "TypedDict" defined here discord/abc.py:1269: error: Unexpected keyword argument "lock_permissions" for "update" of "TypedDict" [call-arg] -_/venv/lib/python3.8/site-packages/mypy/typeshed/stdlib/typing.pyi:960: note: "update" of "TypedDict" defined here +venv/lib/python3.8/site-packages/mypy/typeshed/stdlib/typing.pyi:960: note: "update" of "TypedDict" defined here discord/abc.py:1815: error: Incompatible types in assignment (expression has type "reversed[MessagePin]", variable has type "List[MessagePin]") [assignment] discord/abc.py:1821: error: Incompatible types in "yield" (actual type "Message", expected type "PinnedMessage") [misc] discord/abc.py:2035: error: Incompatible types in assignment (expression has type "Callable[[Arg(int, 'retrieve'), Arg(Optional[Snowflake], 'after'), Arg(Optional[int], 'limit')], Coroutine[Any, Any, Any]]", variable has type "Callable[[Arg(int, 'retrieve'), Arg(Optional[Snowflake], 'around'), Arg(Optional[int], 'limit')], Coroutine[Any, Any, Any]]") [assignment] diff --git a/scripts/ty_benchmark/snapshots/discord.py_ty.txt b/scripts/ty_benchmark/snapshots/discord.py_ty.txt index 342345b116..a260ef52e2 100644 --- a/scripts/ty_benchmark/snapshots/discord.py_ty.txt +++ b/scripts/ty_benchmark/snapshots/discord.py_ty.txt @@ -37,8 +37,8 @@ discord/app_commands/commands.py:2026:40: error[invalid-type-arguments] Too many discord/app_commands/commands.py:2053:49: error[invalid-type-arguments] Too many type arguments: expected 1, got 3 discord/app_commands/commands.py:2066:51: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Unknown]` has no attribute `__name__` discord/app_commands/commands.py:2129:23: error[unresolved-attribute] Object of type `((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) | ((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) | ((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any])` has no attribute `__name__` -discord/app_commands/commands.py:2477:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__discord_app_commands_checks__` on type `(((...) -> Coroutine[Any, Any, Unknown]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu & ~)` -discord/app_commands/commands.py:2479:13: error[unresolved-attribute] Object of type `(((...) -> Coroutine[Any, Any, Unknown]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu) | (((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu) | (((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu) | (((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~ContextMenu)` has no attribute `__discord_app_commands_checks__` +discord/app_commands/commands.py:2477:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__discord_app_commands_checks__` on type `(((...) -> Coroutine[Any, Any, Unknown]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu & ~) | (((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu & ~)` +discord/app_commands/commands.py:2479:13: error[unresolved-attribute] Object of type `(((...) -> Coroutine[Any, Any, Unknown]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu) | (((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu) | (((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu) | (((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~ContextMenu)` has no attribute `__discord_app_commands_checks__` discord/app_commands/errors.py:453:95: error[unresolved-attribute] Object of type `(() -> Coroutine[object, Never, object]) | ((...) -> Coroutine[Any, Any, Unknown])` has no attribute `__qualname__` discord/app_commands/errors.py:460:88: error[unresolved-attribute] Object of type `((Interaction[Any], Member, /) -> Coroutine[Any, Any, Any]) | ((Interaction[Any], User, /) -> Coroutine[Any, Any, Any]) | ((Interaction[Any], Message, /) -> Coroutine[Any, Any, Any])` has no attribute `__qualname__` discord/app_commands/models.py:926:16: error[invalid-return-type] Return type does not match returned value: expected `Member | None`, found `(Guild & ~AlwaysTruthy) | None | Member` @@ -115,7 +115,6 @@ discord/emoji.py:287:26: warning[possibly-missing-attribute] Attribute `http` ma discord/emoji.py:292:54: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `ConnectionState[Client]`, found `Any | None | ConnectionState[Client]` discord/emoji.py:294:22: warning[possibly-missing-attribute] Attribute `http` may be missing on object of type `Any | None | ConnectionState[Client]` discord/errors.py:30:10: error[unresolved-import] Cannot resolve imported module `requests` -discord/ext/commands/bot.py:175:36: error[invalid-type-arguments] Too many type arguments: expected 0, got 1 discord/ext/commands/bot.py:177:9: error[invalid-parameter-default] Default value of type `_DefaultRepr` is not assignable to annotated parameter type `HelpCommand | None` discord/ext/commands/bot.py:296:41: error[invalid-type-arguments] Too many type arguments: expected 1, got 4 discord/ext/commands/bot.py:306:50: error[invalid-type-arguments] Too many type arguments: expected 1, got 4 @@ -123,7 +122,6 @@ discord/ext/commands/bot.py:320:41: error[invalid-type-arguments] Too many type discord/ext/commands/bot.py:330:50: error[invalid-type-arguments] Too many type arguments: expected 1, got 4 discord/ext/commands/bot.py:655:16: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Any]` has no attribute `__name__` discord/ext/commands/bot.py:681:16: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Any]` has no attribute `__name__` -discord/ext/commands/bot.py:1544:40: error[invalid-type-arguments] Too many type arguments: expected 0, got 1 discord/ext/commands/bot.py:1546:13: error[invalid-parameter-default] Default value of type `_DefaultRepr` is not assignable to annotated parameter type `HelpCommand | None` discord/ext/commands/cog.py:288:36: error[invalid-type-arguments] Type `` is not assignable to upper bound `Cog | None` of type variable `CogT@Command` discord/ext/commands/cog.py:289:79: error[invalid-type-arguments] Type `` is not assignable to upper bound `Group | Cog` of type variable `GroupT@Command` @@ -144,29 +142,29 @@ discord/ext/commands/core.py:508:28: error[unresolved-attribute] Object of type discord/ext/commands/core.py:544:24: error[unresolved-attribute] Object of type `(...) -> Any` has no attribute `__globals__` discord/ext/commands/core.py:1552:22: error[no-matching-overload] No overload of function `command` matches arguments discord/ext/commands/core.py:1609:22: error[no-matching-overload] No overload of function `group` matches arguments -discord/ext/commands/core.py:1942:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~` -discord/ext/commands/core.py:1944:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` has no attribute `__commands_checks__` -discord/ext/commands/core.py:1949:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Any, @Todo, Any] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Any, @Todo, Any] | ((...) -> Coroutine[Any, Any, Any])`. -discord/ext/commands/core.py:1956:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Any, @Todo, Any] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Any, @Todo, Any] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:1942:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~` +discord/ext/commands/core.py:1944:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` has no attribute `__commands_checks__` +discord/ext/commands/core.py:1949:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Any, (...), Any] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Any, (...), Any] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:1956:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Any, (...), Any] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Any, (...), Any] | ((...) -> Coroutine[Any, Any, Any])`. discord/ext/commands/core.py:2358:32: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `(Context[object], /) -> bool | Coroutine[Never, object, bool]`, found `def predicate[BotT](ctx: Context[BotT@predicate]) -> bool` -discord/ext/commands/core.py:2365:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~` -discord/ext/commands/core.py:2367:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` has no attribute `__commands_checks__` -discord/ext/commands/core.py:2368:13: error[invalid-assignment] Object of type `Literal[True]` is not assignable to attribute `__discord_app_commands_guild_only__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` -discord/ext/commands/core.py:2373:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])`. -discord/ext/commands/core.py:2380:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:2365:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~` +discord/ext/commands/core.py:2367:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` has no attribute `__commands_checks__` +discord/ext/commands/core.py:2368:13: error[invalid-assignment] Object of type `Literal[True]` is not assignable to attribute `__discord_app_commands_guild_only__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` +discord/ext/commands/core.py:2373:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:2380:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])`. discord/ext/commands/core.py:2433:32: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `(Context[object], /) -> bool | Coroutine[Never, object, bool]`, found `def predicate[BotT](ctx: Context[BotT@predicate]) -> bool` -discord/ext/commands/core.py:2440:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]] & ~` -discord/ext/commands/core.py:2442:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` has no attribute `__commands_checks__` -discord/ext/commands/core.py:2443:13: error[invalid-assignment] Object of type `Literal[True]` is not assignable to attribute `__discord_app_commands_is_nsfw__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` -discord/ext/commands/core.py:2448:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])`. -discord/ext/commands/core.py:2455:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, Unknown, Unknown] | ((...) -> Coroutine[Any, Any, Any])`. -discord/ext/commands/core.py:2499:13: error[invalid-assignment] Object of type `CooldownMapping[Unknown]` is not assignable to attribute `__commands_cooldown__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` -discord/ext/commands/core.py:2547:13: error[invalid-assignment] Object of type `DynamicCooldownMapping[Unknown]` is not assignable to attribute `__commands_cooldown__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` -discord/ext/commands/core.py:2582:13: error[invalid-assignment] Object of type `MaxConcurrency` is not assignable to attribute `__commands_max_concurrency__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` +discord/ext/commands/core.py:2440:17: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to attribute `__commands_checks__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]] & ~` +discord/ext/commands/core.py:2442:13: error[unresolved-attribute] Object of type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` has no attribute `__commands_checks__` +discord/ext/commands/core.py:2443:13: error[invalid-assignment] Object of type `Literal[True]` is not assignable to attribute `__discord_app_commands_is_nsfw__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` +discord/ext/commands/core.py:2448:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:2455:9: error[unresolved-attribute] Unresolved attribute `predicate` on type `def decorator(func: Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])) -> Command[Unknown, (...), Unknown] | ((...) -> Coroutine[Any, Any, Any])`. +discord/ext/commands/core.py:2499:13: error[invalid-assignment] Object of type `CooldownMapping[Unknown]` is not assignable to attribute `__commands_cooldown__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` +discord/ext/commands/core.py:2547:13: error[invalid-assignment] Object of type `DynamicCooldownMapping[Unknown]` is not assignable to attribute `__commands_cooldown__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` +discord/ext/commands/core.py:2582:13: error[invalid-assignment] Object of type `MaxConcurrency` is not assignable to attribute `__commands_max_concurrency__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` discord/ext/commands/core.py:2632:32: error[invalid-argument-type] Argument to bound method `before_invoke` is incorrect: Expected `((object, Unknown, /) -> Coroutine[Never, object, Never]) | ((Unknown, /) -> Coroutine[Never, object, Never])`, found `((CogT@before_invoke, ContextT@before_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@before_invoke, /) -> Coroutine[Any, Any, Any])` -discord/ext/commands/core.py:2634:13: error[invalid-assignment] Object of type `((CogT@before_invoke, ContextT@before_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@before_invoke, /) -> Coroutine[Any, Any, Any])` is not assignable to attribute `__before_invoke__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` +discord/ext/commands/core.py:2634:13: error[invalid-assignment] Object of type `((CogT@before_invoke, ContextT@before_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@before_invoke, /) -> Coroutine[Any, Any, Any])` is not assignable to attribute `__before_invoke__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` discord/ext/commands/core.py:2655:31: error[invalid-argument-type] Argument to bound method `after_invoke` is incorrect: Expected `((object, Unknown, /) -> Coroutine[Never, object, Never]) | ((Unknown, /) -> Coroutine[Never, object, Never])`, found `((CogT@after_invoke, ContextT@after_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@after_invoke, /) -> Coroutine[Any, Any, Any])` -discord/ext/commands/core.py:2657:13: error[invalid-assignment] Object of type `((CogT@after_invoke, ContextT@after_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@after_invoke, /) -> Coroutine[Any, Any, Any])` is not assignable to attribute `__after_invoke__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, object, Unknown]]` +discord/ext/commands/core.py:2657:13: error[invalid-assignment] Object of type `((CogT@after_invoke, ContextT@after_invoke, /) -> Coroutine[Any, Any, Any]) | ((ContextT@after_invoke, /) -> Coroutine[Any, Any, Any])` is not assignable to attribute `__after_invoke__` on type `((...) -> Coroutine[Any, Any, Any]) & ~Top[Command[Unknown, (), Unknown]]` discord/ext/commands/help.py:309:9: error[invalid-assignment] Implicit shadowing of function `get_commands` discord/ext/commands/help.py:310:9: error[invalid-assignment] Implicit shadowing of function `walk_commands` discord/ext/commands/help.py:1255:9: error[invalid-method-override] Invalid override of method `get_destination`: Definition is incompatible with `HelpCommand.get_destination` @@ -177,6 +175,7 @@ discord/ext/commands/hybrid.py:176:49: error[unresolved-attribute] Object of typ discord/ext/commands/hybrid.py:232:13: error[unresolved-attribute] Unresolved attribute `__hybrid_command_flag__` on type `(...) -> Any`. discord/ext/commands/hybrid.py:328:9: error[unresolved-attribute] Unresolved attribute `__signature__` on type `(...) -> Coroutine[Any, Any, T@HybridAppCommand]`. discord/ext/commands/hybrid.py:338:17: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, T@HybridAppCommand]` has no attribute `__signature__` +discord/ext/commands/hybrid.py:430:45: error[invalid-argument-type] Argument to function `maybe_coroutine` is incorrect: Expected `Interaction[ClientT@interaction_check]`, found `Interaction[Client]` discord/ext/commands/hybrid.py:512:37: error[invalid-type-arguments] Too many type arguments: expected 1, got 4 discord/ext/commands/hybrid.py:563:9: error[invalid-method-override] Invalid override of method `_ensure_assignment_on_copy`: Definition is incompatible with `Command._ensure_assignment_on_copy` discord/ext/commands/hybrid.py:731:9: error[invalid-method-override] Invalid override of method `_ensure_assignment_on_copy`: Definition is incompatible with `Command._ensure_assignment_on_copy` @@ -207,6 +206,8 @@ discord/file.py:160:9: error[invalid-assignment] Implicit shadowing of function discord/flags.py:1784:9: error[invalid-method-override] Invalid override of method `_from_value`: Definition is incompatible with `BaseFlags._from_value` discord/flags.py:1881:9: error[invalid-method-override] Invalid override of method `to_array`: Definition is incompatible with `ArrayFlags.to_array` discord/gateway.py:137:48: error[parameter-already-assigned] Multiple values provided for parameter `name` of bound method `__init__` +discord/gateway.py:402:13: error[invalid-assignment] Implicit shadowing of function `send` +discord/gateway.py:403:13: error[invalid-assignment] Implicit shadowing of function `log_receive` discord/gateway.py:466:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `int` discord/gateway.py:470:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `int` discord/gateway.py:478:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `int` @@ -275,7 +276,7 @@ discord/soundboard.py:301:22: warning[possibly-missing-attribute] Attribute `htt discord/soundboard.py:302:50: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `ConnectionState[Client]`, found `Any | None | ConnectionState[Client]` discord/soundboard.py:325:15: warning[possibly-missing-attribute] Attribute `http` may be missing on object of type `Any | None | ConnectionState[Client]` discord/state.py:263:13: error[invalid-assignment] Implicit shadowing of function `store_user` -discord/state.py:551:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[VoiceChannel | StageChannel | ForumChannel | ... omitted 5 union elements, Guild | None]`, found `tuple[(Unknown & ~AlwaysFalsy) | (Guild & ~AlwaysTruthy & ~AlwaysFalsy) | (VoiceChannel & ~AlwaysFalsy) | ... omitted 6 union elements, Guild | None]` +discord/state.py:551:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[VoiceChannel | StageChannel | ForumChannel | ... omitted 5 union elements, Guild | None]`, found `tuple[(DMChannel & ~AlwaysFalsy) | (Guild & ~AlwaysTruthy & ~AlwaysFalsy) | (VoiceChannel & ~AlwaysFalsy) | ... omitted 6 union elements, Guild | None]` discord/state.py:822:31: error[invalid-key] Unknown key "data" for TypedDict `PingInteraction`: Unknown key "data" discord/state.py:823:36: error[invalid-key] Unknown key "custom_id" for TypedDict `ChatInputApplicationCommandInteractionData`: Unknown key "custom_id" discord/state.py:823:36: error[invalid-key] Unknown key "custom_id" for TypedDict `UserApplicationCommandInteractionData`: Unknown key "custom_id" @@ -403,4 +404,4 @@ discord/webhook/sync.py:522:9: error[invalid-method-override] Invalid override o discord/webhook/sync.py:652:16: error[unresolved-import] Cannot resolve imported module `requests` discord/webhook/sync.py:695:16: error[unresolved-import] Cannot resolve imported module `requests` discord/welcome_screen.py:104:33: warning[possibly-missing-attribute] Attribute `name` may be missing on object of type `(Unknown & _EmojiTag) | PartialEmoji | Emoji | (str & _EmojiTag)` -Found 405 diagnostics +Found 406 diagnostics diff --git a/scripts/ty_benchmark/snapshots/homeassistant_Pyrefly.txt b/scripts/ty_benchmark/snapshots/homeassistant_Pyrefly.txt index 1286eb4209..75d0ec9ddd 100644 --- a/scripts/ty_benchmark/snapshots/homeassistant_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/homeassistant_Pyrefly.txt @@ -159,8 +159,8 @@ ERROR homeassistant/components/accuweather/sensor.py:424:5-23: Class member `Acc ERROR homeassistant/components/accuweather/sensor.py:424:5-23: Class member `AccuWeatherSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/accuweather/sensor.py:476:5-23: Class member `AccuWeatherForecastSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/accuweather/sensor.py:476:5-23: Class member `AccuWeatherForecastSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/acmeda/config_flow.py:58:32-61: `dict[None, Hub]` is not assignable to attribute `discovered_hubs` with type `dict[str, Hub] | None` [bad-assignment] -ERROR homeassistant/components/acmeda/config_flow.py:74:46-52: Argument `None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] +ERROR homeassistant/components/acmeda/config_flow.py:58:32-61: `dict[Unknown | None, Hub]` is not assignable to attribute `discovered_hubs` with type `dict[str, Hub] | None` [bad-assignment] +ERROR homeassistant/components/acmeda/config_flow.py:74:46-52: Argument `Unknown | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] ERROR homeassistant/components/acmeda/cover.py:60:24-56: `-` is not supported between `Literal[100]` and `None` [unsupported-operation] ERROR homeassistant/components/acmeda/cover.py:71:24-56: `-` is not supported between `Literal[100]` and `None` [unsupported-operation] ERROR homeassistant/components/acmeda/hub.py:64:20-24: `None` is not assignable to attribute `api` with type `Hub` [bad-assignment] @@ -197,7 +197,7 @@ ERROR homeassistant/components/adax/sensor.py:34:9-12: Unexpected keyword argume ERROR homeassistant/components/adax/sensor.py:42:9-12: Unexpected keyword argument `key` in function `AdaxSensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/adax/sensor.py:75:5-23: Class member `AdaxSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/adax/sensor.py:75:5-23: Class member `AdaxSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/adguard/entity.py:63:25-70:14: Argument `set[tuple[str, str, int, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/adguard/entity.py:61:26-75:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, str, int, str]], manufacturer=Literal['AdGuard Team'], name=Literal['AdGuard Home'], sw_version=str, configuration_url=str) [no-matching-overload] ERROR homeassistant/components/adguard/sensor.py:34:9-12: Unexpected keyword argument `key` in function `AdGuardHomeEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/adguard/sensor.py:35:9-24: Unexpected keyword argument `translation_key` in function `AdGuardHomeEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/adguard/sensor.py:40:9-12: Unexpected keyword argument `key` in function `AdGuardHomeEntityDescription.__init__` [unexpected-keyword] @@ -262,7 +262,6 @@ ERROR homeassistant/components/advantage_air/switch.py:78:5-23: Class member `Ad ERROR homeassistant/components/advantage_air/switch.py:104:5-23: Class member `AdvantageAirNightMode._attr_device_class` overrides parent class `AdvantageAirAcEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/advantage_air/switch.py:128:5-23: Class member `AdvantageAirRelay._attr_device_class` overrides parent class `AdvantageAirThingEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/aemet/__init__.py:70:38-73:6: Unpacked argument `tuple[str]` is not assignable to parameter `*args` with type `tuple[StrOrBytesPath, bool, (((...) -> Any, str, tuple[type[BaseException], BaseException, TracebackType]) -> object) | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/aemet/config_flow.py:85:9-31: Class member `AemetConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/aemet/image.py:19:9-12: Unexpected keyword argument `key` in function `homeassistant.components.image.ImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/aemet/image.py:20:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.image.ImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/aemet/image.py:54:5-23: Class member `AemetImage.entity_description` overrides parent class `AemetEntity` in an inconsistent manner [bad-override] @@ -349,7 +348,7 @@ ERROR homeassistant/components/aemet/sensor.py:406:38-66: Argument `list[str] | ERROR homeassistant/components/aftership/sensor.py:56:19-44: Argument `Any | None` is not assignable to parameter `title` with type `str` in function `pyaftership.trackings.AfterShipTrackings.add` [bad-argument-type] ERROR homeassistant/components/aftership/sensor.py:57:18-42: Argument `Any | None` is not assignable to parameter `slug` with type `str` in function `pyaftership.trackings.AfterShipTrackings.add` [bad-argument-type] ERROR homeassistant/components/aftership/sensor.py:88:5-37: Class member `AfterShipSensor._attr_native_unit_of_measurement` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/agent_dvr/camera.py:85:25-51: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/agent_dvr/camera.py:84:44-90:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], manufacturer=Literal['Agent'], model=Literal['Camera'], name=str, sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/ai_task/entity.py:42:16-45: Returned type `int | None` is not assignable to declared return type `AITaskEntityFeature` [bad-return] ERROR homeassistant/components/airgradient/button.py:34:5-8: Unexpected keyword argument `key` in function `AirGradientButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airgradient/button.py:35:5-20: Unexpected keyword argument `translation_key` in function `AirGradientButtonEntityDescription.__init__` [unexpected-keyword] @@ -465,7 +464,6 @@ ERROR homeassistant/components/airly/sensor.py:151:9-12: Unexpected keyword argu ERROR homeassistant/components/airly/sensor.py:162:9-12: Unexpected keyword argument `key` in function `AirlySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airly/sensor.py:201:5-23: Class member `AirlySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/airly/sensor.py:201:5-23: Class member `AirlySensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/airnow/config_flow.py:127:9-31: Class member `AirNowConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/airnow/coordinator.py:44:5-17: Class member `AirNowDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/airnow/sensor.py:88:9-12: Unexpected keyword argument `key` in function `AirNowEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airnow/sensor.py:89:9-24: Unexpected keyword argument `translation_key` in function `AirNowEntityDescription.__init__` [unexpected-keyword] @@ -535,7 +533,6 @@ ERROR homeassistant/components/airos/sensor.py:159:9-40: Unexpected keyword argu ERROR homeassistant/components/airos/sensor.py:178:5-23: Class member `AirOSSensor.entity_description` overrides parent class `AirOSEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/airos/sensor.py:178:5-23: Class member `AirOSSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/airq/config_flow.py:87:50-69: Argument `str | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] -ERROR homeassistant/components/airq/config_flow.py:95:9-31: Class member `AirQConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/airq/coordinator.py:25:5-17: Class member `AirQCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/airq/number.py:31:5-8: Unexpected keyword argument `key` in function `AirQBrightnessDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airq/number.py:32:5-20: Unexpected keyword argument `translation_key` in function `AirQBrightnessDescription.__init__` [unexpected-keyword] @@ -678,7 +675,6 @@ ERROR homeassistant/components/airtouch4/climate.py:200:5-29: Class member `Airt ERROR homeassistant/components/airtouch5/__init__.py:48:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/airtouch5/cover.py:52:5-23: Class member `Airtouch5ZoneOpenPercentage._attr_device_class` overrides parent class `Airtouch5Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/airtouch5/cover.py:57:5-29: Class member `Airtouch5ZoneOpenPercentage._attr_supported_features` overrides parent class `Airtouch5Entity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/airvisual/config_flow.py:175:9-31: Class member `AirVisualFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/airvisual/sensor.py:45:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airvisual/sensor.py:46:9-13: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/airvisual/sensor.py:56:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -877,7 +873,6 @@ ERROR homeassistant/components/alarmdecoder/__init__.py:134:9-19: `controller` m ERROR homeassistant/components/alarmdecoder/__init__.py:139:11-21: `controller` may be uninitialized [unbound-name] ERROR homeassistant/components/alarmdecoder/alarm_control_panel.py:77:5-29: Class member `AlarmDecoderAlarmPanel._attr_supported_features` overrides parent class `AlarmDecoderEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/alarmdecoder/binary_sensor.py:101:14-32: Class member `AlarmDecoderBinarySensor._attr_device_class` overrides parent class `AlarmDecoderEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/alarmdecoder/config_flow.py:70:9-31: Class member `AlarmDecoderFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/alarmdecoder/config_flow.py:118:32-38: `device` may be uninitialized [unbound-name] ERROR homeassistant/components/alarmdecoder/config_flow.py:127:27-32: `title` may be uninitialized [unbound-name] ERROR homeassistant/components/alarmdecoder/config_flow.py:152:25-31: `schema` may be uninitialized [unbound-name] @@ -900,7 +895,6 @@ ERROR homeassistant/components/alexa/handlers.py:1546:49-75: No matching overloa ERROR homeassistant/components/alexa/handlers.py:1582:51-77: No matching overload found for function `max` called with arguments: (Literal[0], float | Unknown) [no-matching-overload] ERROR homeassistant/components/alexa/handlers.py:1654:49-75: No matching overload found for function `max` called with arguments: (Literal[0], float | Unknown) [no-matching-overload] ERROR homeassistant/components/alexa/logbook.py:43:38-47: `entity_id` may be uninitialized [unbound-name] -ERROR homeassistant/components/alexa/resources.py:307:37-41: `str | None` is not assignable to attribute `_unit_of_measure` with type `None` [bad-assignment] ERROR homeassistant/components/alexa_devices/binary_sensor.py:43:9-12: Unexpected keyword argument `key` in function `AmazonBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/alexa_devices/binary_sensor.py:45:9-24: Unexpected keyword argument `entity_category` in function `AmazonBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/alexa_devices/binary_sensor.py:49:9-12: Unexpected keyword argument `key` in function `AmazonBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -1418,7 +1412,6 @@ ERROR homeassistant/components/analytics/analytics.py:169:10-32: Function declar ERROR homeassistant/components/analytics/analytics.py:182:16-60: Returned type `ModuleType` is not assignable to declared return type `AnalyticsPlatformProtocol | None` [bad-return] ERROR homeassistant/components/analytics/analytics.py:445:33-48: `enabled_domains` may be uninitialized [unbound-name] ERROR homeassistant/components/analytics/analytics.py:450:35-50: `enabled_domains` may be uninitialized [unbound-name] -ERROR homeassistant/components/analytics_insights/config_flow.py:48:9-31: Class member `HomeassistantAnalyticsConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/analytics_insights/coordinator.py:46:5-17: Class member `HomeassistantAnalyticsDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/analytics_insights/sensor.py:37:9-12: Unexpected keyword argument `key` in function `AnalyticsSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/analytics_insights/sensor.py:38:9-24: Unexpected keyword argument `translation_key` in function `AnalyticsSensorEntityDescription.__init__` [unexpected-keyword] @@ -1521,11 +1514,9 @@ ERROR homeassistant/components/android_ip_webcam/switch.py:136:5-23: Class membe ERROR homeassistant/components/android_ip_webcam/switch.py:136:5-23: Class member `IPWebcamSettingSwitch.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv/__init__.py:224:15-29: Object of class `NoneType` has no attribute `adb_close` [missing-attribute] ERROR homeassistant/components/androidtv/__init__.py:244:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/androidtv/config_flow.py:190:9-31: Class member `AndroidTVFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv/media_player.py:72:5-23: Class member `ADBDevice._attr_device_class` overrides parent class `AndroidTVEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv/media_player.py:319:5-9: Class member `AndroidTVDevice.aftv` overrides parent class `ADBDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv/media_player.py:412:5-9: Class member `FireTVDevice.aftv` overrides parent class `ADBDevice` in an inconsistent manner [bad-override] -ERROR homeassistant/components/androidtv_remote/config_flow.py:249:9-31: Class member `AndroidTVRemoteConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv_remote/media_player.py:44:5-23: Class member `AndroidTVRemoteMediaPlayerEntity._attr_device_class` overrides parent class `AndroidTVRemoteBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv_remote/media_player.py:45:5-29: Class member `AndroidTVRemoteMediaPlayerEntity._attr_supported_features` overrides parent class `AndroidTVRemoteBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/androidtv_remote/remote.py:43:5-29: Class member `AndroidTVRemoteEntity._attr_supported_features` overrides parent class `AndroidTVRemoteBaseEntity` in an inconsistent manner [bad-override] @@ -1571,16 +1562,19 @@ ERROR homeassistant/components/anthemav/config_flow.py:75:38-56: Object of class ERROR homeassistant/components/anthemav/media_player.py:44:13-25: Argument `Protocol` is not assignable to parameter `avr` with type `AVR` in function `AnthemAVR.__init__` [bad-argument-type] ERROR homeassistant/components/anthemav/media_player.py:46:28-46: Object of class `Protocol` has no attribute `zones` [missing-attribute] ERROR homeassistant/components/anthropic/ai_task.py:60:16-44: Object of class `ToolResultContent` has no attribute `content` [missing-attribute] -ERROR homeassistant/components/anthropic/entity.py:184:29-189:22: Argument `bool | dict[str, Unknown] | float | int | list[Unknown] | str | WebSearchToolRequestErrorParam | None` is not assignable to parameter `content` with type `Iterable[WebSearchResultBlockParam] | WebSearchToolRequestErrorParam` in function `anthropic.types.web_search_tool_result_block_param.WebSearchToolResultBlockParam.__init__` [bad-argument-type] -ERROR homeassistant/components/anthropic/entity.py:210:54-77: Argument `Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str` is not assignable to parameter `text` with type `str` in function `anthropic.types.text_block_param.TextBlockParam.__init__` [bad-argument-type] -ERROR homeassistant/components/anthropic/entity.py:226:54-77: Argument `Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str` is not assignable to parameter `text` with type `str` in function `anthropic.types.text_block_param.TextBlockParam.__init__` [bad-argument-type] -ERROR homeassistant/components/anthropic/entity.py:258:58-81: Argument `Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str` is not assignable to parameter `text` with type `str` in function `anthropic.types.text_block_param.TextBlockParam.__init__` [bad-argument-type] +ERROR homeassistant/components/anthropic/entity.py:181:85-190:18: No matching overload found for function `anthropic.types.web_search_tool_result_block_param.WebSearchToolResultBlockParam.__init__` called with arguments: (type=Literal['web_search_tool_result'], tool_use_id=str, content=bool | dict[str, Unknown] | float | int | list[Unknown] | str | WebSearchToolRequestErrorParam | None) [no-matching-overload] +ERROR homeassistant/components/anthropic/entity.py:186:56-189:22: No matching overload found for function `anthropic.types.web_search_tool_request_error_param.WebSearchToolRequestErrorParam.__init__` called with arguments: (type=Literal['web_search_tool_result_error'], error_code=bool | dict[str, Unknown] | float | int | list[Unknown] | str | None) [no-matching-overload] +ERROR homeassistant/components/anthropic/entity.py:210:35-78: No matching overload found for function `anthropic.types.text_block_param.TextBlockParam.__init__` called with arguments: (type=Literal['text'], text=Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str) [no-matching-overload] +ERROR homeassistant/components/anthropic/entity.py:226:35-78: No matching overload found for function `anthropic.types.text_block_param.TextBlockParam.__init__` called with arguments: (type=Literal['text'], text=Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str) [no-matching-overload] +ERROR homeassistant/components/anthropic/entity.py:258:39-82: No matching overload found for function `anthropic.types.text_block_param.TextBlockParam.__init__` called with arguments: (type=Literal['text'], text=Iterable[RedactedThinkingBlock | ServerToolUseBlock | TextBlock | ThinkingBlock | ToolUseBlock | WebSearchToolResultBlock | DocumentBlockParam | ImageBlockParam | RedactedThinkingBlockParam | SearchResultBlockParam | ServerToolUseBlockParam | TextBlockParam | ThinkingBlockParam | ToolResultBlockParam | ToolUseBlockParam | WebSearchToolResultBlockParam] | str) [no-matching-overload] ERROR homeassistant/components/anthropic/entity.py:396:24-35: `first_block` is uninitialized [unbound-name] ERROR homeassistant/components/anthropic/entity.py:407:21-32: `first_block` is uninitialized [unbound-name] ERROR homeassistant/components/anthropic/entity.py:428:20-31: `first_block` is uninitialized [unbound-name] ERROR homeassistant/components/anthropic/entity.py:504:21-38: `current_tool_args` is uninitialized [unbound-name] ERROR homeassistant/components/anthropic/entity.py:526:40-57: `current_tool_args` is uninitialized [unbound-name] ERROR homeassistant/components/anthropic/entity.py:526:62-79: `current_tool_args` is uninitialized [unbound-name] +ERROR homeassistant/components/anthropic/entity.py:787:54-791:26: No matching overload found for function `anthropic.types.base64_image_source_param.Base64ImageSourceParam.__init__` called with arguments: (type=Literal['base64'], media_type=str, data=str) [no-matching-overload] +ERROR homeassistant/components/anthropic/entity.py:798:52-802:26: No matching overload found for function `anthropic.types.base64_pdf_source_param.Base64PDFSourceParam.__init__` called with arguments: (type=Literal['base64'], media_type=str, data=str) [no-matching-overload] ERROR homeassistant/components/aosmith/coordinator.py:39:5-17: Class member `AOSmithStatusCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/aosmith/coordinator.py:82:5-17: Class member `AOSmithEnergyCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/aosmith/sensor.py:35:9-12: Unexpected keyword argument `key` in function `AOSmithStatusSensorEntityDescription.__init__` [unexpected-keyword] @@ -1833,7 +1827,6 @@ ERROR homeassistant/components/apple_tv/config_flow.py:14:1-66: Could not find i ERROR homeassistant/components/apple_tv/config_flow.py:15:1-50: Could not find import of `pyatv.convert` [missing-import] ERROR homeassistant/components/apple_tv/config_flow.py:16:1-40: Could not find import of `pyatv.helpers` [missing-import] ERROR homeassistant/components/apple_tv/config_flow.py:17:1-55: Could not find import of `pyatv.interface` [missing-import] -ERROR homeassistant/components/apple_tv/config_flow.py:113:9-31: Class member `AppleTVConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/apple_tv/config_flow.py:141:31-55: Object of class `NoneType` has no attribute `all_identifiers` [missing-attribute] ERROR homeassistant/components/apple_tv/config_flow.py:144:16-35: Object of class `NoneType` has no attribute `identifier` [missing-attribute] ERROR homeassistant/components/apple_tv/config_flow.py:199:44-68: Object of class `NoneType` has no attribute `all_identifiers` [missing-attribute] @@ -2065,7 +2058,6 @@ ERROR homeassistant/components/aranet/sensor.py:122:9-24: Unexpected keyword arg ERROR homeassistant/components/aranet/sensor.py:125:9-12: Unexpected keyword argument `key` in function `AranetSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/aranet/sensor.py:131:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `AranetSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/aranet/sensor.py:132:9-24: Unexpected keyword argument `entity_category` in function `AranetSensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/aranet/sensor.py:149:35-37: Expected 0 positional arguments, got 1 in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-count] ERROR homeassistant/components/aranet/sensor.py:201:7-35: Field `entity_description` is declared `EntityDescription` in ancestor `class PassiveBluetoothProcessorEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/arest/sensor.py:172:39-53: Expected a callable, got `None` [not-callable] @@ -2134,15 +2126,10 @@ ERROR homeassistant/components/assist_pipeline/select.py:153:5-23: Class member ERROR homeassistant/components/assist_pipeline/select.py:154:9-12: Unexpected keyword argument `key` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/assist_pipeline/select.py:155:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/assist_pipeline/select.py:156:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/assist_satellite/__init__.py:124:69-88: Unpacked keyword argument `Any | None` is not assignable to parameter `preannounce` with type `bool` in function `homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.async_internal_ask_question` [bad-argument-type] -ERROR homeassistant/components/assist_satellite/__init__.py:124:69-88: Unpacked keyword argument `Any | None` is not assignable to parameter `preannounce_media_id` with type `str` in function `homeassistant.components.assist_satellite.entity.AssistSatelliteEntity.async_internal_ask_question` [bad-argument-type] ERROR homeassistant/components/assist_satellite/entity.py:129:5-23: Class member `AssistSatelliteEntity.entity_description` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/assist_satellite/websocket_api.py:60:38-73: Object of class `NoneType` has no attribute `async_intercept_wake_word` [missing-attribute] ERROR homeassistant/components/asuswrt/__init__.py:43:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/asuswrt/bridge.py:104:20-30: Expected a type form, got instance of `tuple[type[Exception], ...] | type[Exception]` [not-a-type] -ERROR homeassistant/components/asuswrt/config_flow.py:297:9-31: Class member `AsusWrtFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/asuswrt/diagnostics.py:65:9-59: Cannot set item in `list[Unknown]` [unsupported-operation] -ERROR homeassistant/components/asuswrt/diagnostics.py:76:9-49: Object of class `dict` has no attribute `append` [missing-attribute] ERROR homeassistant/components/asuswrt/helpers.py:41:16-20: Returned type `None` is not assignable to declared return type `T` [bad-return] ERROR homeassistant/components/asuswrt/helpers.py:44:16-70: Returned type `dict[str, Any]` is not assignable to declared return type `T` [bad-return] ERROR homeassistant/components/asuswrt/helpers.py:47:16-52:10: Returned type `list[str | Unknown]` is not assignable to declared return type `T` [bad-return] @@ -2280,13 +2267,9 @@ ERROR homeassistant/components/august/camera.py:76:49-61: Argument `DoorbellDeta ERROR homeassistant/components/august/camera.py:76:63-80: Argument `Activity` is not assignable to parameter `activity` with type `BridgeOperationActivity | DoorbellImageCaptureActivity | DoorbellMotionActivity` in function `yalexs.util.update_doorbell_image_from_activity` [bad-argument-type] ERROR homeassistant/components/august/camera.py:84:35-57: Object of class `LockDetail` has no attribute `image_url` [missing-attribute] ERROR homeassistant/components/august/camera.py:88:31-53: Object of class `LockDetail` has no attribute `image_url` [missing-attribute] -ERROR homeassistant/components/august/data.py:29:36-37:14: Missing argument `address` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/august/data.py:29:36-37:14: Missing argument `serial` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/august/data.py:29:36-37:14: Missing argument `key` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/august/data.py:29:36-37:14: Missing argument `slot` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/august/data.py:30:17-36:18: Expected argument `name` to be passed by name in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [unexpected-positional-argument] +ERROR homeassistant/components/august/data.py:29:36-37:14: No matching overload found for function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` called with arguments: (dict[str, int | str | Unknown | None]) [no-matching-overload] ERROR homeassistant/components/august/data.py:47:42-60: Argument `type[HomeAssistantError]` is not assignable to parameter `error_exception_class` with type `Exception` in function `yalexs.manager.data.YaleXSData.__init__` [bad-argument-type] -ERROR homeassistant/components/august/entity.py:43:19-31: Argument `int | str | Unknown | None` is not assignable to parameter `model` with type `str | None` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/august/entity.py:40:44-48:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | Unknown]], manufacturer=Literal['August Home Inc.'], model=int | str | Unknown | None, name=str | Unknown, sw_version=Unknown, suggested_area=str, configuration_url=str) [no-matching-overload] ERROR homeassistant/components/august/entity.py:59:21-40: Object of class `DoorbellDetail` has no attribute `bridge` [missing-attribute] ERROR homeassistant/components/august/entity.py:59:45-77: Object of class `object` has no attribute `hyper_bridge` [missing-attribute] ERROR homeassistant/components/august/event.py:39:9-12: Unexpected keyword argument `key` in function `AugustEventEntityDescription.__init__` [unexpected-keyword] @@ -2327,7 +2310,6 @@ ERROR homeassistant/components/august/sensor.py:205:5-23: Class member `AugustBa ERROR homeassistant/components/august/sensor.py:206:5-23: Class member `AugustBatterySensor._attr_device_class` overrides parent class `AugustDescriptionEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/august/sensor.py:212:68-80: Argument `DoorbellDetail | LockDetail` is not assignable to parameter with type `T` [bad-argument-type] ERROR homeassistant/components/august/util.py:38:12-17: Returned type `Literal[False]` is not assignable to declared return type `Activity | None` [bad-return] -ERROR homeassistant/components/aurora/config_flow.py:44:9-31: Class member `AuroraConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/aurora/coordinator.py:27:5-17: Class member `AuroraDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/aurora_abb_powerone/config_flow.py:53:12-33: Object of class `Serial` has no attribute `isOpen` [missing-attribute] ERROR homeassistant/components/aurora_abb_powerone/coordinator.py:24:5-17: Class member `AuroraAbbDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -2433,7 +2415,7 @@ ERROR homeassistant/components/autarco/sensor.py:247:5-23: Class member `Autarco ERROR homeassistant/components/autarco/sensor.py:281:5-23: Class member `AutarcoInverterSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/autarco/sensor.py:281:5-23: Class member `AutarcoInverterSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/auth/__init__.py:679:34-55: `current_refresh_token` may be uninitialized [unbound-name] -ERROR homeassistant/components/auth/login_flow.py:276:30-63: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/auth/login_flow.py:276:30-63: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/components/auth/login_flow.py:333:36-58: `tuple[@_, ...]` is not assignable to `tuple[str, str]` [bad-assignment] ERROR homeassistant/components/automation/__init__.py:170:71-75: Function declared to return `bool` but is missing an explicit `return` [bad-return] ERROR homeassistant/components/automation/reproduce_state.py:56:17-24: `service` may be uninitialized [unbound-name] @@ -2468,9 +2450,6 @@ ERROR homeassistant/components/aws/__init__.py:97:30-34: `conf` may be uninitial ERROR homeassistant/components/aws/__init__.py:102:76-80: `conf` may be uninitialized [unbound-name] ERROR homeassistant/components/aws_s3/__init__.py:67:26-32: `client` may be uninitialized [unbound-name] ERROR homeassistant/components/aws_s3/backup.py:104:15-36: Class member `S3BackupAgent.async_download_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/aws_s3/backup.py:252:15-34: Class member `S3BackupAgent.async_delete_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/aws_s3/backup.py:272:15-33: Class member `S3BackupAgent.async_list_backups` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/aws_s3/backup.py:278:15-31: Class member `S3BackupAgent.async_get_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] ERROR homeassistant/components/axis/binary_sensor.py:115:9-12: Unexpected keyword argument `key` in function `AxisBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/axis/binary_sensor.py:122:9-12: Unexpected keyword argument `key` in function `AxisBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/axis/binary_sensor.py:127:9-12: Unexpected keyword argument `key` in function `AxisBinarySensorDescription.__init__` [unexpected-keyword] @@ -2484,7 +2463,6 @@ ERROR homeassistant/components/axis/binary_sensor.py:192:5-23: Class member `Axi ERROR homeassistant/components/axis/binary_sensor.py:192:5-23: Class member `AxisBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/axis/camera.py:40:5-29: Class member `AxisCamera._attr_supported_features` overrides parent class `AxisEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/axis/camera.py:42:5-21: Class member `AxisCamera._still_image_url` overrides parent class `MjpegCamera` in an inconsistent manner [bad-override] -ERROR homeassistant/components/axis/config_flow.py:68:9-31: Class member `AxisFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/axis/entity.py:88:5-23: Class member `AxisEventEntity.entity_description` overrides parent class `AxisEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/axis/light.py:38:9-12: Unexpected keyword argument `key` in function `AxisLightDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/axis/light.py:60:5-23: Class member `AxisLight.entity_description` overrides parent class `AxisEventEntity` in an inconsistent manner [bad-override] @@ -2498,7 +2476,7 @@ ERROR homeassistant/components/azure_devops/config_flow.py:54:51-69: Argument `s ERROR homeassistant/components/azure_devops/config_flow.py:58:53-71: Argument `str | None` is not assignable to parameter `organization` with type `str` in function `aioazuredevops.client.DevOpsClient.get_project` [bad-argument-type] ERROR homeassistant/components/azure_devops/config_flow.py:58:73-86: Argument `str | None` is not assignable to parameter `project` with type `str` in function `aioazuredevops.client.DevOpsClient.get_project` [bad-argument-type] ERROR homeassistant/components/azure_devops/coordinator.py:55:5-17: Class member `AzureDevOpsDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/azure_devops/entity.py:23:25-25:14: Argument `set[tuple[str, str, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/azure_devops/entity.py:21:44-28:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, str, str]], manufacturer=str, name=str) [no-matching-overload] ERROR homeassistant/components/azure_devops/sensor.py:48:9-12: Unexpected keyword argument `key` in function `AzureDevOpsBuildSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/azure_devops/sensor.py:49:9-24: Unexpected keyword argument `translation_key` in function `AzureDevOpsBuildSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/azure_devops/sensor.py:67:9-12: Unexpected keyword argument `key` in function `AzureDevOpsBuildSensorEntityDescription.__init__` [unexpected-keyword] @@ -2537,7 +2515,6 @@ ERROR homeassistant/components/azure_devops/sensor.py:198:16-46: Object of class ERROR homeassistant/components/azure_devops/sensor.py:202:32-58: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR homeassistant/components/azure_devops/sensor.py:224:5-23: Class member `AzureDevOpsWorkItemSensor.entity_description` overrides parent class `AzureDevOpsEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/azure_devops/sensor.py:224:5-23: Class member `AzureDevOpsWorkItemSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/azure_event_hub/config_flow.py:95:9-31: Class member `AEHConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/azure_service_bus/notify.py:8:1-47: Could not find import of `azure.servicebus` [missing-import] ERROR homeassistant/components/azure_service_bus/notify.py:9:1-68: Could not find import of `azure.servicebus.aio` [missing-import] ERROR homeassistant/components/azure_service_bus/notify.py:10:1-14:2: Could not find import of `azure.servicebus.exceptions` [missing-import] @@ -2545,10 +2522,6 @@ ERROR homeassistant/components/azure_storage/backup.py:114:15-36: Class member ` ERROR homeassistant/components/backblaze_b2/__init__.py:51:16-66: Returned type `b2sdk._internal.bucket.Bucket` is not assignable to declared return type `b2sdk.v2.bucket.Bucket` [bad-return] ERROR homeassistant/components/backblaze_b2/backup.py:193:15-36: Class member `BackblazeBackupAgent.async_download_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] ERROR homeassistant/components/backblaze_b2/backup.py:208:68-210:22: Unpacked argument `tuple[Iterator[Any], None]` is not assignable to parameter `*args` with type `tuple[SupportsNext[@_]]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/backblaze_b2/backup.py:220:15-34: Class member `BackblazeBackupAgent.async_upload_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/backblaze_b2/backup.py:345:15-34: Class member `BackblazeBackupAgent.async_delete_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/backblaze_b2/backup.py:373:15-33: Class member `BackblazeBackupAgent.async_list_backups` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/backblaze_b2/backup.py:411:15-31: Class member `BackblazeBackupAgent.async_get_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] ERROR homeassistant/components/backup/agent.py:37:15-36: Abstract methods for async generators should use `def`, not `async def` [bad-function-definition] ERROR homeassistant/components/backup/agent.py:116:10-27: Function declared to return `list[BackupAgent]` but is missing an explicit `return` [bad-return] ERROR homeassistant/components/backup/agent.py:126:10-28: Function declared to return `() -> None` but is missing an explicit `return` [bad-return] @@ -2596,7 +2569,7 @@ ERROR homeassistant/components/baf/binary_sensor.py:34:9-12: Unexpected keyword ERROR homeassistant/components/baf/binary_sensor.py:57:5-23: Class member `BAFBinarySensor.entity_description` overrides parent class `BAFDescriptionEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/baf/binary_sensor.py:57:5-23: Class member `BAFBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/baf/climate.py:35:5-29: Class member `BAFAutoComfort._attr_supported_features` overrides parent class `BAFEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/baf/entity.py:24:25-80: Argument `set[tuple[str, str | None]]` is not assignable to parameter `connections` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/baf/entity.py:23:44-29:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (connections=set[tuple[str, str | None]], name=str, manufacturer=Literal['Big Ass Fans'], model=str | None, sw_version=str | None) [no-matching-overload] ERROR homeassistant/components/baf/fan.py:42:5-29: Class member `BAFFan._attr_supported_features` overrides parent class `BAFEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/baf/number.py:34:9-12: Unexpected keyword argument `key` in function `BAFNumberDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/baf/number.py:35:9-24: Unexpected keyword argument `translation_key` in function `BAFNumberDescription.__init__` [unexpected-keyword] @@ -2702,7 +2675,6 @@ ERROR homeassistant/components/balboa/binary_sensor.py:61:5-20: Unexpected keywo ERROR homeassistant/components/balboa/binary_sensor.py:70:5-23: Class member `BalboaBinarySensorEntity.entity_description` overrides parent class `BalboaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/balboa/binary_sensor.py:70:5-23: Class member `BalboaBinarySensorEntity.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/balboa/climate.py:60:5-29: Class member `BalboaClimateEntity._attr_supported_features` overrides parent class `BalboaEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/balboa/config_flow.py:64:9-31: Class member `BalboaSpaClientFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/balboa/config_flow.py:86:27-31: `info` may be uninitialized [unbound-name] ERROR homeassistant/components/balboa/fan.py:36:5-29: Class member `BalboaPumpFanEntity._attr_supported_features` overrides parent class `BalboaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/balboa/fan.py:84:66-85: Argument `IntEnum` is not assignable to parameter `value` with type `float` in function `homeassistant.util.percentage.ranged_value_to_percentage` [bad-argument-type] @@ -2865,8 +2837,8 @@ ERROR homeassistant/components/blebox/switch.py:34:5-23: Class member `BleBoxSwi ERROR homeassistant/components/blink/alarm_control_panel.py:47:5-29: Class member `BlinkSyncModuleHA._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/blink/alarm_control_panel.py:59:14-29: Class member `BlinkSyncModuleHA._attr_unique_id` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/blink/alarm_control_panel.py:59:14-29: Class member `BlinkSyncModuleHA._attr_unique_id` overrides parent class `AlarmControlPanelEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/blink/alarm_control_panel.py:59:37-48: `None` is not assignable to attribute `_attr_unique_id` with type `str` [bad-assignment] -ERROR homeassistant/components/blink/alarm_control_panel.py:61:25-48: Argument `set[tuple[str, None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/blink/alarm_control_panel.py:59:37-48: `Unknown | None` is not assignable to attribute `_attr_unique_id` with type `str` [bad-assignment] +ERROR homeassistant/components/blink/alarm_control_panel.py:60:44-66:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Unknown | None]], name=str, manufacturer=Literal['Blink'], serial_number=Unknown | None, sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/blink/binary_sensor.py:31:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/blink/binary_sensor.py:33:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/blink/binary_sensor.py:37:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -2874,9 +2846,7 @@ ERROR homeassistant/components/blink/binary_sensor.py:38:9-24: Unexpected keywor ERROR homeassistant/components/blink/binary_sensor.py:39:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/blink/binary_sensor.py:42:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/blink/binary_sensor.py:78:14-32: Class member `BlinkBinarySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/blink/camera.py:89:25-50: Argument `set[tuple[str, None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/blink/camera.py:116:39-43: `Literal[True]` is not assignable to attribute `motion_enabled` with type `None` [bad-assignment] -ERROR homeassistant/components/blink/camera.py:132:39-44: `Literal[False]` is not assignable to attribute `motion_enabled` with type `None` [bad-assignment] +ERROR homeassistant/components/blink/camera.py:88:44-95:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Unknown | None]], serial_number=Unknown | None, sw_version=Unknown, name=Unknown, manufacturer=Literal['Blink'], model=str) [no-matching-overload] ERROR homeassistant/components/blink/config_flow.py:103:43-53: Argument `Blink | None` is not assignable to parameter `blink` with type `Blink` in function `_send_blink_2fa_pin` [bad-argument-type] ERROR homeassistant/components/blink/coordinator.py:33:5-17: Class member `BlinkUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/blink/sensor.py:30:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -2998,21 +2968,16 @@ ERROR homeassistant/components/bluesound/media_player.py:628:25-40: No matching ERROR homeassistant/components/bluesound/media_player.py:637:25-40: No matching overload found for function `max` called with arguments: (Literal[0], float) [no-matching-overload] ERROR homeassistant/components/bluesound/media_player.py:646:41-47: Argument `float` is not assignable to parameter `level` with type `int | None` in function `pyblu.player.Player.volume` [bad-argument-type] ERROR homeassistant/components/bluetooth/__init__.py:199:13-31: Argument `HassJob[[now: datetime], Coroutine[Unknown, Unknown, None]]` is not assignable to parameter `action` with type `((datetime) -> Coroutine[Any, Any, None] | None) | HassJob[[datetime], Coroutine[Any, Any, None] | None]` in function `homeassistant.helpers.event.async_call_later` [bad-argument-type] -ERROR homeassistant/components/bluetooth/config_flow.py:222:9-31: Class member `BluetoothConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/bluetooth/manager.py:215:36-45: No matching overload found for function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcherWithCallback.update` called with arguments: (BluetoothCallbackMatcher) [no-matching-overload] -ERROR homeassistant/components/bluetooth/match.py:202:54-73: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:209:34-58: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:213:31-52: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:217:36-62: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:229:54-73: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:235:34-58: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:239:31-52: `_T` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/bluetooth/match.py:243:36-62: `_T` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/bluetooth/match.py:202:54-73: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:209:34-58: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:213:31-52: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:217:36-62: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:229:54-73: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:235:34-58: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:239:31-52: Cannot index into `_T` [bad-index] +ERROR homeassistant/components/bluetooth/match.py:243:36-62: Cannot index into `_T` [bad-index] ERROR homeassistant/components/bluetooth/match.py:299:37-50: `matched_uuids` may be uninitialized [unbound-name] -ERROR homeassistant/components/bluetooth/passive_update_processor.py:310:32-53: `str` is not assignable to attribute `restore_key` with type `None` [bad-assignment] -ERROR homeassistant/components/bluetooth/passive_update_processor.py:655:43-45: Expected 0 positional arguments, got 1 in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-count] -ERROR homeassistant/components/bluetooth/passive_update_processor.py:658:17-73: Expected 0 positional arguments, got 1 in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-count] -ERROR homeassistant/components/bluetooth/passive_update_processor.py:663:17-56: Expected 0 positional arguments, got 1 in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-count] ERROR homeassistant/components/bmw_connected_drive/binary_sensor.py:126:9-12: Unexpected keyword argument `key` in function `BMWBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/bmw_connected_drive/binary_sensor.py:127:9-24: Unexpected keyword argument `translation_key` in function `BMWBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/bmw_connected_drive/binary_sensor.py:136:9-12: Unexpected keyword argument `key` in function `BMWBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -3043,7 +3008,6 @@ ERROR homeassistant/components/bmw_connected_drive/button.py:62:9-12: Unexpected ERROR homeassistant/components/bmw_connected_drive/button.py:63:9-24: Unexpected keyword argument `translation_key` in function `BMWButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/bmw_connected_drive/button.py:95:5-23: Class member `BMWButton.entity_description` overrides parent class `BMWBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/bmw_connected_drive/button.py:95:5-23: Class member `BMWButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/bmw_connected_drive/config_flow.py:223:9-31: Class member `BMWConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/bmw_connected_drive/coordinator.py:37:5-17: Class member `BMWDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/bmw_connected_drive/number.py:42:9-12: Unexpected keyword argument `key` in function `BMWNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/bmw_connected_drive/number.py:43:9-24: Unexpected keyword argument `translation_key` in function `BMWNumberEntityDescription.__init__` [unexpected-keyword] @@ -3190,6 +3154,7 @@ ERROR homeassistant/components/bond/button.py:296:5-23: Class member `BondButton ERROR homeassistant/components/bond/button.py:296:5-23: Class member `BondButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/bond/cover.py:51:5-23: Class member `BondCover._attr_device_class` overrides parent class `BondEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/bond/cover.py:72:14-38: Class member `BondCover._attr_supported_features` overrides parent class `BondEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/bond/entity.py:80:33-85:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (manufacturer=str, identifiers=set[tuple[str, str | None, str]], configuration_url=str) [no-matching-overload] ERROR homeassistant/components/bond/entity.py:192:13-53: Argument `HassJob[[now: datetime], None]` is not assignable to parameter `action` with type `((datetime) -> Coroutine[Any, Any, None] | None) | HassJob[[datetime], Coroutine[Any, Any, None] | None]` in function `homeassistant.helpers.event.async_call_later` [bad-argument-type] ERROR homeassistant/components/bond/fan.py:79:14-38: Class member `BondFan._attr_supported_features` overrides parent class `BondEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/bosch_alarm/__init__.py:84:12-21: `unload_ok` may be uninitialized [unbound-name] @@ -3500,6 +3465,7 @@ ERROR homeassistant/components/brottsplatskartan/sensor.py:69:13-52: `bool | lis ERROR homeassistant/components/brunt/coordinator.py:29:5-17: Class member `BruntCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/brunt/cover.py:56:5-23: Class member `BruntDevice._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/brunt/cover.py:58:5-29: Class member `BruntDevice._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/brunt/cover.py:79:44-86:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=str, via_device=tuple[Literal['brunt'], str], manufacturer=Literal['Brunt'], sw_version=str, model=str) [no-matching-overload] ERROR homeassistant/components/brunt/cover.py:159:37-58: Argument `str | None` is not assignable to parameter `thing_uri` with type `str` in function `brunt.client.BruntClientAsync.async_change_request_position` [bad-argument-type] ERROR homeassistant/components/brunt/cover.py:173:63-84: Cannot index into `dict[str, int]` [bad-index] ERROR homeassistant/components/bryant_evolution/__init__.py:73:32-41: Cannot set item in `dict[tuple[int, int], BryantEvolutionLocalClient]` [unsupported-operation] @@ -3617,7 +3583,6 @@ ERROR homeassistant/components/bthome/sensor.py:462:7-34: Field `entity_descript `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/buienradar/__init__.py:33:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/buienradar/camera.py:133:63-76: `last_modified` may be uninitialized [unbound-name] -ERROR homeassistant/components/buienradar/config_flow.py:81:9-31: Class member `BuienradarFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/buienradar/sensor.py:76:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/buienradar/sensor.py:77:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/buienradar/sensor.py:81:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -3911,7 +3876,6 @@ ERROR homeassistant/components/canary/camera.py:173:17-30: Argument `asyncio.str ERROR homeassistant/components/canary/sensor.py:126:14-32: Class member `CanarySensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/cast/__init__.py:39:10-27: Function declared to return `list[BrowseMedia]` but is missing an explicit `return` [bad-return] ERROR homeassistant/components/cast/__init__.py:62:10-14: Function declared to return `bool` but is missing an explicit `return` [bad-return] -ERROR homeassistant/components/cast/config_flow.py:44:9-31: Class member `FlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/cast/discovery.py:64:13-21: Class member `CastListener.add_cast` overrides parent class `AbstractCastListener` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/cast/discovery.py:68:13-24: Class member `CastListener.update_cast` overrides parent class `AbstractCastListener` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/cast/helpers.py:132:13-29: Unexpected keyword argument `is_dynamic_group` in function `ChromecastInfo.__init__` [unexpected-keyword] @@ -3919,7 +3883,6 @@ ERROR homeassistant/components/cast/helpers.py:268:12-37: Module `aiohttp.client ERROR homeassistant/components/cast/media_player.py:234:60-238:10: Unpacked argument `tuple[CastInfo, HaZeroconf | None]` is not assignable to parameter `*args` with type `tuple[CastInfo, Zeroconf | None, int | None, float | None, float | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/cast/media_player.py:353:28-51: Object of class `NoneType` has no attribute `status` [missing-attribute] ERROR homeassistant/components/cast/media_player.py:354:29-62: Object of class `NoneType` has no attribute `media_controller` [missing-attribute] -ERROR homeassistant/components/cast/media_player.py:418:38-54: `datetime` is not assignable to attribute `media_status_received` with type `None` [bad-assignment] ERROR homeassistant/components/cast/media_player.py:460:35-72: Object of class `NoneType` has no attribute `get_multizone_memberships` [missing-attribute] ERROR homeassistant/components/cast/media_player.py:463:46-87: Object of class `NoneType` has no attribute `get_multizone_mediacontroller` [missing-attribute] ERROR homeassistant/components/cast/media_player.py:493:28-61: Object of class `NoneType` has no attribute `media_controller` [missing-attribute] @@ -3938,7 +3901,6 @@ ERROR homeassistant/components/chacon_dio/cover.py:42:5-23: Class member `Chacon ERROR homeassistant/components/chacon_dio/cover.py:45:5-29: Class member `ChaconDioCover._attr_supported_features` overrides parent class `ChaconDioEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/chacon_dio/switch.py:38:5-23: Class member `ChaconDioSwitch._attr_device_class` overrides parent class `ChaconDioEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/channels/media_player.py:7:1-32: Could not find import of `pychannels` [missing-import] -ERROR homeassistant/components/channels/media_player.py:208:23-32: `Literal['stopped']` is not assignable to attribute `status` with type `None` [bad-assignment] ERROR homeassistant/components/cisco_ios/device_tracker.py:71:33-35: `list[@_]` is not assignable to attribute `last_results` with type `dict[Unknown, Unknown]` [bad-assignment] ERROR homeassistant/components/cisco_ios/device_tracker.py:98:33-45: `list[@_]` is not assignable to attribute `last_results` with type `dict[Unknown, Unknown]` [bad-assignment] ERROR homeassistant/components/cisco_mobility_express/device_tracker.py:7:1-62: Could not find import of `ciscomobilityexpress.ciscome` [missing-import] @@ -3973,7 +3935,6 @@ ERROR homeassistant/components/co2signal/sensor.py:46:9-12: Unexpected keyword a ERROR homeassistant/components/co2signal/sensor.py:47:9-24: Unexpected keyword argument `translation_key` in function `CO2SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/co2signal/sensor.py:69:5-23: Class member `CO2Sensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/co2signal/sensor.py:69:5-23: Class member `CO2Sensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/coinbase/config_flow.py:206:9-31: Class member `CoinbaseConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/coinbase/sensor.py:57:24-41: Type `None` is not iterable [not-iterable] ERROR homeassistant/components/coinbase/sensor.py:66:35-80: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/coinbase/sensor.py:128:24-46: Type `None` is not iterable [not-iterable] @@ -4010,7 +3971,6 @@ ERROR homeassistant/components/comelit/sensor.py:164:14-32: Class member `Comeli WARN homeassistant/components/comelit/sensor.py:182:20-39: Redundant cast: `str` is the same type as `str` [redundant-cast] ERROR homeassistant/components/comelit/switch.py:63:18-36: Class member `ComelitSwitchEntity._attr_device_class` overrides parent class `ComelitBridgeBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/comfoconnect/__init__.py:104:26-41: Object of class `str` has no attribute `hex` [missing-attribute] -ERROR homeassistant/components/comfoconnect/__init__.py:112:45-65: `BoundMethod[Self@ComfoConnectBridge, (self: Self@ComfoConnectBridge, var: str, value: str) -> None]` is not assignable to attribute `callback_sensor` with type `None` [bad-assignment] ERROR homeassistant/components/comfoconnect/fan.py:99:47-101:10: Unpacked argument `tuple[Literal[65]]` is not assignable to parameter `*args` with type `tuple[int, int]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/comfoconnect/fan.py:102:47-104:10: Unpacked argument `tuple[Literal[49]]` is not assignable to parameter `*args` with type `tuple[int, int]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/comfoconnect/sensor.py:93:9-12: Unexpected keyword argument `key` in function `ComfoconnectSensorEntityDescription.__init__` [unexpected-keyword] @@ -4080,14 +4040,14 @@ ERROR homeassistant/components/concord232/binary_sensor.py:68:9-21: Object of cl ERROR homeassistant/components/concord232/binary_sensor.py:69:9-32: Object of class `Client` has no attribute `last_zone_update` [missing-attribute] ERROR homeassistant/components/concord232/binary_sensor.py:80:5-17: Object of class `Client` has no attribute `zones` [missing-attribute] ERROR homeassistant/components/concord232/binary_sensor.py:82:17-29: Object of class `Client` has no attribute `zones` [missing-attribute] -ERROR homeassistant/components/config/config_entries.py:365:16-40: `_FlowContextT` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/config/config_entries.py:418:16-40: `_FlowContextT` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/config/config_entries.py:428:16-40: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/config/config_entries.py:365:16-40: Cannot index into `_FlowContextT` [bad-index] +ERROR homeassistant/components/config/config_entries.py:418:16-40: Cannot index into `_FlowContextT` [bad-index] +ERROR homeassistant/components/config/config_entries.py:428:16-40: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/components/config/config_entries.py:469:12-17: `entry` may be uninitialized [unbound-name] ERROR homeassistant/components/config/config_entries.py:565:30-41: `disabled_by` may be uninitialized [unbound-name] -ERROR homeassistant/components/config/config_entries.py:611:36-68: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/config/config_entries.py:611:36-68: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/components/config/config_entries.py:613:9-24: Argument `_HandlerT` is not assignable to parameter `handler` with type `str` in function `homeassistant.config_entries.ConfigEntriesFlowManager.async_init` [bad-argument-type] -ERROR homeassistant/components/config/config_entries.py:615:28-56: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/config/config_entries.py:615:28-56: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/components/config/entity_registry.py:264:68-77: Unpacked keyword argument `set[Unknown]` is not assignable to parameter `area_id` with type `UndefinedType | str | None` in function `homeassistant.helpers.entity_registry.EntityRegistry.async_update_entity` [bad-argument-type] ERROR homeassistant/components/config/entity_registry.py:264:68-77: Unpacked keyword argument `set[Unknown]` is not assignable to parameter `categories` with type `UndefinedType | dict[str, str]` in function `homeassistant.helpers.entity_registry.EntityRegistry.async_update_entity` [bad-argument-type] ERROR homeassistant/components/config/entity_registry.py:264:68-77: Unpacked keyword argument `set[Unknown]` is not assignable to parameter `capabilities` with type `Mapping[str, Any] | UndefinedType | None` in function `homeassistant.helpers.entity_registry.EntityRegistry.async_update_entity` [bad-argument-type] @@ -4116,8 +4076,7 @@ ERROR homeassistant/components/configurator/__init__.py:84:18-26: `instance` may ERROR homeassistant/components/configurator/__init__.py:91:39-47: `instance` may be uninitialized [unbound-name] ERROR homeassistant/components/control4/climate.py:155:5-29: Class member `Control4Climate._attr_supported_features` overrides parent class `Control4Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/control4/config_flow.py:133:24-50: Object of class `NoneType` has no attribute `split` [missing-attribute] -ERROR homeassistant/components/control4/config_flow.py:138:27-47: Argument `None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] -ERROR homeassistant/components/control4/config_flow.py:153:9-31: Class member `Control4ConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] +ERROR homeassistant/components/control4/config_flow.py:138:27-47: Argument `Unknown | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] ERROR homeassistant/components/control4/media_player.py:212:14-38: Class member `Control4Room._attr_supported_features` overrides parent class `Control4Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/conversation/chat_log.py:55:9-29: Object of class `NoneType` has no attribute `remove` [missing-attribute] ERROR homeassistant/components/conversation/chat_log.py:93:16-31: Object of class `ToolResultContent` has no attribute `content` [missing-attribute] @@ -4166,13 +4125,11 @@ ERROR homeassistant/components/cover/device_trigger.py:174:47-55: `position` may ERROR homeassistant/components/cppm_tracker/device_tracker.py:8:1-34: Could not find import of `clearpasspy` [missing-import] ERROR homeassistant/components/cppm_tracker/device_tracker.py:65:45-57: Type `None` is not iterable [not-iterable] ERROR homeassistant/components/cppm_tracker/device_tracker.py:70:43-55: Type `None` is not iterable [not-iterable] -ERROR homeassistant/components/cppm_tracker/device_tracker.py:84:24-31: `list[Unknown]` is not assignable to attribute `results` with type `None` [bad-assignment] -ERROR homeassistant/components/crownstone/config_flow.py:142:9-31: Class member `CrownstoneConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/crownstone/config_flow.py:238:60-70: Cannot index into `dict[str, Sphere]` [bad-index] ERROR homeassistant/components/crownstone/entry_manager.py:110:20-30: Cannot use `CrownstoneSSEAsync` as a context manager [bad-context-manager] ERROR homeassistant/components/crownstone/entry_manager.py:110:20-30: Cannot use `CrownstoneSSEAsync` as a context manager [bad-context-manager] ERROR homeassistant/components/crownstone/light.py:95:12-65: Object of class `NoneType` has no attribute `is_enabled` [missing-attribute] -ERROR homeassistant/components/crownstone/listeners.py:106:13-30: Argument `None` is not assignable to parameter `crownstone_uid` with type `int` in function `crownstone_cloud.cloud.CrownstoneCloud.get_crownstone_by_uid` [bad-argument-type] +ERROR homeassistant/components/crownstone/listeners.py:106:13-30: Argument `Unknown | None` is not assignable to parameter `crownstone_uid` with type `int` in function `crownstone_cloud.cloud.CrownstoneCloud.get_crownstone_by_uid` [bad-argument-type] ERROR homeassistant/components/cync/config_flow.py:43:23-27: `None` is not assignable to `Auth` [bad-assignment] ERROR homeassistant/components/cync/config_flow.py:126:40-76: Argument `Any | None` is not assignable to parameter `two_factor_code` with type `str` in function `pycync.auth.Auth.login` [bad-argument-type] ERROR homeassistant/components/cync/coordinator.py:28:5-17: Class member `CyncCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -4253,7 +4210,6 @@ ERROR homeassistant/components/deconz/climate.py:123:14-38: Class member `Deconz ERROR homeassistant/components/deconz/climate.py:143:39-60: Cannot index into `dict[ThermostatFanMode, str]` [bad-index] ERROR homeassistant/components/deconz/climate.py:162:46-63: Cannot index into `dict[ThermostatMode, HVACMode]` [bad-index] ERROR homeassistant/components/deconz/climate.py:200:42-61: Cannot index into `dict[ThermostatPreset, str]` [bad-index] -ERROR homeassistant/components/deconz/config_flow.py:68:9-31: Class member `DeconzFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/deconz/cover.py:63:14-38: Class member `DeconzCover._attr_supported_features` overrides parent class `DeconzDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/deconz/cover.py:78:14-32: Class member `DeconzCover._attr_device_class` overrides parent class `DeconzDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/deconz/deconz_event.py:86:36-45: `new_event` may be uninitialized [unbound-name] @@ -4332,12 +4288,10 @@ ERROR homeassistant/components/deluge/sensor.py:120:9-12: Unexpected keyword arg ERROR homeassistant/components/deluge/sensor.py:121:9-24: Unexpected keyword argument `translation_key` in function `DelugeSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/deluge/sensor.py:142:5-23: Class member `DelugeSensor.entity_description` overrides parent class `DelugeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/deluge/sensor.py:142:5-23: Class member `DelugeSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/demo/config_flow.py:34:9-31: Class member `DemoConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/demo/media_player.py:290:14-33: Class member `DemoMusicPlayer._attr_group_members` overrides parent class `AbstractDemoPlayer` in an inconsistent manner [bad-override] ERROR homeassistant/components/demo/sensor.py:182:5-23: Class member `DemoSumSensor._attr_native_value` overrides parent class `RestoreSensor` in an inconsistent manner [bad-override] ERROR homeassistant/components/denon/media_player.py:208:31-42: `str | None` is not assignable to attribute `_mediainfo` with type `str` [bad-assignment] ERROR homeassistant/components/denonavr/__init__.py:56:26-34: `DenonAVR | None` is not assignable to attribute `runtime_data` with type `DenonAVR` [bad-assignment] -ERROR homeassistant/components/denonavr/config_flow.py:120:9-31: Class member `DenonAvrFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/denonavr/config_flow.py:212:31-60: Object of class `NoneType` has no attribute `replace` [missing-attribute] ERROR homeassistant/components/denonavr/config_flow.py:229:19-32: Argument `str | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] ERROR homeassistant/components/denonavr/media_player.py:122:53-71: Object of class `DenonAVRFoundation` has no attribute `zone` [missing-attribute] @@ -4441,7 +4395,7 @@ ERROR homeassistant/components/devolo_home_network/update.py:76:5-23: Class memb ERROR homeassistant/components/devolo_home_network/update.py:76:5-23: Class member `DevoloUpdateEntity.entity_description` overrides parent class `UpdateEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/diagnostics/__init__.py:96:10-27: Function declared to return `Mapping[str, Any]` but is missing an explicit `return` [bad-return] ERROR homeassistant/components/diagnostics/__init__.py:101:10-27: Function declared to return `Mapping[str, Any]` but is missing an explicit `return` [bad-return] -ERROR homeassistant/components/diagnostics/__init__.py:219:29-40: Cannot set item in `dict[str, Mapping[str | None, dict[SetupPhases, float]] | Mapping[str, Any] | dict[str, Any] | dict[Unknown, Unknown] | Manifest]` [unsupported-operation] +ERROR homeassistant/components/diagnostics/__init__.py:219:29-40: `list[dict[str, Any]]` is not assignable to TypedDict key `issues` with type `Mapping[str | None, dict[SetupPhases, float]] | Mapping[str, Any] | dict[str, Any] | dict[Unknown, Unknown] | Manifest` [bad-typed-dict-key] ERROR homeassistant/components/dialogflow/__init__.py:94:46-56: `parameters` may be uninitialized [unbound-name] ERROR homeassistant/components/dialogflow/__init__.py:126:14-17: `req` may be uninitialized [unbound-name] ERROR homeassistant/components/dialogflow/__init__.py:127:18-21: `req` may be uninitialized [unbound-name] @@ -4478,8 +4432,6 @@ ERROR homeassistant/components/directv/entity.py:29:24-44: Object of class `None ERROR homeassistant/components/directv/entity.py:30:33-53: Object of class `NoneType` has no attribute `info` [missing-attribute] ERROR homeassistant/components/directv/media_player.py:70:29-49: Object of class `NoneType` has no attribute `locations` [missing-attribute] ERROR homeassistant/components/directv/media_player.py:88:14-32: Class member `DIRECTVMediaPlayer._attr_device_class` overrides parent class `DIRECTVEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/directv/media_player.py:103:25-38: `Program | None` is not assignable to attribute `_program` with type `None` [bad-assignment] -ERROR homeassistant/components/directv/media_player.py:116:37-53: `datetime` is not assignable to attribute `_last_update` with type `Never` [bad-assignment] ERROR homeassistant/components/directv/remote.py:39:29-49: Object of class `NoneType` has no attribute `locations` [missing-attribute] ERROR homeassistant/components/discogs/sensor.py:9:8-22: Could not find import of `discogs_client` [missing-import] ERROR homeassistant/components/discogs/sensor.py:42:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -4529,7 +4481,6 @@ ERROR homeassistant/components/dlink/switch.py:20:5-8: Unexpected keyword argume ERROR homeassistant/components/dlink/switch.py:33:7-22: Field `entity_description` is declared `EntityDescription` in ancestor `class DLinkEntity: ... `, which is not assignable to the type `SwitchEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/dlna_dms/util.py:28:12-31: `suggested_source_id` may be uninitialized [unbound-name] -ERROR homeassistant/components/dnsip/config_flow.py:100:9-31: Class member `DnsIPConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/doods/image_processing.py:12:1-28: Could not find import of `pydoods` [missing-import] ERROR homeassistant/components/doods/image_processing.py:176:71-87: `label_confidence` may be uninitialized [unbound-name] ERROR homeassistant/components/doods/image_processing.py:177:43-59: `label_confidence` may be uninitialized [unbound-name] @@ -4543,13 +4494,11 @@ ERROR homeassistant/components/doorbird/button.py:40:9-24: Unexpected keyword ar ERROR homeassistant/components/doorbird/button.py:71:5-23: Class member `DoorBirdButton.entity_description` overrides parent class `DoorBirdEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/doorbird/button.py:71:5-23: Class member `DoorBirdButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/doorbird/camera.py:77:18-42: Class member `DoorBirdCamera._attr_supported_features` overrides parent class `DoorBirdEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/doorbird/config_flow.py:266:9-31: Class member `DoorBirdConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/doorbird/event.py:21:9-12: Unexpected keyword argument `key` in function `homeassistant.components.event.EventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/doorbird/event.py:22:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.event.EventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/doorbird/event.py:27:9-12: Unexpected keyword argument `key` in function `homeassistant.components.event.EventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/doorbird/event.py:28:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.event.EventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/doorbird/event.py:52:5-23: Class member `DoorBirdEventEntity.entity_description` overrides parent class `DoorBirdEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/dormakaba_dkey/__init__.py:48:38-56: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/dormakaba_dkey/binary_sensor.py:31:9-12: Unexpected keyword argument `key` in function `DormakabaDkeyBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dormakaba_dkey/binary_sensor.py:36:9-12: Unexpected keyword argument `key` in function `DormakabaDkeyBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dormakaba_dkey/binary_sensor.py:37:9-24: Unexpected keyword argument `translation_key` in function `DormakabaDkeyBinarySensorDescription.__init__` [unexpected-keyword] @@ -4751,7 +4700,6 @@ ERROR homeassistant/components/droplet/sensor.py:74:9-24: Unexpected keyword arg ERROR homeassistant/components/droplet/sensor.py:78:9-24: Unexpected keyword argument `entity_category` in function `DropletSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/droplet/sensor.py:96:5-23: Class member `DropletSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/droplet/sensor.py:96:5-23: Class member `DropletSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/dsmr/config_flow.py:174:9-31: Class member `DSMRFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/dsmr/sensor.py:94:9-12: Unexpected keyword argument `key` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dsmr/sensor.py:97:9-24: Unexpected keyword argument `entity_category` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dsmr/sensor.py:98:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] @@ -4923,7 +4871,7 @@ ERROR homeassistant/components/dsmr/sensor.py:556:13-16: Unexpected keyword argu ERROR homeassistant/components/dsmr/sensor.py:557:13-28: Unexpected keyword argument `translation_key` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dsmr/sensor.py:566:13-16: Unexpected keyword argument `key` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dsmr/sensor.py:567:13-28: Unexpected keyword argument `translation_key` in function `DSMRSensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/dsmr/sensor.py:590:66-69: Cannot index into `dict[str, UnitOfVolume]` [bad-index] +ERROR homeassistant/components/dsmr/sensor.py:590:66-69: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/dsmr/sensor.py:892:5-23: Class member `DSMREntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/dsmr/sensor.py:983:42-47: `value` is uninitialized [unbound-name] ERROR homeassistant/components/dsmr/sensor.py:983:42-47: Argument `float | int | str` is not assignable to parameter `value` with type `str` in function `DSMREntity.translate_tariff` [bad-argument-type] @@ -5133,20 +5081,18 @@ ERROR homeassistant/components/dwd_weather_warnings/config_flow.py:75:35-43: `po ERROR homeassistant/components/dwd_weather_warnings/coordinator.py:28:5-17: Class member `DwdWeatherWarningsCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/dwd_weather_warnings/coordinator.py:70:21-32: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/dwd_weather_warnings/coordinator.py:71:21-32: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/dwd_weather_warnings/coordinator.py:86:39-47: `tuple[float, float] | None` is not assignable to attribute `_previous_position` with type `None` [bad-assignment] ERROR homeassistant/components/dwd_weather_warnings/sensor.py:45:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dwd_weather_warnings/sensor.py:46:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dwd_weather_warnings/sensor.py:49:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dwd_weather_warnings/sensor.py:50:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/dwd_weather_warnings/sensor.py:89:14-32: Class member `DwdWeatherWarningsSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/dwd_weather_warnings/sensor.py:120:36-58: Cannot set item in `dict[str, None]` [unsupported-operation] -ERROR homeassistant/components/dwd_weather_warnings/sensor.py:120:40-57: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] -ERROR homeassistant/components/dwd_weather_warnings/sensor.py:122:37-54: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/dwd_weather_warnings/sensor.py:120:40-57: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/dwd_weather_warnings/sensor.py:122:37-54: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/dynalite/bridge.py:60:53-69: Object of class `DynaliteBaseDevice` has no attribute `unique_id` [missing-attribute] ERROR homeassistant/components/dynalite/bridge.py:110:49-64: Object of class `DynaliteBaseDevice` has no attribute `category` [missing-attribute] ERROR homeassistant/components/dynalite/bridge.py:117:55-71: Argument `list[DynaliteBaseDevice]` is not assignable to parameter `iterable` with type `Iterable[str]` in function `list.extend` [bad-argument-type] ERROR homeassistant/components/dynalite/cover.py:43:14-32: Class member `DynaliteCover._attr_device_class` overrides parent class `DynaliteBase` in an inconsistent manner [bad-override] -ERROR homeassistant/components/eafm/sensor.py:101:25-66: Argument `set[tuple[str, str, Unknown]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/eafm/sensor.py:99:26-105:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, str, Unknown]], manufacturer=Literal['https://environment.data.gov.uk/'], model=Unknown, name=str) [no-matching-overload] ERROR homeassistant/components/easyenergy/coordinator.py:38:5-17: Class member `EasyEnergyDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/easyenergy/sensor.py:46:9-12: Unexpected keyword argument `key` in function `EasyEnergySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/easyenergy/sensor.py:47:9-24: Unexpected keyword argument `translation_key` in function `EasyEnergySensorEntityDescription.__init__` [unexpected-keyword] @@ -5234,10 +5180,10 @@ ERROR homeassistant/components/ebox/sensor.py:136:9-13: Unexpected keyword argum ERROR homeassistant/components/ebusd/__init__.py:5:8-15: Could not find import of `ebusdpy` [missing-import] ERROR homeassistant/components/ebusd/sensor.py:94:41-59: Cannot set item in `dict[str, None]` [unsupported-operation] ERROR homeassistant/components/ecoal_boiler/__init__.py:5:1-46: Could not find import of `ecoaliface.simple` [missing-import] -ERROR homeassistant/components/ecobee/binary_sensor.py:25:28-51: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/binary_sensor.py:25:28-51: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/binary_sensor.py:27:25-45: Cannot index into `str` [bad-index] ERROR homeassistant/components/ecobee/binary_sensor.py:31:53-67: Cannot index into `str` [bad-index] -ERROR homeassistant/components/ecobee/climate.py:214:28-51: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/climate.py:214:28-51: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:216:12-37: Cannot index into `str` [bad-index] ERROR homeassistant/components/ecobee/climate.py:225:17-35: Cannot index into `str` [bad-index] ERROR homeassistant/components/ecobee/climate.py:226:17-42: Cannot index into `str` [bad-index] @@ -5247,26 +5193,26 @@ ERROR homeassistant/components/ecobee/climate.py:251:17-43: Object of class `Ent ERROR homeassistant/components/ecobee/climate.py:268:13-43: Object of class `Entity` has no attribute `set_fan_min_on_time` [missing-attribute] ERROR homeassistant/components/ecobee/climate.py:285:13-38: Object of class `Entity` has no attribute `resume_program` [missing-attribute] ERROR homeassistant/components/ecobee/climate.py:399:27-81: `str` is not assignable to attribute `thermostat` with type `dict[Unknown, Unknown]` [bad-assignment] -ERROR homeassistant/components/ecobee/climate.py:660:69-82: Argument `None` is not assignable to parameter `vacation` with type `str` in function `pyecobee.Ecobee.delete_vacation` [bad-argument-type] +ERROR homeassistant/components/ecobee/climate.py:660:69-82: Argument `Unknown | None` is not assignable to parameter `vacation` with type `str` in function `pyecobee.Ecobee.delete_vacation` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:801:62-75: Argument `int` is not assignable to parameter `humidity` with type `str` in function `pyecobee.Ecobee.set_humidity` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:821:36-69: Argument `Literal['false', 'true']` is not assignable to parameter `resume_all` with type `bool` in function `pyecobee.Ecobee.resume_program` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:908:36-47: Argument `str | None` is not assignable to parameter `climate_name` with type `str` in function `pyecobee.Ecobee.update_climate_sensors` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:925:16-932:10: Returned type `list[str | None]` is not assignable to declared return type `list[str]` [bad-return] ERROR homeassistant/components/ecobee/climate.py:1040:36-45: Argument `Unknown | None` is not assignable to parameter `auto_away` with type `bool` in function `pyecobee.Ecobee.set_occupancy_modes` [bad-argument-type] ERROR homeassistant/components/ecobee/climate.py:1040:47-56: Argument `Unknown | None` is not assignable to parameter `follow_me` with type `bool` in function `pyecobee.Ecobee.set_occupancy_modes` [bad-argument-type] -ERROR homeassistant/components/ecobee/config_flow.py:64:38-67:14: Argument `dict[str, str | None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.config_entries.ConfigFlow.async_show_form` [bad-argument-type] +ERROR homeassistant/components/ecobee/config_flow.py:64:38-67:14: Argument `dict[str, str | Unknown | None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.config_entries.ConfigFlow.async_show_form` [bad-argument-type] ERROR homeassistant/components/ecobee/entity.py:36:16-70: Returned type `str` is not assignable to declared return type `dict[str, Any]` [bad-return] -ERROR homeassistant/components/ecobee/humidifier.py:38:28-51: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/humidifier.py:38:28-51: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/humidifier.py:40:12-34: Cannot index into `str` [bad-index] -ERROR homeassistant/components/ecobee/notify.py:21:64-87: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/notify.py:21:64-87: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/number.py:35:9-12: Unexpected keyword argument `key` in function `EcobeeNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/number.py:36:9-24: Unexpected keyword argument `translation_key` in function `EcobeeNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/number.py:38:16-40:10: Argument `(data: EcobeeData, id: int, min_time: int) -> None` is not assignable to parameter `set_fn` with type `(EcobeeData, int, int) -> Awaitable[Unknown]` in function `EcobeeNumberEntityDescription.__init__` [bad-argument-type] ERROR homeassistant/components/ecobee/number.py:43:9-12: Unexpected keyword argument `key` in function `EcobeeNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/number.py:44:9-24: Unexpected keyword argument `translation_key` in function `EcobeeNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/number.py:46:16-48:10: Argument `(data: EcobeeData, id: int, min_time: int) -> None` is not assignable to parameter `set_fn` with type `(EcobeeData, int, int) -> Awaitable[Unknown]` in function `EcobeeNumberEntityDescription.__init__` [bad-argument-type] -ERROR homeassistant/components/ecobee/number.py:65:44-67: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] -ERROR homeassistant/components/ecobee/number.py:74:48-71: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/ecobee/number.py:65:44-67: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/ecobee/number.py:74:48-71: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/ecobee/number.py:85:5-23: Class member `EcobeeVentilatorMinTime.entity_description` overrides parent class `EcobeeBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ecobee/number.py:85:5-23: Class member `EcobeeVentilatorMinTime.entity_description` overrides parent class `NumberEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ecobee/number.py:134:5-23: Class member `EcobeeCompressorMinTemp._attr_device_class` overrides parent class `EcobeeBaseEntity` in an inconsistent manner [bad-override] @@ -5277,14 +5223,14 @@ ERROR homeassistant/components/ecobee/sensor.py:52:9-12: Unexpected keyword argu ERROR homeassistant/components/ecobee/sensor.py:59:9-12: Unexpected keyword argument `key` in function `EcobeeSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/sensor.py:66:9-12: Unexpected keyword argument `key` in function `EcobeeSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ecobee/sensor.py:82:28-42: Cannot index into `str` [bad-index] -ERROR homeassistant/components/ecobee/sensor.py:83:32-55: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/sensor.py:83:32-55: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/sensor.py:85:21-41: Cannot index into `str` [bad-index] ERROR homeassistant/components/ecobee/sensor.py:98:5-23: Class member `EcobeeSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/ecobee/sensor.py:174:26-37: Argument `None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] -ERROR homeassistant/components/ecobee/switch.py:40:44-67: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] -ERROR homeassistant/components/ecobee/switch.py:47:48-71: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/ecobee/sensor.py:174:26-37: Argument `Unknown | None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] +ERROR homeassistant/components/ecobee/switch.py:40:44-67: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/ecobee/switch.py:47:48-71: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/ecobee/switch.py:133:36-72: Argument `str | None` is not assignable to parameter `hvac_mode` with type `str` in function `pyecobee.Ecobee.set_hvac_mode` [bad-argument-type] -ERROR homeassistant/components/ecobee/weather.py:48:28-51: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/ecobee/weather.py:48:28-51: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/ecobee/weather.py:51:44-62: Cannot index into `str` [bad-index] ERROR homeassistant/components/ecobee/weather.py:78:24-49: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/ecobee/weather.py:170:12-43: `not in` is not supported between `Literal['forecasts']` and `None` [not-iterable] @@ -5648,7 +5594,6 @@ ERROR homeassistant/components/edl21/sensor.py:267:9-12: Unexpected keyword argu ERROR homeassistant/components/edl21/sensor.py:268:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/edl21/sensor.py:271:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/edl21/sensor.py:272:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/edl21/sensor.py:427:41-429:10: `() -> None` is not assignable to attribute `_async_remove_dispatcher` with type `None` [bad-assignment] ERROR homeassistant/components/efergy/sensor.py:29:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/efergy/sensor.py:30:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/efergy/sensor.py:36:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -5681,7 +5626,6 @@ ERROR homeassistant/components/efergy/sensor.py:100:9-24: Unexpected keyword arg ERROR homeassistant/components/efergy/sensor.py:160:14-32: Class member `EfergySensor.entity_description` overrides parent class `EfergyEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/egardia/__init__.py:5:1-55: Could not find import of `pythonegardia` [missing-import] ERROR homeassistant/components/egardia/alarm_control_panel.py:104:44-64: Object of class `NoneType` has no attribute `items` [missing-attribute] -ERROR homeassistant/components/egardia/binary_sensor.py:65:23-63: `Literal['off', 'on']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/eheimdigital/climate.py:64:5-29: Class member `EheimDigitalHeaterClimate._attr_supported_features` overrides parent class `EheimDigitalEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/eheimdigital/coordinator.py:33:5-17: Class member `EheimDigitalUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/eheimdigital/light.py:69:5-29: Class member `EheimDigitalClassicLEDControlLight._attr_supported_features` overrides parent class `EheimDigitalEntity` in an inconsistent manner [bad-override] @@ -5832,15 +5776,10 @@ ERROR homeassistant/components/elmax/coordinator.py:70:20-56: Returned type `Act ERROR homeassistant/components/elmax/coordinator.py:76:20-52: Returned type `Actuator | Area | Cover | DeviceEndpoint` is not assignable to declared return type `Actuator` [bad-return] ERROR homeassistant/components/elmax/coordinator.py:82:20-52: Returned type `Actuator | Area | Cover | DeviceEndpoint` is not assignable to declared return type `Area` [bad-return] ERROR homeassistant/components/elmax/coordinator.py:88:20-53: Returned type `Actuator | Area | Cover | DeviceEndpoint` is not assignable to declared return type `Cover` [bad-return] -ERROR homeassistant/components/elmax/coordinator.py:154:43-158:10: `PushNotificationHandler` is not assignable to attribute `_push_notification_handler` with type `None` [bad-assignment] -ERROR homeassistant/components/elmax/coordinator.py:159:9-75: Object of class `NoneType` has no attribute `register_push_notification_handler` [missing-attribute] -ERROR homeassistant/components/elmax/coordinator.py:162:9-46: Object of class `NoneType` has no attribute `start` [missing-attribute] ERROR homeassistant/components/elmax/cover.py:71:5-29: Class member `ElmaxCover._attr_supported_features` overrides parent class `ElmaxEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/elv/switch.py:8:8-13: Could not find import of `pypca` [missing-import] ERROR homeassistant/components/elvia/config_flow.py:58:20-31: `meter_count` is uninitialized [unbound-name] ERROR homeassistant/components/emby/media_player.py:7:1-30: Could not find import of `pyemby` [missing-import] -ERROR homeassistant/components/emby/media_player.py:161:46-62: `datetime` is not assignable to attribute `media_status_received` with type `None` [bad-assignment] -ERROR homeassistant/components/emoncms/config_flow.py:74:9-31: Class member `EmoncmsConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/emoncms/coordinator.py:20:5-17: Class member `EmoncmsCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/emoncms/sensor.py:42:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/emoncms/sensor.py:43:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -5966,12 +5905,10 @@ ERROR homeassistant/components/energyzero/sensor.py:120:9-12: Unexpected keyword ERROR homeassistant/components/energyzero/sensor.py:121:9-24: Unexpected keyword argument `translation_key` in function `EnergyZeroSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/energyzero/sensor.py:170:5-23: Class member `EnergyZeroSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/energyzero/sensor.py:170:5-23: Class member `EnergyZeroSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/enigma2/config_flow.py:161:9-31: Class member `Enigma2ConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/enigma2/coordinator.py:42:5-17: Class member `Enigma2UpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/enigma2/media_player.py:47:5-29: Class member `Enigma2Device._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/enigma2/media_player.py:170:18-29: Class member `Enigma2Device._attr_state` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/enocean/binary_sensor.py:65:14-32: Class member `EnOceanBinarySensor._attr_device_class` overrides parent class `EnOceanEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/enocean/dongle.py:39:45-41:10: `() -> None` is not assignable to attribute `dispatcher_disconnect_handle` with type `None` [bad-assignment] ERROR homeassistant/components/enocean/light.py:72:27-56: `/` is not supported between `None` and `float` [unsupported-operation] ERROR homeassistant/components/enocean/sensor.py:56:5-8: Unexpected keyword argument `key` in function `EnOceanSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/enocean/sensor.py:57:5-9: Unexpected keyword argument `name` in function `EnOceanSensorEntityDescription.__init__` [unexpected-keyword] @@ -6006,7 +5943,6 @@ ERROR homeassistant/components/enphase_envoy/binary_sensor.py:156:5-23: Class me ERROR homeassistant/components/enphase_envoy/binary_sensor.py:191:5-23: Class member `EnvoyEnpowerBinarySensorEntity.entity_description` overrides parent class `EnvoyBaseBinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/enphase_envoy/binary_sensor.py:224:5-23: Class member `EnvoyCollarBinarySensorEntity.entity_description` overrides parent class `EnvoyBaseBinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/enphase_envoy/binary_sensor.py:257:5-23: Class member `EnvoyC6CCBinarySensorEntity.entity_description` overrides parent class `EnvoyBaseBinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/enphase_envoy/config_flow.py:96:9-31: Class member `EnphaseConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/enphase_envoy/coordinator.py:43:5-17: Class member `EnphaseUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/enphase_envoy/number.py:48:9-12: Unexpected keyword argument `key` in function `EnvoyRelayNumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/enphase_envoy/number.py:49:9-24: Unexpected keyword argument `translation_key` in function `EnvoyRelayNumberEntityDescription.__init__` [unexpected-keyword] @@ -6277,7 +6213,6 @@ ERROR homeassistant/components/epion/sensor.py:39:9-12: Unexpected keyword argum ERROR homeassistant/components/epion/sensor.py:46:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/epion/sensor.py:53:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/epion/sensor.py:90:14-32: Class member `EpionSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/epson/media_player.py:148:27-61: `str | None` is not assignable to attribute `_cmode` with type `None` [bad-assignment] ERROR homeassistant/components/eq3btsmart/__init__.py:75:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/eq3btsmart/binary_sensor.py:32:9-12: Unexpected keyword argument `key` in function `Eq3BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/eq3btsmart/binary_sensor.py:34:9-24: Unexpected keyword argument `entity_category` in function `Eq3BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -6327,7 +6262,6 @@ ERROR homeassistant/components/esphome/binary_sensor.py:41:14-32: Class member ` ERROR homeassistant/components/esphome/button.py:29:14-32: Class member `EsphomeButton._attr_device_class` overrides parent class `EsphomeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/esphome/climate.py:191:14-38: Class member `EsphomeClimateEntity._attr_supported_features` overrides parent class `EsphomeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/esphome/config_flow.py:696:12-29: `unique_id_matches` may be uninitialized [unbound-name] -ERROR homeassistant/components/esphome/config_flow.py:914:9-31: Class member `EsphomeFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/esphome/cover.py:49:14-38: Class member `EsphomeCover._attr_supported_features` overrides parent class `EsphomeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/esphome/cover.py:50:14-32: Class member `EsphomeCover._attr_device_class` overrides parent class `EsphomeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/esphome/entity.py:318:5-17: Class member `EsphomeBaseEntity.device_entry` overrides parent class `Entity` in an inconsistent manner [bad-override] @@ -6398,16 +6332,11 @@ ERROR homeassistant/components/essent/sensor.py:194:5-23: Class member `EssentSe ERROR homeassistant/components/etherscan/sensor.py:7:1-36: Could not find import of `pyetherscan` [missing-import] ERROR homeassistant/components/eufy/__init__.py:3:8-16: Could not find import of `lakeside` [missing-import] ERROR homeassistant/components/eufy/light.py:7:8-16: Could not find import of `lakeside` [missing-import] -ERROR homeassistant/components/eufy/light.py:72:28-74: `tuple[float, float]` is not assignable to attribute `_hs` with type `None` [bad-assignment] ERROR homeassistant/components/eufy/light.py:95:20-42: `*` is not supported between `None` and `Literal[255]` [unsupported-operation] ERROR homeassistant/components/eufy/light.py:102:16-72: `*` is not supported between `None` and `int` [unsupported-operation] -ERROR homeassistant/components/eufy/light.py:132:36-39: `Literal[100]` is not assignable to attribute `_brightness` with type `None` [bad-assignment] -ERROR homeassistant/components/eufy/light.py:145:61-77: `/` is not supported between `None` and `Literal[255]` [unsupported-operation] ERROR homeassistant/components/eufy/light.py:149:17-28: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/eufy/light.py:149:30-41: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/eufy/light.py:149:43-59: `/` is not supported between `None` and `Literal[255]` [unsupported-operation] ERROR homeassistant/components/eufy/switch.py:7:8-16: Could not find import of `lakeside` [missing-import] -ERROR homeassistant/components/eufylife_ble/__init__.py:41:38-56: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/eufylife_ble/sensor.py:41:25-60: Argument `EufyLifeHeartRateSensorEntity` is not assignable to parameter `object` with type `EufyLifeRealTimeWeightSensorEntity | EufyLifeWeightSensorEntity` in function `list.append` [bad-argument-type] ERROR homeassistant/components/event/__init__.py:77:5-17: Class member `EventEntityDescription.device_class` overrides parent class `EntityDescription` in an inconsistent manner [bad-override] ERROR homeassistant/components/event/__init__.py:115:5-23: Class member `EventEntity.entity_description` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] @@ -6424,6 +6353,7 @@ ERROR homeassistant/components/evohome/entity.py:95:5-16: Class member `EvoChild ERROR homeassistant/components/evohome/water_heater.py:74:5-29: Class member `EvoDHW._attr_supported_features` overrides parent class `EvoChild` in an inconsistent manner [bad-override] ERROR homeassistant/components/evohome/water_heater.py:81:5-16: Class member `EvoDHW._evo_device` overrides parent class `EvoChild` in an inconsistent manner [bad-override] ERROR homeassistant/components/ezviz/alarm_control_panel.py:40:5-8: Unexpected keyword argument `key` in function `EzvizAlarmControlPanelEntityDescription.__init__` [unexpected-keyword] +ERROR homeassistant/components/ezviz/alarm_control_panel.py:58:29-63:6: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=Literal['EZVIZ Alarm'], model=Literal['EZVIZ Alarm'], manufacturer=Literal['EZVIZ']) [no-matching-overload] ERROR homeassistant/components/ezviz/alarm_control_panel.py:73:5-23: Class member `EzvizAlarm.entity_description` overrides parent class `AlarmControlPanelEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ezviz/alarm_control_panel.py:104:17-48: Argument `int` is not assignable to parameter `mode` with type `DefenseModeType` in function `pyezvizapi.client.EzvizClient.api_set_defence_mode` [bad-argument-type] ERROR homeassistant/components/ezviz/alarm_control_panel.py:115:17-48: Argument `int` is not assignable to parameter `mode` with type `DefenseModeType` in function `pyezvizapi.client.EzvizClient.api_set_defence_mode` [bad-argument-type] @@ -6446,7 +6376,6 @@ ERROR homeassistant/components/ezviz/button.py:93:5-23: Class member `EzvizButto ERROR homeassistant/components/ezviz/button.py:93:5-23: Class member `EzvizButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ezviz/camera.py:142:18-42: Class member `EzvizCamera._attr_supported_features` overrides parent class `EzvizEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ezviz/config_flow.py:132:47-134:10: Unpacked argument `tuple[Unknown]` is not assignable to parameter `*args` with type `tuple[str, str, int]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/ezviz/config_flow.py:151:9-31: Class member `EzvizConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/ezviz/image.py:25:5-8: Unexpected keyword argument `key` in function `homeassistant.components.image.ImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ezviz/image.py:26:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.image.ImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ezviz/light.py:78:58-82:18: Unpacked argument `tuple[str, int]` is not assignable to parameter `*args` with type `tuple[str, int, int, int]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] @@ -6541,13 +6470,11 @@ ERROR homeassistant/components/faa_delays/binary_sensor.py:74:9-12: Unexpected k ERROR homeassistant/components/faa_delays/binary_sensor.py:75:9-24: Unexpected keyword argument `translation_key` in function `FaaDelaysBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/faa_delays/binary_sensor.py:106:5-23: Class member `FAABinarySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/faa_delays/binary_sensor.py:106:5-23: Class member `FAABinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/fail2ban/sensor.py:113:29-35: `Literal['None']` is not assignable to attribute `last_ban` with type `None` [bad-assignment] ERROR homeassistant/components/familyhub/camera.py:5:1-42: Could not find import of `pyfamilyhublocal` [missing-import] ERROR homeassistant/components/fan/__init__.py:211:5-23: Class member `FanEntity.entity_description` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fan/__init__.py:218:5-29: Class member `FanEntity._attr_supported_features` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fastdotcom/sensor.py:33:5-23: Class member `SpeedtestSensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/feedreader/config_flow.py:35:45-68: Unpacked argument `tuple[str]` is not assignable to parameter `*args` with type `tuple[Unknown, Unknown | None, Unknown | None, Unknown | None, Unknown | None, Unknown | None, Unknown | None, Unknown | None, Unknown | None, Unknown | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/feedreader/config_flow.py:45:9-31: Class member `FeedReaderConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/feedreader/coordinator.py:39:5-17: Class member `FeedReaderCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/feedreader/coordinator.py:161:13-31: Object of class `FeedParserDict` has no attribute `entries` [missing-attribute] ERROR homeassistant/components/feedreader/event.py:88:35-46: `description` may be uninitialized [unbound-name] @@ -6555,7 +6482,7 @@ ERROR homeassistant/components/feedreader/event.py:89:29-34: `title` may be unin ERROR homeassistant/components/feedreader/event.py:91:31-38: `content` may be uninitialized [unbound-name] ERROR homeassistant/components/ffmpeg/camera.py:96:17-30: Argument `asyncio.streams.StreamReader` is not assignable to parameter `stream` with type `aiohttp.streams.StreamReader` in function `homeassistant.helpers.aiohttp_client.async_aiohttp_proxy_stream` [bad-argument-type] ERROR homeassistant/components/ffmpeg_motion/binary_sensor.py:128:9-131:10: Result of async function call is unused. Did you forget to `await`? [unused-coroutine] -ERROR homeassistant/components/fibaro/__init__.py:188:25-58: Argument `set[tuple[str, int]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/fibaro/__init__.py:187:63-192:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, int]], manufacturer=Unknown | None, name=str, via_device=tuple[Literal['fibaro'], str]) [no-matching-overload] ERROR homeassistant/components/fibaro/__init__.py:236:9-288:21: `int | None` is not assignable to `None` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR homeassistant/components/fibaro/__init__.py:238:17-41: Object of class `DeviceModel` has no attribute `fibaro_controller` [missing-attribute] ERROR homeassistant/components/fibaro/__init__.py:242:17-33: Object of class `DeviceModel` has no attribute `room_name` [missing-attribute] @@ -6565,8 +6492,6 @@ ERROR homeassistant/components/fibaro/__init__.py:251:17-37: Object of class `De ERROR homeassistant/components/fibaro/__init__.py:255:21-33: Object of class `DeviceModel` has no attribute `ha_id` [missing-attribute] ERROR homeassistant/components/fibaro/__init__.py:269:25-37: Object of class `DeviceModel` has no attribute `ha_id` [missing-attribute] ERROR homeassistant/components/fibaro/__init__.py:273:72-84: Object of class `DeviceModel` has no attribute `ha_id` [missing-attribute] -ERROR homeassistant/components/fibaro/binary_sensor.py:68:40-58: `str | None` is not assignable to attribute `_fibaro_sensor_type` with type `None` [bad-assignment] -ERROR homeassistant/components/fibaro/binary_sensor.py:70:40-63: `str | None` is not assignable to attribute `_fibaro_sensor_type` with type `None` [bad-assignment] ERROR homeassistant/components/fibaro/binary_sensor.py:72:18-36: Class member `FibaroBinarySensor._attr_device_class` overrides parent class `FibaroEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fibaro/climate.py:139:42-61: Object of class `DeviceModel` has no attribute `ha_id` [missing-attribute] ERROR homeassistant/components/fibaro/climate.py:263:20-42: Returned type `str | None` is not assignable to declared return type `int | str` [bad-return] @@ -6668,7 +6593,6 @@ ERROR homeassistant/components/fido/sensor.py:163:9-13: Unexpected keyword argum ERROR homeassistant/components/fido/sensor.py:166:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fido/sensor.py:167:9-13: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fido/sensor.py:169:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/file/config_flow.py:76:9-31: Class member `FileConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/file/sensor.py:76:24-28: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/file_upload/__init__.py:147:39-47: `filename` is uninitialized [unbound-name] ERROR homeassistant/components/file_upload/__init__.py:165:19-38: `/` is not supported between `Path` and `None` [unsupported-operation] @@ -6697,8 +6621,6 @@ ERROR homeassistant/components/firefly_iii/coordinator.py:49:5-17: Class member ERROR homeassistant/components/firefly_iii/sensor.py:82:5-23: Class member `FireflyAccountBalanceSensor._attr_device_class` overrides parent class `FireflyAccountBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/firefly_iii/sensor.py:165:5-23: Class member `FireflyCategorySensor._attr_device_class` overrides parent class `FireflyCategoryBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/firefly_iii/sensor.py:197:5-23: Class member `FireflyBudgetSensor._attr_device_class` overrides parent class `FireflyBudgetBaseEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/fireservicerota/config_flow.py:66:20-70:10: `FireServiceRota` is not assignable to attribute `api` with type `None` [bad-assignment] -ERROR homeassistant/components/fireservicerota/config_flow.py:73:65-88: Object of class `NoneType` has no attribute `request_tokens` [missing-attribute] ERROR homeassistant/components/fireservicerota/config_flow.py:93:53-58: Argument `ConfigEntry[Any] | None` is not assignable to parameter `entry` with type `ConfigEntry[Any]` in function `homeassistant.config_entries.ConfigEntries.async_update_entry` [bad-argument-type] ERROR homeassistant/components/fireservicerota/config_flow.py:94:53-67: Object of class `NoneType` has no attribute `entry_id` [missing-attribute] ERROR homeassistant/components/fireservicerota/coordinator.py:37:5-17: Class member `FireServiceUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -7053,7 +6975,6 @@ ERROR homeassistant/components/flume/sensor.py:79:9-12: Unexpected keyword argum ERROR homeassistant/components/flume/sensor.py:80:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/flume/sensor.py:153:7-18: Field `entity_description` is declared `EntityDescription` in ancestor `class FlumeEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/flux/switch.py:247:30-251:10: `() -> None` is not assignable to attribute `unsub_tracker` with type `None` [bad-assignment] ERROR homeassistant/components/flux/switch.py:261:13-31: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/flux/switch.py:286:12-37: `<` is not supported between `datetime` and `None` [unsupported-operation] ERROR homeassistant/components/flux/switch.py:290:30-46: Object of class `NoneType` has no attribute `timestamp` [missing-attribute] @@ -7071,7 +6992,6 @@ ERROR homeassistant/components/flux_led/button.py:24:5-8: Unexpected keyword arg ERROR homeassistant/components/flux_led/button.py:28:5-8: Unexpected keyword argument `key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/flux_led/button.py:29:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/flux_led/button.py:64:14-32: Class member `FluxButton.entity_description` overrides parent class `FluxBaseEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/flux_led/config_flow.py:74:9-31: Class member `FluxLedConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/flux_led/coordinator.py:29:5-17: Class member `FluxLedUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/flux_led/light.py:189:5-29: Class member `FluxLight._attr_supported_features` overrides parent class `FluxOnOffEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/flux_led/light.py:189:5-29: Class member `FluxLight._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] @@ -7095,7 +7015,6 @@ ERROR homeassistant/components/foobot/sensor.py:78:9-13: Unexpected keyword argu ERROR homeassistant/components/foobot/sensor.py:80:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/foobot/sensor.py:120:9-34: Module `aiohttp.client_exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/foobot/sensor.py:177:13-38: Module `aiohttp.client_exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR homeassistant/components/forecast_solar/config_flow.py:40:9-31: Class member `ForecastSolarFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/forecast_solar/coordinator.py:32:5-17: Class member `ForecastSolarDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/forecast_solar/coordinator.py:56:22-35: `inverter_size` may be uninitialized [unbound-name] ERROR homeassistant/components/forecast_solar/sensor.py:40:9-12: Unexpected keyword argument `key` in function `ForecastSolarSensorEntityDescription.__init__` [unexpected-keyword] @@ -7125,55 +7044,16 @@ ERROR homeassistant/components/forecast_solar/sensor.py:124:9-12: Unexpected key ERROR homeassistant/components/forecast_solar/sensor.py:125:9-24: Unexpected keyword argument `translation_key` in function `ForecastSolarSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/forecast_solar/sensor.py:158:5-23: Class member `ForecastSolarSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/forecast_solar/sensor.py:158:5-23: Class member `ForecastSolarSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/forked_daapd/config_flow.py:113:9-31: Class member `ForkedDaapdFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/forked_daapd/config_flow.py:194:28-67: No matching overload found for function `homeassistant.config_entries.ConfigFlowContext.update` called with arguments: (dict[str, dict[str, int | str | Any | None]]) [no-matching-overload] -ERROR homeassistant/components/forked_daapd/media_player.py:331:37-45: `datetime` is not assignable to attribute `_player_last_updated` with type `None` [bad-assignment] -ERROR homeassistant/components/forked_daapd/media_player.py:386:32-390:14: `str | Unknown` is not assignable to attribute `_track_info` with type `defaultdict[Unknown, str]` [bad-assignment] -ERROR homeassistant/components/forked_daapd/media_player.py:388:30-50: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:388:30-50: Type `bool` is not iterable [not-iterable] ERROR homeassistant/components/forked_daapd/media_player.py:388:30-50: Type `int` is not iterable [not-iterable] -ERROR homeassistant/components/forked_daapd/media_player.py:389:20-31: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:389:35-58: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:423:18-30: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:429:30-43: `dict[str, bool | int | str] | dict[str, int | list[Unknown]] | list[Unknown]` is not assignable to attribute `_last_outputs` with type `list[Unknown]` [bad-assignment] -ERROR homeassistant/components/forked_daapd/media_player.py:430:16-34: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:452:12-33: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:456:20-38: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:465:16-38: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:465:16-44: `/` is not supported between `list[Unknown]` and `Literal[100]` [unsupported-operation] ERROR homeassistant/components/forked_daapd/media_player.py:465:16-44: `/` is not supported between `str` and `Literal[100]` [unsupported-operation] -ERROR homeassistant/components/forked_daapd/media_player.py:470:16-38: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:475:16-39: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:485:16-46: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:485:16-53: `/` is not supported between `list[Unknown]` and `Literal[1000]` [unsupported-operation] ERROR homeassistant/components/forked_daapd/media_player.py:485:16-53: `/` is not supported between `str` and `Literal[1000]` [unsupported-operation] -ERROR homeassistant/components/forked_daapd/media_player.py:490:16-48: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:490:16-55: `/` is not supported between `list[Unknown]` and `Literal[1000]` [unsupported-operation] ERROR homeassistant/components/forked_daapd/media_player.py:490:16-55: `/` is not supported between `str` and `Literal[1000]` [unsupported-operation] -ERROR homeassistant/components/forked_daapd/media_player.py:533:16-39: Cannot index into `list[Unknown]` [bad-index] ERROR homeassistant/components/forked_daapd/media_player.py:619:16-19: `url` may be uninitialized [unbound-name] -ERROR homeassistant/components/forked_daapd/media_player.py:624:30-43: `dict[str, bool | int | str] | dict[str, int | list[Unknown]] | list[Unknown]` is not assignable to attribute `_last_outputs` with type `list[Unknown]` [bad-assignment] -ERROR homeassistant/components/forked_daapd/media_player.py:630:25-37: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:697:17-33: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:698:29-49: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:698:29-49: Type `bool` is not iterable [not-iterable] ERROR homeassistant/components/forked_daapd/media_player.py:698:29-49: Type `int` is not iterable [not-iterable] -ERROR homeassistant/components/forked_daapd/media_player.py:699:20-30: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:699:34-57: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:728:31-63: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:729:38-58: Cannot index into `list[Unknown]` [bad-index] ERROR homeassistant/components/forked_daapd/media_player.py:729:38-62: `>` is not supported between `list[Unknown]` and `Literal[0]` [unsupported-operation] -ERROR homeassistant/components/forked_daapd/media_player.py:729:38-62: `>` is not supported between `str` and `Literal[0]` [unsupported-operation] -ERROR homeassistant/components/forked_daapd/media_player.py:733:42-62: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:733:42-62: Argument `bool | int | list[Unknown] | str | Unknown` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] -ERROR homeassistant/components/forked_daapd/media_player.py:734:34-57: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:747:13-33: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:747:13-36: Cannot index into `bool` [bad-index] +ERROR homeassistant/components/forked_daapd/media_player.py:733:42-62: Argument `int | list[Unknown]` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/forked_daapd/media_player.py:747:13-36: Cannot index into `int` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:747:13-49: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:767:27-38: Cannot index into `str` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:767:51-71: Cannot index into `list[Unknown]` [bad-index] -ERROR homeassistant/components/forked_daapd/media_player.py:767:51-71: Type `bool` is not iterable [not-iterable] ERROR homeassistant/components/forked_daapd/media_player.py:767:51-71: Type `int` is not iterable [not-iterable] ERROR homeassistant/components/forked_daapd/media_player.py:769:36-56: `saved_queue_position` may be uninitialized [unbound-name] ERROR homeassistant/components/forked_daapd/media_player.py:842:17-30: `other_sources` may be uninitialized [unbound-name] @@ -7294,7 +7174,6 @@ ERROR homeassistant/components/fritz/button.py:62:9-12: Unexpected keyword argum ERROR homeassistant/components/fritz/button.py:63:9-24: Unexpected keyword argument `translation_key` in function `FritzButtonDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fritz/button.py:64:9-24: Unexpected keyword argument `entity_category` in function `FritzButtonDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fritz/button.py:107:5-23: Class member `FritzButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/fritz/config_flow.py:71:9-31: Class member `FritzBoxToolsFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/fritz/config_flow.py:186:16-20: `uuid` may be uninitialized [unbound-name] ERROR homeassistant/components/fritz/config_flow.py:187:78-82: `uuid` may be uninitialized [unbound-name] ERROR homeassistant/components/fritz/config_flow.py:295:12-17: `error` may be uninitialized [unbound-name] @@ -7398,9 +7277,9 @@ ERROR homeassistant/components/fritzbox/coordinator.py:36:5-17: Class member `Fr ERROR homeassistant/components/fritzbox/cover.py:52:5-23: Class member `FritzboxCover._attr_device_class` overrides parent class `FritzBoxDeviceEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fritzbox/cover.py:53:5-29: Class member `FritzboxCover._attr_supported_features` overrides parent class `FritzBoxDeviceEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fritzbox/diagnostics.py:27:33-30:6: `dict[str, FritzhomeDevice | FritzhomeTemplate]` is not assignable to `dict[str, dict[Unknown, Unknown]]` [bad-assignment] -ERROR homeassistant/components/fritzbox/entity.py:51:16-55: Returned type `Literal[False] | None` is not assignable to declared return type `bool` [bad-return] -ERROR homeassistant/components/fritzbox/light.py:104:16-56: Returned type `tuple[None, float]` is not assignable to declared return type `tuple[float, float]` [bad-return] -ERROR homeassistant/components/fritzbox/light.py:104:28-38: Argument `None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] +ERROR homeassistant/components/fritzbox/entity.py:51:16-55: Returned type `Literal[False] | Unknown | None` is not assignable to declared return type `bool` [bad-return] +ERROR homeassistant/components/fritzbox/light.py:104:16-56: Returned type `tuple[Unknown | None, float]` is not assignable to declared return type `tuple[float, float]` [bad-return] +ERROR homeassistant/components/fritzbox/light.py:104:28-38: Argument `Unknown | None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] ERROR homeassistant/components/fritzbox/sensor.py:117:9-12: Unexpected keyword argument `key` in function `FritzSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fritzbox/sensor.py:126:9-12: Unexpected keyword argument `key` in function `FritzSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fritzbox/sensor.py:134:9-12: Unexpected keyword argument `key` in function `FritzSensorEntityDescription.__init__` [unexpected-keyword] @@ -7431,13 +7310,12 @@ ERROR homeassistant/components/fritzbox/sensor.py:257:5-23: Class member `FritzB ERROR homeassistant/components/fritzbox/sensor.py:257:5-23: Class member `FritzBoxSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fritzbox_callmonitor/base.py:84:22-49: Object of class `NoneType` has no attribute `contacts` [missing-attribute] ERROR homeassistant/components/fritzbox_callmonitor/base.py:103:23-36: Type `None` is not iterable [not-iterable] -ERROR homeassistant/components/fritzbox_callmonitor/config_flow.py:133:9-31: Class member `FritzBoxCallMonitorConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/fronius/coordinator.py:165:50-54: `data` may be uninitialized [unbound-name] -ERROR homeassistant/components/fronius/diagnostics.py:29:9-84: Cannot set item in `dict[str, dict[Unknown, Unknown]]` [unsupported-operation] -ERROR homeassistant/components/fronius/diagnostics.py:32:9-82: Cannot set item in `dict[str, dict[Unknown, Unknown]]` [unsupported-operation] -ERROR homeassistant/components/fronius/diagnostics.py:35:9-88: Cannot set item in `dict[str, dict[Unknown, Unknown]]` [unsupported-operation] -ERROR homeassistant/components/fronius/diagnostics.py:38:9-40:18: Cannot set item in `dict[str, dict[Unknown, Unknown]]` [unsupported-operation] -ERROR homeassistant/components/fronius/diagnostics.py:43:9-86: Cannot set item in `dict[str, dict[Unknown, Unknown]]` [unsupported-operation] +ERROR homeassistant/components/fronius/diagnostics.py:29:9-84: `dict[str, dict[str, Any]] | None` is not assignable to TypedDict key `logger` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] +ERROR homeassistant/components/fronius/diagnostics.py:32:9-82: `dict[str, dict[str, Any]] | None` is not assignable to TypedDict key `meter` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] +ERROR homeassistant/components/fronius/diagnostics.py:35:9-88: `dict[str, dict[str, Any]] | None` is not assignable to TypedDict key `ohmpilot` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] +ERROR homeassistant/components/fronius/diagnostics.py:38:9-40:18: `dict[str, dict[str, Any]] | None` is not assignable to TypedDict key `power_flow` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] +ERROR homeassistant/components/fronius/diagnostics.py:43:9-86: `dict[str, dict[str, Any]] | None` is not assignable to TypedDict key `storage` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] ERROR homeassistant/components/fronius/sensor.py:125:9-12: Unexpected keyword argument `key` in function `FroniusSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fronius/sensor.py:131:9-12: Unexpected keyword argument `key` in function `FroniusSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fronius/sensor.py:137:9-12: Unexpected keyword argument `key` in function `FroniusSensorEntityDescription.__init__` [unexpected-keyword] @@ -7616,7 +7494,7 @@ ERROR homeassistant/components/fujitsu_fglair/climate.py:88:14-38: Class member ERROR homeassistant/components/fujitsu_fglair/coordinator.py:23:5-17: Class member `FGLairCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/fujitsu_fglair/coordinator.py:68:71-84: Object of class `Device` has no attribute `is_online` [missing-attribute] ERROR homeassistant/components/fujitsu_fglair/coordinator.py:77:16-60: Returned type `dict[str | None, Device | FujitsuHVAC]` is not assignable to declared return type `dict[str, FujitsuHVAC]` [bad-return] -ERROR homeassistant/components/fujitsu_fglair/entity.py:22:25-64: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/fujitsu_fglair/entity.py:21:44-28:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=str, manufacturer=Literal['Fujitsu'], model=Unknown, serial_number=str | None, sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/fujitsu_fglair/sensor.py:34:5-23: Class member `FGLairOutsideTemperature._attr_device_class` overrides parent class `FGLairEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fully_kiosk/binary_sensor.py:20:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fully_kiosk/binary_sensor.py:21:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -7716,7 +7594,6 @@ ERROR homeassistant/components/fully_kiosk/switch.py:74:9-24: Unexpected keyword ERROR homeassistant/components/fully_kiosk/switch.py:100:5-23: Class member `FullySwitchEntity.entity_description` overrides parent class `FullyKioskEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fully_kiosk/switch.py:100:5-23: Class member `FullySwitchEntity.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/futurenow/light.py:7:8-14: Could not find import of `pyfnip` [missing-import] -ERROR homeassistant/components/futurenow/light.py:140:23-34: `bool` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/fyta/binary_sensor.py:33:9-12: Unexpected keyword argument `key` in function `FytaBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fyta/binary_sensor.py:35:9-24: Unexpected keyword argument `entity_category` in function `FytaBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/fyta/binary_sensor.py:39:9-12: Unexpected keyword argument `key` in function `FytaBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -7780,13 +7657,6 @@ ERROR homeassistant/components/fyta/sensor.py:181:9-24: Unexpected keyword argum ERROR homeassistant/components/fyta/sensor.py:240:5-23: Class member `FytaPlantSensor.entity_description` overrides parent class `FytaPlantEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fyta/sensor.py:240:5-23: Class member `FytaPlantSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/fyta/sensor.py:252:5-23: Class member `FytaPlantMeasurementSensor.entity_description` overrides parent class `FytaPlantSensor` in an inconsistent manner [bad-override] -ERROR homeassistant/components/garadget/cover.py:124:27-40: `Literal['offline']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:133:27-40: `Literal['offline']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:202:42-204:14: `() -> None` is not assignable to attribute `_unsub_listener_cover` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:233:27-59: `CoverState | str | None` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:240:27-40: `Literal['offline']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:246:27-40: `Literal['offline']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/garadget/cover.py:253:42-46: `None` is not assignable to attribute `_unsub_listener_cover` with type `Never` [bad-assignment] ERROR homeassistant/components/garages_amsterdam/binary_sensor.py:34:9-12: Unexpected keyword argument `key` in function `GaragesAmsterdamBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/garages_amsterdam/binary_sensor.py:35:9-24: Unexpected keyword argument `translation_key` in function `GaragesAmsterdamBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/garages_amsterdam/binary_sensor.py:63:5-23: Class member `GaragesAmsterdamBinarySensor.entity_description` overrides parent class `GaragesAmsterdamEntity` in an inconsistent manner [bad-override] @@ -7870,7 +7740,6 @@ ERROR homeassistant/components/gdacs/geo_location.py:164:32-57: `None` is not su ERROR homeassistant/components/generic/config_flow.py:179:15-18: `url` may be uninitialized [unbound-name] ERROR homeassistant/components/generic/config_flow.py:265:25-38: `stream_source` may be uninitialized [unbound-name] ERROR homeassistant/components/generic/config_flow.py:267:62-75: `stream_source` may be uninitialized [unbound-name] -ERROR homeassistant/components/generic/config_flow.py:338:9-31: Class member `GenericIPCamConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/generic_thermostat/climate.py:264:14-38: Class member `GenericThermostat._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/geniushub/__init__.py:176:13-38: Module `aiohttp.client_exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/geniushub/climate.py:48:5-29: Class member `GeniusClimateZone._attr_supported_features` overrides parent class `GeniusHeatingZone` in an inconsistent manner [bad-override] @@ -7880,10 +7749,6 @@ ERROR homeassistant/components/gentex_homelink/event.py:54:14-24: Class member ` ERROR homeassistant/components/gentex_homelink/event.py:55:14-29: Class member `HomeLinkEventEntity._attr_unique_id` overrides parent class `EventEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/geo_json_events/geo_location.py:109:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/geo_json_events/geo_location.py:110:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/geo_rss_events/sensor.py:164:27-44: `int` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/geo_rss_events/sensor.py:171:38-44: `dict[@_, @_]` is not assignable to attribute `_state_attributes` with type `None` [bad-assignment] -ERROR homeassistant/components/geo_rss_events/sensor.py:181:27-28: `Literal[0]` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/geo_rss_events/sensor.py:182:38-40: `dict[@_, @_]` is not assignable to attribute `_state_attributes` with type `None` [bad-assignment] ERROR homeassistant/components/geocaching/coordinator.py:23:5-17: Class member `GeocachingDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/geocaching/sensor.py:37:9-12: Unexpected keyword argument `key` in function `GeocachingSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/geocaching/sensor.py:38:9-24: Unexpected keyword argument `translation_key` in function `GeocachingSensorEntityDescription.__init__` [unexpected-keyword] @@ -7907,26 +7772,10 @@ ERROR homeassistant/components/geocaching/sensor.py:163:5-23: Class member `Geoc ERROR homeassistant/components/geocaching/sensor.py:163:5-23: Class member `GeocachingProfileSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/geofency/device_tracker.py:71:14-31: Class member `GeofencyEntity._attr_device_info` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/geofency/device_tracker.py:71:34-74:10: `DeviceInfo` is not assignable to attribute `_attr_device_info` with type `None` [bad-assignment] -ERROR homeassistant/components/geofency/device_tracker.py:79:34-81:10: `() -> None` is not assignable to attribute `_unsub_dispatcher` with type `None` [bad-assignment] ERROR homeassistant/components/geofency/device_tracker.py:98:9-31: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/geonetnz_quakes/__init__.py:139:25-53: Argument `timedelta` is not assignable to parameter `filter_time` with type `datetime` in function `aio_geojson_geonetnz_quakes.feed_manager.GeonetnzQuakesFeedManager.__init__` [bad-argument-type] -ERROR homeassistant/components/geonetnz_quakes/__init__.py:160:44-162:10: `() -> None` is not assignable to attribute `_track_time_remove_callback` with type `None` [bad-assignment] ERROR homeassistant/components/geonetnz_quakes/geo_location.py:146:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/geonetnz_quakes/geo_location.py:147:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:149:23-39: `float | None` is not assignable to attribute `_depth` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:150:26-45: `str | None` is not assignable to attribute `_locality` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:151:27-47: `float | None` is not assignable to attribute `_magnitude` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:152:21-35: `int | None` is not assignable to attribute `_mmi` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:153:25-43: `str | None` is not assignable to attribute `_quality` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/geo_location.py:154:22-37: `datetime | None` is not assignable to attribute `_time` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/sensor.py:67:38-71:10: `() -> None` is not assignable to attribute `_remove_signal_status` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/sensor.py:99:13-89: `datetime | None` is not assignable to attribute `_last_update` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_quakes/sensor.py:102:44-104:14: `datetime` is not assignable to attribute `_last_update_successful` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_volcano/__init__.py:152:44-154:10: `() -> None` is not assignable to attribute `_track_time_remove_callback` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_volcano/sensor.py:83:38-87:10: `() -> None` is not assignable to attribute `_remove_signal_update` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_volcano/sensor.py:113:30-120:14: `float` is not assignable to attribute `_distance` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_volcano/sensor.py:129:34-86: `datetime | None` is not assignable to attribute `_feed_last_update` with type `None` [bad-assignment] -ERROR homeassistant/components/geonetnz_volcano/sensor.py:131:13-87: `datetime | None` is not assignable to attribute `_feed_last_update_successful` with type `None` [bad-assignment] ERROR homeassistant/components/gios/coordinator.py:35:5-17: Class member `GiosDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/gios/sensor.py:60:9-12: Unexpected keyword argument `key` in function `GiosSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/gios/sensor.py:64:9-24: Unexpected keyword argument `translation_key` in function `GiosSensorEntityDescription.__init__` [unexpected-keyword] @@ -7967,7 +7816,6 @@ ERROR homeassistant/components/github/config_flow.py:132:29-59: Argument `str | ERROR homeassistant/components/github/config_flow.py:140:29-44: Keyword argument `client_name` with type `str` is not assignable to parameter `**kwargs` with type `dict[GitHubClientKwarg, Any]` in function `aiogithubapi.device.GitHubDeviceAPI.__init__` [bad-argument-type] ERROR homeassistant/components/github/config_flow.py:165:38-168:14: Argument `dict[str, str | None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.data_entry_flow.FlowHandler.async_show_progress` [bad-argument-type] ERROR homeassistant/components/github/config_flow.py:183:62-86: Argument `str | None` is not assignable to parameter `access_token` with type `str` in function `get_repositories` [bad-argument-type] -ERROR homeassistant/components/github/config_flow.py:210:9-31: Class member `GitHubConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/github/coordinator.py:108:5-17: Class member `GitHubDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/github/coordinator.py:132:15-33: Class member `GitHubDataUpdateCoordinator._async_update_data` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/github/coordinator.py:149:16-37: `None` is not subscriptable [unsupported-operation] @@ -8009,7 +7857,6 @@ ERROR homeassistant/components/github/sensor.py:161:5-23: Class member `GitHubSe ERROR homeassistant/components/gitlab_ci/sensor.py:8:1-69: Could not find import of `gitlab` [missing-import] ERROR homeassistant/components/gitter/sensor.py:7:1-41: Could not find import of `gitterpy.client` [missing-import] ERROR homeassistant/components/gitter/sensor.py:8:1-62: Could not find import of `gitterpy.errors` [missing-import] -ERROR homeassistant/components/gitter/sensor.py:112:27-44: `int` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/glances/coordinator.py:26:5-17: Class member `GlancesDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/glances/sensor.py:38:9-12: Unexpected keyword argument `key` in function `GlancesSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/glances/sensor.py:40:9-24: Unexpected keyword argument `translation_key` in function `GlancesSensorEntityDescription.__init__` [unexpected-keyword] @@ -8159,7 +8006,7 @@ ERROR homeassistant/components/gogogate2/cover.py:46:5-29: Class member `DeviceC ERROR homeassistant/components/gogogate2/cover.py:57:14-32: Class member `DeviceCover._attr_device_class` overrides parent class `GoGoGate2Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/gogogate2/entity.py:45:16-49: Returned type `DoorStatus | TransitionDoorStatus` is not assignable to declared return type `AbstractDoor` [bad-return] ERROR homeassistant/components/gogogate2/sensor.py:39:9-43:10: Argument `list[DoorSensorTemperature]` is not assignable to parameter `*iterables` with type `Iterable[DoorSensorBattery]` in function `itertools.chain.__new__` [bad-argument-type] -ERROR homeassistant/components/goodwe/__init__.py:38:21-55: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/goodwe/__init__.py:36:29-43:6: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (configuration_url=Literal['https://www.semsportal.com'], identifiers=set[tuple[str, str | None]], name=str, manufacturer=Literal['GoodWe'], model=str | None, sw_version=str) [no-matching-overload] ERROR homeassistant/components/goodwe/button.py:29:5-8: Unexpected keyword argument `key` in function `GoodweButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/goodwe/button.py:30:5-20: Unexpected keyword argument `translation_key` in function `GoodweButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/goodwe/button.py:31:5-20: Unexpected keyword argument `entity_category` in function `GoodweButtonEntityDescription.__init__` [unexpected-keyword] @@ -8212,7 +8059,6 @@ ERROR homeassistant/components/google/calendar.py:284:53-287:18: Missing argumen ERROR homeassistant/components/google/calendar.py:340:5-23: Class member `GoogleCalendarEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/google/calendar.py:340:5-23: Class member `GoogleCalendarEntity.entity_description` overrides parent class `CalendarEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/google/calendar.py:449:27-39: `offset_value` may be uninitialized [unbound-name] -ERROR homeassistant/components/google/config_flow.py:242:9-31: Class member `OAuth2FlowHandler.async_get_options_flow` overrides parent class `AbstractOAuth2FlowHandler` in an inconsistent manner [bad-override] ERROR homeassistant/components/google/coordinator.py:51:5-17: Class member `CalendarSyncUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/google/coordinator.py:112:5-17: Class member `CalendarQueryUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/google/coordinator.py:139:36-144:10: Missing argument `calendarId` in function `gcal_sync.api.ListEventsRequest.__init__` [missing-argument] @@ -8248,13 +8094,9 @@ ERROR homeassistant/components/google_assistant/helpers.py:89:12-24: `entity_ent ERROR homeassistant/components/google_assistant/helpers.py:437:58-71: Argument `None` is not assignable to parameter `agent_user_id` with type `str` in function `homeassistant.components.google_assistant.data_redaction.async_redact_msg` [bad-argument-type] ERROR homeassistant/components/google_assistant/helpers.py:458:65-70: `msgid` may be uninitialized [unbound-name] ERROR homeassistant/components/google_assistant/helpers.py:460:69-74: `msgid` may be uninitialized [unbound-name] -ERROR homeassistant/components/google_assistant/helpers.py:622:13-40: Cannot set item in `list[str]` [unsupported-operation] -ERROR homeassistant/components/google_assistant/helpers.py:622:13-40: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/google_assistant/helpers.py:637:13-40: Object of class `list` has no attribute `update` -Object of class `str` has no attribute `update` [missing-attribute] ERROR homeassistant/components/google_assistant/helpers.py:740:22-58: `State | None` is not assignable to attribute `state` with type `State` [bad-assignment] +ERROR homeassistant/components/google_assistant/http.py:243:38-68: `>` is not supported between `datetime` and `None` [unsupported-operation] ERROR homeassistant/components/google_assistant/http.py:252:34-55: Cannot index into `list[Any]` [bad-index] -ERROR homeassistant/components/google_assistant/http.py:253:40-84: `datetime` is not assignable to attribute `_access_token_renew` with type `None` [bad-assignment] ERROR homeassistant/components/google_assistant/http.py:253:64-83: Cannot index into `list[Any]` [bad-index] ERROR homeassistant/components/google_assistant/http.py:334:47-51: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/google_assistant/http.py:336:17-21: `data` may be uninitialized [unbound-name] @@ -8287,7 +8129,6 @@ ERROR homeassistant/components/google_assistant/trait.py:1668:36-45: `arm_level` ERROR homeassistant/components/google_assistant/trait.py:1672:45-54: `arm_level` may be uninitialized [unbound-name] ERROR homeassistant/components/google_assistant/trait.py:1738:9-18: Class member `FanSpeedTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/google_assistant/trait.py:1889:9-18: Class member `ModesTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] -ERROR homeassistant/components/google_assistant/trait.py:1928:13-36: Object of class `bool` has no attribute `append` [missing-attribute] ERROR homeassistant/components/google_assistant/trait.py:2120:9-18: Class member `InputSelectorTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/google_assistant/trait.py:2192:9-18: Class member `OpenCloseTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/google_assistant/trait.py:2345:9-18: Class member `VolumeTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] @@ -8296,7 +8137,6 @@ ERROR homeassistant/components/google_assistant/trait.py:2645:9-18: Class member ERROR homeassistant/components/google_assistant/trait.py:2672:9-18: Class member `ChannelTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/google_assistant/trait.py:2771:9-18: Class member `SensorStateTrait.supported` overrides parent class `_Trait` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/google_assistant_sdk/helpers.py:109:29-67: Object of class `NoneType` has no attribute `format` [missing-attribute] -ERROR homeassistant/components/google_cloud/config_flow.py:134:9-31: Class member `GoogleCloudConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/google_cloud/tts.py:63:8-16: `key_file` may be uninitialized [unbound-name] ERROR homeassistant/components/google_cloud/tts.py:65:13-21: `key_file` may be uninitialized [unbound-name] ERROR homeassistant/components/google_drive/backup.py:109:15-36: Class member `GoogleDriveBackupAgent.async_download_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] @@ -8332,7 +8172,6 @@ ERROR homeassistant/components/google_tasks/api.py:144:28-41: Object of class `R ERROR homeassistant/components/google_tasks/api.py:156:53-63: Object of class `ServerNotFoundError` has no attribute `reason` [missing-attribute] ERROR homeassistant/components/google_tasks/api.py:156:67-82: Object of class `ServerNotFoundError` has no attribute `status_code` [missing-attribute] ERROR homeassistant/components/google_tasks/coordinator.py:25:5-17: Class member `TaskUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/google_travel_time/config_flow.py:215:9-31: Class member `GoogleTravelTimeConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/google_travel_time/sensor.py:97:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/google_travel_time/sensor.py:280:32-46: `departure_time` may be uninitialized [unbound-name] ERROR homeassistant/components/google_travel_time/sensor.py:281:30-42: `arrival_time` may be uninitialized [unbound-name] @@ -8479,7 +8318,6 @@ ERROR homeassistant/components/gpsd/sensor.py:151:9-40: Unexpected keyword argum ERROR homeassistant/components/gpsd/sensor.py:179:5-23: Class member `GpsdSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/gpslogger/device_tracker.py:83:14-31: Class member `GPSLoggerEntity._attr_device_info` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/gpslogger/device_tracker.py:83:34-86:10: `DeviceInfo` is not assignable to attribute `_attr_device_info` with type `None` [bad-assignment] -ERROR homeassistant/components/gpslogger/device_tracker.py:96:34-98:10: `() -> None` is not assignable to attribute `_unsub_dispatcher` with type `None` [bad-assignment] ERROR homeassistant/components/gpslogger/device_tracker.py:134:9-31: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/graphite/__init__.py:107:9-34: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/gree/climate.py:109:5-29: Class member `GreeClimateEntity._attr_supported_features` overrides parent class `GreeEntity` in an inconsistent manner [bad-override] @@ -8844,7 +8682,6 @@ ERROR homeassistant/components/growatt_server/switch.py:43:9-24: Unexpected keyw ERROR homeassistant/components/growatt_server/switch.py:75:5-23: Class member `GrowattSwitch.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/growatt_server/switch.py:75:5-23: Class member `GrowattSwitch.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/gtfs/sensor.py:11:8-14: Could not find import of `pygtfs` [missing-import] -ERROR homeassistant/components/gtfs/sensor.py:640:36-41: `Literal[False]` is not assignable to attribute `_agency` with type `None` [bad-assignment] ERROR homeassistant/components/guardian/binary_sensor.py:61:9-12: Unexpected keyword argument `key` in function `PairedSensorBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/guardian/binary_sensor.py:62:9-24: Unexpected keyword argument `translation_key` in function `PairedSensorBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/guardian/binary_sensor.py:67:9-12: Unexpected keyword argument `key` in function `PairedSensorBinarySensorDescription.__init__` [unexpected-keyword] @@ -9083,12 +8920,11 @@ ERROR homeassistant/components/harman_kardon_avr/media_player.py:5:8-13: Could n ERROR homeassistant/components/harmony/config_flow.py:87:48-57: `validated` may be uninitialized [unbound-name] ERROR homeassistant/components/harmony/config_flow.py:90:21-30: `validated` may be uninitialized [unbound-name] ERROR homeassistant/components/harmony/config_flow.py:116:34-53: Argument `bytes | str | None` is not assignable to parameter `ip_address` with type `str` in function `aioharmony.hubconnector_websocket.HubConnector.__init__` [bad-argument-type] -ERROR homeassistant/components/harmony/config_flow.py:157:9-31: Class member `HarmonyConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/harmony/data.py:113:68-79: Unpacked keyword argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `connect` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] -ERROR homeassistant/components/harmony/data.py:113:68-79: Unpacked keyword argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `disconnect` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] -ERROR homeassistant/components/harmony/data.py:113:68-79: Unpacked keyword argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `new_activity_starting` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] -ERROR homeassistant/components/harmony/data.py:113:68-79: Unpacked keyword argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `new_activity` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] -ERROR homeassistant/components/harmony/data.py:113:68-79: Unpacked keyword argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None] | BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `config_updated` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] +ERROR homeassistant/components/harmony/data.py:113:68-79: Argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: dict[Unknown, Unknown] | None = None) -> None]` is not assignable to parameter `config_updated` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] +ERROR homeassistant/components/harmony/data.py:113:68-79: Argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None]` is not assignable to parameter `connect` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] +ERROR homeassistant/components/harmony/data.py:113:68-79: Argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, _: str | None = None) -> None]` is not assignable to parameter `disconnect` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] +ERROR homeassistant/components/harmony/data.py:113:68-79: Argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `new_activity_starting` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] +ERROR homeassistant/components/harmony/data.py:113:68-79: Argument `BoundMethod[Self@HarmonyData, (self: Self@HarmonyData, activity_info: tuple[Unknown, ...]) -> None]` is not assignable to parameter `new_activity` with type `((object, Any | None) -> Any) | Event | Future[Unknown] | None` in function `aioharmony.const.ClientCallbackType.__new__` [bad-argument-type] ERROR homeassistant/components/harmony/data.py:234:28-37: Argument `str` is not assignable to parameter `device` with type `int` in function `aioharmony.const.SendCommandDevice.__new__` [bad-argument-type] ERROR homeassistant/components/harmony/remote.py:88:5-29: Class member `HarmonyRemote._attr_supported_features` overrides parent class `HarmonyEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/harmony/remote.py:88:5-29: Class member `HarmonyRemote._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] @@ -9185,11 +9021,7 @@ ERROR homeassistant/components/hassio/update.py:273:7-33: Field `entity_descript `, which is not assignable to the type `UpdateEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/hassio/update.py:276:5-29: Class member `SupervisorCoreUpdateEntity._attr_supported_features` overrides parent class `HassioCoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/haveibeenpwned/sensor.py:94:17-59: Argument `datetime | None` is not assignable to parameter `dattim` with type `datetime` in function `homeassistant.util.dt.as_local` [bad-argument-type] -ERROR homeassistant/components/haveibeenpwned/sensor.py:124:23-56: `int` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/haveibeenpwned/sensor.py:132:27-60: `int` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/hddtemp/sensor.py:68:27-41: No matching overload found for function `iter` called with arguments: (None) [no-matching-overload] -ERROR homeassistant/components/hddtemp/sensor.py:100:57-85: `Literal[UnitOfTemperature.FAHRENHEIT]` is not assignable to attribute `_attr_native_unit_of_measurement` with type `Never` [bad-assignment] -ERROR homeassistant/components/hddtemp/sensor.py:127:25-89: `dict[str, str]` is not assignable to attribute `data` with type `None` [bad-assignment] +ERROR homeassistant/components/hddtemp/sensor.py:68:27-41: No matching overload found for function `iter` called with arguments: (Unknown | None) [no-matching-overload] ERROR homeassistant/components/hdmi_cec/__init__.py:189:51-72: Argument `HassJob[[now: Unknown | None = None], Unknown]` is not assignable to parameter `action` with type `((datetime) -> Coroutine[Any, Any, None] | None) | HassJob[[datetime], Coroutine[Any, Any, None] | None]` [bad-argument-type] ERROR homeassistant/components/hdmi_cec/__init__.py:200:64-85: Argument `HassJob[[now: Unknown | None = None], Unknown]` is not assignable to parameter `action` with type `((datetime) -> Coroutine[Any, Any, None] | None) | HassJob[[datetime], Coroutine[Any, Any, None] | None]` in function `homeassistant.helpers.event.async_call_later` [bad-argument-type] ERROR homeassistant/components/hdmi_cec/__init__.py:258:49-52: Argument `Literal[''] | Unknown` is not assignable to parameter `att` with type `list[int]` in function `pycec.commands.CecCommand.__init__` [bad-argument-type] @@ -9199,11 +9031,7 @@ ERROR homeassistant/components/hdmi_cec/__init__.py:287:36-40: `addr` may be uni ERROR homeassistant/components/hdmi_cec/__init__.py:288:67-71: `addr` may be uninitialized [unbound-name] ERROR homeassistant/components/hdmi_cec/media_player.py:95:14-25: Class member `CecPlayerEntity._attr_state` overrides parent class `CecEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/heatmiser/climate.py:8:1-46: Could not find import of `heatmiserv3` [missing-import] -ERROR homeassistant/components/heatmiser/climate.py:116:36-52: `int` is not assignable to attribute `_target_temperature` with type `None` [bad-assignment] -ERROR homeassistant/components/heatmiser/climate.py:131:37-69: `int` is not assignable to attribute `_current_temperature` with type `None` [bad-assignment] -ERROR homeassistant/components/heatmiser/climate.py:132:36-69: `int` is not assignable to attribute `_target_temperature` with type `None` [bad-assignment] ERROR homeassistant/components/heos/media_player.py:168:5-29: Class member `HeosMediaPlayer._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/here_travel_time/config_flow.py:116:9-31: Class member `HERETravelTimeConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/here_travel_time/coordinator.py:67:5-17: Class member `HERERoutingDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/here_travel_time/coordinator.py:191:5-17: Class member `HERETransitDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/here_travel_time/coordinator.py:226:30-46: Argument `str` is not assignable to parameter `latitude` with type `float` in function `here_transit.model.Place.__init__` [bad-argument-type] @@ -9227,9 +9055,6 @@ ERROR homeassistant/components/here_travel_time/sensor.py:205:13-28: Unexpected ERROR homeassistant/components/here_travel_time/sensor.py:206:13-17: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/here_travel_time/sensor.py:207:13-16: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/hikvision/binary_sensor.py:8:1-38: Could not find import of `pyhik.hikvision` [missing-import] -ERROR homeassistant/components/hikvision/binary_sensor.py:286:31-35: `None` is not assignable to attribute `_timer` with type `Never` [bad-assignment] -ERROR homeassistant/components/hikvision/binary_sensor.py:288:27-290:14: `() -> None` is not assignable to attribute `_timer` with type `None` [bad-assignment] -ERROR homeassistant/components/hikvision/binary_sensor.py:296:31-35: `None` is not assignable to attribute `_timer` with type `Never` [bad-assignment] ERROR homeassistant/components/hikvisioncam/switch.py:8:8-21: Could not find import of `hikvision.api` [missing-import] ERROR homeassistant/components/hikvisioncam/switch.py:9:1-62: Could not find import of `hikvision.error` [missing-import] WARN homeassistant/components/history/__init__.py:124:20-137:10: Redundant cast: `Response` is the same type as `Response` [redundant-cast] @@ -9244,8 +9069,7 @@ ERROR homeassistant/components/history/websocket_api.py:579:29-39: `start_time` ERROR homeassistant/components/history_stats/config_flow.py:194:73-196:10: No matching overload found for function `dict.get` called with arguments: (_HandlerT) [no-matching-overload] ERROR homeassistant/components/history_stats/config_flow.py:201:60-82: Argument `_HandlerT` is not assignable to parameter `entry_id` with type `str` in function `homeassistant.config_entries.ConfigEntries.async_get_entry` [bad-argument-type] ERROR homeassistant/components/history_stats/config_flow.py:206:60-82: Argument `_HandlerT` is not assignable to parameter `entry_id` with type `str` in function `homeassistant.config_entries.ConfigEntries.async_get_entry` [bad-argument-type] -ERROR homeassistant/components/hitron_coda/device_tracker.py:96:28-49: `str` is not assignable to attribute `_userid` with type `None` [bad-assignment] -ERROR homeassistant/components/hitron_coda/device_tracker.py:113:63-87: Argument `dict[str, None]` is not assignable to parameter `cookies` with type `CookieJar | MutableMapping[str, str] | None` in function `requests.api.get` [bad-argument-type] +ERROR homeassistant/components/hitron_coda/device_tracker.py:113:63-87: Argument `dict[str, Unknown | None]` is not assignable to parameter `cookies` with type `CookieJar | MutableMapping[str, str] | None` in function `requests.api.get` [bad-argument-type] ERROR homeassistant/components/hive/binary_sensor.py:25:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/hive/binary_sensor.py:28:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/hive/binary_sensor.py:32:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -9266,8 +9090,7 @@ ERROR homeassistant/components/hive/binary_sensor.py:110:14-32: Class member `Hi ERROR homeassistant/components/hive/binary_sensor.py:140:14-32: Class member `HiveSensorEntity.entity_description` overrides parent class `HiveEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hive/climate.py:93:5-29: Class member `HiveClimateEntity._attr_supported_features` overrides parent class `HiveEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hive/climate.py:127:61-63: Argument `Literal[30]` is not assignable to parameter `mins` with type `str` in function `apyhiveapi.heating.HiveHeating.setBoostOn` [bad-argument-type] -ERROR homeassistant/components/hive/config_flow.py:167:9-31: Class member `HiveFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/hive/config_flow.py:194:21-51: `Hive` is not assignable to attribute `hive` with type `None` [bad-assignment] +ERROR homeassistant/components/hive/config_flow.py:199:44-56: Argument `Any | None` is not assignable to parameter `new_interval` with type `timedelta` in function `apyhiveapi.session.HiveSession.updateInterval` [bad-argument-type] ERROR homeassistant/components/hive/light.py:83:26-40: Argument `int | None` is not assignable to parameter `brightness` with type `int` in function `apyhiveapi.light.Light.turnOn` [bad-argument-type] ERROR homeassistant/components/hive/light.py:83:42-56: Argument `Any | None` is not assignable to parameter `color_temp` with type `int` in function `apyhiveapi.light.Light.turnOn` [bad-argument-type] ERROR homeassistant/components/hive/light.py:83:58-67: Argument `tuple[int, int, Literal[100]] | None` is not assignable to parameter `color` with type `list[Unknown]` in function `apyhiveapi.light.Light.turnOn` [bad-argument-type] @@ -9292,7 +9115,6 @@ ERROR homeassistant/components/hive/switch.py:67:14-32: Class member `HiveSwitch ERROR homeassistant/components/hive/water_heater.py:76:5-29: Class member `HiveWaterHeater._attr_supported_features` overrides parent class `HiveEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hko/coordinator.py:74:5-17: Class member `HKOUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/hlk_sw16/config_flow.py:56:17-56: Object of class `NoneType` has no attribute `set_exception` [missing-attribute] -ERROR homeassistant/components/holiday/config_flow.py:116:9-31: Class member `HolidayConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/holiday/config_flow.py:176:69-77: `province` may be uninitialized [unbound-name] ERROR homeassistant/components/holiday/config_flow.py:207:69-77: `province` may be uninitialized [unbound-name] ERROR homeassistant/components/home_connect/binary_sensor.py:39:9-12: Unexpected keyword argument `key` in function `HomeConnectBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -9635,7 +9457,6 @@ ERROR homeassistant/components/homeassistant_connect_zbt2/update.py:36:9-12: Une ERROR homeassistant/components/homeassistant_connect_zbt2/update.py:47:9-12: Unexpected keyword argument `key` in function `homeassistant.components.homeassistant_hardware.update.FirmwareUpdateEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/homeassistant_connect_zbt2/update.py:58:9-12: Unexpected keyword argument `key` in function `homeassistant.components.homeassistant_hardware.update.FirmwareUpdateEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/homeassistant_connect_zbt2/update.py:69:9-12: Unexpected keyword argument `key` in function `homeassistant.components.homeassistant_hardware.update.FirmwareUpdateEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/homeassistant_green/config_flow.py:47:9-31: Class member `HomeAssistantGreenConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/homeassistant_green/hardware.py:26:12-17: `board` is uninitialized [unbound-name] ERROR homeassistant/components/homeassistant_green/hardware.py:36:33-38: `board` is uninitialized [unbound-name] ERROR homeassistant/components/homeassistant_hardware/firmware_config_flow.py:282:45-88: Argument `str | None` is not assignable to parameter `version` with type `str` in function `universal_silabs_flasher.common.Version.__init__` [bad-argument-type] @@ -9863,9 +9684,6 @@ ERROR homeassistant/components/homekit/accessories.py:330:13-59: Multiple values ERROR homeassistant/components/homekit/accessories.py:378:13-41: Object of class `NoneType` has no attribute `add_characteristic` [missing-attribute] ERROR homeassistant/components/homekit/accessories.py:379:13-37: Object of class `NoneType` has no attribute `configure_char` [missing-attribute] ERROR homeassistant/components/homekit/accessories.py:440:49-69: Argument `Literal['BatteryService']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] -ERROR homeassistant/components/homekit/accessories.py:441:30-86: `Characteristic` is not assignable to attribute `_char_battery` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/accessories.py:442:31-444:10: `Characteristic` is not assignable to attribute `_char_charging` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/accessories.py:445:34-447:10: `Characteristic` is not assignable to attribute `_char_low_battery` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/accessories.py:464:43-48: `state` may be uninitialized [unbound-name] ERROR homeassistant/components/homekit/accessories.py:493:14-19: `state` may be uninitialized [unbound-name] ERROR homeassistant/components/homekit/accessories.py:494:29-34: `state` may be uninitialized [unbound-name] @@ -9875,13 +9693,10 @@ ERROR homeassistant/components/homekit/accessories.py:749:56-70: Argument `Acces ERROR homeassistant/components/homekit/accessories.py:751:13-35: Object of class `NoneType` has no attribute `xhm_uri` [missing-attribute] ERROR homeassistant/components/homekit/accessories.py:765:15-29: Object of class `NoneType` has no attribute `aid` [missing-attribute] ERROR homeassistant/components/homekit/accessories.py:767:32-43: `Service | None` is not assignable to `Service` [bad-assignment] -ERROR homeassistant/components/homekit/config_flow.py:363:9-31: Class member `HomeKitConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/homekit/diagnostics.py:42:66-82: Argument `Accessory` is not assignable to parameter `accessory` with type `HomeAccessory` in function `_get_accessory_diagnostics` [bad-argument-type] -ERROR homeassistant/components/homekit/diagnostics.py:80:32-74: Cannot set item in `dict[str, dict[str, Any] | int | str | None]` [unsupported-operation] +ERROR homeassistant/components/homekit/diagnostics.py:80:32-74: `State` is not assignable to TypedDict key `entity_state` with type `dict[str, Any] | int | str | None` [bad-typed-dict-key] ERROR homeassistant/components/homekit/doorbell.py:55:50-63: Argument `Literal['Doorbell']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] -ERROR homeassistant/components/homekit/doorbell.py:57:40-60:10: `Characteristic` is not assignable to attribute `_char_doorbell_detected` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/doorbell.py:62:13-47: Argument `Literal['StatelessProgrammableSwitch']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] -ERROR homeassistant/components/homekit/doorbell.py:64:47-68:10: `Characteristic` is not assignable to attribute `_char_doorbell_detected_switch` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/doorbell.py:69:49-61: Argument `Literal['Speaker']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_air_purifiers.py:96:54-71: Argument `Literal['AirPurifier']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_air_purifiers.py:96:73-83: Argument `list[str]` is not assignable to parameter `chars` with type `Iterable[Characteristic] | None` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] @@ -9896,19 +9711,14 @@ ERROR homeassistant/components/homekit/type_air_purifiers.py:181:42-47: Argument ERROR homeassistant/components/homekit/type_air_purifiers.py:428:69-87: `current_life_level` may be uninitialized [unbound-name] ERROR homeassistant/components/homekit/type_air_purifiers.py:434:17-35: `current_life_level` may be uninitialized [unbound-name] ERROR homeassistant/components/homekit/type_cameras.py:226:56-74: Argument `Literal['MotionSensor']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] -ERROR homeassistant/components/homekit/type_cameras.py:227:46-229:18: `Characteristic` is not assignable to attribute `_char_motion_detected` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/type_cameras.py:366:26-38: `input_source` may be uninitialized [unbound-name] ERROR homeassistant/components/homekit/type_covers.py:110:53-76: Argument `Literal['GarageDoorOpener']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_covers.py:353:65-74: Argument `Literal['Door']` is not assignable to parameter `service` with type `Service` in function `OpeningDevice.__init__` [bad-argument-type] ERROR homeassistant/components/homekit/type_covers.py:365:67-78: Argument `Literal['Window']` is not assignable to parameter `service` with type `Service` in function `OpeningDevice.__init__` [bad-argument-type] ERROR homeassistant/components/homekit/type_covers.py:378:63-83: Argument `Literal['WindowCovering']` is not assignable to parameter `service` with type `Service` in function `OpeningDevice.__init__` [bad-argument-type] ERROR homeassistant/components/homekit/type_covers.py:393:63-83: Argument `Literal['WindowCovering']` is not assignable to parameter `service` with type `Service` in function `OpeningDeviceBase.__init__` [bad-argument-type] -ERROR homeassistant/components/homekit/type_fans.py:94:35-96:14: `Characteristic` is not assignable to attribute `char_direction` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/type_fans.py:102:31-106:14: `Characteristic` is not assignable to attribute `char_speed` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/type_fans.py:114:42-117:14: `Characteristic` is not assignable to attribute `char_target_fan_state` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/type_fans.py:124:21-32: Argument `Literal['Switch']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_fans.py:125:21-54: Argument `list[str]` is not assignable to parameter `chars` with type `Iterable[Characteristic] | None` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] -ERROR homeassistant/components/homekit/type_fans.py:149:31-80: `Characteristic` is not assignable to attribute `char_swing` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/type_fans.py:157:45-55: Argument `Literal['Fanv2']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_fans.py:157:57-67: Argument `list[str]` is not assignable to parameter `chars` with type `Iterable[Characteristic] | None` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_humidifiers.py:124:13-41: Argument `Literal['HumidifierDehumidifier']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] @@ -9960,10 +9770,6 @@ ERROR homeassistant/components/homekit/type_switches.py:535:34-63: Argument `Cha ERROR homeassistant/components/homekit/type_thermostats.py:235:52-67: Argument `Literal['Thermostat']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_thermostats.py:235:69-79: Argument `list[str]` is not assignable to parameter `chars` with type `Iterable[Characteristic] | None` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_thermostats.py:252:26-49: Argument `dict[HVACMode, int]` is not assignable to parameter `valid_values` with type `dict[str, Any] | None` in function `pyhap.characteristic.Characteristic.override_properties` [bad-argument-type] -ERROR homeassistant/components/homekit/type_thermostats.py:279:45-286:14: `Characteristic` is not assignable to attribute `char_cooling_thresh_temp` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/type_thermostats.py:288:45-295:14: `Characteristic` is not assignable to attribute `char_heating_thresh_temp` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/type_thermostats.py:298:41-307:14: `Characteristic` is not assignable to attribute `char_target_humidity` with type `None` [bad-assignment] -ERROR homeassistant/components/homekit/type_thermostats.py:310:42-312:14: `Characteristic` is not assignable to attribute `char_current_humidity` with type `None` [bad-assignment] ERROR homeassistant/components/homekit/type_thermostats.py:349:49-59: Argument `Literal['Fanv2']` is not assignable to parameter `service` with type `Service` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_thermostats.py:349:61-75: Argument `list[str]` is not assignable to parameter `chars` with type `Iterable[Characteristic] | None` in function `pyhap.accessory.Accessory.add_preload_service` [bad-argument-type] ERROR homeassistant/components/homekit/type_thermostats.py:475:20-47: `CHAR_TARGET_HEATING_COOLING` may be uninitialized [unbound-name] @@ -10189,7 +9995,6 @@ ERROR homeassistant/components/homematic/entity.py:178:41-69: Object of class `H ERROR homeassistant/components/homematic/entity.py:189:24-35: Cannot set item in `dict[str, Any]` [unsupported-operation] ERROR homeassistant/components/homematic/entity.py:194:31-42: Cannot index into `dict[str, Any]` [bad-index] ERROR homeassistant/components/homematic/entity.py:200:26-54: Object of class `HMGeneric` has no attribute `ATTRIBUTENODE` [missing-attribute] -ERROR homeassistant/components/homematic/entity.py:259:27-32: `int | None` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/homematic/light.py:47:7-14: Field `entity_description` is declared `EntityDescription` in ancestor `class HMDevice: ... `, which is not assignable to the type `LightEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/homematic/light.py:72:23-47: Object of class `HMGeneric` has no attribute `WRITENODE` [missing-attribute] @@ -10272,16 +10077,16 @@ ERROR homeassistant/components/homematic/switch.py:58:9-26: Object of class `HMG ERROR homeassistant/components/homematic/switch.py:62:9-27: Object of class `HMGeneric` has no attribute `off` [missing-attribute] ERROR homeassistant/components/homematic/switch.py:70:21-46: Object of class `HMGeneric` has no attribute `SENSORNODE` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/__init__.py:99:29-39: Object of class `AsyncHome` has no attribute `label` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/__init__.py:103:21-40: Argument `set[tuple[str, None]]` is not assignable to parameter `identifiers` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] +ERROR homeassistant/components/homematicip_cloud/__init__.py:103:21-40: Argument `set[tuple[str, Unknown | None]]` is not assignable to parameter `identifiers` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] ERROR homeassistant/components/homematicip_cloud/__init__.py:106:14-21: Argument `object | str` is not assignable to parameter `name` with type `UndefinedType | str | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] ERROR homeassistant/components/homematicip_cloud/__init__.py:128:8-44: `<` is not supported between `None` and `Literal['2.2.12']` [unsupported-operation] -ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:58:24-47: Argument `tuple[Literal['homematicip_cloud'], None]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:53:26-59:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str]], manufacturer=Literal['eQ-3'], model=Literal['HmIP Alarm Control Panel'], name=str, via_device=tuple[Literal['homematicip_cloud'], Unknown | None]) [no-matching-overload] ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:80:16-67: Returned type `FunctionalHome | None` is not assignable to declared return type `SecurityAndAlarmHome` [bad-return] ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:118:12-27: Object of class `AsyncHome` has no attribute `name` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:125:16-36: Returned type `None` is not assignable to declared return type `bool` [bad-return] +ERROR homeassistant/components/homematicip_cloud/alarm_control_panel.py:125:16-36: Returned type `Unknown | None` is not assignable to declared return type `bool` [bad-return] ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:160:28-43: Object of class `AsyncHome` has no attribute `name` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:167:25-170:14: Argument `set[tuple[str, None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:185:16-36: Returned type `None` is not assignable to declared return type `bool` [bad-return] +ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:166:26-171:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Unknown | None]]) [no-matching-overload] +ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:185:16-36: Returned type `Unknown | None` is not assignable to declared return type `bool` [bad-return] ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:196:5-23: Class member `HomematicipBaseActionSensor._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:226:5-23: Class member `HomematicipMultiContactInterface._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:249:12-31: Object of class `FunctionalChannel` has no attribute `windowState` [missing-attribute] @@ -10296,9 +10101,10 @@ ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:415:5-23: Clas ERROR homeassistant/components/homematicip_cloud/binary_sensor.py:430:5-23: Class member `HomematicipSecurityZoneSensorGroup._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/climate.py:78:5-29: Class member `HomematicipHeatingGroup._attr_supported_features` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/climate.py:85:9-25: Object of class `HeatingGroup` has no attribute `modelType` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/climate.py:89:36-67: `HeatingThermostat | HeatingThermostatCompact | HeatingThermostatEvo | None` is not assignable to attribute `_simple_heating` with type `None` [bad-assignment] ERROR homeassistant/components/homematicip_cloud/climate.py:259:16-64: Returned type `FunctionalHome | None` is not assignable to declared return type `IndoorClimateHome` [bad-return] -ERROR homeassistant/components/homematicip_cloud/climate.py:281:20-32: Returned type `None` is not assignable to declared return type `str` [bad-return] +ERROR homeassistant/components/homematicip_cloud/climate.py:281:20-32: Returned type `Unknown | None` is not assignable to declared return type `str` [bad-return] +ERROR homeassistant/components/homematicip_cloud/climate.py:283:39-52: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR homeassistant/components/homematicip_cloud/climate.py:285:16-29: Returned type `Unknown | None` is not assignable to declared return type `str` [bad-return] ERROR homeassistant/components/homematicip_cloud/climate.py:296:31-44: Cannot index into `dict[str, int]` [bad-index] ERROR homeassistant/components/homematicip_cloud/cover.py:70:5-23: Class member `HomematicipBlindModule._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/cover.py:148:5-23: Class member `HomematicipMultiCoverShutter._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] @@ -10308,7 +10114,6 @@ ERROR homeassistant/components/homematicip_cloud/cover.py:292:15-46: Object of c ERROR homeassistant/components/homematicip_cloud/cover.py:297:15-46: Object of class `FunctionalChannel` has no attribute `async_send_door_command` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/cover.py:302:15-46: Object of class `FunctionalChannel` has no attribute `async_send_door_command` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/cover.py:308:5-23: Class member `HomematicipCoverShutterGroup._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/homematicip_cloud/entity.py:107:39-65: `FunctionalChannel` is not assignable to attribute `functional_channel` with type `None` [bad-assignment] ERROR homeassistant/components/homematicip_cloud/event.py:33:9-12: Unexpected keyword argument `key` in function `HmipEventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/homematicip_cloud/event.py:34:9-24: Unexpected keyword argument `translation_key` in function `HmipEventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/homematicip_cloud/event.py:71:5-23: Class member `HomematicipDoorBellEvent._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] @@ -10321,7 +10126,7 @@ ERROR homeassistant/components/homematicip_cloud/hap.py:39:24-29: Argument `str ERROR homeassistant/components/homematicip_cloud/hap.py:291:9-18: Object of class `AsyncHome` has no attribute `name` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/hap.py:293:9-19: Object of class `AsyncHome` has no attribute `label` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/hap.py:294:9-23: Object of class `AsyncHome` has no attribute `modelType` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/light.py:70:38-60: Argument `None` is not assignable to parameter `version` with type `str` in function `packaging.version.Version.__init__` [bad-argument-type] +ERROR homeassistant/components/homematicip_cloud/light.py:70:38-60: Argument `Unknown | None` is not assignable to parameter `version` with type `str` in function `packaging.version.Version.__init__` [bad-argument-type] ERROR homeassistant/components/homematicip_cloud/light.py:138:16-26: Object of class `FunctionalChannel` has no attribute `on` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/light.py:144:20-36: Object of class `FunctionalChannel` has no attribute `dimLevel` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/light.py:150:12-23: Object of class `FunctionalChannel` has no attribute `hue` [missing-attribute] @@ -10350,8 +10155,8 @@ ERROR homeassistant/components/homematicip_cloud/sensor.py:674:5-23: Class membe ERROR homeassistant/components/homematicip_cloud/sensor.py:691:5-23: Class member `HomematicpTemperatureExternalSensorCh1._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/sensor.py:708:5-23: Class member `HomematicpTemperatureExternalSensorCh2._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homematicip_cloud/sensor.py:725:5-23: Class member `HomematicpTemperatureExternalSensorDelta._attr_device_class` overrides parent class `HomematicipGenericEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/homematicip_cloud/sensor.py:766:51-74: Argument `None` is not assignable to parameter with type `FunctionalChannel` [bad-argument-type] -ERROR homeassistant/components/homematicip_cloud/sensor.py:773:35-58: Argument `None` is not assignable to parameter with type `FunctionalChannel` [bad-argument-type] +ERROR homeassistant/components/homematicip_cloud/sensor.py:766:51-74: Argument `Unknown | None` is not assignable to parameter with type `FunctionalChannel` [bad-argument-type] +ERROR homeassistant/components/homematicip_cloud/sensor.py:773:35-58: Argument `Unknown | None` is not assignable to parameter with type `FunctionalChannel` [bad-argument-type] ERROR homeassistant/components/homematicip_cloud/sensor.py:789:38-69: Object of class `FunctionalChannel` has no attribute `currentPowerConsumption` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/sensor.py:807:38-62: Object of class `FunctionalChannel` has no attribute `energyCounterOne` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/sensor.py:808:37-65: Object of class `FunctionalChannel` has no attribute `energyCounterOneType` [missing-attribute] @@ -10372,7 +10177,7 @@ ERROR homeassistant/components/homematicip_cloud/valve.py:51:15-54: Object of cl ERROR homeassistant/components/homematicip_cloud/valve.py:56:15-54: Object of class `FunctionalChannel` has no attribute `set_watering_switch_state_async` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/valve.py:62:16-38: Object of class `FunctionalChannel` has no attribute `wateringActive` [missing-attribute] ERROR homeassistant/components/homematicip_cloud/weather.py:127:9-27: Object of class `AsyncHome` has no attribute `modelType` [missing-attribute] -ERROR homeassistant/components/homematicip_cloud/weather.py:133:16-36: Returned type `None` is not assignable to declared return type `bool` [bad-return] +ERROR homeassistant/components/homematicip_cloud/weather.py:133:16-36: Returned type `Unknown | None` is not assignable to declared return type `bool` [bad-return] ERROR homeassistant/components/homematicip_cloud/weather.py:138:27-51: Object of class `NoneType` has no attribute `city` [missing-attribute] ERROR homeassistant/components/homewizard/__init__.py:59:17-45: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/homewizard/button.py:29:5-23: Class member `HomeWizardIdentifyButton._attr_device_class` overrides parent class `HomeWizardEntity` in an inconsistent manner [bad-override] @@ -10581,7 +10386,6 @@ ERROR homeassistant/components/homewizard/switch.py:60:9-24: Unexpected keyword ERROR homeassistant/components/homewizard/switch.py:85:5-23: Class member `HomeWizardSwitchEntity.entity_description` overrides parent class `HomeWizardEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homewizard/switch.py:85:5-23: Class member `HomeWizardSwitchEntity.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/homeworks/__init__.py:192:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/homeworks/config_flow.py:662:9-31: Class member `HomeworksConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/honeywell/__init__.py:61:12-33: Module `aiosomecomfort.device` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/honeywell/__init__.py:65:9-30: Module `aiosomecomfort.device` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/honeywell/__init__.py:66:9-30: Module `aiosomecomfort.device` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -10591,7 +10395,6 @@ ERROR homeassistant/components/honeywell/climate.py:286:16-45: Returned type `fl ERROR homeassistant/components/honeywell/climate.py:345:37-60: No matching overload found for function `dict.get` called with arguments: (str | None) [no-matching-overload] ERROR homeassistant/components/honeywell/climate.py:421:63-74: `temperature` is uninitialized [unbound-name] ERROR homeassistant/components/honeywell/climate.py:425:66-77: `temperature` is uninitialized [unbound-name] -ERROR homeassistant/components/honeywell/config_flow.py:132:9-31: Class member `HoneywellConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/honeywell/humidifier.py:43:9-12: Unexpected keyword argument `key` in function `HoneywellHumidifierEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/honeywell/humidifier.py:44:9-24: Unexpected keyword argument `translation_key` in function `HoneywellHumidifierEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/honeywell/humidifier.py:56:9-12: Unexpected keyword argument `key` in function `HoneywellHumidifierEntityDescription.__init__` [unexpected-keyword] @@ -10633,7 +10436,6 @@ ERROR homeassistant/components/huawei_lte/button.py:73:9-24: Unexpected keyword ERROR homeassistant/components/huawei_lte/button.py:74:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/huawei_lte/button.py:89:9-12: Unexpected keyword argument `key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/huawei_lte/button.py:91:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/huawei_lte/config_flow.py:78:9-31: Class member `HuaweiLteConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/huawei_lte/config_flow.py:309:37-40: Argument `str | None` is not assignable to parameter `url` with type `str` in function `huawei_lte_api.Connection.Connection.__init__` [bad-argument-type] ERROR homeassistant/components/huawei_lte/select.py:47:9-12: Unexpected keyword argument `key` in function `HuaweiSelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/huawei_lte/select.py:48:9-24: Unexpected keyword argument `entity_category` in function `HuaweiSelectEntityDescription.__init__` [unexpected-keyword] @@ -10921,7 +10723,6 @@ ERROR homeassistant/components/hue/__init__.py:107:18-33: Object of class `NoneT ERROR homeassistant/components/hue/__init__.py:108:22-41: Object of class `NoneType` has no attribute `model_id` [missing-attribute] ERROR homeassistant/components/hue/__init__.py:109:24-51: Object of class `NoneType` has no attribute `software_version` [missing-attribute] ERROR homeassistant/components/hue/bridge.py:61:24-55: `HueBridgeV2` is not assignable to attribute `api` with type `HueBridgeV1` [bad-assignment] -ERROR homeassistant/components/hue/config_flow.py:56:9-31: Class member `HueFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/hue/config_flow.py:98:20-24: Returned type `None` is not assignable to declared return type `DiscoveredHueBridge` [bad-return] ERROR homeassistant/components/hue/config_flow.py:223:31-38: `app_key` may be uninitialized [unbound-name] ERROR homeassistant/components/hue/diagnostics.py:21:18-44: Object of class `HueBridgeV1` has no attribute `get_diagnostics` [missing-attribute] @@ -11062,7 +10863,6 @@ ERROR homeassistant/components/hue/v1/binary_sensor.py:38:5-23: Class member `Hu ERROR homeassistant/components/hue/v1/device_trigger.py:116:26-74: Object of class `NoneType` has no attribute `current_events` [missing-attribute] ERROR homeassistant/components/hue/v1/device_trigger.py:140:31-49: Cannot index into `dict[str, dict[tuple[str, str], dict[str, int]]]` [bad-index] ERROR homeassistant/components/hue/v1/device_trigger.py:191:37-49: Cannot index into `dict[str, dict[tuple[str, str], dict[str, int]]]` [bad-index] -ERROR homeassistant/components/hue/v1/hue_event.py:99:35-43: `str` is not assignable to attribute `device_registry_id` with type `None` [bad-assignment] ERROR homeassistant/components/hue/v1/light.py:150:41-69: Object of class `NoneType` has no attribute `apiversion` [missing-attribute] ERROR homeassistant/components/hue/v1/light.py:164:57-81: Object of class `NoneType` has no attribute `update` [missing-attribute] ERROR homeassistant/components/hue/v1/light.py:199:57-81: Object of class `NoneType` has no attribute `update` [missing-attribute] @@ -11072,23 +10872,23 @@ ERROR homeassistant/components/hue/v1/light.py:236:34-62: Argument `None` is not ERROR homeassistant/components/hue/v1/light.py:237:9-37: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/hue/v1/light.py:334:14-38: Class member `HueLight._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hue/v1/light.py:439:61-71: Expected 3 positional arguments, got 4 in function `homeassistant.util.color.color_xy_to_hs` [bad-argument-count] -ERROR homeassistant/components/hue/v1/light.py:544:41-74: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:548:34-77: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:549:34-75: Cannot set item in `dict[str, bool]` [unsupported-operation] +ERROR homeassistant/components/hue/v1/light.py:544:41-74: `int` is not assignable to TypedDict key `transitiontime` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:548:34-77: `int` is not assignable to TypedDict key `hue` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:549:34-75: `int` is not assignable to TypedDict key `sat` with type `bool` [bad-typed-dict-key] ERROR homeassistant/components/hue/v1/light.py:554:78-88: Expected 3 positional arguments, got 4 in function `homeassistant.util.color.color_hs_to_xy` [bad-argument-count] -ERROR homeassistant/components/hue/v1/light.py:555:33-41: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:561:29-81: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:569:32-41: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:572:32-40: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:580:32-38: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:585:37-48: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:587:34-60: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:588:34-60: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:590:37-43: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:604:41-74: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:609:32-41: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:612:32-40: Cannot set item in `dict[str, bool]` [unsupported-operation] -ERROR homeassistant/components/hue/v1/light.py:615:32-38: Cannot set item in `dict[str, bool]` [unsupported-operation] +ERROR homeassistant/components/hue/v1/light.py:555:33-41: `tuple[float, float]` is not assignable to TypedDict key `xy` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:561:29-81: `int` is not assignable to TypedDict key `ct` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:569:32-41: `Literal['lselect']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:572:32-40: `Literal['select']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:580:32-38: `Literal['none']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:585:37-48: `Literal['colorloop']` is not assignable to TypedDict key `effect` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:587:34-60: `int` is not assignable to TypedDict key `hue` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:588:34-60: `int` is not assignable to TypedDict key `sat` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:590:37-43: `Literal['none']` is not assignable to TypedDict key `effect` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:604:41-74: `int` is not assignable to TypedDict key `transitiontime` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:609:32-41: `Literal['lselect']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:612:32-40: `Literal['select']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] +ERROR homeassistant/components/hue/v1/light.py:615:32-38: `Literal['none']` is not assignable to TypedDict key `alert` with type `bool` [bad-typed-dict-key] ERROR homeassistant/components/hue/v1/sensor.py:103:5-23: Class member `HueBattery._attr_device_class` overrides parent class `GenericHueSensor` in an inconsistent manner [bad-override] ERROR homeassistant/components/hue/v1/sensor_base.py:134:24-58: Class `HueEvent` has no class attribute `format` [missing-attribute] ERROR homeassistant/components/hue/v1/sensor_base.py:135:29-50: Expected a callable, got `str` [not-callable] @@ -11204,10 +11004,7 @@ ERROR homeassistant/components/hue/v2/entity.py:95:22-45: Object of class `HueBr ERROR homeassistant/components/hue/v2/entity.py:97:17-60: Object of class `NoneType` has no attribute `zigbee_connectivity` Object of class `Sensors` has no attribute `zigbee_connectivity` [missing-attribute] ERROR homeassistant/components/hue/v2/entity.py:116:22-45: Object of class `HueBridgeV1` has no attribute `devices` [missing-attribute] -ERROR homeassistant/components/hue/v2/entity.py:148:41-46: `Literal[False]` is not assignable to attribute `_ignore_availability` with type `None` [bad-assignment] -ERROR homeassistant/components/hue/v2/entity.py:154:41-45: `Literal[True]` is not assignable to attribute `_ignore_availability` with type `None` [bad-assignment] -ERROR homeassistant/components/hue/v2/entity.py:163:41-46: `Literal[False]` is not assignable to attribute `_ignore_availability` with type `None` [bad-assignment] -ERROR homeassistant/components/hue/v2/entity.py:199:45-50: `Literal[False]` is not assignable to attribute `_ignore_availability` with type `Never` [bad-assignment] +ERROR homeassistant/components/hue/v2/entity.py:176:22-45: Object of class `HueBridgeV1` has no attribute `devices` [missing-attribute] ERROR homeassistant/components/hue/v2/group.py:49:24-34: `HueBridgeV1` is not assignable to `HueBridgeV2` [bad-assignment] ERROR homeassistant/components/hue/v2/group.py:62:12-17: `group` may be uninitialized [unbound-name] ERROR homeassistant/components/hue/v2/group.py:65:51-56: `group` may be uninitialized [unbound-name] @@ -11423,8 +11220,8 @@ ERROR homeassistant/components/humidifier/__init__.py:131:5-17: Class member `Hu ERROR homeassistant/components/humidifier/__init__.py:154:5-23: Class member `HumidifierEntity.entity_description` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/humidifier/__init__.py:158:5-23: Class member `HumidifierEntity._attr_device_class` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/humidifier/__init__.py:162:5-29: Class member `HumidifierEntity._attr_supported_features` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:71:21-67: Argument `set[tuple[str, None]]` is not assignable to parameter `connections` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] -ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:72:21-50: Argument `set[tuple[str, None]]` is not assignable to parameter `identifiers` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] +ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:71:21-67: Argument `set[tuple[str, Unknown | None]]` is not assignable to parameter `connections` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] +ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:72:21-50: Argument `set[tuple[str, Unknown | None]]` is not assignable to parameter `identifiers` with type `UndefinedType | set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_or_create` [bad-argument-type] ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:77:20-51: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:114:19-38: Argument `dict[str, Automation | BaseShade | Hub | Room | Scene]` is not assignable to parameter `room_data` with type `dict[str, Room]` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewEntryData.__init__` [bad-argument-type] ERROR homeassistant/components/hunterdouglas_powerview/__init__.py:115:20-40: Argument `dict[str, Automation | BaseShade | Hub | Room | Scene]` is not assignable to parameter `scene_data` with type `dict[str, Scene]` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewEntryData.__init__` [bad-argument-type] @@ -11450,11 +11247,14 @@ ERROR homeassistant/components/hunterdouglas_powerview/coordinator.py:26:5-17: C ERROR homeassistant/components/hunterdouglas_powerview/cover.py:75:51-66: No matching overload found for function `dict.get` called with arguments: (int) [no-matching-overload] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:95:5-23: Class member `PowerViewShadeBase._attr_device_class` overrides parent class `ShadeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:96:5-29: Class member `PowerViewShadeBase._attr_supported_features` overrides parent class `ShadeEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/hunterdouglas_powerview/cover.py:115:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:115:13-69: `|=` is not supported between `None` and `Literal[CoverEntityFeature.STOP]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:146:16-57: `<=` is not supported between `None` and `Literal[0]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:151:16-38: Returned type `float | int | None` is not assignable to declared return type `int` [bad-return] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:156:16-38: Returned type `float | int | None` is not assignable to declared return type `int` [bad-return] +ERROR homeassistant/components/hunterdouglas_powerview/cover.py:352:9-38: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:352:9-356:10: `|=` is not supported between `None` and `CoverEntityFeature` [unsupported-operation] +ERROR homeassistant/components/hunterdouglas_powerview/cover.py:358:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:364:16-35: Returned type `float | int | None` is not assignable to declared return type `int` [bad-return] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:369:16-60: `+` is not supported between `float` and `None` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:369:16-60: `+` is not supported between `int` and `None` [unsupported-operation] @@ -11486,7 +11286,9 @@ ERROR homeassistant/components/hunterdouglas_powerview/cover.py:756:21-47: `/` i ERROR homeassistant/components/hunterdouglas_powerview/cover.py:758:24-52: `/` is not supported between `None` and `Literal[2]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:880:16-59: `<=` is not supported between `None` and `Literal[0]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:885:16-40: Returned type `float | int | None` is not assignable to declared return type `int` [bad-return] +ERROR homeassistant/components/hunterdouglas_powerview/cover.py:929:9-38: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:929:9-933:10: `|=` is not supported between `None` and `CoverEntityFeature` [unsupported-operation] +ERROR homeassistant/components/hunterdouglas_powerview/cover.py:935:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:944:20-46: `/` is not supported between `None` and `Literal[2]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:948:21-49: `/` is not supported between `None` and `Literal[2]` [unsupported-operation] ERROR homeassistant/components/hunterdouglas_powerview/cover.py:950:21-47: `+` is not supported between `float` and `None` [unsupported-operation] @@ -11516,10 +11318,10 @@ ERROR homeassistant/components/hunterdouglas_powerview/sensor.py:88:51-66: No ma ERROR homeassistant/components/hunterdouglas_powerview/sensor.py:107:5-23: Class member `PowerViewSensor.entity_description` overrides parent class `ShadeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hunterdouglas_powerview/sensor.py:107:5-23: Class member `PowerViewSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hunterdouglas_powerview/util.py:25:14-22: Argument `str | None` is not assignable to parameter `name` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/hunterdouglas_powerview/util.py:26:21-36: Argument `None` is not assignable to parameter `mac_address` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/hunterdouglas_powerview/util.py:27:23-40: Argument `None` is not assignable to parameter `serial_number` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/hunterdouglas_powerview/util.py:26:21-36: Argument `Unknown | None` is not assignable to parameter `mac_address` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/hunterdouglas_powerview/util.py:27:23-40: Argument `Unknown | None` is not assignable to parameter `serial_number` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] ERROR homeassistant/components/hunterdouglas_powerview/util.py:29:15-24: Argument `str | None` is not assignable to parameter `model` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/hunterdouglas_powerview/util.py:30:21-27: Argument `None` is not assignable to parameter `hub_address` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/hunterdouglas_powerview/util.py:30:21-27: Argument `Unknown | None` is not assignable to parameter `hub_address` with type `str` in function `homeassistant.components.hunterdouglas_powerview.model.PowerviewDeviceInfo.__init__` [bad-argument-type] ERROR homeassistant/components/husqvarna_automower/binary_sensor.py:35:9-12: Unexpected keyword argument `key` in function `AutomowerBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/husqvarna_automower/binary_sensor.py:40:9-12: Unexpected keyword argument `key` in function `AutomowerBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/husqvarna_automower/binary_sensor.py:41:9-24: Unexpected keyword argument `translation_key` in function `AutomowerBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -11617,12 +11419,8 @@ ERROR homeassistant/components/huum/climate.py:64:16-59: Object of class `NoneTy ERROR homeassistant/components/huum/coordinator.py:29:5-17: Class member `HuumDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/huum/number.py:50:16-46: Returned type `int | None` is not assignable to declared return type `float` [bad-return] ERROR homeassistant/components/hvv_departures/binary_sensor.py:132:5-23: Class member `HvvDepartureBinarySensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/hvv_departures/binary_sensor.py:144:25-151:14: Argument `set[tuple[str, Unknown, Unknown, Unknown]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/hvv_departures/config_flow.py:134:9-31: Class member `HVVDeparturesConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/hvv_departures/sensor.py:79:25-86:14: Argument `set[tuple[str, Unknown, Unknown, Unknown]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/hvv_departures/sensor.py:121:36-47: `type[InvalidAuth]` is not assignable to attribute `_last_error` with type `None` [bad-assignment] -ERROR homeassistant/components/hvv_departures/sensor.py:126:36-56: `type[ClientConnectorError]` is not assignable to attribute `_last_error` with type `None` [bad-assignment] -ERROR homeassistant/components/hvv_departures/sensor.py:131:36-41: `Exception` is not assignable to attribute `_last_error` with type `None` [bad-assignment] +ERROR homeassistant/components/hvv_departures/binary_sensor.py:142:44-154:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, Unknown, Unknown, Unknown]], manufacturer=Literal['HVV'], name=str) [no-matching-overload] +ERROR homeassistant/components/hvv_departures/sensor.py:77:44-89:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, Unknown, Unknown, Unknown]], manufacturer=Literal['HVV'], name=Unknown) [no-matching-overload] ERROR homeassistant/components/hvv_departures/sensor.py:134:17-21: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/hvv_departures/sensor.py:134:48-52: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/hvv_departures/sensor.py:143:21-25: `data` may be uninitialized [unbound-name] @@ -11664,7 +11462,6 @@ ERROR homeassistant/components/hydrawise/valve.py:54:7-21: Field `entity_descrip `, which is not assignable to the type `ValveEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/hydrawise/valve.py:59:5-29: Class member `HydrawiseValve._attr_supported_features` overrides parent class `HydrawiseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/hyperion/camera.py:160:20-66: Object of class `NoneType` has no attribute `get` [missing-attribute] -ERROR homeassistant/components/hyperion/config_flow.py:427:9-31: Class member `HyperionConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/hyperion/sensor.py:47:5-8: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/hyperion/sensor.py:48:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/hyperion/sensor.py:49:5-9: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -11817,19 +11614,12 @@ ERROR homeassistant/components/ibeacon/sensor.py:103:5-23: Class member `IBeacon ERROR homeassistant/components/icloud/account.py:148:35-69: Object of class `NoneType` has no attribute `items` [missing-attribute] ERROR homeassistant/components/icloud/account.py:223:26-76: Unpacked argument `tuple[HomeAssistant]` is not assignable to parameter `*args` with type `tuple[HomeAssistant, ConfigFlowContext | None, dict[str, Any] | None]` in function `homeassistant.core.HomeAssistant.add_job` [bad-argument-type] ERROR homeassistant/components/icloud/account.py:450:54-58: Argument `None` is not assignable to parameter `newpasscode` with type `str` in function `pyicloud.services.findmyiphone.AppleDevice.lost_device` [bad-argument-type] -ERROR homeassistant/components/icloud/config_flow.py:118:24-126:14: `PyiCloudService` is not assignable to attribute `api` with type `None` [bad-assignment] ERROR homeassistant/components/icloud/config_flow.py:118:62-126:14: Unpacked argument `tuple[Unknown, Unknown, Unknown, Literal[True], None, Unknown]` is not assignable to parameter `*args` with type `tuple[str, str | None, str | None, bool, str | None, bool, bool, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/icloud/config_flow.py:133:12-33: Object of class `NoneType` has no attribute `requires_2fa` [missing-attribute] -ERROR homeassistant/components/icloud/config_flow.py:136:12-33: Object of class `NoneType` has no attribute `requires_2sa` [missing-attribute] ERROR homeassistant/components/icloud/config_flow.py:163:53-58: Argument `ConfigEntry[Any] | None` is not assignable to parameter `entry` with type `ConfigEntry[Any]` in function `homeassistant.config_entries.ConfigEntries.async_update_entry` [bad-argument-type] ERROR homeassistant/components/icloud/config_flow.py:164:53-67: Object of class `NoneType` has no attribute `entry_id` [missing-attribute] ERROR homeassistant/components/icloud/config_flow.py:176:51-81: Unpacked argument `tuple[Unknown]` is not assignable to parameter `*args` with type `tuple[StrOrBytesPath, int, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/icloud/config_flow.py:234:36-40: `None` is not assignable to attribute `_trusted_device` with type `Never` [bad-assignment] -ERROR homeassistant/components/icloud/config_flow.py:292:36-40: `None` is not assignable to attribute `_trusted_device` with type `Never` [bad-assignment] -ERROR homeassistant/components/icloud/config_flow.py:293:39-43: `None` is not assignable to attribute `_verification_code` with type `Never` [bad-assignment] -ERROR homeassistant/components/icloud/config_flow.py:310:32-36: `None` is not assignable to attribute `api` with type `Never` [bad-assignment] +ERROR homeassistant/components/icloud/config_flow.py:298:70-306:22: Unpacked argument `tuple[Unknown | None, Unknown | None, Unknown, Literal[True], None, Unknown | None]` is not assignable to parameter `*args` with type `tuple[str, str | None, str | None, bool, str | None, bool, bool, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/icloud/services.py:105:16-20: Returned type `None` is not assignable to declared return type `IcloudAccount` [bad-return] -ERROR homeassistant/components/idasen_desk/__init__.py:51:38-56: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/idasen_desk/__init__.py:73:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/idasen_desk/button.py:30:9-12: Unexpected keyword argument `key` in function `IdasenDeskButtonDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/idasen_desk/button.py:31:9-24: Unexpected keyword argument `translation_key` in function `IdasenDeskButtonDescription.__init__` [unexpected-keyword] @@ -11852,18 +11642,12 @@ ERROR homeassistant/components/iglo/light.py:7:1-22: Could not find import of `i ERROR homeassistant/components/iglo/light.py:8:1-33: Could not find import of `iglo.lamp` [missing-import] ERROR homeassistant/components/igloohome/lock.py:52:5-29: Class member `IgloohomeLockEntity._attr_supported_features` overrides parent class `IgloohomeBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/igloohome/sensor.py:46:5-23: Class member `IgloohomeBatteryEntity._attr_device_class` overrides parent class `IgloohomeBaseEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/ign_sismologia/geo_location.py:203:23-39: `str | None` is not assignable to attribute `_title` with type `None` [bad-assignment] ERROR homeassistant/components/ign_sismologia/geo_location.py:205:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/ign_sismologia/geo_location.py:206:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/ign_sismologia/geo_location.py:208:24-41: `float | None` is not assignable to attribute `_region` with type `None` [bad-assignment] -ERROR homeassistant/components/ign_sismologia/geo_location.py:209:27-47: `float` is not assignable to attribute `_magnitude` with type `None` [bad-assignment] -ERROR homeassistant/components/ign_sismologia/geo_location.py:210:34-54: `datetime | None` is not assignable to attribute `_publication_date` with type `None` [bad-assignment] -ERROR homeassistant/components/ign_sismologia/geo_location.py:211:27-47: `str | None` is not assignable to attribute `_image_url` with type `None` [bad-assignment] ERROR homeassistant/components/ihc/__init__.py:5:1-47: Could not find import of `ihcsdk.ihccontroller` [missing-import] ERROR homeassistant/components/ihc/binary_sensor.py:5:1-47: Could not find import of `ihcsdk.ihccontroller` [missing-import] ERROR homeassistant/components/ihc/binary_sensor.py:70:14-32: Class member `IHCBinarySensor._attr_device_class` overrides parent class `IHCEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ihc/entity.py:5:1-47: Could not find import of `ihcsdk.ihccontroller` [missing-import] -ERROR homeassistant/components/ihc/entity.py:46:34-65: `str` is not assignable to attribute `device_id` with type `None` [bad-assignment] ERROR homeassistant/components/ihc/light.py:7:1-47: Could not find import of `ihcsdk.ihccontroller` [missing-import] ERROR homeassistant/components/ihc/light.py:105:66-76: `brightness` may be uninitialized [unbound-name] ERROR homeassistant/components/ihc/sensor.py:5:1-47: Could not find import of `ihcsdk.ihccontroller` [missing-import] @@ -11883,7 +11667,6 @@ ERROR homeassistant/components/imap/__init__.py:196:17-40: Object of class `None ERROR homeassistant/components/imap/__init__.py:254:29-45: Object of class `str` has no attribute `get_payload` [missing-attribute] ERROR homeassistant/components/imap/__init__.py:264:20-24: Returned type `Message[str, str] | str | Any` is not assignable to declared return type `Message[str, str]` [bad-return] ERROR homeassistant/components/imap/__init__.py:356:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/imap/config_flow.py:210:9-31: Class member `IMAPConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/imap/coordinator.py:84:8-29: Object of class `NoneType` has no attribute `state` [missing-attribute] ERROR homeassistant/components/imap/coordinator.py:156:48-56: `date_str` is uninitialized [unbound-name] ERROR homeassistant/components/imap/coordinator.py:159:77-85: `date_str` is uninitialized [unbound-name] @@ -12053,7 +11836,6 @@ ERROR homeassistant/components/immich/sensor.py:132:5-23: Class member `ImmichSe ERROR homeassistant/components/immich/sensor.py:132:5-23: Class member `ImmichSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/immich/services.py:78:12-24: `target_album` may be uninitialized [unbound-name] ERROR homeassistant/components/immich/services.py:80:17-29: `target_album` may be uninitialized [unbound-name] -ERROR homeassistant/components/improv_ble/config_flow.py:221:17-66: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/improv_ble/config_flow.py:384:42-61: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/incomfort/binary_sensor.py:32:5-20: Class member `IncomfortBinarySensorEntityDescription.entity_category` overrides parent class `BinarySensorEntityDescription` in an inconsistent manner [bad-override] ERROR homeassistant/components/incomfort/binary_sensor.py:37:9-12: Unexpected keyword argument `key` in function `IncomfortBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -12071,20 +11853,11 @@ ERROR homeassistant/components/incomfort/binary_sensor.py:65:9-40: Unexpected ke ERROR homeassistant/components/incomfort/binary_sensor.py:88:5-23: Class member `IncomfortBinarySensor.entity_description` overrides parent class `IncomfortBoilerEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/incomfort/binary_sensor.py:88:5-23: Class member `IncomfortBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/incomfort/climate.py:51:5-29: Class member `InComfortClimate._attr_supported_features` overrides parent class `IncomfortEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/config_flow.py:107:9-31: Class member `InComfortConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/incomfort/config_flow.py:189:22-39: `reconfigure_entry` may be uninitialized [unbound-name] ERROR homeassistant/components/incomfort/config_flow.py:190:24-38: `is_reconfigure` may be uninitialized [unbound-name] ERROR homeassistant/components/incomfort/config_flow.py:194:20-34: `is_reconfigure` may be uninitialized [unbound-name] ERROR homeassistant/components/incomfort/config_flow.py:196:25-42: `reconfigure_entry` may be uninitialized [unbound-name] ERROR homeassistant/components/incomfort/coordinator.py:56:5-17: Class member `InComfortDataCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:11:5-23: Class member `NotFound.translation_domain` overrides parent class `HomeAssistantError` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:12:5-20: Class member `NotFound.translation_key` overrides parent class `HomeAssistantError` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:18:5-23: Class member `NoHeaters.translation_domain` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:19:5-20: Class member `NoHeaters.translation_key` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:25:5-23: Class member `InComfortTimeout.translation_domain` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:26:5-20: Class member `InComfortTimeout.translation_key` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:32:5-23: Class member `InComfortUnknownError.translation_domain` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] -ERROR homeassistant/components/incomfort/errors.py:33:5-20: Class member `InComfortUnknownError.translation_key` overrides parent class `ConfigEntryNotReady` in an inconsistent manner [bad-override] ERROR homeassistant/components/incomfort/sensor.py:38:9-12: Unexpected keyword argument `key` in function `IncomfortSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/incomfort/sensor.py:43:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `IncomfortSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/incomfort/sensor.py:46:9-12: Unexpected keyword argument `key` in function `IncomfortSensorEntityDescription.__init__` [unexpected-keyword] @@ -12112,8 +11885,6 @@ ERROR homeassistant/components/influxdb/__init__.py:455:25-37: Object of class ` ERROR homeassistant/components/influxdb/sensor.py:214:25-221:14: `InfluxQLSensorData` is not assignable to attribute `data` with type `InfluxFluxSensorData` [bad-assignment] ERROR homeassistant/components/influxdb/sensor.py:245:21-26: `value` may be uninitialized [unbound-name] ERROR homeassistant/components/influxdb/sensor.py:248:23-28: `value` may be uninitialized [unbound-name] -ERROR homeassistant/components/influxdb/sensor.py:289:27-87: `str` is not assignable to attribute `full_query` with type `None` [bad-assignment] -ERROR homeassistant/components/influxdb/sensor.py:334:13-335:56: `str` is not assignable to attribute `query` with type `None` [bad-assignment] ERROR homeassistant/components/inkbird/sensor.py:34:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/inkbird/sensor.py:40:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/inkbird/sensor.py:46:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -12123,14 +11894,10 @@ ERROR homeassistant/components/inkbird/sensor.py:62:9-12: Unexpected keyword arg ERROR homeassistant/components/inkbird/sensor.py:68:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/inkbird/sensor.py:125:7-35: Field `entity_description` is declared `EntityDescription` in ancestor `class PassiveBluetoothProcessorEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/input_datetime/__init__.py:237:38-239:14: `datetime` is not assignable to attribute `_current_datetime` with type `None` [bad-assignment] -ERROR homeassistant/components/input_datetime/__init__.py:241:38-243:14: `datetime` is not assignable to attribute `_current_datetime` with type `None` [bad-assignment] -ERROR homeassistant/components/input_datetime/__init__.py:272:38-75: `datetime | None` is not assignable to attribute `_current_datetime` with type `None` [bad-assignment] ERROR homeassistant/components/input_datetime/__init__.py:295:34-58: Object of class `NoneType` has no attribute `replace` [missing-attribute] ERROR homeassistant/components/input_datetime/__init__.py:372:34-54: Cannot set item in `dict[str, bool]` [unsupported-operation] ERROR homeassistant/components/input_datetime/__init__.py:404:20-47: Object of class `NoneType` has no attribute `date` [missing-attribute] ERROR homeassistant/components/input_datetime/__init__.py:407:20-47: Object of class `NoneType` has no attribute `time` [missing-attribute] -ERROR homeassistant/components/input_datetime/__init__.py:409:34-411:10: `datetime` is not assignable to attribute `_current_datetime` with type `None` [bad-assignment] ERROR homeassistant/components/input_number/__init__.py:316:40-72: `+` is not supported between `None` and `int` [unsupported-operation] ERROR homeassistant/components/input_number/__init__.py:320:40-72: `-` is not supported between `None` and `int` [unsupported-operation] ERROR homeassistant/components/insteon/__init__.py:69:11-18: `devices` may be uninitialized [unbound-name] @@ -12288,12 +12055,8 @@ ERROR homeassistant/components/intent/timers.py:464:27-42: Cannot index into `di ERROR homeassistant/components/intent/timers.py:727:29-36: Object of class `NoneType` has no attribute `id` [missing-attribute] ERROR homeassistant/components/intent/timers.py:730:30-43: Object of class `NoneType` has no attribute `floor_id` [missing-attribute] ERROR homeassistant/components/intesishome/climate.py:9:1-80: Could not find import of `pyintesishome` [missing-import] -ERROR homeassistant/components/intesishome/climate.py:280:27-36: `Literal[HVACMode.AUTO, HVACMode.COOL, HVACMode.DRY, HVACMode.FAN_ONLY, HVACMode.HEAT, HVACMode.HEAT_COOL]` is not assignable to attribute `_hvac_mode` with type `None` [bad-assignment] -ERROR homeassistant/components/intesishome/climate.py:324:27-56: `HVACMode | None` is not assignable to attribute `_hvac_mode` with type `None` [bad-assignment] -ERROR homeassistant/components/intesishome/climate.py:351:39-56: No matching overload found for function `dict.get` called with arguments: (None) [no-matching-overload] -ERROR homeassistant/components/intesishome/climate.py:359:31-36: `Literal[False]` is not assignable to attribute `_connected` with type `None` [bad-assignment] -ERROR homeassistant/components/intesishome/climate.py:375:31-35: `Literal[True]` is not assignable to attribute `_connected` with type `None` [bad-assignment] -ERROR homeassistant/components/intesishome/climate.py:409:20-35: Returned type `None` is not assignable to declared return type `HVACMode` [bad-return] +ERROR homeassistant/components/intesishome/climate.py:351:39-56: No matching overload found for function `dict.get` called with arguments: (Unknown | None) [no-matching-overload] +ERROR homeassistant/components/intesishome/climate.py:409:20-35: Returned type `Unknown | None` is not assignable to declared return type `HVACMode` [bad-return] ERROR homeassistant/components/iometer/binary_sensor.py:28:9-12: Unexpected keyword argument `key` in function `IOmeterBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/iometer/binary_sensor.py:29:9-24: Unexpected keyword argument `translation_key` in function `IOmeterBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/iometer/binary_sensor.py:31:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `IOmeterBinarySensorDescription.__init__` [unexpected-keyword] @@ -12700,7 +12463,6 @@ ERROR homeassistant/components/iskra/sensor.py:268:5-23: Class member `IskraSens ERROR homeassistant/components/iskra/sensor.py:268:5-23: Class member `IskraSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/islamic_prayer_times/__init__.py:71:47-56: `unique_id` may be uninitialized [unbound-name] ERROR homeassistant/components/islamic_prayer_times/__init__.py:89:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/islamic_prayer_times/config_flow.py:51:9-31: Class member `IslamicPrayerFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/islamic_prayer_times/coordinator.py:38:5-17: Class member `IslamicPrayerDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] WARN homeassistant/components/islamic_prayer_times/coordinator.py:90:20-63: Redundant cast: `dict[str, Any]` is the same type as `dict[str, Any]` [redundant-cast] ERROR homeassistant/components/islamic_prayer_times/sensor.py:21:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -12733,7 +12495,6 @@ ERROR homeassistant/components/israel_rail/sensor.py:67:9-24: Unexpected keyword ERROR homeassistant/components/israel_rail/sensor.py:97:5-23: Class member `IsraelRailEntitySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/israel_rail/sensor.py:97:5-23: Class member `IsraelRailEntitySensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/iss/__init__.py:77:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/iss/config_flow.py:26:9-31: Class member `ISSConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/ista_ecotrend/__init__.py:26:9-16: Argument `Logger` is not assignable to parameter `totp` with type `str | None` in function `pyecotrend_ista.pyecotrend_ista.PyEcotrendIsta.__init__` [bad-argument-type] ERROR homeassistant/components/ista_ecotrend/config_flow.py:54:17-24: Argument `Logger` is not assignable to parameter `totp` with type `str | None` in function `pyecotrend_ista.pyecotrend_ista.PyEcotrendIsta.__init__` [bad-argument-type] ERROR homeassistant/components/ista_ecotrend/config_flow.py:57:56-66: Argument `BoundMethod[PyEcotrendIsta, (self: PyEcotrendIsta, **kwargs: Unknown) -> str | None]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] @@ -12833,7 +12594,6 @@ Object of class `Variable` has no attribute `set_fan_mode` [missing-attribute] ERROR homeassistant/components/isy994/climate.py:214:15-42: Object of class `Program` has no attribute `set_climate_mode` Object of class `Variable` has no attribute `set_climate_mode` [missing-attribute] ERROR homeassistant/components/isy994/config_flow.py:105:17-28: Argument `Any | None` is not assignable to parameter `tls_ver` with type `float` in function `pyisy.connection.Connection.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/config_flow.py:144:9-31: Class member `Isy994ConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/isy994/cover.py:32:41-60: No matching overload found for function `dict.get` called with arguments: (str | None) [no-matching-overload] ERROR homeassistant/components/isy994/cover.py:47:5-29: Class member `ISYCoverEntity._attr_supported_features` overrides parent class `ISYNodeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/isy994/cover.py:58:12-26: Object of class `Program` has no attribute `uom` @@ -12881,7 +12641,7 @@ ERROR homeassistant/components/isy994/fan.py:86:15-33: Object of class `Program` Object of class `Variable` has no attribute `turn_on` [missing-attribute] ERROR homeassistant/components/isy994/fan.py:99:15-34: Object of class `Program` has no attribute `turn_off` Object of class `Variable` has no attribute `turn_off` [missing-attribute] -ERROR homeassistant/components/isy994/helpers.py:287:26-42: Cannot index into `dict[str, str]` [bad-index] +ERROR homeassistant/components/isy994/helpers.py:287:26-42: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/isy994/helpers.py:298:22-41: Object of class `NoneType` has no attribute `title` [missing-attribute] ERROR homeassistant/components/isy994/helpers.py:336:9-19: Type `Node` is not iterable [not-iterable] ERROR homeassistant/components/isy994/helpers.py:336:9-19: Type `Nodes` is not iterable [not-iterable] @@ -12955,16 +12715,8 @@ ERROR homeassistant/components/isy994/number.py:91:13-16: Unexpected keyword arg ERROR homeassistant/components/isy994/number.py:92:13-17: Unexpected keyword argument `name` in function `homeassistant.components.number.NumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/isy994/number.py:93:13-44: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.number.NumberEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/isy994/number.py:130:43-62: No matching overload found for function `dict.get` called with arguments: (str | None) [no-matching-overload] -ERROR homeassistant/components/isy994/number.py:133:54-72: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `node` with type `Node` in function `ISYBacklightNumberEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:133:54-72: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `control` with type `str` in function `ISYBacklightNumberEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:133:54-72: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `unique_id` with type `str` in function `ISYBacklightNumberEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:133:54-72: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `description` with type `NumberEntityDescription` in function `ISYBacklightNumberEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:133:54-72: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `device_info` with type `DeviceInfo | None` in function `ISYBacklightNumberEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:135:51-69: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `node` with type `Node` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:135:51-69: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `control` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:135:51-69: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `unique_id` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:135:51-69: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `description` with type `EntityDescription` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/number.py:135:51-69: Unpacked keyword argument `Node | NumberEntityDescription | str` is not assignable to parameter `device_info` with type `DeviceInfo | None` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] +ERROR homeassistant/components/isy994/number.py:133:53-73: Missing argument `device_info` in function `ISYBacklightNumberEntity.__init__` [missing-argument] +ERROR homeassistant/components/isy994/number.py:135:50-70: Missing argument `device_info` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [missing-argument] ERROR homeassistant/components/isy994/number.py:139:7-32: Field `entity_description` is declared `EntityDescription` in ancestor `class ISYAuxControlEntity: ... `, which is not assignable to the type `NumberEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/isy994/number.py:152:13-63: Object of class `EntityDescription` has no attribute `native_unit_of_measurement` [missing-attribute] @@ -12978,21 +12730,9 @@ ERROR homeassistant/components/isy994/select.py:84:13-16: Unexpected keyword arg ERROR homeassistant/components/isy994/select.py:85:13-17: Unexpected keyword argument `name` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/isy994/select.py:86:13-28: Unexpected keyword argument `entity_category` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/isy994/select.py:94:43-62: No matching overload found for function `dict.get` called with arguments: (str | None) [no-matching-overload] -ERROR homeassistant/components/isy994/select.py:98:53-68: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `node` with type `Node` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:98:53-68: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `control` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:98:53-68: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `unique_id` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:98:53-68: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `description` with type `EntityDescription` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:98:53-68: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `device_info` with type `DeviceInfo | None` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:101:54-69: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `node` with type `Node` in function `ISYBacklightSelectEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:101:54-69: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `control` with type `str` in function `ISYBacklightSelectEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:101:54-69: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `unique_id` with type `str` in function `ISYBacklightSelectEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:101:54-69: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `description` with type `SelectEntityDescription` in function `ISYBacklightSelectEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:101:54-69: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `device_info` with type `DeviceInfo | None` in function `ISYBacklightSelectEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:104:60-75: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `node` with type `Node` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:104:60-75: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `control` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:104:60-75: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `unique_id` with type `str` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:104:60-75: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `description` with type `EntityDescription` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] -ERROR homeassistant/components/isy994/select.py:104:60-75: Unpacked keyword argument `Node | SelectEntityDescription | str` is not assignable to parameter `device_info` with type `DeviceInfo | None` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [bad-argument-type] +ERROR homeassistant/components/isy994/select.py:98:52-69: Missing argument `device_info` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [missing-argument] +ERROR homeassistant/components/isy994/select.py:101:53-70: Missing argument `device_info` in function `ISYBacklightSelectEntity.__init__` [missing-argument] +ERROR homeassistant/components/isy994/select.py:104:59-76: Missing argument `device_info` in function `homeassistant.components.isy994.entity.ISYAuxControlEntity.__init__` [missing-argument] ERROR homeassistant/components/isy994/select.py:113:7-30: Field `entity_description` is declared `EntityDescription` in ancestor `class ISYAuxControlEntity: ... `, which is not assignable to the type `SelectEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/isy994/select.py:131:7-37: Field `entity_description` is declared `EntityDescription` in ancestor `class ISYAuxControlEntity: ... @@ -13068,9 +12808,8 @@ ERROR homeassistant/components/ituran/sensor.py:96:9-12: Unexpected keyword argu ERROR homeassistant/components/ituran/sensor.py:123:5-23: Class member `IturanSensor.entity_description` overrides parent class `IturanBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ituran/sensor.py:123:5-23: Class member `IturanSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/izone/climate.py:367:16-44: Returned type `float | None` is not assignable to declared return type `float` [bad-return] -ERROR homeassistant/components/izone/climate.py:469:25-471:14: Argument `set[tuple[str, str, int]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/izone/climate.py:468:44-476:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str, int]], manufacturer=Literal['IZone'], model=str, name=str, via_device=tuple[Literal['izone'], str]) [no-matching-overload] ERROR homeassistant/components/izone/climate.py:539:16-39: Returned type `float | None` is not assignable to declared return type `float` [bad-return] -ERROR homeassistant/components/jellyfin/config_flow.py:140:9-31: Class member `JellyfinConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/jellyfin/coordinator.py:22:5-17: Class member `JellyfinDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/jellyfin/media_player.py:151:14-25: Class member `JellyfinMediaPlayer._attr_state` overrides parent class `JellyfinClientEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/jellyfin/media_source.py:67:5-9: Class member `JellyfinSource.name` overrides parent class `MediaSource` in an inconsistent manner [bad-override] @@ -13088,7 +12827,6 @@ ERROR homeassistant/components/jewish_calendar/binary_sensor.py:46:9-24: Unexpec ERROR homeassistant/components/jewish_calendar/binary_sensor.py:48:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `JewishCalendarBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/jewish_calendar/binary_sensor.py:70:5-23: Class member `JewishCalendarBinarySensor.entity_description` overrides parent class `JewishCalendarEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/jewish_calendar/binary_sensor.py:70:5-23: Class member `JewishCalendarBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/jewish_calendar/config_flow.py:91:9-31: Class member `JewishCalendarConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/jewish_calendar/sensor.py:62:9-12: Unexpected keyword argument `key` in function `JewishCalendarSensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/jewish_calendar/sensor.py:63:9-24: Unexpected keyword argument `translation_key` in function `JewishCalendarSensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/jewish_calendar/sensor.py:74:9-12: Unexpected keyword argument `key` in function `JewishCalendarSensorDescription.__init__` [unexpected-keyword] @@ -13272,22 +13010,17 @@ ERROR homeassistant/components/keba/sensor.py:67:17-20: Unexpected keyword argum ERROR homeassistant/components/keba/sensor.py:68:17-21: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/keba/sensor.py:77:17-20: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/keba/sensor.py:78:17-21: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/keenetic_ndms2/config_flow.py:57:9-31: Class member `KeeneticFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/keenetic_ndms2/config_flow.py:75:21-25: Argument `bytes | str | Any` is not assignable to parameter `host` with type `str` in function `ndms2_client.connection.TelnetConnection.__init__` [bad-argument-type] ERROR homeassistant/components/keenetic_ndms2/config_flow.py:187:16-36: Object of class `NoneType` has no attribute `lower` [missing-attribute] ERROR homeassistant/components/keenetic_ndms2/device_tracker.py:56:34-60: Argument `str | None` is not assignable to parameter `name` with type `str` in function `ndms2_client.client.Device.__new__` [bad-argument-type] ERROR homeassistant/components/keenetic_ndms2/device_tracker.py:57:32-36: Argument `None` is not assignable to parameter `ip` with type `str` in function `ndms2_client.client.Device.__new__` [bad-argument-type] ERROR homeassistant/components/keenetic_ndms2/device_tracker.py:58:39-43: Argument `None` is not assignable to parameter `interface` with type `str` in function `ndms2_client.client.Device.__new__` [bad-argument-type] -ERROR homeassistant/components/keenetic_ndms2/router.py:129:26-74: `Task[Unknown]` is not assignable to attribute `_progress` with type `None` [bad-assignment] -ERROR homeassistant/components/keenetic_ndms2/router.py:130:9-29: Type `None` is not awaitable [not-async] ERROR homeassistant/components/keenetic_ndms2/router.py:168:9-36: Object of class `NoneType` has no attribute `disconnect` [missing-attribute] ERROR homeassistant/components/keenetic_ndms2/router.py:172:33-61: Object of class `NoneType` has no attribute `get_router_info` [missing-attribute] ERROR homeassistant/components/keenetic_ndms2/router.py:183:25-49: Object of class `NoneType` has no attribute `get_devices` [missing-attribute] ERROR homeassistant/components/keenetic_ndms2/router.py:194:33-61: Object of class `NoneType` has no attribute `get_router_info` [missing-attribute] ERROR homeassistant/components/kef/media_player.py:10:1-35: Could not find import of `aiokef` [missing-import] ERROR homeassistant/components/kef/media_player.py:11:1-45: Could not find import of `aiokef.aiokef` [missing-import] -ERROR homeassistant/components/kef/media_player.py:327:21-335:10: `dict[str, Unknown]` is not assignable to attribute `_dsp` with type `None` [bad-assignment] -ERROR homeassistant/components/kef/media_player.py:339:41-341:10: `() -> None` is not assignable to attribute `_update_dsp_task_remover` with type `None` [bad-assignment] ERROR homeassistant/components/kef/media_player.py:345:9-38: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/kegtron/sensor.py:36:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/kegtron/sensor.py:37:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -13309,16 +13042,15 @@ ERROR homeassistant/components/kegtron/sensor.py:76:9-40: Unexpected keyword arg ERROR homeassistant/components/kegtron/sensor.py:124:7-35: Field `entity_description` is declared `EntityDescription` in ancestor `class PassiveBluetoothProcessorEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/keyboard_remote/__init__.py:12:1-64: Could not find import of `evdev` [missing-import] -ERROR homeassistant/components/keyboard_remote/__init__.py:119:24-33: `Inotify` is not assignable to attribute `inotify` with type `None` [bad-assignment] -ERROR homeassistant/components/keyboard_remote/__init__.py:120:24-46: Object of class `NoneType` has no attribute `add_watch` [missing-attribute] -ERROR homeassistant/components/keyboard_remote/__init__.py:144:29-86: `Task[Unknown]` is not assignable to attribute `monitor_task` with type `None` [bad-assignment] ERROR homeassistant/components/keyboard_remote/__init__.py:163:37-73: Object of class `Future` has no attribute `async_device_stop_monitoring` [missing-attribute] -ERROR homeassistant/components/keyboard_remote/__init__.py:204:32-44: Type `None` is not an async iterable [not-iterable] +ERROR homeassistant/components/keyboard_remote/__init__.py:204:32-44: Type `Unknown | None` is not an async iterable [not-iterable] ERROR homeassistant/components/keyboard_remote/__init__.py:218:27-63: Object of class `Future` has no attribute `async_device_stop_monitoring` [missing-attribute] ERROR homeassistant/components/keyboard_remote/__init__.py:268:38-51: Object of class `NoneType` has no attribute `name` [missing-attribute] -ERROR homeassistant/components/keyboard_remote/__init__.py:284:37-286:18: `Task[Unknown]` is not assignable to attribute `monitor_task` with type `None` [bad-assignment] -ERROR homeassistant/components/keyboard_remote/__init__.py:309:37-41: `None` is not assignable to attribute `monitor_task` with type `Never` [bad-assignment] -ERROR homeassistant/components/keyboard_remote/__init__.py:318:28-32: `None` is not assignable to attribute `dev` with type `Never` [bad-assignment] +ERROR homeassistant/components/keyboard_remote/__init__.py:300:60-75: Object of class `NoneType` has no attribute `ungrab` [missing-attribute] +ERROR homeassistant/components/keyboard_remote/__init__.py:304:56-71: Object of class `NoneType` has no attribute `fileno` [missing-attribute] +ERROR homeassistant/components/keyboard_remote/__init__.py:305:17-31: Object of class `NoneType` has no attribute `close` [missing-attribute] +ERROR homeassistant/components/keyboard_remote/__init__.py:314:38-51: Object of class `NoneType` has no attribute `name` [missing-attribute] +ERROR homeassistant/components/keyboard_remote/__init__.py:317:60-73: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR homeassistant/components/keyboard_remote/__init__.py:332:56-69: Object of class `NoneType` has no attribute `grab` [missing-attribute] ERROR homeassistant/components/keyboard_remote/__init__.py:333:36-60: Object of class `NoneType` has no attribute `async_read_loop` [missing-attribute] ERROR homeassistant/components/keyboard_remote/__init__.py:337:51-64: Object of class `NoneType` has no attribute `name` [missing-attribute] @@ -13327,11 +13059,9 @@ ERROR homeassistant/components/keymitt_ble/config_flow.py:68:41-61: Argument `Mi ERROR homeassistant/components/keymitt_ble/config_flow.py:105:46-66: Argument `MicroBotAdvertisement | None` is not assignable to parameter `discovery` with type `MicroBotAdvertisement` in function `name_from_discovery` [bad-argument-type] ERROR homeassistant/components/keymitt_ble/config_flow.py:133:20-36: Argument `BLEDevice | None` is not assignable to parameter `device` with type `BLEDevice` in function `microbot.MicroBotApiClient.__init__` [bad-argument-type] ERROR homeassistant/components/kitchen_sink/backup.py:77:15-36: Class member `KitchenSinkBackupAgent.async_download_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] -ERROR homeassistant/components/kitchen_sink/config_flow.py:35:9-31: Class member `KitchenSinkConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/kiwi/lock.py:8:1-45: Could not find import of `kiwiki` [missing-import] ERROR homeassistant/components/kmtronic/config_flow.py:50:12-37: Module `aiohttp.client_exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/kmtronic/config_flow.py:52:12-37: Module `aiohttp.client_exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR homeassistant/components/kmtronic/config_flow.py:65:9-31: Class member `KmtronicConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/knocki/coordinator.py:19:5-17: Class member `KnockiCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/knx/binary_sensor.py:113:5-12: Class member `KnxYamlBinarySensor._device` overrides parent class `KnxYamlEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/knx/binary_sensor.py:132:14-32: Class member `KnxYamlBinarySensor._attr_device_class` overrides parent class `KnxYamlEntity` in an inconsistent manner [bad-override] @@ -13342,7 +13072,6 @@ ERROR homeassistant/components/knx/climate.py:344:14-38: Class member `_KnxClima ERROR homeassistant/components/knx/climate.py:517:61-80: Argument `HVACControllerMode | None` is not assignable to parameter `controller_mode` with type `HVACControllerMode` in function `xknx.devices.climate_mode.ClimateMode.set_controller_mode` [bad-argument-type] ERROR homeassistant/components/knx/climate.py:646:5-12: Class member `KnxYamlClimate._device` overrides parent class `KnxYamlEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/knx/climate.py:676:5-12: Class member `KnxUiClimate._device` overrides parent class `KnxUiEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/knx/config_flow.py:127:9-31: Class member `KNXConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/knx/config_flow.py:312:20-68: Object of class `NoneType` has no attribute `tunnelling_requires_secure` [missing-attribute] ERROR homeassistant/components/knx/config_flow.py:314:20-65: Object of class `NoneType` has no attribute `supports_tunnelling_tcp` [missing-attribute] ERROR homeassistant/components/knx/config_flow.py:318:22-51: Object of class `NoneType` has no attribute `ip_addr` [missing-attribute] @@ -13394,7 +13123,7 @@ ERROR homeassistant/components/knx/sensor.py:52:5-20: Class member `KNXSystemEnt ERROR homeassistant/components/knx/sensor.py:59:9-12: Unexpected keyword argument `key` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/knx/sensor.py:65:9-12: Unexpected keyword argument `key` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/knx/sensor.py:72:9-12: Unexpected keyword argument `key` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/knx/sensor.py:75:17-58: Argument `list[str | None]` is not assignable to parameter `options` with type `list[str] | None` in function `KNXSystemEntityDescription.__init__` [bad-argument-type] +ERROR homeassistant/components/knx/sensor.py:75:17-58: Argument `list[str | Unknown | None]` is not assignable to parameter `options` with type `list[str] | None` in function `KNXSystemEntityDescription.__init__` [bad-argument-type] ERROR homeassistant/components/knx/sensor.py:80:9-12: Unexpected keyword argument `key` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/knx/sensor.py:81:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/knx/sensor.py:82:9-21: Unexpected keyword argument `force_update` in function `KNXSystemEntityDescription.__init__` [unexpected-keyword] @@ -13425,7 +13154,6 @@ ERROR homeassistant/components/kodi/media_player.py:129:59-62: `uid` may be unin ERROR homeassistant/components/kodi/media_player.py:321:55-81: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]] | None` in function `homeassistant.helpers.device_registry.DeviceRegistry.async_get_device` [bad-argument-type] ERROR homeassistant/components/kodi/media_player.py:322:37-46: Object of class `NoneType` has no attribute `id` [missing-attribute] ERROR homeassistant/components/kodi/media_player.py:323:27-36: Object of class `NoneType` has no attribute `id` [missing-attribute] -ERROR homeassistant/components/kodi/media_player.py:406:51-67: `datetime` is not assignable to attribute `_media_position_updated_at` with type `None` [bad-assignment] ERROR homeassistant/components/kodi/media_player.py:456:36-60: No matching overload found for function `dict.get` called with arguments: (Unknown | None) [no-matching-overload] ERROR homeassistant/components/konnected/__init__.py:242:32-35: `cfg` may be uninitialized [unbound-name] ERROR homeassistant/components/konnected/__init__.py:243:28-31: `cfg` may be uninitialized [unbound-name] @@ -13439,7 +13167,6 @@ ERROR homeassistant/components/konnected/__init__.py:380:65-72: `payload` may be ERROR homeassistant/components/konnected/__init__.py:427:31-39: `zone_num` may be uninitialized [unbound-name] ERROR homeassistant/components/konnected/__init__.py:428:14-22: `zone_num` may be uninitialized [unbound-name] ERROR homeassistant/components/konnected/__init__.py:429:42-50: `zone_num` may be uninitialized [unbound-name] -ERROR homeassistant/components/konnected/config_flow.py:397:9-31: Class member `KonnectedFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/konnected/config_flow.py:766:52-81: No matching overload found for function `dict.get` called with arguments: (Literal['activation'], Literal['high']) [no-matching-overload] ERROR homeassistant/components/konnected/config_flow.py:770:52-83: No matching overload found for function `dict.get` called with arguments: (Literal['momentary'], Undefined) [no-matching-overload] ERROR homeassistant/components/konnected/config_flow.py:774:52-79: No matching overload found for function `dict.get` called with arguments: (Literal['pause'], Undefined) [no-matching-overload] @@ -13448,10 +13175,7 @@ ERROR homeassistant/components/konnected/config_flow.py:818:56-85: No matching o ERROR homeassistant/components/konnected/config_flow.py:822:56-87: No matching overload found for function `dict.get` called with arguments: (Literal['momentary'], Undefined) [no-matching-overload] ERROR homeassistant/components/konnected/config_flow.py:826:56-83: No matching overload found for function `dict.get` called with arguments: (Literal['pause'], Undefined) [no-matching-overload] ERROR homeassistant/components/konnected/config_flow.py:830:56-84: No matching overload found for function `dict.get` called with arguments: (Literal['repeat'], Undefined) [no-matching-overload] -ERROR homeassistant/components/konnected/panel.py:117:27-121:14: `Client` is not assignable to attribute `client` with type `None` [bad-assignment] -ERROR homeassistant/components/konnected/panel.py:122:33-55: Object of class `NoneType` has no attribute `get_status` [missing-attribute] ERROR homeassistant/components/konnected/panel.py:136:16-39: Object of class `NoneType` has no attribute `ClientError` [missing-attribute] -ERROR homeassistant/components/konnected/panel.py:141:41-143:14: `() -> None` is not assignable to attribute `cancel_connect_retry` with type `None` [bad-assignment] ERROR homeassistant/components/konnected/panel.py:191:16-39: Object of class `NoneType` has no attribute `ClientError` [missing-attribute] ERROR homeassistant/components/konnected/panel.py:320:28-43: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/konnected/panel.py:356:20-43: `None` is not subscriptable [unsupported-operation] @@ -13466,11 +13190,7 @@ ERROR homeassistant/components/konnected/sensor.py:35:9-12: Unexpected keyword a ERROR homeassistant/components/konnected/sensor.py:36:9-13: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/konnected/sensor.py:122:27-31: `name` may be uninitialized [unbound-name] ERROR homeassistant/components/kostal_plenticore/__init__.py:39:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/kostal_plenticore/coordinator.py:57:16-28: Returned type `None` is not assignable to declared return type `ApiClient` [bad-return] -ERROR homeassistant/components/kostal_plenticore/coordinator.py:61:24-63:10: `ExtendedApiClient` is not assignable to attribute `_client` with type `None` [bad-assignment] -ERROR homeassistant/components/kostal_plenticore/coordinator.py:65:19-37: Object of class `NoneType` has no attribute `login` [missing-attribute] -ERROR homeassistant/components/kostal_plenticore/coordinator.py:85:45-57: Argument `None` is not assignable to parameter `client` with type `ApiClient` in function `homeassistant.components.kostal_plenticore.helper.get_hostname_id` [bad-argument-type] -ERROR homeassistant/components/kostal_plenticore/coordinator.py:86:26-57: Object of class `NoneType` has no attribute `get_setting_values` [missing-attribute] +ERROR homeassistant/components/kostal_plenticore/coordinator.py:57:16-28: Returned type `Unknown | None` is not assignable to declared return type `ApiClient` [bad-return] ERROR homeassistant/components/kostal_plenticore/coordinator.py:103:28-113:10: `DeviceInfo` is not assignable to attribute `device_info` with type `dict[Unknown, Unknown]` [bad-assignment] ERROR homeassistant/components/kostal_plenticore/coordinator.py:128:15-34: Object of class `NoneType` has no attribute `logout` [missing-attribute] ERROR homeassistant/components/kostal_plenticore/coordinator.py:171:5-17: Class member `PlenticoreUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -13696,7 +13416,6 @@ ERROR homeassistant/components/kostal_plenticore/switch.py:258:5-23: Class membe ERROR homeassistant/components/kostal_plenticore/switch.py:285:13-16: Unexpected keyword argument `key` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/kostal_plenticore/switch.py:286:13-17: Unexpected keyword argument `name` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/kostal_plenticore/switch.py:287:13-44: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/kraken/config_flow.py:32:9-31: Class member `KrakenConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/kraken/sensor.py:45:9-12: Unexpected keyword argument `key` in function `KrakenSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/kraken/sensor.py:46:9-24: Unexpected keyword argument `translation_key` in function `KrakenSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/kraken/sensor.py:50:9-12: Unexpected keyword argument `key` in function `KrakenSensorEntityDescription.__init__` [unexpected-keyword] @@ -13786,7 +13505,6 @@ ERROR homeassistant/components/lamarzocco/button.py:46:9-12: Unexpected keyword ERROR homeassistant/components/lamarzocco/button.py:47:9-24: Unexpected keyword argument `translation_key` in function `LaMarzoccoButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lamarzocco/button.py:71:5-23: Class member `LaMarzoccoButtonEntity.entity_description` overrides parent class `LaMarzoccoEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lamarzocco/button.py:71:5-23: Class member `LaMarzoccoButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lamarzocco/config_flow.py:368:9-31: Class member `LmConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/lamarzocco/coordinator.py:53:5-17: Class member `LaMarzoccoUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/lamarzocco/entity.py:101:5-23: Class member `LaMarzoccoEntity.entity_description` overrides parent class `LaMarzoccoBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lamarzocco/number.py:48:9-12: Unexpected keyword argument `key` in function `LaMarzoccoNumberEntityDescription.__init__` [unexpected-keyword] @@ -14005,7 +13723,6 @@ ERROR homeassistant/components/landisgyr_heat_meter/sensor.py:261:9-13: Unexpect ERROR homeassistant/components/landisgyr_heat_meter/sensor.py:262:9-24: Unexpected keyword argument `entity_category` in function `HeatMeterSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/landisgyr_heat_meter/sensor.py:298:5-23: Class member `HeatMeterSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/landisgyr_heat_meter/sensor.py:298:5-23: Class member `HeatMeterSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lastfm/config_flow.py:83:9-31: Class member `LastFmConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/lastfm/coordinator.py:41:5-17: Class member `LastFMDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/launch_library/__init__.py:44:29-73: Argument `dict[str, int | str]` is not assignable to parameter `filters` with type `Mapping[str, str] | None` in function `pylaunches.api.PyLaunches.launch_upcoming` [bad-argument-type] ERROR homeassistant/components/launch_library/__init__.py:73:12-21: `unload_ok` may be uninitialized [unbound-name] @@ -14079,15 +13796,14 @@ ERROR homeassistant/components/lawn_mower/__init__.py:85:5-29: Class member `Law ERROR homeassistant/components/lcn/__init__.py:301:26-307:10: No matching overload found for function `typing.MutableMapping.update` called with arguments: (dict[str, int | str | None]) [no-matching-overload] ERROR homeassistant/components/lcn/climate.py:108:14-38: Class member `LcnClimate._attr_supported_features` overrides parent class `LcnEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lcn/cover.py:179:5-29: Class member `LcnRelayCover._attr_supported_features` overrides parent class `LcnEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/lcn/cover.py:196:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/lcn/cover.py:196:13-77: `|=` is not supported between `None` and `Literal[CoverEntityFeature.SET_POSITION]` [unsupported-operation] ERROR homeassistant/components/lcn/helpers.py:273:12-20: `is_group` may be uninitialized [unbound-name] ERROR homeassistant/components/lcn/helpers.py:275:8-16: `is_group` may be uninitialized [unbound-name] ERROR homeassistant/components/lcn/helpers.py:276:34-42: `is_group` may be uninitialized [unbound-name] ERROR homeassistant/components/lcn/light.py:84:5-29: Class member `LcnOutputLight._attr_supported_features` overrides parent class `LcnEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lcn/scene.py:87:31-89:14: `int` is not assignable to attribute `transition` with type `None` [bad-assignment] ERROR homeassistant/components/lcn/schemas.py:66:9-34: Argument `Literal[UnitOfTemperature.CELSIUS]` is not assignable to parameter `container` with type `Container[Unknown]` in function `voluptuous.validators.In.__init__` [bad-argument-type] ERROR homeassistant/components/lcn/sensor.py:132:14-32: Class member `LcnVariableSensor._attr_device_class` overrides parent class `LcnEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/ld2410_ble/__init__.py:65:38-56: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/ld2410_ble/__init__.py:98:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/ld2410_ble/binary_sensor.py:19:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ld2410_ble/binary_sensor.py:23:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -14146,7 +13862,6 @@ ERROR homeassistant/components/leaone/sensor.py:71:9-24: Unexpected keyword argu ERROR homeassistant/components/leaone/sensor.py:73:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/leaone/sensor.py:123:7-34: Field `entity_description` is declared `EntityDescription` in ancestor `class PassiveBluetoothProcessorEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/led_ble/__init__.py:51:38-56: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] ERROR homeassistant/components/led_ble/__init__.py:117:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/led_ble/light.py:47:5-29: Class member `LEDBLEEntity._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lektrico/binary_sensor.py:29:9-12: Unexpected keyword argument `key` in function `LektricoBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -14333,10 +14048,6 @@ ERROR homeassistant/components/letpot/time.py:46:9-24: Unexpected keyword argume ERROR homeassistant/components/letpot/time.py:53:9-24: Unexpected keyword argument `entity_category` in function `LetPotTimeEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/letpot/time.py:75:5-23: Class member `LetPotTimeEntity.entity_description` overrides parent class `LetPotEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/letpot/time.py:75:5-23: Class member `LetPotTimeEntity.entity_description` overrides parent class `TimeEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lg_netcast/media_player.py:130:44-64: `int` is not assignable to attribute `_channel_id` with type `None` [bad-assignment] -ERROR homeassistant/components/lg_soundbar/media_player.py:89:24-91:10: `temescal` is not assignable to attribute `_device` with type `None` [bad-assignment] -ERROR homeassistant/components/lg_soundbar/media_player.py:92:9-38: Object of class `NoneType` has no attribute `get_product_info` [missing-attribute] -ERROR homeassistant/components/lg_soundbar/media_player.py:93:9-34: Object of class `NoneType` has no attribute `get_mac_info` [missing-attribute] ERROR homeassistant/components/lg_soundbar/media_player.py:155:9-28: Object of class `NoneType` has no attribute `get_eq` [missing-attribute] ERROR homeassistant/components/lg_soundbar/media_player.py:156:9-30: Object of class `NoneType` has no attribute `get_info` [missing-attribute] ERROR homeassistant/components/lg_soundbar/media_player.py:157:9-30: Object of class `NoneType` has no attribute `get_func` [missing-attribute] @@ -14751,7 +14462,7 @@ ERROR homeassistant/components/lg_thinq/vacuum.py:83:55-85:14: No matching overl ERROR homeassistant/components/lg_thinq/vacuum.py:97:7-29: Field `entity_description` is declared `EntityDescription` in ancestor `class ThinQEntity: ... `, which is not assignable to the type `StateVacuumEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/lg_thinq/vacuum.py:100:5-29: Class member `ThinQStateVacuumEntity._attr_supported_features` overrides parent class `ThinQEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lg_thinq/vacuum.py:114:50-73: Cannot index into `dict[str, VacuumActivity]` [bad-index] +ERROR homeassistant/components/lg_thinq/vacuum.py:114:50-73: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/lg_thinq/water_heater.py:29:70-38:2: `dict[str, WaterHeaterEntityDescription]` is not assignable to `dict[DeviceType, WaterHeaterEntityDescription]` [bad-assignment] ERROR homeassistant/components/lg_thinq/water_heater.py:31:9-12: Unexpected keyword argument `key` in function `homeassistant.components.water_heater.WaterHeaterEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lg_thinq/water_heater.py:32:9-13: Unexpected keyword argument `name` in function `homeassistant.components.water_heater.WaterHeaterEntityDescription.__init__` [unexpected-keyword] @@ -14789,43 +14500,41 @@ ERROR homeassistant/components/lifx/button.py:19:5-8: Unexpected keyword argumen ERROR homeassistant/components/lifx/button.py:21:5-20: Unexpected keyword argument `entity_category` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/button.py:25:5-8: Unexpected keyword argument `key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/button.py:27:5-20: Unexpected keyword argument `entity_category` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/lifx/config_flow.py:147:46-58: `dict[str, None]` is not assignable to TypedDict key `title_placeholders` with type `Mapping[str, str]` [bad-typed-dict-key] -ERROR homeassistant/components/lifx/config_flow.py:149:67-79: Argument `dict[str, None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.config_entries.ConfigFlow.async_show_form` [bad-argument-type] -ERROR homeassistant/components/lifx/config_flow.py:219:19-31: Argument `None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] -ERROR homeassistant/components/lifx/config_flow.py:233:25-42: `None` is not assignable to `Light` [bad-assignment] -ERROR homeassistant/components/lifx/config_flow.py:261:27-60: `str | Unknown` is not assignable to attribute `mac_addr` with type `Never` [bad-assignment] +ERROR homeassistant/components/lifx/config_flow.py:147:46-58: `dict[str, Unknown | None]` is not assignable to TypedDict key `title_placeholders` with type `Mapping[str, str]` [bad-typed-dict-key] +ERROR homeassistant/components/lifx/config_flow.py:149:67-79: Argument `dict[str, Unknown | None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.config_entries.ConfigFlow.async_show_form` [bad-argument-type] +ERROR homeassistant/components/lifx/config_flow.py:219:19-31: Argument `Unknown | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] +ERROR homeassistant/components/lifx/config_flow.py:233:25-42: `Unknown | None` is not assignable to `Light` [bad-assignment] ERROR homeassistant/components/lifx/coordinator.py:93:5-17: Class member `LIFXUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lifx/coordinator.py:139:27-60: Argument `None` is not assignable to parameter `version` with type `str` in function `awesomeversion.awesomeversion.AwesomeVersion.__new__` [bad-argument-type] -ERROR homeassistant/components/lifx/coordinator.py:147:52-83: Argument `None` is not assignable to parameter `value` with type `int` in function `homeassistant.components.lifx.util.infrared_brightness_value_to_option` [bad-argument-type] -ERROR homeassistant/components/lifx/coordinator.py:162:13-46: Argument `None` is not assignable to parameter `firmware` with type `str` in function `homeassistant.components.lifx.util.get_real_mac_addr` [bad-argument-type] +ERROR homeassistant/components/lifx/coordinator.py:139:27-60: Argument `Unknown | None` is not assignable to parameter `version` with type `str` in function `awesomeversion.awesomeversion.AwesomeVersion.__new__` [bad-argument-type] +ERROR homeassistant/components/lifx/coordinator.py:147:52-83: Argument `Unknown | None` is not assignable to parameter `value` with type `int` in function `homeassistant.components.lifx.util.infrared_brightness_value_to_option` [bad-argument-type] +ERROR homeassistant/components/lifx/coordinator.py:162:13-46: Argument `Unknown | None` is not assignable to parameter `firmware` with type `str` in function `homeassistant.components.lifx.util.get_real_mac_addr` [bad-argument-type] ERROR homeassistant/components/lifx/coordinator.py:200:20-40: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/coordinator.py:201:27-47: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/coordinator.py:202:27-47: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/coordinator.py:203:23-43: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/lifx/coordinator.py:209:48-71: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] -ERROR homeassistant/components/lifx/coordinator.py:210:17-38: Cannot set item in `int` [unsupported-operation] +ERROR homeassistant/components/lifx/coordinator.py:209:48-71: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/lifx/coordinator.py:294:27-31: Argument `Light` is not assignable to parameter with type `Message` [bad-argument-type] ERROR homeassistant/components/lifx/coordinator.py:294:33-41: Argument `Message` is not assignable to parameter with type `dict[str, Any] | None` [bad-argument-type] ERROR homeassistant/components/lifx/coordinator.py:385:47-66: Object of class `Message` has no attribute `signal` [missing-attribute] ERROR homeassistant/components/lifx/coordinator.py:388:49-88: Enum `FirmwareEffect` can only be indexed by strings [bad-index] ERROR homeassistant/components/lifx/coordinator.py:532:28-69: `int` is not assignable to variable `sky_type` with type `str | None` [bad-assignment] -ERROR homeassistant/components/lifx/entity.py:29:43-75: No matching overload found for function `dict.get` called with arguments: (None, Literal['LIFX Bulb']) [no-matching-overload] +ERROR homeassistant/components/lifx/entity.py:29:43-75: No matching overload found for function `dict.get` called with arguments: (Unknown | None, Literal['LIFX Bulb']) [no-matching-overload] ERROR homeassistant/components/lifx/light.py:120:5-29: Class member `LIFXLight._attr_supported_features` overrides parent class `LIFXEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lifx/light.py:155:16-45: `/` is not supported between `None` and `Literal[65535]` [unsupported-operation] ERROR homeassistant/components/lifx/light.py:156:43-75: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/light.py:161:20-48: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/lifx/light.py:315:34-49: Argument `None` is not assignable to parameter `base` with type `list[float | int | None]` in function `homeassistant.components.lifx.util.merge_hsbk` [bad-argument-type] +ERROR homeassistant/components/lifx/light.py:315:34-49: Argument `Unknown | None` is not assignable to parameter `base` with type `list[float | int | None]` in function `homeassistant.components.lifx.util.merge_hsbk` [bad-argument-type] ERROR homeassistant/components/lifx/light.py:383:19-51: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/light.py:389:9-23: Type `None` is not iterable [not-iterable] ERROR homeassistant/components/lifx/light.py:426:26-40: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/light.py:429:17-34: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/light.py:433:17-34: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/lifx/light.py:447:36-53: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/lifx/light.py:488:42-53: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/lifx/light.py:488:42-53: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/lifx/light.py:489:17-35: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/lifx/light.py:492:42-53: Argument `None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] +ERROR homeassistant/components/lifx/light.py:492:42-53: Argument `Unknown | None` is not assignable to parameter `iterable` with type `Iterable[@_]` in function `enumerate.__new__` [bad-argument-type] ERROR homeassistant/components/lifx/light.py:494:21-39: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/lifx/light.py:499:17-28: Argument `None` is not assignable to parameter `colors` with type `list[tuple[float | int, float | int, float | int, float | int]]` in function `homeassistant.components.lifx.coordinator.LIFXUpdateCoordinator.async_set_extended_color_zones` [bad-argument-type] +ERROR homeassistant/components/lifx/light.py:499:17-28: Argument `Unknown | None` is not assignable to parameter `colors` with type `list[tuple[float | int, float | int, float | int, float | int]]` in function `homeassistant.components.lifx.coordinator.LIFXUpdateCoordinator.async_set_extended_color_zones` [bad-argument-type] ERROR homeassistant/components/lifx/select.py:20:5-8: Unexpected keyword argument `key` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/select.py:21:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/select.py:22:5-20: Unexpected keyword argument `entity_category` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] @@ -14839,7 +14548,7 @@ ERROR homeassistant/components/lifx/sensor.py:25:5-20: Unexpected keyword argume ERROR homeassistant/components/lifx/sensor.py:27:5-20: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/sensor.py:29:5-36: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lifx/sensor.py:54:14-32: Class member `LIFXRssiSensor.entity_description` overrides parent class `LIFXEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lifx/util.py:82:34-48: No matching overload found for function `dict.get` called with arguments: (None) [no-matching-overload] +ERROR homeassistant/components/lifx/util.py:82:34-48: No matching overload found for function `dict.get` called with arguments: (Unknown | None) [no-matching-overload] ERROR homeassistant/components/light/__init__.py:503:21-48: Expected 7 positional arguments, got 9 in function `homeassistant.util.color.color_rgbww_to_rgb` [bad-argument-count] ERROR homeassistant/components/light/__init__.py:806:25-28: `rec` is uninitialized [unbound-name] ERROR homeassistant/components/light/__init__.py:903:5-23: Class member `LightEntity.entity_description` overrides parent class `ToggleEntity` in an inconsistent manner [bad-override] @@ -14857,7 +14566,6 @@ ERROR homeassistant/components/limitlessled/light.py:15:1-48: Could not find imp ERROR homeassistant/components/limitlessled/light.py:16:1-43: Could not find import of `limitlessled.pipeline` [missing-import] ERROR homeassistant/components/limitlessled/light.py:17:1-43: Could not find import of `limitlessled.presets` [missing-import] ERROR homeassistant/components/limitlessled/light.py:229:18-42: Class member `LimitlessLEDGroup._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/limitlessled/light.py:246:38-76: `ColorMode | str` is not assignable to attribute `_fixed_color_mode` with type `None` [bad-assignment] ERROR homeassistant/components/limitlessled/light.py:362:26-42: No matching overload found for function `min` called with arguments: (Literal[1], float) [no-matching-overload] ERROR homeassistant/components/linkplay/__init__.py:68:36-42: Argument `LinkPlayBridge | None` is not assignable to parameter `bridge_to_remove` with type `LinkPlayBridge` in function `linkplay.controller.LinkPlayController.remove_bridge` [bad-argument-type] ERROR homeassistant/components/linkplay/button.py:36:9-12: Unexpected keyword argument `key` in function `LinkPlayButtonEntityDescription.__init__` [unexpected-keyword] @@ -14870,7 +14578,7 @@ ERROR homeassistant/components/linkplay/button.py:67:5-23: Class member `LinkPla ERROR homeassistant/components/linkplay/entity.py:42:78-87: Cannot index into `dict[DeviceAttribute, str]` [bad-index] ERROR homeassistant/components/linkplay/entity.py:45:49-58: Cannot index into `dict[DeviceAttribute, str]` [bad-index] ERROR homeassistant/components/linkplay/entity.py:50:70-75: Cannot index into `dict[DeviceAttribute, str]` [bad-index] -ERROR homeassistant/components/linkplay/entity.py:54:31-46: Argument `LinkPlayEndpoint` is not assignable to parameter `configuration_url` with type `URL | str | None` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/linkplay/entity.py:53:47-63:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (configuration_url=LinkPlayEndpoint, connections=set[tuple[str, str]], hw_version=str, identifiers=set[tuple[str, str]], manufacturer=str, model=str, model_id=str | None, name=str, sw_version=str) [no-matching-overload] ERROR homeassistant/components/linkplay/entity.py:56:49-59: Cannot index into `dict[DeviceAttribute, str]` [bad-index] ERROR homeassistant/components/linkplay/entity.py:62:49-59: Cannot index into `dict[DeviceAttribute, str]` [bad-index] ERROR homeassistant/components/linkplay/media_player.py:143:5-23: Class member `LinkPlayMediaPlayerEntity._attr_device_class` overrides parent class `LinkPlayBaseEntity` in an inconsistent manner [bad-override] @@ -14892,7 +14600,6 @@ ERROR homeassistant/components/linode/switch.py:73:12-28: Object of class `NoneT ERROR homeassistant/components/linode/switch.py:74:13-27: Object of class `NoneType` has no attribute `boot` [missing-attribute] ERROR homeassistant/components/linode/switch.py:78:12-28: Object of class `NoneType` has no attribute `status` [missing-attribute] ERROR homeassistant/components/linode/switch.py:79:13-31: Object of class `NoneType` has no attribute `shutdown` [missing-attribute] -ERROR homeassistant/components/linode/switch.py:90:49-99:14: `dict[str, Never]` is not assignable to attribute `_attr_extra_state_attributes` with type `Never` [bad-assignment] ERROR homeassistant/components/linux_battery/sensor.py:8:1-30: Could not find import of `batinfo` [missing-import] ERROR homeassistant/components/linux_battery/sensor.py:104:28-51: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR homeassistant/components/linux_battery/sensor.py:105:28-51: Object of class `NoneType` has no attribute `path` [missing-attribute] @@ -14913,7 +14620,6 @@ ERROR homeassistant/components/linux_battery/sensor.py:121:33-65: Object of clas ERROR homeassistant/components/linux_battery/sensor.py:122:26-51: Object of class `NoneType` has no attribute `status` [missing-attribute] ERROR homeassistant/components/linux_battery/sensor.py:123:38-75: Object of class `NoneType` has no attribute `voltage_min_design` [missing-attribute] ERROR homeassistant/components/linux_battery/sensor.py:124:31-61: Object of class `NoneType` has no attribute `voltage_now` [missing-attribute] -ERROR homeassistant/components/litejet/config_flow.py:79:9-31: Class member `LiteJetConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/litejet/light.py:110:73-85: No matching overload found for function `int.__new__` called with arguments: (type[int], Any | None) [no-matching-overload] ERROR homeassistant/components/litterrobot/binary_sensor.py:36:13-16: Unexpected keyword argument `key` in function `RobotBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/litterrobot/binary_sensor.py:37:13-28: Unexpected keyword argument `translation_key` in function `RobotBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -15028,7 +14734,6 @@ ERROR homeassistant/components/livisi/coordinator.py:107:42-84: `dict[str, Any]` ERROR homeassistant/components/local_calendar/calendar.py:220:13-24: `-` is not supported between `datetime` and `date` [unsupported-operation] ERROR homeassistant/components/local_todo/todo.py:155:25-28: `due` may be uninitialized [unbound-name] ERROR homeassistant/components/local_todo/todo.py:176:51-84: Unpacked argument `tuple[str, Todo]` is not assignable to parameter `*args` with type `tuple[str, Todo, str | None, Range]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/locative/device_tracker.py:52:34-54:10: `() -> None` is not assignable to attribute `_unsub_dispatcher` with type `None` [bad-assignment] ERROR homeassistant/components/locative/device_tracker.py:58:9-31: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/lock/__init__.py:116:5-23: Class member `LockEntity.entity_description` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lock/__init__.py:125:5-16: Class member `LockEntity._attr_state` overrides parent class `Entity` in an inconsistent manner [bad-override] @@ -15048,7 +14753,6 @@ ERROR homeassistant/components/logbook/websocket_api.py:377:9-19: `start_time` m ERROR homeassistant/components/logbook/websocket_api.py:424:29-39: `start_time` may be uninitialized [unbound-name] ERROR homeassistant/components/logger/websocket_api.py:42:12-31: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/logger/websocket_api.py:43:30-45: Argument `_HandlerT` is not assignable to parameter `element` with type `str` in function `set.add` [bad-argument-type] -ERROR homeassistant/components/london_air/sensor.py:141:26-84: Cannot set item in `dict[str, None]` [unsupported-operation] ERROR homeassistant/components/london_underground/config_flow.py:36:9-31: Class member `LondonUndergroundConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/components/lookin/__init__.py:81:78-82: Argument `None` is not assignable to parameter `device_id` with type `str` in function `aiolookin.protocol.start_lookin_udp` [bad-argument-type] ERROR homeassistant/components/lookin/__init__.py:82:20-39: Returned type `LookinUDPSubscriptions | None` is not assignable to declared return type `LookinUDPSubscriptions` [bad-return] @@ -15081,14 +14785,6 @@ ERROR homeassistant/components/loqed/sensor.py:33:9-12: Unexpected keyword argum ERROR homeassistant/components/loqed/sensor.py:36:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/loqed/sensor.py:61:14-32: Class member `LoqedSensor.entity_description` overrides parent class `LoqedEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/loqed/sensor.py:67:16-37: Returned type `Lock` is not assignable to declared return type `StatusMessage` [bad-return] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `sidebar_title` with type `str | None` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `sidebar_icon` with type `str | None` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `sidebar_default_visible` with type `bool` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `frontend_url_path` with type `str | None` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `config` with type `dict[str, Any] | None` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `require_admin` with type `bool` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `update` with type `bool` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] -ERROR homeassistant/components/lovelace/__init__.py:340:58-66: Unpacked keyword argument `bool | dict[str, str] | str | Unknown | None` is not assignable to parameter `config_panel_domain` with type `str | None` in function `homeassistant.components.frontend.async_register_built_in_panel` [bad-argument-type] ERROR homeassistant/components/lovelace/resources.py:153:15-27: Class member `ResourceStorageCollectionWebsocket.ws_list_item` overrides parent class `DictStorageCollectionWebsocket` in an inconsistent manner [bad-override] ERROR homeassistant/components/lovelace/websocket.py:61:43-49: `result` may be uninitialized [unbound-name] ERROR homeassistant/components/luci/device_tracker.py:7:1-40: Could not find import of `openwrt_luci_rpc` [missing-import] @@ -15126,7 +14822,6 @@ ERROR homeassistant/components/lutron/__init__.py:127:46-78: Argument `tuple[Unk ERROR homeassistant/components/lutron/binary_sensor.py:49:5-19: Class member `LutronOccupancySensor._lutron_device` overrides parent class `LutronDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron/binary_sensor.py:50:5-23: Class member `LutronOccupancySensor._attr_device_class` overrides parent class `LutronDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron/config_flow.py:62:48-52: `guid` may be uninitialized [unbound-name] -ERROR homeassistant/components/lutron/config_flow.py:81:9-31: Class member `LutronConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron/cover.py:48:5-29: Class member `LutronCover._attr_supported_features` overrides parent class `LutronDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron/cover.py:53:5-19: Class member `LutronCover._lutron_device` overrides parent class `LutronDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron/event.py:62:27-31: `name` may be uninitialized [unbound-name] @@ -15147,13 +14842,13 @@ ERROR homeassistant/components/lutron_caseta/__init__.py:292:35-41: `keypad` may ERROR homeassistant/components/lutron_caseta/__init__.py:303:9-15: `keypad` may be uninitialized [unbound-name] ERROR homeassistant/components/lutron_caseta/__init__.py:483:13-485:14: Argument `(event_type: str, button_id: Unknown) -> Unknown` is not assignable to parameter `callback_` with type `(str) -> None` in function `pylutron_caseta.smartbridge.Smartbridge.add_button_subscriber` [bad-argument-type] ERROR homeassistant/components/lutron_caseta/binary_sensor.py:43:5-23: Class member `LutronOccupancySensor._attr_device_class` overrides parent class `LutronCasetaEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lutron_caseta/binary_sensor.py:55:18-27: Argument `UndefinedType | str | None` is not assignable to parameter `name` with type `str | None` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/lutron_caseta/binary_sensor.py:51:44-59:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Unknown]], manufacturer=Literal['Lutron Electronics Co., Inc'], model=Literal['Lutron Occupancy'], name=UndefinedType | str | None, via_device=tuple[Literal['lutron_caseta'], Any], configuration_url=Literal['https://device-login.lutron.com'], entry_type=Literal[DeviceEntryType.SERVICE]) [no-matching-overload] ERROR homeassistant/components/lutron_caseta/button.py:56:57-68: `device_name` may be uninitialized [unbound-name] ERROR homeassistant/components/lutron_caseta/cover.py:32:5-29: Class member `LutronCasetaShade._attr_supported_features` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron_caseta/cover.py:38:5-23: Class member `LutronCasetaShade._attr_device_class` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron_caseta/cover.py:107:5-29: Class member `LutronCasetaTiltOnlyBlind._attr_supported_features` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron_caseta/cover.py:113:5-23: Class member `LutronCasetaTiltOnlyBlind._attr_device_class` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/lutron_caseta/entity.py:50:25-55:14: Argument `set[tuple[str, int | str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/lutron_caseta/entity.py:44:26-61:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, int | str]], manufacturer=Literal['Lutron Electronics Co., Inc'], model=str, name=str, via_device=tuple[Literal['lutron_caseta'], Any], configuration_url=Literal['https://device-login.lutron.com']) [no-matching-overload] ERROR homeassistant/components/lutron_caseta/fan.py:47:5-29: Class member `LutronCasetaFan._attr_supported_features` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron_caseta/light.py:87:5-29: Class member `LutronCasetaLight._attr_supported_features` overrides parent class `LutronCasetaUpdatableEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/lutron_caseta/light.py:169:29-39: Argument `Unknown | None` is not assignable to parameter `enabled` with type `bool` in function `pylutron_caseta.smartbridge.Smartbridge.set_warm_dim` [bad-argument-type] @@ -15162,8 +14857,6 @@ ERROR homeassistant/components/lutron_caseta/light.py:185:49-60: Argument `float ERROR homeassistant/components/lutron_caseta/switch.py:101:53-79: Argument `BoundMethod[Self@LutronCasetaSmartAwaySwitch, (self: Self@LutronCasetaSmartAwaySwitch) -> None]` is not assignable to parameter `callback_` with type `(str) -> None` in function `pylutron_caseta.smartbridge.Smartbridge.add_smart_away_subscriber` [bad-argument-type] ERROR homeassistant/components/lw12wifi/light.py:8:8-12: Could not find import of `lw12` [missing-import] ERROR homeassistant/components/lw12wifi/light.py:124:31-81: `tuple[int, int, int]` is not assignable to attribute `_rgb_color` with type `list[int]` [bad-assignment] -ERROR homeassistant/components/lw12wifi/light.py:145:23-27: `Literal[True]` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/lw12wifi/light.py:150:23-28: `Literal[False]` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/lyric/climate.py:133:21-24: Unexpected keyword argument `key` in function `homeassistant.components.climate.ClimateEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lyric/climate.py:134:21-25: Unexpected keyword argument `name` in function `homeassistant.components.climate.ClimateEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/lyric/climate.py:165:5-23: Class member `LyricClimate.entity_description` overrides parent class `LyricDeviceEntity` in an inconsistent manner [bad-override] @@ -15266,14 +14959,9 @@ ERROR homeassistant/components/madvr/sensor.py:247:9-24: Unexpected keyword argu ERROR homeassistant/components/madvr/sensor.py:248:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `MadvrSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/madvr/sensor.py:273:14-32: Class member `MadvrSensor.entity_description` overrides parent class `MadVREntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/madvr/sensor.py:273:14-32: Class member `MadvrSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mailgun/notify.py:75:24-74: `Client` is not assignable to attribute `_client` with type `None` [bad-assignment] -ERROR homeassistant/components/mailgun/notify.py:76:45-64: Object of class `NoneType` has no attribute `domain` [missing-attribute] -ERROR homeassistant/components/mailgun/notify.py:77:24-43: Object of class `NoneType` has no attribute `domain` [missing-attribute] ERROR homeassistant/components/mailgun/notify.py:105:20-42: Object of class `NoneType` has no attribute `send_mail` [missing-attribute] ERROR homeassistant/components/manual/alarm_control_panel.py:251:14-38: Class member `ManualAlarm._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/manual_mqtt/alarm_control_panel.py:361:26-42: `datetime` is not assignable to attribute `_state_ts` with type `None` [bad-assignment] ERROR homeassistant/components/manual_mqtt/alarm_control_panel.py:405:23-28: `str` is not assignable to attribute `_state` with type `AlarmControlPanelState` [bad-assignment] -ERROR homeassistant/components/manual_mqtt/alarm_control_panel.py:406:26-42: `datetime` is not assignable to attribute `_state_ts` with type `None` [bad-assignment] ERROR homeassistant/components/mastodon/coordinator.py:34:5-17: Class member `MastodonCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/mastodon/sensor.py:35:9-12: Unexpected keyword argument `key` in function `MastodonSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mastodon/sensor.py:36:9-24: Unexpected keyword argument `translation_key` in function `MastodonSensorEntityDescription.__init__` [unexpected-keyword] @@ -15837,20 +15525,19 @@ ERROR homeassistant/components/medcom_ble/sensor.py:26:9-24: Unexpected keyword ERROR homeassistant/components/medcom_ble/sensor.py:71:14-32: Class member `MedcomSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/medcom_ble/sensor.py:96:16-74: Returned type `float | str | None` is not assignable to declared return type `float` [bad-return] ERROR homeassistant/components/media_extractor/__init__.py:168:30-38: `entities` may be uninitialized [unbound-name] -ERROR homeassistant/components/media_extractor/__init__.py:178:40-57: Cannot set item in `dict[str, Logger | bool]` [unsupported-operation] +ERROR homeassistant/components/media_extractor/__init__.py:178:40-57: `str` is not assignable to TypedDict key `cookiefile` with type `Logger | bool` [bad-typed-dict-key] ERROR homeassistant/components/media_player/__init__.py:493:5-17: Class member `MediaPlayerEntityDescription.device_class` overrides parent class `EntityDescription` in an inconsistent manner [bad-override] ERROR homeassistant/components/media_player/__init__.py:553:5-23: Class member `MediaPlayerEntity.entity_description` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/media_player/__init__.py:558:5-23: Class member `MediaPlayerEntity._attr_device_class` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/media_player/__init__.py:585:5-16: Class member `MediaPlayerEntity._attr_state` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/media_player/__init__.py:586:5-29: Class member `MediaPlayerEntity._attr_supported_features` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/media_source/__init__.py:51:68-79: Function declared to return `MediaSource` but is missing an explicit `return` [bad-return] -ERROR homeassistant/components/media_source/__init__.py:74:56-68: Argument `Module[homeassistant.components.media_source.local_source]` is not assignable to parameter `platform` with type `MediaSourceProtocol` in function `_process_media_source_platform` [bad-argument-type] ERROR homeassistant/components/media_source/local_source.py:305:49-67: Argument `BoundMethod[Path, (self: Path, *, follow_symlinks: bool = True) -> bool]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/mediaroom/media_player.py:8:1-14:2: Could not find import of `pymediaroom` [missing-import] ERROR homeassistant/components/mediaroom/media_player.py:79:9-20: `known_hosts` may be uninitialized [unbound-name] ERROR homeassistant/components/mediaroom/media_player.py:85:12-44: `in` is not supported between `Unknown` and `None` [not-iterable] ERROR homeassistant/components/mediaroom/media_player.py:90:9-27: Object of class `NoneType` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/melcloud/__init__.py:105:25-68: Argument `set[tuple[str, Any | None]]` is not assignable to parameter `connections` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/melcloud/__init__.py:104:26-110:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (connections=set[tuple[str, Any | None]], identifiers=set[tuple[str, str]], manufacturer=Literal['Mitsubishi Electric'], model=Unknown | None, name=str) [no-matching-overload] ERROR homeassistant/components/melcloud/climate.py:84:38-55: Argument `Device` is not assignable to parameter `ata_device` with type `AtaDevice` in function `AtaDeviceClimate.__init__` [bad-argument-type] ERROR homeassistant/components/melcloud/climate.py:89:46-63: Argument `Device` is not assignable to parameter `atw_device` with type `AtwDevice` in function `AtwDeviceZoneClimate.__init__` [bad-argument-type] ERROR homeassistant/components/melcloud/climate.py:91:25-48: Object of class `Device` has no attribute `zones` [missing-attribute] @@ -15922,9 +15609,9 @@ ERROR homeassistant/components/melnor/time.py:61:5-23: Class member `MelnorZoneT ERROR homeassistant/components/melnor/time.py:61:5-23: Class member `MelnorZoneTime.entity_description` overrides parent class `TimeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/message_bird/notify.py:7:8-19: Could not find import of `messagebird` [missing-import] ERROR homeassistant/components/message_bird/notify.py:8:1-46: Could not find import of `messagebird.client` [missing-import] -ERROR homeassistant/components/met/config_flow.py:143:9-31: Class member `MetConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/met/coordinator.py:95:5-17: Class member `MetDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/met_eireann/coordinator.py:52:5-17: Class member `MetEireannUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] +ERROR homeassistant/components/met_eireann/weather.py:100:44-107:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Forecast'], entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str]], manufacturer=Literal['Met Éireann'], model=Literal['Forecast'], configuration_url=Literal['https://www.met.ie']) [no-matching-overload] ERROR homeassistant/components/meteo_france/__init__.py:47:49-49:10: Unpacked argument `tuple[Any, Any]` is not assignable to parameter `*args` with type `tuple[float, float, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/meteo_france/__init__.py:53:49-87: Unpacked argument `tuple[Any, Any]` is not assignable to parameter `*args` with type `tuple[float, float, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/meteo_france/config_flow.py:64:65-66:14: Unpacked argument `tuple[Any]` is not assignable to parameter `*args` with type `tuple[str, str | None, str | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] @@ -16056,9 +15743,6 @@ ERROR homeassistant/components/metoffice/sensor.py:167:9-13: Unexpected keyword ERROR homeassistant/components/metoffice/sensor.py:172:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `MetOfficeSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/metoffice/sensor.py:230:5-23: Class member `MetOfficeCurrentSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/metoffice/sensor.py:230:5-23: Class member `MetOfficeCurrentSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mfi/switch.py:107:34-38: `None` is not assignable to attribute `_target_state` with type `Never` [bad-assignment] -ERROR homeassistant/components/mfi/switch.py:112:30-34: `Literal[True]` is not assignable to attribute `_target_state` with type `None` [bad-assignment] -ERROR homeassistant/components/mfi/switch.py:117:30-35: `Literal[False]` is not assignable to attribute `_target_state` with type `None` [bad-assignment] ERROR homeassistant/components/microbees/__init__.py:64:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/microbees/binary_sensor.py:21:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/microbees/binary_sensor.py:25:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -16213,7 +15897,6 @@ ERROR homeassistant/components/miele/vacuum.py:119:13-28: Unexpected keyword arg ERROR homeassistant/components/miele/vacuum.py:163:5-23: Class member `MieleVacuum.entity_description` overrides parent class `MieleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/miele/vacuum.py:163:5-23: Class member `MieleVacuum.entity_description` overrides parent class `StateVacuumEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/miele/vacuum.py:164:5-29: Class member `MieleVacuum._attr_supported_features` overrides parent class `MieleEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mikrotik/config_flow.py:45:9-31: Class member `MikrotikFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/mikrotik/coordinator.py:251:5-17: Class member `MikrotikDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/mikrotik/coordinator.py:345:12-15: Returned type `type[Api]` is not assignable to declared return type `Api` [bad-return] ERROR homeassistant/components/mill/climate.py:98:5-29: Class member `MillHeater._attr_supported_features` overrides parent class `MillBaseEntity` in an inconsistent manner [bad-override] @@ -16231,7 +15914,7 @@ ERROR homeassistant/components/mill/climate.py:195:15-75: Object of class `Mill` ERROR homeassistant/components/mill/climate.py:203:19-96: Object of class `Mill` has no attribute `set_operation_mode_control_individually` [missing-attribute] ERROR homeassistant/components/mill/climate.py:206:19-79: Object of class `Mill` has no attribute `set_operation_mode_off` [missing-attribute] ERROR homeassistant/components/mill/coordinator.py:40:5-17: Class member `MillDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mill/entity.py:33:25-58: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/mill/entity.py:32:44-37:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=str | None, manufacturer=Literal['Mill'], model=str | None) [no-matching-overload] ERROR homeassistant/components/mill/entity.py:43:49-57: Cannot index into `dict[str, Any]` [bad-index] ERROR homeassistant/components/mill/number.py:39:5-23: Class member `MillNumber._attr_device_class` overrides parent class `MillBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mill/number.py:56:35-64: `None` is not subscriptable [unsupported-operation] @@ -16299,12 +15982,7 @@ ERROR homeassistant/components/minecraft_server/sensor.py:150:9-12: Unexpected k ERROR homeassistant/components/minecraft_server/sensor.py:151:9-24: Unexpected keyword argument `translation_key` in function `MinecraftServerSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/minecraft_server/sensor.py:183:5-23: Class member `MinecraftServerSensorEntity.entity_description` overrides parent class `MinecraftServerEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/minecraft_server/sensor.py:183:5-23: Class member `MinecraftServerSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/minio/__init__.py:245:36-255:10: `MinioEventThread` is not assignable to attribute `_minio_event_thread` with type `None` [bad-assignment] -ERROR homeassistant/components/minio/__init__.py:256:9-39: Object of class `NoneType` has no attribute `start` [missing-attribute] -ERROR homeassistant/components/minio/minio_helper.py:139:41-75: `MinioEventStreamIterator` is not assignable to attribute `_event_stream_it` with type `None` [bad-assignment] -ERROR homeassistant/components/minio/minio_helper.py:182:37-41: `None` is not assignable to attribute `_event_stream_it` with type `Never` [bad-assignment] ERROR homeassistant/components/mjpeg/config_flow.py:117:63-123:14: Unpacked argument `tuple[Any, Any | None, Any, Any]` is not assignable to parameter `*args` with type `tuple[str, str | None, str, bool, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/mjpeg/config_flow.py:140:9-31: Class member `MJPEGFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/mjpeg/config_flow.py:162:27-80: Argument `Any | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] ERROR homeassistant/components/moat/__init__.py:50:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/moat/sensor.py:35:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -16324,7 +16002,6 @@ ERROR homeassistant/components/mobile_app/device_tracker.py:85:16-30: Object of ERROR homeassistant/components/mobile_app/device_tracker.py:90:20-34: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/mobile_app/device_tracker.py:98:20-34: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/mobile_app/device_tracker.py:106:29-43: Object of class `NoneType` has no attribute `get` [missing-attribute] -ERROR homeassistant/components/mobile_app/device_tracker.py:129:32-133:10: `() -> None` is not assignable to attribute `_dispatch_unsub` with type `None` [bad-assignment] ERROR homeassistant/components/mobile_app/entity.py:100:28-46: Argument `MappingProxyType[str, Any]` is not assignable to parameter `registration` with type `dict[Unknown, Unknown]` in function `homeassistant.components.mobile_app.helpers.device_info` [bad-argument-type] ERROR homeassistant/components/mobile_app/notify.py:70:20-71: `-` is not supported between `None` and `datetime` [unsupported-operation] ERROR homeassistant/components/mobile_app/notify.py:128:23-30: `targets` may be uninitialized [unbound-name] @@ -16348,28 +16025,8 @@ ERROR homeassistant/components/modbus/cover.py:100:34-54: Argument `Any | None` ERROR homeassistant/components/modbus/light.py:67:14-41: Class member `ModbusLight._attr_min_color_temp_kelvin` overrides parent class `LightEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/modbus/light.py:68:14-41: Class member `ModbusLight._attr_max_color_temp_kelvin` overrides parent class `LightEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/modbus/modbus.py:179:16-46: Returned type `tuple[ModbusHub | Unknown, Any | None, Any]` is not assignable to declared return type `tuple[ModbusHub, int, int]` [bad-return] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `port` with type `str` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `framer` with type `FramerType` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `parity` with type `str` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `handle_local_echo` with type `bool` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `name` with type `str` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_packet` with type `((bool, bytes) -> bytes) | None` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_pdu` with type `((bool, ModbusPDU) -> ModbusPDU) | None` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_connect` with type `((bool) -> None) | None` in function `pymodbus.client.serial.AsyncModbusSerialClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `host` with type `str` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `framer` with type `FramerType` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `name` with type `str` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `source_address` with type `tuple[str, int] | None` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_packet` with type `((bool, bytes) -> bytes) | None` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_pdu` with type `((bool, ModbusPDU) -> ModbusPDU) | None` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_connect` with type `((bool) -> None) | None` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `host` with type `str` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `framer` with type `FramerType` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `name` with type `str` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `source_address` with type `tuple[str, int] | None` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_packet` with type `((bool, bytes) -> bytes) | None` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_pdu` with type `((bool, ModbusPDU) -> ModbusPDU) | None` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] -ERROR homeassistant/components/modbus/modbus.py:336:62-79: Unpacked keyword argument `int | Any` is not assignable to parameter `trace_connect` with type `((bool) -> None) | None` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [bad-argument-type] +ERROR homeassistant/components/modbus/modbus.py:336:61-80: Missing argument `host` in function `pymodbus.client.tcp.AsyncModbusTcpClient.__init__` [missing-argument] +ERROR homeassistant/components/modbus/modbus.py:336:61-80: Missing argument `host` in function `pymodbus.client.udp.AsyncModbusUdpClient.__init__` [missing-argument] ERROR homeassistant/components/modbus/sensor.py:88:14-32: Class member `ModbusRegisterSensor._attr_device_class` overrides parent class `RestoreSensor` in an inconsistent manner [bad-override] ERROR homeassistant/components/modbus/sensor.py:88:14-32: Class member `ModbusRegisterSensor._attr_device_class` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/modbus/sensor.py:186:14-32: Class member `SlaveSensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] @@ -16408,7 +16065,6 @@ ERROR homeassistant/components/monarch_money/sensor.py:159:5-23: Class member `M ERROR homeassistant/components/monarch_money/sensor.py:159:5-23: Class member `MonarchMoneyCashFlowSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/monarch_money/sensor.py:170:5-23: Class member `MonarchMoneySensor.entity_description` overrides parent class `MonarchMoneyAccountEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/monarch_money/sensor.py:170:5-23: Class member `MonarchMoneySensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/monoprice/config_flow.py:107:9-31: Class member `MonoPriceConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/monzo/coordinator.py:33:5-17: Class member `MonzoCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/monzo/sensor.py:34:9-12: Unexpected keyword argument `key` in function `MonzoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/monzo/sensor.py:35:9-24: Unexpected keyword argument `translation_key` in function `MonzoSensorEntityDescription.__init__` [unexpected-keyword] @@ -16418,7 +16074,6 @@ ERROR homeassistant/components/monzo/sensor.py:53:9-12: Unexpected keyword argum ERROR homeassistant/components/monzo/sensor.py:54:9-24: Unexpected keyword argument `translation_key` in function `MonzoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/monzo/sensor.py:97:5-23: Class member `MonzoSensor.entity_description` overrides parent class `MonzoBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/monzo/sensor.py:97:5-23: Class member `MonzoSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mopeka/config_flow.py:57:9-31: Class member `MopekaConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/mopeka/sensor.py:35:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mopeka/sensor.py:39:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mopeka/sensor.py:42:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -16441,7 +16096,6 @@ ERROR homeassistant/components/mopeka/sensor.py:131:7-34: Field `entity_descript `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/motion_blinds/button.py:57:52-84: Object of class `MotionGateway` has no attribute `Go_favorite_position` [missing-attribute] ERROR homeassistant/components/motion_blinds/button.py:77:52-85: Object of class `MotionGateway` has no attribute `Set_favorite_position` [missing-attribute] -ERROR homeassistant/components/motion_blinds/config_flow.py:81:9-31: Class member `MotionBlindsFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/motion_blinds/coordinator.py:29:5-17: Class member `DataUpdateCoordinatorMotionBlinds.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/motion_blinds/cover.py:181:14-32: Class member `MotionBaseDevice._attr_device_class` overrides parent class `MotionCoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/motion_blinds/cover.py:201:12-32: Object of class `MotionGateway` has no attribute `position` [missing-attribute] @@ -16509,9 +16163,7 @@ ERROR homeassistant/components/motion_blinds/entity.py:130:17-37: Object of clas ERROR homeassistant/components/motion_blinds/entity.py:135:17-34: Object of class `MotionGateway` has no attribute `angle` [missing-attribute] ERROR homeassistant/components/motion_blinds/entity.py:156:12-32: Object of class `MotionGateway` has no attribute `position` [missing-attribute] ERROR homeassistant/components/motion_blinds/entity.py:156:45-62: Object of class `MotionGateway` has no attribute `angle` [missing-attribute] -ERROR homeassistant/components/motion_blinds/gateway.py:53:32-55:10: `MotionGateway` is not assignable to attribute `_gateway_device` with type `None` [bad-assignment] ERROR homeassistant/components/motion_blinds/gateway.py:54:41-56: Argument `Unknown | None` is not assignable to parameter `multicast` with type `MotionMulticast` in function `motionblinds.motion_blinds.MotionGateway.__init__` [bad-argument-type] -ERROR homeassistant/components/motion_blinds/gateway.py:121:36-123:14: `MotionGateway` is not assignable to attribute `_gateway_device` with type `None` [bad-assignment] ERROR homeassistant/components/motion_blinds/gateway.py:122:45-60: Argument `AsyncMotionMulticast` is not assignable to parameter `multicast` with type `MotionMulticast` in function `motionblinds.motion_blinds.MotionGateway.__init__` [bad-argument-type] ERROR homeassistant/components/motion_blinds/sensor.py:55:5-23: Class member `MotionBatterySensor._attr_device_class` overrides parent class `MotionCoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/motion_blinds/sensor.py:68:16-41: Object of class `MotionGateway` has no attribute `battery_level` [missing-attribute] @@ -16560,7 +16212,6 @@ ERROR homeassistant/components/motionblinds_ble/sensor.py:145:7-20: Field `entit `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/motionblinds_ble/sensor.py:155:13-16: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/motionblinds_ble/sensor.py:159:13-28: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/motioneye/config_flow.py:182:9-31: Class member `MotionEyeConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/motioneye/media_source.py:56:5-9: Class member `MotionEyeMediaSource.name` overrides parent class `MediaSource` in an inconsistent manner [bad-override] ERROR homeassistant/components/motioneye/sensor.py:52:7-28: Field `entity_description` is declared `EntityDescription` in ancestor `class MotionEyeEntity: ... `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] @@ -16614,8 +16265,6 @@ ERROR homeassistant/components/mpd/media_player.py:228:17-38: Object of class `N ERROR homeassistant/components/mpd/media_player.py:229:21-42: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:245:19-40: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:253:16-37: Object of class `NoneType` has no attribute `get` [missing-attribute] -ERROR homeassistant/components/mpd/media_player.py:292:38-294:31: `str` is not assignable to attribute `_media_image_hash` with type `Never` [bad-assignment] -ERROR homeassistant/components/mpd/media_player.py:299:38-42: `None` is not assignable to attribute `_media_image_hash` with type `Never` [bad-assignment] ERROR homeassistant/components/mpd/media_player.py:308:35-56: Object of class `MPDClient` has no attribute `commands` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:318:38-62: Object of class `MPDClient` has no attribute `readpicture` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:330:38-59: Object of class `MPDClient` has no attribute `albumart` [missing-attribute] @@ -16646,13 +16295,9 @@ ERROR homeassistant/components/mpd/media_player.py:515:19-36: Object of class `M ERROR homeassistant/components/mpd/media_player.py:520:19-36: Object of class `MPDClient` has no attribute `play` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:526:19-37: Object of class `MPDClient` has no attribute `clear` [missing-attribute] ERROR homeassistant/components/mpd/media_player.py:531:19-39: Object of class `MPDClient` has no attribute `seekcur` [missing-attribute] -ERROR homeassistant/components/mqtt/alarm_control_panel.py:134:9-22: Class member `MqttAlarm.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/binary_sensor.py:140:9-22: Class member `MqttBinarySensor.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/binary_sensor.py:152:14-32: Class member `MqttBinarySensor._attr_device_class` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/binary_sensor.py:152:14-32: Class member `MqttBinarySensor._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/button.py:71:9-22: Class member `MqttButton.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/button.py:80:14-32: Class member `MqttButton._attr_device_class` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/camera.py:97:9-22: Class member `MqttCamera.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/client.py:356:23-32: `client_id` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/client.py:396:12-23: `certificate` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/client.py:398:17-28: `certificate` may be uninitialized [unbound-name] @@ -16665,8 +16310,6 @@ ERROR homeassistant/components/mqtt/config_flow.py:1170:9-21: `device_class` may ERROR homeassistant/components/mqtt/config_flow.py:1179:9-21: `device_class` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/config_flow.py:1180:13-25: `device_class` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/config_flow.py:1181:59-71: `device_class` may be uninitialized [unbound-name] -ERROR homeassistant/components/mqtt/config_flow.py:3843:60-84: Expected 0 positional arguments, got 1 in function `homeassistant.data_entry_flow.SectionConfig.__init__` [bad-argument-count] -ERROR homeassistant/components/mqtt/config_flow.py:3976:9-31: Class member `FlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/config_flow.py:4232:13-30: `reconfigure_entry` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/config_flow.py:4232:39-53: `is_reconfigure` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/config_flow.py:4237:16-30: `is_reconfigure` may be uninitialized [unbound-name] @@ -16684,7 +16327,7 @@ ERROR homeassistant/components/mqtt/cover.py:331:14-32: Class member `MqttCover. ERROR homeassistant/components/mqtt/cover.py:348:14-38: Class member `MqttCover._attr_supported_features` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/device_tracker.py:155:9-47: Class member `MqttDeviceTracker._process_update_extra_state_attributes` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/device_tracker.py:174:40-49: `longitude` may be uninitialized [unbound-name] -ERROR homeassistant/components/mqtt/diagnostics.py:59:35-78: Cannot set item in `dict[str, bool | dict[str, dict[str, Any] | dict[Unknown, Unknown]]]` [unsupported-operation] +ERROR homeassistant/components/mqtt/diagnostics.py:59:35-78: `dict[str, list[Any]]` is not assignable to TypedDict key `mqtt_debug_info` with type `bool | dict[str, dict[str, Any] | dict[Unknown, Unknown]]` [bad-typed-dict-key] ERROR homeassistant/components/mqtt/diagnostics.py:62:20-70:10: No matching overload found for function `typing.MutableMapping.update` called with arguments: (devices=list[dict[str, Any]], mqtt_debug_info=dict[str, list[Any]]) [no-matching-overload] ERROR homeassistant/components/mqtt/discovery.py:447:17-34: `discovery_payload` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/discovery.py:448:17-34: `discovery_payload` may be uninitialized [unbound-name] @@ -16704,15 +16347,12 @@ ERROR homeassistant/components/mqtt/light/schema_basic.py:390:14-38: Class membe ERROR homeassistant/components/mqtt/light/schema_basic.py:390:14-38: Class member `MqttLight._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/light/schema_template.py:197:14-38: Class member `MqttLightTemplate._attr_supported_features` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/light/schema_template.py:197:14-38: Class member `MqttLightTemplate._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/lock.py:144:9-22: Class member `MqttLock.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/lock.py:155:28-38: `optimistic` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/lock.py:156:41-51: `optimistic` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/lock.py:172:14-38: Class member `MqttLock._attr_supported_features` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/models.py:140:5-13: Class member `MqttCommandTemplateException._message` overrides parent class `ServiceValidationError` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/models.py:228:5-13: Class member `MqttValueTemplateException._message` overrides parent class `TemplateError` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/notify.py:63:9-22: Class member `MqttNotify.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/number.py:161:14-32: Class member `MqttNumber._attr_device_class` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/mqtt/scene.py:70:9-22: Class member `MqttScene.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/sensor.py:133:41-60: `unit_of_measurement` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/sensor.py:141:9-28: `unit_of_measurement` may be uninitialized [unbound-name] ERROR homeassistant/components/mqtt/sensor.py:141:30-49: `unit_of_measurement` may be uninitialized [unbound-name] @@ -16721,7 +16361,6 @@ ERROR homeassistant/components/mqtt/sensor.py:227:39-55: `last_sensor_data` may ERROR homeassistant/components/mqtt/sensor.py:257:14-32: Class member `MqttSensor._attr_device_class` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/siren.py:175:14-38: Class member `MqttSiren._attr_supported_features` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/subscription.py:165:10-39: Function declared to return `dict[str, EntitySubscription]` but is missing an explicit `return` [bad-return] -ERROR homeassistant/components/mqtt/switch.py:99:9-22: Class member `MqttSwitch.config_schema` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/switch.py:105:14-32: Class member `MqttSwitch._attr_device_class` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/switch.py:105:14-32: Class member `MqttSwitch._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/tag.py:90:9-13: `tags` may be uninitialized [unbound-name] @@ -16735,7 +16374,6 @@ ERROR homeassistant/components/mqtt/valve.py:202:14-32: Class member `MqttValve. ERROR homeassistant/components/mqtt/valve.py:216:14-38: Class member `MqttValve._attr_supported_features` overrides parent class `MqttEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/water_heater.py:261:14-38: Class member `MqttWaterHeater._attr_supported_features` overrides parent class `MqttTemperatureControlEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mqtt/water_heater.py:304:15-44: Method `async_set_temperature` inherited from class `MqttTemperatureControlEntity` has no implementation and cannot be accessed via `super()` [missing-attribute] -ERROR homeassistant/components/mqtt_room/sensor.py:138:29-45: `datetime` is not assignable to attribute `_updated` with type `None` [bad-assignment] ERROR homeassistant/components/msteams/notify.py:7:8-17: Could not find import of `pymsteams` [missing-import] ERROR homeassistant/components/mullvad/binary_sensor.py:21:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mullvad/binary_sensor.py:22:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -16771,8 +16409,6 @@ ERROR homeassistant/components/mysensors/binary_sensor.py:64:9-12: Unexpected ke ERROR homeassistant/components/mysensors/binary_sensor.py:100:5-23: Class member `MySensorsBinarySensor.entity_description` overrides parent class `MySensorsChildEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mysensors/binary_sensor.py:100:5-23: Class member `MySensorsBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/mysensors/climate.py:168:29-39: `value_type` may be uninitialized [unbound-name] -ERROR homeassistant/components/mysensors/gateway.py:107:32-44: `(_: BaseAsyncGateway) -> None` is not assignable to attribute `on_conn_made` with type `None` [bad-assignment] -ERROR homeassistant/components/mysensors/gateway.py:285:28-45: `(_: BaseAsyncGateway) -> None` is not assignable to attribute `on_conn_made` with type `None` [bad-assignment] ERROR homeassistant/components/mysensors/gateway.py:327:20-37: Object of class `NoneType` has no attribute `const` [missing-attribute] ERROR homeassistant/components/mysensors/handler.py:40:16-33: Object of class `NoneType` has no attribute `const` [missing-attribute] ERROR homeassistant/components/mysensors/helpers.py:167:26-37: Argument `Unknown | None` is not assignable to parameter `gateway` with type `BaseAsyncGateway` in function `validate_node` [bad-argument-type] @@ -16831,7 +16467,7 @@ ERROR homeassistant/components/mystrom/sensor.py:56:9-12: Unexpected keyword arg ERROR homeassistant/components/mystrom/sensor.py:57:9-24: Unexpected keyword argument `translation_key` in function `MyStromSwitchSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mystrom/sensor.py:65:9-12: Unexpected keyword argument `key` in function `MyStromSwitchSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mystrom/sensor.py:80:29-54: `MyStromBulb | MyStromSwitch` is not assignable to `MyStromSwitch` [bad-assignment] -ERROR homeassistant/components/mystrom/sensor.py:108:25-47: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/mystrom/sensor.py:107:44-112:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=str, manufacturer=Literal['myStrom'], sw_version=str | None) [no-matching-overload] ERROR homeassistant/components/mystrom/sensor.py:118:5-23: Class member `MyStromSwitchSensor.entity_description` overrides parent class `MyStromSensorBase` in an inconsistent manner [bad-override] ERROR homeassistant/components/mystrom/sensor.py:141:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/mystrom/sensor.py:143:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -16991,7 +16627,6 @@ ERROR homeassistant/components/nasweb/coordinator.py:176:13-22: Argument `HassJo ERROR homeassistant/components/nasweb/sensor.py:126:5-18: Class member `InputStateSensor._attr_options` overrides parent class `BaseSensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/nasweb/sensor.py:143:14-32: Class member `InputStateSensor._attr_native_value` overrides parent class `BaseSensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/nasweb/switch.py:115:53-71: Cannot index into `dict[str | None, bool | None]` [bad-index] -ERROR homeassistant/components/neato/__init__.py:64:43-60: Argument `BoundMethod[NeatoHub, (...) -> Unknown]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/neato/api.py:31:9-23: Class member `ConfigEntryAuth.refresh_tokens` overrides parent class `OAuthSession` in an inconsistent manner [bad-override] ERROR homeassistant/components/neato/camera.py:94:26-34: `map_data` may be uninitialized [unbound-name] ERROR homeassistant/components/neato/camera.py:114:30-38: `map_data` may be uninitialized [unbound-name] @@ -17058,13 +16693,12 @@ ERROR homeassistant/components/nederlandse_spoorwegen/sensor.py:271:5-23: Class ERROR homeassistant/components/ness_alarm/alarm_control_panel.py:74:35-39: Argument `str | None` is not assignable to parameter `code` with type `str` in function `nessclient.client.Client.disarm` [bad-argument-type] ERROR homeassistant/components/ness_alarm/alarm_control_panel.py:86:34-38: Argument `str | None` is not assignable to parameter `code` with type `str` in function `nessclient.client.Client.panic` [bad-argument-type] ERROR homeassistant/components/ness_alarm/alarm_control_panel.py:101:62-103:14: No matching overload found for function `dict.get` called with arguments: (ArmingMode | None, Literal[AlarmControlPanelState.ARMED_AWAY]) [no-matching-overload] -ERROR homeassistant/components/nest/__init__.py:176:41-51: Cannot set item in `dict[str, datetime | str]` [unsupported-operation] -ERROR homeassistant/components/nest/__init__.py:178:36-53: Cannot set item in `dict[str, datetime | str]` [unsupported-operation] +ERROR homeassistant/components/nest/__init__.py:176:41-51: `dict[str, str]` is not assignable to TypedDict key `attachment` with type `datetime | str` [bad-typed-dict-key] +ERROR homeassistant/components/nest/__init__.py:178:36-53: `list[str]` is not assignable to TypedDict key `zones` with type `datetime | str` [bad-typed-dict-key] ERROR homeassistant/components/nest/__init__.py:306:49-66: `subscription_name` may be uninitialized [unbound-name] ERROR homeassistant/components/nest/__init__.py:308:48-65: `subscription_name` may be uninitialized [unbound-name] ERROR homeassistant/components/nest/__init__.py:315:13-30: `subscription_name` may be uninitialized [unbound-name] ERROR homeassistant/components/nest/__init__.py:427:57-69: `content_type` may be uninitialized [unbound-name] -ERROR homeassistant/components/nest/api.py:70:24-76: `datetime` is not assignable to attribute `expiry` with type `None` [bad-assignment] ERROR homeassistant/components/nest/api.py:132:68-85: `subscription_name` may be uninitialized [unbound-name] ERROR homeassistant/components/nest/camera.py:315:27-45: Object of class `NoneType` has no attribute `stop_stream` [missing-attribute] ERROR homeassistant/components/nest/event.py:42:9-12: Unexpected keyword argument `key` in function `NestEventEntityDescription.__init__` [unexpected-keyword] @@ -17159,20 +16793,14 @@ ERROR homeassistant/components/netatmo/sensor.py:683:5-23: Class member `Netatmo ERROR homeassistant/components/netatmo/switch.py:46:5-11: Class member `NetatmoSwitch.device` overrides parent class `NetatmoModuleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/netdata/sensor.py:7:1-28: Could not find import of `netdata` [missing-import] ERROR homeassistant/components/netdata/sensor.py:8:1-44: Could not find import of `netdata.exceptions` [missing-import] -ERROR homeassistant/components/netdata/sensor.py:214:31-41: `Literal['critical']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/netdata/sensor.py:216:23-76: `Literal['ok', 'warning']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/netgear/button.py:32:9-12: Unexpected keyword argument `key` in function `NetgearButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/netgear/button.py:34:9-24: Unexpected keyword argument `entity_category` in function `NetgearButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/netgear/button.py:57:5-23: Class member `NetgearRouterButtonEntity.entity_description` overrides parent class `NetgearRouterCoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/netgear/button.py:57:5-23: Class member `NetgearRouterButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/netgear/config_flow.py:109:9-31: Class member `NetgearFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/netgear/config_flow.py:133:38-55: Argument `dict[str, bool | int | str]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.config_entries.ConfigFlow.async_show_form` [bad-argument-type] ERROR homeassistant/components/netgear/config_flow.py:147:36-44: `hostname` may be uninitialized [unbound-name] ERROR homeassistant/components/netgear/config_flow.py:200:57-202:14: Unpacked argument `tuple[Any, Any, Any, bool | int | str, bool | int | str]` is not assignable to parameter `*args` with type `tuple[str, str | None, str | None, int | None, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/netgear/router.py:84:29-33: `None` is not assignable to attribute `api` with type `Netgear` [bad-assignment] -ERROR homeassistant/components/netgear/router.py:115:30-83: `bool | Unknown` is not assignable to attribute `track_devices` with type `Never` [bad-assignment] -ERROR homeassistant/components/netgear/router.py:124:39-40: `Literal[2]` is not assignable to attribute `method_version` with type `Never` [bad-assignment] -ERROR homeassistant/components/netgear/router.py:135:39-40: `Literal[1]` is not assignable to attribute `method_version` with type `Never` [bad-assignment] ERROR homeassistant/components/netgear/sensor.py:47:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/netgear/sensor.py:48:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/netgear/sensor.py:49:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -17368,7 +16996,6 @@ ERROR homeassistant/components/netgear_lte/services.py:73:15-20: `modem` is unin ERROR homeassistant/components/netio/switch.py:10:1-26: Could not find import of `pynetio` [missing-import] ERROR homeassistant/components/network/__init__.py:90:12-65: Returned type `str | Unknown | None` is not assignable to declared return type `str` [bad-return] ERROR homeassistant/components/neurio_energy/sensor.py:8:8-14: Could not find import of `neurio` [missing-import] -ERROR homeassistant/components/neurio_energy/sensor.py:135:29-42: `int` is not assignable to attribute `_daily_usage` with type `None` [bad-assignment] ERROR homeassistant/components/neurio_energy/sensor.py:156:41-68: `Literal[UnitOfEnergy.KILO_WATT_HOUR]` is not assignable to attribute `_unit_of_measurement` with type `UnitOfPower` [bad-assignment] ERROR homeassistant/components/nexia/climate.py:170:45-57: Argument `int | str` is not assignable to parameter `unique_id` with type `str` in function `homeassistant.components.nexia.entity.NexiaThermostatZoneEntity.__init__` [bad-argument-type] ERROR homeassistant/components/nexia/climate.py:181:14-38: Class member `NexiaZone._attr_supported_features` overrides parent class `NexiaThermostatZoneEntity` in an inconsistent manner [bad-override] @@ -17378,7 +17005,7 @@ ERROR homeassistant/components/nexia/config_flow.py:103:52-56: `info` may be uni ERROR homeassistant/components/nexia/config_flow.py:105:54-58: `info` may be uninitialized [unbound-name] ERROR homeassistant/components/nexia/coordinator.py:23:5-17: Class member `NexiaDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/nexia/coordinator.py:44:16-46: Returned type `dict[str, Any] | None` is not assignable to declared return type `dict[str, Any]` [bad-return] -ERROR homeassistant/components/nexia/entity.py:59:25-50: Argument `set[tuple[str, int | str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/nexia/entity.py:57:44-64:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (configuration_url=str, identifiers=set[tuple[str, int | str]], manufacturer=Literal['Trane'], model=str | None, name=str, sw_version=str | None) [no-matching-overload] ERROR homeassistant/components/nexia/entity.py:110:9-31: `dict[str, object]` is not assignable to attribute `_attr_device_info` with type `DeviceInfo | None` [bad-assignment] ERROR homeassistant/components/nexia/scene.py:45:39-63: Argument `int` is not assignable to parameter `unique_id` with type `str` in function `homeassistant.components.nexia.entity.NexiaEntity.__init__` [bad-argument-type] ERROR homeassistant/components/nexia/sensor.py:211:14-32: Class member `NexiaThermostatSensor._attr_device_class` overrides parent class `NexiaThermostatEntity` in an inconsistent manner [bad-override] @@ -18076,7 +17703,6 @@ ERROR homeassistant/components/nextdns/switch.py:548:5-23: Class member `NextDns ERROR homeassistant/components/nibe_heatpump/__init__.py:121:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/nibe_heatpump/climate.py:56:27-79: Object of class `tuple` has no attribute `items` [missing-attribute] ERROR homeassistant/components/nibe_heatpump/climate.py:69:5-29: Class member `NibeClimateEntity._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/nibe_heatpump/climate.py:126:43-73: `Coil` is not assignable to attribute `_coil_active_accessory` with type `None` [bad-assignment] ERROR homeassistant/components/nibe_heatpump/climate.py:239:74-85: `temperature` may be uninitialized [unbound-name] ERROR homeassistant/components/nibe_heatpump/coordinator.py:76:5-17: Class member `CoilCoordinator.config_entry` overrides parent class `ContextCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/nibe_heatpump/sensor.py:37:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -18145,7 +17771,6 @@ ERROR homeassistant/components/niko_home_control/light.py:67:37-42: `int | str` ERROR homeassistant/components/niko_home_control/scene.py:36:15-36: Object of class `NHCAction` has no attribute `activate` [missing-attribute] ERROR homeassistant/components/nilu/air_quality.py:8:1-23:2: Could not find import of `niluclient` [missing-import] ERROR homeassistant/components/nina/binary_sensor.py:61:5-23: Class member `NINAMessage._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/nina/config_flow.py:179:9-31: Class member `NinaConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/nina/coordinator.py:53:5-17: Class member `NINADataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/nintendo_parental_controls/coordinator.py:30:5-17: Class member `NintendoUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/nintendo_parental_controls/number.py:41:9-12: Unexpected keyword argument `key` in function `NintendoParentalControlsNumberEntityDescription.__init__` [unexpected-keyword] @@ -18174,11 +17799,8 @@ ERROR homeassistant/components/nissan_leaf/binary_sensor.py:44:5-23: Class membe ERROR homeassistant/components/nissan_leaf/binary_sensor.py:70:5-23: Class member `LeafChargingSensor._attr_device_class` overrides parent class `LeafEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/nissan_leaf/sensor.py:52:5-23: Class member `LeafBatterySensor._attr_device_class` overrides parent class `LeafEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/nmap_tracker/__init__.py:131:24-35: `new_options` may be uninitialized [unbound-name] -ERROR homeassistant/components/nmap_tracker/__init__.py:195:31-197:10: `timedelta` is not assignable to attribute `_scan_interval` with type `None` [bad-assignment] -ERROR homeassistant/components/nmap_tracker/__init__.py:202:30-204:10: `timedelta` is not assignable to attribute `home_interval` with type `None` [bad-assignment] -ERROR homeassistant/components/nmap_tracker/__init__.py:209:27-41: `Lock` is not assignable to attribute `_scan_lock` with type `None` [bad-assignment] ERROR homeassistant/components/nmap_tracker/__init__.py:220:37-225:10: `dict[str, str | None]` is not assignable to attribute `_known_mac_addresses` with type `dict[str, str]` [bad-assignment] -ERROR homeassistant/components/nmap_tracker/__init__.py:249:17-36: Argument `None` is not assignable to parameter `interval` with type `timedelta` in function `homeassistant.helpers.event.async_track_time_interval` [bad-argument-type] +ERROR homeassistant/components/nmap_tracker/__init__.py:249:17-36: Argument `Unknown | None` is not assignable to parameter `interval` with type `timedelta` in function `homeassistant.helpers.event.async_track_time_interval` [bad-argument-type] ERROR homeassistant/components/nmap_tracker/__init__.py:265:33-89: `+` is not supported between `None` and `list[str]` [unsupported-operation] ERROR homeassistant/components/nmap_tracker/__init__.py:272:13-63: `+=` is not supported between `None` and `str` [unsupported-operation] ERROR homeassistant/components/nmap_tracker/__init__.py:274:12-37: `not in` is not supported between `Literal['--reason']` and `None` [not-iterable] @@ -18192,22 +17814,20 @@ ERROR homeassistant/components/nmap_tracker/__init__.py:312:17-21: Argument `Non ERROR homeassistant/components/nmap_tracker/__init__.py:314:17-21: Argument `None` is not assignable to parameter `ipv4` with type `str` in function `NmapDevice.__init__` [bad-argument-type] ERROR homeassistant/components/nmap_tracker/__init__.py:315:17-47: Argument `str | None` is not assignable to parameter `manufacturer` with type `str` in function `NmapDevice.__init__` [bad-argument-type] ERROR homeassistant/components/nmap_tracker/__init__.py:318:17-18: Argument `Literal[1]` is not assignable to parameter `first_offline` with type `datetime | None` in function `NmapDevice.__init__` [bad-argument-type] -ERROR homeassistant/components/nmap_tracker/__init__.py:326:29-42: `PortScanner` is not assignable to attribute `_scanner` with type `None` [bad-assignment] -ERROR homeassistant/components/nmap_tracker/__init__.py:330:26-44: Object of class `NoneType` has no attribute `scan` [missing-attribute] -ERROR homeassistant/components/nmap_tracker/__init__.py:331:35-48: No matching overload found for function `str.join` called with arguments: (None) [no-matching-overload] +ERROR homeassistant/components/nmap_tracker/__init__.py:331:35-48: No matching overload found for function `str.join` called with arguments: (Unknown | None) [no-matching-overload] ERROR homeassistant/components/nmap_tracker/__init__.py:348:16-22: `result` may be uninitialized [unbound-name] ERROR homeassistant/components/nmap_tracker/__init__.py:418:16-50: `in` is not supported between `str` and `None` [not-iterable] ERROR homeassistant/components/nmap_tracker/__init__.py:430:50-56: Argument `str | Unknown | None` is not assignable to parameter `vendor` with type `str` in function `human_readable_name` [bad-argument-type] ERROR homeassistant/components/nmap_tracker/__init__.py:432:54-60: Argument `str | Unknown | None` is not assignable to parameter `manufacturer` with type `str` in function `NmapDevice.__init__` [bad-argument-type] -ERROR homeassistant/components/nmap_tracker/config_flow.py:262:9-31: Class member `NmapTrackerConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/nmbs/sensor.py:261:34-38: Cannot set item in `dict[str, Never]` [unsupported-operation] -ERROR homeassistant/components/nmbs/sensor.py:262:42-46: Cannot set item in `dict[str, Never]` [unsupported-operation] -ERROR homeassistant/components/nmbs/sensor.py:264:34-59: Cannot set item in `dict[str, Never]` [unsupported-operation] -ERROR homeassistant/components/nmbs/sensor.py:281:26-44: Cannot set item in `dict[str, Never]` [unsupported-operation] +ERROR homeassistant/components/nmbs/sensor.py:259:29-59: `bool` is not assignable to TypedDict key `canceled` with type `str` [bad-typed-dict-key] +ERROR homeassistant/components/nmbs/sensor.py:261:34-38: `None` is not assignable to TypedDict key `departure` with type `str` [bad-typed-dict-key] +ERROR homeassistant/components/nmbs/sensor.py:262:42-46: `None` is not assignable to TypedDict key `departure_minutes` with type `str` [bad-typed-dict-key] +ERROR homeassistant/components/nmbs/sensor.py:268:36-63: `float` is not assignable to TypedDict key `latitude` with type `str` [bad-typed-dict-key] +ERROR homeassistant/components/nmbs/sensor.py:269:37-64: `float` is not assignable to TypedDict key `longitude` with type `str` [bad-typed-dict-key] +ERROR homeassistant/components/nmbs/sensor.py:272:19-38: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/noaa_tides/sensor.py:9:8-27: Could not find import of `noaa_coops` [missing-import] ERROR homeassistant/components/nobo_hub/__init__.py:58:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/nobo_hub/config_flow.py:169:38-65: Object of class `NoneType` has no attribute `items` [missing-attribute] -ERROR homeassistant/components/nobo_hub/config_flow.py:174:9-31: Class member `NoboHubConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/nordpool/coordinator.py:36:5-17: Class member `NordPoolDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/nordpool/sensor.py:159:9-12: Unexpected keyword argument `key` in function `NordpoolDefaultSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/nordpool/sensor.py:160:9-24: Unexpected keyword argument `translation_key` in function `NordpoolDefaultSensorEntityDescription.__init__` [unexpected-keyword] @@ -18306,15 +17926,6 @@ ERROR homeassistant/components/notion/sensor.py:69:7-19: Field `entity_descripti ERROR homeassistant/components/nsw_fuel_station/__init__.py:64:20-66:14: Argument `dict[tuple[int | None, str], float]` is not assignable to parameter `prices` with type `dict[tuple[int, str], float]` in function `StationPriceData.__init__` [bad-argument-type] ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:249:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:250:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:252:26-45: `str` is not assignable to attribute `_category` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:253:34-61: `datetime` is not assignable to attribute `_publication_date` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:254:26-45: `str` is not assignable to attribute `_location` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:255:30-53: `str` is not assignable to attribute `_council_area` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:256:24-41: `str` is not assignable to attribute `_status` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:257:22-37: `str` is not assignable to attribute `_type` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:258:22-37: `bool` is not assignable to attribute `_fire` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:259:22-37: `str` is not assignable to attribute `_size` with type `None` [bad-assignment] -ERROR homeassistant/components/nsw_rural_fire_service_feed/geo_location.py:260:36-65: `str` is not assignable to attribute `_responsible_agency` with type `None` [bad-assignment] ERROR homeassistant/components/ntfy/config_flow.py:330:24-29: `token` may be uninitialized [unbound-name] ERROR homeassistant/components/ntfy/config_flow.py:355:51-56: `token` may be uninitialized [unbound-name] ERROR homeassistant/components/ntfy/config_flow.py:367:37-42: `token` may be uninitialized [unbound-name] @@ -18387,8 +17998,7 @@ ERROR homeassistant/components/ntfy/sensor.py:225:9-40: Unexpected keyword argum ERROR homeassistant/components/ntfy/sensor.py:246:5-23: Class member `NtfySensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ntfy/sensor.py:246:5-23: Class member `NtfySensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/nuheat/climate.py:76:5-29: Class member `NuHeatThermostat._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/nuheat/climate.py:159:52-85: No matching overload found for function `dict.get` called with arguments: (None, Literal['Run Schedule']) [no-matching-overload] -ERROR homeassistant/components/nuheat/climate.py:210:31-51: `int` is not assignable to attribute `_schedule_mode` with type `None` [bad-assignment] +ERROR homeassistant/components/nuheat/climate.py:159:52-85: No matching overload found for function `dict.get` called with arguments: (Unknown | None, Literal['Run Schedule']) [no-matching-overload] ERROR homeassistant/components/nuheat/config_flow.py:87:48-52: `info` may be uninitialized [unbound-name] ERROR homeassistant/components/nuheat/config_flow.py:89:54-58: `info` may be uninitialized [unbound-name] ERROR homeassistant/components/nuki/binary_sensor.py:50:5-23: Class member `NukiDoorsensorEntity._attr_device_class` overrides parent class `NukiEntity` in an inconsistent manner [bad-override] @@ -19091,6 +18701,7 @@ ERROR homeassistant/components/ohme/time.py:33:9-24: Unexpected keyword argument ERROR homeassistant/components/ohme/time.py:63:5-23: Class member `OhmeTime.entity_description` overrides parent class `OhmeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ohme/time.py:63:5-23: Class member `OhmeTime.entity_description` overrides parent class `TimeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ollama/ai_task.py:60:16-44: Object of class `ToolResultContent` has no attribute `content` [missing-attribute] +ERROR homeassistant/components/ollama/entity.py:103:35-54: Argument `dict[str, Any]` is not assignable to parameter `arguments` with type `Mapping[LaxStr, Any]` in function `ollama._types.Function.__init__` [bad-argument-type] ERROR homeassistant/components/ombi/__init__.py:5:8-14: Could not find import of `pyombi` [missing-import] ERROR homeassistant/components/ombi/sensor.py:8:1-29: Could not find import of `pyombi` [missing-import] ERROR homeassistant/components/ombi/sensor.py:24:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -19111,10 +18722,9 @@ ERROR homeassistant/components/ombi/sensor.py:46:9-13: Unexpected keyword argume ERROR homeassistant/components/ombi/sensor.py:49:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ombi/sensor.py:50:9-13: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ombi/sensor.py:51:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/omnilogic/config_flow.py:33:9-31: Class member `OmniLogicConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/omnilogic/coordinator.py:21:5-17: Class member `OmniLogicUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/omnilogic/sensor.py:93:14-32: Class member `OmnilogicSensor._attr_device_class` overrides parent class `OmniLogicEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/omnilogic/sensor.py:134:13-136:14: Cannot index into `dict[str, str]` [bad-index] +ERROR homeassistant/components/omnilogic/sensor.py:134:13-136:14: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/omnilogic/sensor.py:158:16-21: `state` may be uninitialized [unbound-name] ERROR homeassistant/components/onboarding/__init__.py:106:27-31: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/onboarding/__init__.py:108:25-29: `data` may be uninitialized [unbound-name] @@ -19143,7 +18753,6 @@ ERROR homeassistant/components/ondilo_ico/sensor.py:138:14-32: Class member `Ond ERROR homeassistant/components/onedrive/backup.py:136:15-36: Class member `OneDriveBackupAgent.async_download_backup` overrides parent class `BackupAgent` in an inconsistent manner [bad-override] ERROR homeassistant/components/onedrive/config_flow.py:146:41-47: `folder` may be uninitialized [unbound-name] ERROR homeassistant/components/onedrive/config_flow.py:191:71-86: `new_folder_name` may be uninitialized [unbound-name] -ERROR homeassistant/components/onedrive/config_flow.py:229:9-31: Class member `OneDriveConfigFlow.async_get_options_flow` overrides parent class `AbstractOAuth2FlowHandler` in an inconsistent manner [bad-override] ERROR homeassistant/components/onedrive/coordinator.py:44:5-17: Class member `OneDriveUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/onedrive/sensor.py:36:9-12: Unexpected keyword argument `key` in function `OneDriveSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/onedrive/sensor.py:42:9-24: Unexpected keyword argument `entity_category` in function `OneDriveSensorEntityDescription.__init__` [unexpected-keyword] @@ -19178,7 +18787,6 @@ ERROR homeassistant/components/onewire/binary_sensor.py:79:13-28: Unexpected key ERROR homeassistant/components/onewire/binary_sensor.py:80:13-37: Unexpected keyword argument `translation_placeholders` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/onewire/binary_sensor.py:150:7-32: Field `entity_description` is declared `EntityDescription` in ancestor `class OneWireEntity: ... `, which is not assignable to the type `BinarySensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/onewire/config_flow.py:160:9-31: Class member `OneWireFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/onewire/onewirehub.py:47:42-54: Expected a type form, got instance of `Literal['OneWireHub']` [not-a-type] ERROR homeassistant/components/onewire/select.py:31:13-16: Unexpected keyword argument `key` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/onewire/select.py:32:13-28: Unexpected keyword argument `entity_category` in function `homeassistant.components.select.SelectEntityDescription.__init__` [unexpected-keyword] @@ -19296,7 +18904,6 @@ ERROR homeassistant/components/onewire/switch.py:127:17-32: Unexpected keyword a ERROR homeassistant/components/onewire/switch.py:128:17-41: Unexpected keyword argument `translation_placeholders` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/onewire/switch.py:203:7-26: Field `entity_description` is declared `EntityDescription` in ancestor `class OneWireEntity: ... `, which is not assignable to the type `SwitchEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/onkyo/config_flow.py:339:9-31: Class member `OnkyoConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/onkyo/media_player.py:215:14-37: Expected a callable, got `Literal[CodeBase.get_from_kind_zone]` [not-callable] ERROR homeassistant/components/onkyo/media_player.py:357:46-63: No matching overload found for function `min` called with arguments: (Literal[1], float) [no-matching-overload] ERROR homeassistant/components/onvif/binary_sensor.py:75:5-20: Class member `ONVIFBinarySensor._attr_unique_id` overrides parent class `ONVIFBaseEntity` in an inconsistent manner [bad-override] @@ -19307,7 +18914,6 @@ ERROR homeassistant/components/onvif/binary_sensor.py:87:18-36: Class member `ON ERROR homeassistant/components/onvif/button.py:27:5-23: Class member `RebootButton._attr_device_class` overrides parent class `ONVIFBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/onvif/camera.py:98:5-29: Class member `ONVIFCameraEntity._attr_supported_features` overrides parent class `ONVIFBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/onvif/camera.py:182:17-30: Argument `asyncio.streams.StreamReader` is not assignable to parameter `stream` with type `aiohttp.streams.StreamReader` in function `homeassistant.helpers.aiohttp_client.async_aiohttp_proxy_stream` [bad-argument-type] -ERROR homeassistant/components/onvif/config_flow.py:115:9-31: Class member `OnvifFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/onvif/device.py:189:20-43: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/onvif/device.py:480:15-40: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/onvif/device.py:508:44-52: No matching overload found for function `dict.get` called with arguments: (Unknown | None, Literal[0]) [no-matching-overload] @@ -19335,6 +18941,7 @@ ERROR homeassistant/components/openai_conversation/__init__.py:181:63-77: No mat ERROR homeassistant/components/openai_conversation/__init__.py:246:43-88: Argument `BoundMethod[AsyncModels, (self: AsyncModels, *, extra_headers: Mapping[str, Omit | str] | None = None, extra_query: Mapping[str, object] | None = None, extra_body: object | None = None, timeout: NotGiven | Timeout | float | None = ...) -> AsyncPaginator[Model, AsyncPage[Model]]]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/openai_conversation/ai_task.py:82:16-44: Object of class `ToolResultContent` has no attribute `content` [missing-attribute] ERROR homeassistant/components/openai_conversation/config_flow.py:101:39-84: Argument `BoundMethod[AsyncModels, (self: AsyncModels, *, extra_headers: Mapping[str, Omit | str] | None = None, extra_query: Mapping[str, object] | None = None, extra_body: object | None = None, timeout: NotGiven | Timeout | float | None = ...) -> AsyncPaginator[Model, AsyncPage[Model]]]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] +ERROR homeassistant/components/openai_conversation/entity.py:229:47-244:22: No matching overload found for function `openai.types.responses.response_reasoning_item_param.ResponseReasoningItemParam.__init__` called with arguments: (type=Literal['reasoning'], id=str, summary=list[dict[str, str]] | list[@_], encrypted_content=str | None) [no-matching-overload] ERROR homeassistant/components/openai_conversation/entity.py:273:5-452:80: `int | None` is not assignable to `None` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR homeassistant/components/openai_conversation/entity.py:390:13-30: `current_tool_call` is uninitialized [unbound-name] ERROR homeassistant/components/openai_conversation/entity.py:392:13-30: `current_tool_call` is uninitialized [unbound-name] @@ -19381,7 +18988,6 @@ ERROR homeassistant/components/openrgb/light.py:141:18-42: Class member `OpenRGB ERROR homeassistant/components/openrgb/light.py:293:55-83: Unpacked argument `tuple[str]` is not assignable to parameter `*args` with type `tuple[ModeData | int | str, bool, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/opensensemap/air_quality.py:8:1-42: Could not find import of `opensensemap_api` [missing-import] ERROR homeassistant/components/opensensemap/air_quality.py:9:1-58: Could not find import of `opensensemap_api.exceptions` [missing-import] -ERROR homeassistant/components/opensky/config_flow.py:43:9-31: Class member `OpenSkyConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/opensky/coordinator.py:37:5-17: Class member `OpenSkyDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/opentherm_gw/binary_sensor.py:37:9-12: Unexpected keyword argument `key` in function `OpenThermBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/opentherm_gw/binary_sensor.py:38:9-24: Unexpected keyword argument `translation_key` in function `OpenThermBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -19532,7 +19138,6 @@ ERROR homeassistant/components/opentherm_gw/climate.py:63:17-20: Unexpected keyw ERROR homeassistant/components/opentherm_gw/climate.py:76:5-29: Class member `OpenThermClimate._attr_supported_features` overrides parent class `OpenThermStatusEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/opentherm_gw/climate.py:93:5-23: Class member `OpenThermClimate.entity_description` overrides parent class `OpenThermStatusEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/opentherm_gw/climate.py:93:5-23: Class member `OpenThermClimate.entity_description` overrides parent class `ClimateEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/opentherm_gw/config_flow.py:48:9-31: Class member `OpenThermGwConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/opentherm_gw/entity.py:35:5-23: Class member `OpenThermEntity.entity_description` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/opentherm_gw/select.py:148:9-12: Unexpected keyword argument `key` in function `OpenThermSelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/opentherm_gw/select.py:149:9-24: Unexpected keyword argument `translation_key` in function `OpenThermSelectEntityDescription.__init__` [unexpected-keyword] @@ -19818,7 +19423,6 @@ ERROR homeassistant/components/openuv/binary_sensor.py:22:5-8: Unexpected keywor ERROR homeassistant/components/openuv/binary_sensor.py:23:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/openuv/binary_sensor.py:46:7-25: Field `entity_description` is declared `EntityDescription` in ancestor `class OpenUvEntity: ... `, which is not assignable to the type `BinarySensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] -ERROR homeassistant/components/openuv/config_flow.py:136:9-31: Class member `OpenUvFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/openuv/coordinator.py:27:5-17: Class member `OpenUvCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/openuv/coordinator.py:28:5-18: Class member `OpenUvCoordinator.update_method` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/openuv/sensor.py:84:9-12: Unexpected keyword argument `key` in function `OpenUvSensorEntityDescription.__init__` [unexpected-keyword] @@ -19843,22 +19447,9 @@ ERROR homeassistant/components/openuv/sensor.py:157:9-12: Unexpected keyword arg ERROR homeassistant/components/openuv/sensor.py:158:9-24: Unexpected keyword argument `translation_key` in function `OpenUvSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/openuv/sensor.py:187:5-23: Class member `OpenUvSensor.entity_description` overrides parent class `OpenUvEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/openuv/sensor.py:187:5-23: Class member `OpenUvSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/openweathermap/config_flow.py:70:9-31: Class member `OpenWeatherMapConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/openweathermap/coordinator.py:85:5-17: Class member `OWMUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/openweathermap/coordinator.py:190:25-45: Argument `Decimal` is not assignable to parameter `temperature` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:191:41-60: Argument `Decimal` is not assignable to parameter `native_apparent_temperature` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:192:22-39: Argument `int` is not assignable to parameter `pressure` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:194:30-48: Argument `Decimal | None` is not assignable to parameter `native_dew_point` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:196:24-43: Argument `Decimal` is not assignable to parameter `wind_speed` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:197:36-54: Argument `Decimal | None` is not assignable to parameter `native_wind_gust_speed` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:210:25-49: Argument `Decimal` is not assignable to parameter `temperature` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:211:21-45: Argument `Decimal` is not assignable to parameter `templow` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:212:41-60: Argument `DailyTemperature` is not assignable to parameter `native_apparent_temperature` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:213:22-39: Argument `int` is not assignable to parameter `pressure` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:215:30-48: Argument `Decimal` is not assignable to parameter `native_dew_point` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:217:24-43: Argument `Decimal` is not assignable to parameter `wind_speed` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:218:36-54: Argument `Decimal | None` is not assignable to parameter `native_wind_gust_speed` with type `float | None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] -ERROR homeassistant/components/openweathermap/coordinator.py:222:27-66: Argument `Decimal` is not assignable to parameter `precipitation` with type `None` in function `homeassistant.components.weather.Forecast.__init__` [bad-argument-type] +ERROR homeassistant/components/openweathermap/coordinator.py:187:24-202:10: No matching overload found for function `homeassistant.components.weather.Forecast.__init__` called with arguments: (datetime=str, condition=Unknown, temperature=Decimal, native_apparent_temperature=Decimal, pressure=int, humidity=int, native_dew_point=Decimal | None, cloud_coverage=int, wind_speed=Decimal, native_wind_gust_speed=Decimal | None, wind_bearing=int, uv_index=float | None, precipitation_probability=int, precipitation=Unknown) [no-matching-overload] +ERROR homeassistant/components/openweathermap/coordinator.py:207:24-223:10: No matching overload found for function `homeassistant.components.weather.Forecast.__init__` called with arguments: (datetime=str, condition=Unknown, temperature=Decimal, templow=Decimal, native_apparent_temperature=DailyTemperature, pressure=int, humidity=int, native_dew_point=Decimal, cloud_coverage=int, wind_speed=Decimal, native_wind_gust_speed=Decimal | None, wind_bearing=int, uv_index=float | None, precipitation_probability=int, precipitation=Decimal) [no-matching-overload] ERROR homeassistant/components/openweathermap/sensor.py:66:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/openweathermap/sensor.py:67:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/openweathermap/sensor.py:70:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -19976,8 +19567,6 @@ ERROR homeassistant/components/oralb/sensor.py:160:17-48: Object of class `Entit ERROR homeassistant/components/oralb/sensor.py:161:21-65: `not in` is not supported between `str` and `object` [not-iterable] ERROR homeassistant/components/oralb/sensor.py:163:17-55: Object of class `object` has no attribute `append` [missing-attribute] ERROR homeassistant/components/oru/sensor.py:8:1-34: Could not find import of `oru` [missing-import] -ERROR homeassistant/components/oru/sensor.py:78:31-35: `Literal[True]` is not assignable to attribute `_available` with type `None` [bad-assignment] -ERROR homeassistant/components/oru/sensor.py:87:31-36: `Literal[False]` is not assignable to attribute `_available` with type `None` [bad-assignment] ERROR homeassistant/components/orvibo/switch.py:8:1-51: Could not find import of `orvibo.s20` [missing-import] ERROR homeassistant/components/osoenergy/binary_sensor.py:30:9-12: Unexpected keyword argument `key` in function `OSOEnergyBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/osoenergy/binary_sensor.py:31:9-24: Unexpected keyword argument `translation_key` in function `OSOEnergyBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -20036,15 +19625,9 @@ ERROR homeassistant/components/osoenergy/water_heater.py:271:69-76: Argument `li ERROR homeassistant/components/osoenergy/water_heater.py:289:69-76: Argument `list[float]` is not assignable to parameter `profile` with type `array[Unknown]` in function `apyosoenergyapi.waterheater.OSOWaterHeater.set_profile` [bad-argument-type] ERROR homeassistant/components/osramlightify/light.py:9:1-30: Could not find import of `lightify` [missing-import] ERROR homeassistant/components/osramlightify/light.py:254:43-59: Type `None` is not iterable [not-iterable] -ERROR homeassistant/components/osramlightify/light.py:289:31-293:14: `tuple[int, int, int]` is not assignable to attribute `_rgb_color` with type `None` [bad-assignment] -ERROR homeassistant/components/osramlightify/light.py:308:31-81: `tuple[int, int, int]` is not assignable to attribute `_rgb_color` with type `None` [bad-assignment] -ERROR homeassistant/components/osramlightify/light.py:328:32-50: `Literal[2]` is not assignable to attribute `_brightness` with type `None` [bad-assignment] -ERROR homeassistant/components/osramlightify/light.py:360:32-64: `int` is not assignable to attribute `_brightness` with type `None` [bad-assignment] ERROR homeassistant/components/osramlightify/light.py:362:12-68: `in` is not supported between `Literal[ColorMode.COLOR_TEMP]` and `None` [not-iterable] ERROR homeassistant/components/osramlightify/light.py:365:12-60: `in` is not supported between `Literal[ColorMode.HS]` and `None` [not-iterable] ERROR homeassistant/components/osramlightify/light.py:368:16-48: Argument `set[ColorMode] | set[str] | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] -ERROR homeassistant/components/osramlightify/light.py:402:35-40: `dict[str, str | Unknown]` is not assignable to attribute `_device_attributes` with type `None` [bad-assignment] -ERROR homeassistant/components/osramlightify/light.py:447:35-75: `dict[str, Unknown]` is not assignable to attribute `_device_attributes` with type `None` [bad-assignment] ERROR homeassistant/components/otbr/__init__.py:40:57-79: Argument `Module[homeassistant.components.otbr.homeassistant_hardware]` is not assignable to parameter `platform` with type `AsyncHardwareFirmwareInfoModule | SyncHardwareFirmwareInfoModule` in function `homeassistant.components.homeassistant_hardware.helpers.async_register_firmware_info_provider` [bad-argument-type] ERROR homeassistant/components/otbr/config_flow.py:210:20-29: `unique_id` may be uninitialized [unbound-name] ERROR homeassistant/components/otbr/config_flow.py:230:31-40: `unique_id` may be uninitialized [unbound-name] @@ -20420,8 +20003,8 @@ ERROR homeassistant/components/overseerr/sensor.py:68:9-12: Unexpected keyword a ERROR homeassistant/components/overseerr/sensor.py:92:5-23: Class member `OverseerrSensor.entity_description` overrides parent class `OverseerrEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/overseerr/sensor.py:92:5-23: Class member `OverseerrSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ovo_energy/config_flow.py:66:31-46: Argument `str | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] -ERROR homeassistant/components/ovo_energy/config_flow.py:111:21-34: Argument `None` is not assignable to parameter `username` with type `str` in function `ovoenergy.OVOEnergy.authenticate` [bad-argument-type] -ERROR homeassistant/components/ovo_energy/entity.py:40:25-60: Argument `set[tuple[str, int | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/ovo_energy/config_flow.py:111:21-34: Argument `Unknown | None` is not assignable to parameter `username` with type `str` in function `ovoenergy.OVOEnergy.authenticate` [bad-argument-type] +ERROR homeassistant/components/ovo_energy/entity.py:38:26-43:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, int | None]], manufacturer=Literal['OVO Energy'], name=str | None) [no-matching-overload] ERROR homeassistant/components/ovo_energy/sensor.py:41:62-67: `Overload[[_T](number: _SupportsRound1[_T], ndigits: None = None) -> _T, [_T](number: _SupportsRound2[_T], ndigits: SupportsIndex) -> _T]` is not assignable to `(OVODailyUsage) -> datetime | float | int | str | None` [bad-assignment] ERROR homeassistant/components/ovo_energy/sensor.py:46:9-12: Unexpected keyword argument `key` in function `OVOEnergySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ovo_energy/sensor.py:47:9-24: Unexpected keyword argument `translation_key` in function `OVOEnergySensorEntityDescription.__init__` [unexpected-keyword] @@ -20471,11 +20054,6 @@ ERROR homeassistant/components/owntracks/__init__.py:148:9-25: Cannot set item i ERROR homeassistant/components/owntracks/__init__.py:148:9-25: Cannot set item in `list[Unknown]` [unsupported-operation] ERROR homeassistant/components/owntracks/__init__.py:148:9-25: Cannot set item in `str` [unsupported-operation] ERROR homeassistant/components/owntracks/__init__.py:148:9-25: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/owntracks/messages.py:74:9-41: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/owntracks/messages.py:76:9-36: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/owntracks/messages.py:78:9-40: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/owntracks/messages.py:80:9-39: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/owntracks/messages.py:82:9-47: Cannot set item in `str` [unsupported-operation] ERROR homeassistant/components/p1_monitor/coordinator.py:48:5-17: Class member `P1MonitorDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/p1_monitor/sensor.py:39:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/p1_monitor/sensor.py:40:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -20784,7 +20362,6 @@ ERROR homeassistant/components/pglab/__init__.py:69:66-82: Argument `(sub_state: ERROR homeassistant/components/pglab/cover.py:67:47-79: `dict[str, int]` is not assignable to attribute `_attr_translation_placeholders` with type `Mapping[str, str]` [bad-assignment] ERROR homeassistant/components/pglab/cover.py:71:14-32: Class member `PGLabCover._attr_device_class` overrides parent class `PGLabEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/pglab/cover.py:72:14-38: Class member `PGLabCover._attr_supported_features` overrides parent class `PGLabEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/pglab/discovery.py:287:29-33: `Client` is not assignable to attribute `_mqtt_client` with type `None` [bad-assignment] ERROR homeassistant/components/pglab/entity.py:92:44-48: Argument `None` is not assignable to parameter `on_state_update` with type `(str) -> None` in function `pypglab.entity.Entity.set_on_state_callback` [bad-argument-type] ERROR homeassistant/components/pglab/sensor.py:27:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/pglab/sensor.py:33:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -20800,7 +20377,6 @@ ERROR homeassistant/components/philips_js/binary_sensor.py:34:9-12: Unexpected k ERROR homeassistant/components/philips_js/binary_sensor.py:35:9-24: Unexpected keyword argument `translation_key` in function `PhilipsTVBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/philips_js/binary_sensor.py:69:5-23: Class member `PhilipsTVBinarySensorEntityRecordingType.entity_description` overrides parent class `PhilipsJsEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/philips_js/binary_sensor.py:69:5-23: Class member `PhilipsTVBinarySensorEntityRecordingType.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/philips_js/config_flow.py:241:9-31: Class member `PhilipsJSConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/philips_js/coordinator.py:34:5-17: Class member `PhilipsTVDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/philips_js/light.py:153:14-38: Class member `PhilipsTVLightEntity._attr_supported_features` overrides parent class `PhilipsJsEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/philips_js/light.py:201:45-68: Argument `str | None` is not assignable to parameter `style` with type `str` in function `AmbilightEffect.__init__` [bad-argument-type] @@ -20814,8 +20390,8 @@ ERROR homeassistant/components/philips_js/light.py:311:20-28: TypedDict `Ambilig ERROR homeassistant/components/philips_js/light.py:321:28-44: `str | None` is not assignable to TypedDict key `menuSetting` with type `str` [bad-typed-dict-key] ERROR homeassistant/components/philips_js/media_player.py:68:5-23: Class member `PhilipsTVMediaPlayer._attr_device_class` overrides parent class `PhilipsJsEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/philips_js/media_player.py:79:14-25: Class member `PhilipsTVMediaPlayer._attr_state` overrides parent class `PhilipsJsEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/philips_js/media_player.py:443:46-66: No matching overload found for function `dict.get` called with arguments: (None) [no-matching-overload] -ERROR homeassistant/components/philips_js/media_player.py:472:55-75: No matching overload found for function `dict.get` called with arguments: (None) [no-matching-overload] +ERROR homeassistant/components/philips_js/media_player.py:443:46-66: No matching overload found for function `dict.get` called with arguments: (Unknown | None) [no-matching-overload] +ERROR homeassistant/components/philips_js/media_player.py:472:55-75: No matching overload found for function `dict.get` called with arguments: (Unknown | None) [no-matching-overload] ERROR homeassistant/components/pi_hole/__init__.py:52:10-14: Expected a type form, got instance of `(*args: Unknown, *, version: int | Unknown = 6, **kwargs: Unknown) -> Unknown` [not-a-type] ERROR homeassistant/components/pi_hole/__init__.py:207:15-34: Object of class `HoleV5` has no attribute `authenticate` [missing-attribute] ERROR homeassistant/components/pi_hole/binary_sensor.py:28:28-32: Expected a type form, got instance of `(*args: Unknown, *, version: int | Unknown = 6, **kwargs: Unknown) -> Unknown` [not-a-type] @@ -20880,7 +20456,6 @@ ERROR homeassistant/components/pi_hole/update.py:94:14-18: Expected a type form, ERROR homeassistant/components/picnic/__init__.py:30:20-53: Argument `Any | None` is not assignable to parameter `auth_token` with type `str` in function `python_picnic_api2.client.PicnicAPI.__init__` [bad-argument-type] ERROR homeassistant/components/picnic/__init__.py:31:22-55: Argument `Any | None` is not assignable to parameter `country_code` with type `str` in function `python_picnic_api2.client.PicnicAPI.__init__` [bad-argument-type] ERROR homeassistant/components/picnic/coordinator.py:24:5-17: Class member `PicnicUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/picnic/coordinator.py:85:17-86:74: `str` is not assignable to attribute `_user_address` with type `None` [bad-assignment] WARN homeassistant/components/picnic/coordinator.py:110:22-59: `python_picnic_api2.client.PicnicAPI.get_deliveries` is deprecated [deprecated] ERROR homeassistant/components/picnic/coordinator.py:148:37-48: Cannot set item in `dict[str, list[Unknown]]` [unsupported-operation] ERROR homeassistant/components/picnic/coordinator.py:151:30-51: No matching overload found for function `typing.MutableMapping.setdefault` called with arguments: (Literal['delivery_time'], dict[@_, @_]) [no-matching-overload] @@ -20919,11 +20494,8 @@ ERROR homeassistant/components/picnic/sensor.py:192:9-12: Unexpected keyword arg ERROR homeassistant/components/picnic/sensor.py:193:9-24: Unexpected keyword argument `translation_key` in function `PicnicSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/picnic/sensor.py:223:5-23: Class member `PicnicSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/picnic/sensor.py:223:5-23: Class member `PicnicSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/pilight/binary_sensor.py:192:37-194:18: `datetime` is not assignable to attribute `_delay_after` with type `None` [bad-assignment] -ERROR homeassistant/components/pilight/binary_sensor.py:195:68-85: Argument `None` is not assignable to parameter `point_in_time` with type `datetime` [bad-argument-type] ERROR homeassistant/components/pilight/entity.py:94:32-66: `Any | None` is not assignable to attribute `_brightness` with type `int` [bad-assignment] ERROR homeassistant/components/ping/binary_sensor.py:29:5-23: Class member `PingBinarySensor._attr_device_class` overrides parent class `PingEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/ping/config_flow.py:73:9-31: Class member `PingConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/ping/coordinator.py:33:5-17: Class member `PingUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/ping/sensor.py:31:9-12: Unexpected keyword argument `key` in function `PingSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ping/sensor.py:32:9-24: Unexpected keyword argument `translation_key` in function `PingSensorEntityDescription.__init__` [unexpected-keyword] @@ -20952,18 +20524,9 @@ ERROR homeassistant/components/pioneer/media_player.py:145:23-71: `Unknown | Non ERROR homeassistant/components/pioneer/media_player.py:164:37-87: `Unknown | None` is not assignable to attribute `_selected_source` with type `str` [bad-assignment] ERROR homeassistant/components/pioneer/media_player.py:166:37-41: `None` is not assignable to attribute `_selected_source` with type `str` [bad-assignment] ERROR homeassistant/components/plaato/binary_sensor.py:47:18-36: Class member `PlaatoBinarySensor._attr_device_class` overrides parent class `PlaatoEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/plaato/config_flow.py:184:9-31: Class member `PlaatoConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/plaato/coordinator.py:22:5-17: Class member `PlaatoCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/plaato/sensor.py:85:18-36: Class member `PlaatoSensor._attr_device_class` overrides parent class `PlaatoEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/plant/__init__.py:212:30-35: `Literal['unavailable'] | int` is not assignable to attribute `_moisture` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:216:29-34: `Literal['unavailable'] | int` is not assignable to attribute `_battery` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:220:33-38: `Literal['unavailable'] | float` is not assignable to attribute `_temperature` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:224:34-39: `Literal['unavailable'] | int` is not assignable to attribute `_conductivity` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:228:32-37: `Literal['unavailable'] | int` is not assignable to attribute `_brightness` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:264:27-40: `Literal['problem']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:267:27-35: `Literal['ok']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:391:26-33: `deque[@_]` is not assignable to attribute `_days` with type `None` [bad-assignment] -ERROR homeassistant/components/plant/__init__.py:409:16-26: Argument `None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] +ERROR homeassistant/components/plant/__init__.py:409:16-26: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR homeassistant/components/plant/__init__.py:410:22-40: Object of class `NoneType` has no attribute `popleft` [missing-attribute] ERROR homeassistant/components/plant/__init__.py:412:9-26: Object of class `NoneType` has no attribute `append` [missing-attribute] ERROR homeassistant/components/playstation_network/binary_sensor.py:43:9-12: Unexpected keyword argument `key` in function `PlaystationNetworkBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -20972,10 +20535,6 @@ ERROR homeassistant/components/playstation_network/binary_sensor.py:69:5-23: Cla ERROR homeassistant/components/playstation_network/binary_sensor.py:69:5-23: Class member `PlaystationNetworkBinarySensorEntity.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/playstation_network/binary_sensor.py:70:5-16: Class member `PlaystationNetworkBinarySensorEntity.coordinator` overrides parent class `PlaystationNetworkServiceEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/playstation_network/coordinator.py:56:5-17: Class member `PlayStationNetworkBaseCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/playstation_network/coordinator.py:101:5-21: Class member `PlaystationNetworkUserDataCoordinator._update_interval` overrides parent class `PlayStationNetworkBaseCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/playstation_network/coordinator.py:129:5-21: Class member `PlaystationNetworkTrophyTitlesCoordinator._update_interval` overrides parent class `PlayStationNetworkBaseCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/playstation_network/coordinator.py:145:5-21: Class member `PlaystationNetworkFriendlistCoordinator._update_interval` overrides parent class `PlayStationNetworkBaseCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/playstation_network/coordinator.py:164:5-21: Class member `PlaystationNetworkGroupsUpdateCoordinator._update_interval` overrides parent class `PlayStationNetworkBaseCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/playstation_network/image.py:46:9-12: Unexpected keyword argument `key` in function `PlaystationNetworkImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/playstation_network/image.py:47:9-24: Unexpected keyword argument `translation_key` in function `PlaystationNetworkImageEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/playstation_network/image.py:53:9-12: Unexpected keyword argument `key` in function `PlaystationNetworkImageEntityDescription.__init__` [unexpected-keyword] @@ -21022,22 +20581,9 @@ ERROR homeassistant/components/playstation_network/sensor.py:179:5-23: Class mem ERROR homeassistant/components/playstation_network/sensor.py:179:5-23: Class member `PlaystationNetworkSensorBaseEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/playstation_network/sensor.py:214:5-16: Class member `PlaystationNetworkSensorEntity.coordinator` overrides parent class `PlaystationNetworkSensorBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/playstation_network/sensor.py:220:5-16: Class member `PlaystationNetworkFriendSensorEntity.coordinator` overrides parent class `PlaystationNetworkSensorBaseEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/plex/config_flow.py:103:9-31: Class member `PlexFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/plex/config_flow.py:361:26-57: `str` is not assignable to attribute `client_id` with type `None` [bad-assignment] ERROR homeassistant/components/plex/media_browser.py:46:45-54: Argument `str | None` is not assignable to parameter `server_id` with type `str` in function `homeassistant.components.plex.helpers.get_plex_server` [bad-argument-type] ERROR homeassistant/components/plex/media_browser.py:74:13-40: Object of class `NoneType` has no attribute `thumbnail_cache` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:79:21-30: Argument `str | None` is not assignable to parameter `server_id` with type `str` in function `get_proxy_image_url` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:84:28-37: Unpacked keyword argument `MediaClass | bool | Unknown` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] ERROR homeassistant/components/plex/media_browser.py:89:19-44: Object of class `NoneType` has no attribute `friendly_name` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:100:13-40: Object of class `NoneType` has no attribute `append` Object of class `Sequence` has no attribute `append` [missing-attribute] @@ -21047,20 +20593,6 @@ Object of class `Sequence` has no attribute `append` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:109:9-36: Object of class `NoneType` has no attribute `append` Object of class `Sequence` has no attribute `append` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:134:25-46: Object of class `NoneType` has no attribute `playlists` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:142:17-50: Object of class `MediaClass` has no attribute `append` -Object of class `bool` has no attribute `append` -Object of class `str` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:145:32-48: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] ERROR homeassistant/components/plex/media_browser.py:152:21-45: Object of class `NoneType` has no attribute `lookup_media` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:173:12-24: `hub_location` may be uninitialized [unbound-name] ERROR homeassistant/components/plex/media_browser.py:176:26-45: Object of class `NoneType` has no attribute `library` [missing-attribute] @@ -21068,52 +20600,13 @@ ERROR homeassistant/components/plex/media_browser.py:177:39-53: `hub_identifier` ERROR homeassistant/components/plex/media_browser.py:181:31-50: Object of class `NoneType` has no attribute `library` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:181:67-79: `hub_location` may be uninitialized [unbound-name] ERROR homeassistant/components/plex/media_browser.py:183:73-87: `hub_identifier` may be uninitialized [unbound-name] -ERROR homeassistant/components/plex/media_browser.py:204:17-43: Object of class `MediaClass` has no attribute `append` -Object of class `bool` has no attribute `append` -Object of class `str` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:210:17-43: Object of class `MediaClass` has no attribute `append` -Object of class `bool` has no attribute `append` -Object of class `str` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:213:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | str | Unknown` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] +ERROR homeassistant/components/plex/media_browser.py:213:27-38: Missing argument `title` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [missing-argument] ERROR homeassistant/components/plex/media_browser.py:217:34-53: Object of class `NoneType` has no attribute `library` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:219:21-46: Object of class `NoneType` has no attribute `friendly_name` [missing-attribute] ERROR homeassistant/components/plex/media_browser.py:221:34-53: Object of class `NoneType` has no attribute `library` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:251:17-43: Object of class `MediaClass` has no attribute `append` -Object of class `bool` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:253:28-37: Unpacked keyword argument `MediaClass | bool | list[@_] | Unknown` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] +ERROR homeassistant/components/plex/media_browser.py:253:27-38: Missing argument `title` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [missing-argument] ERROR homeassistant/components/plex/media_browser.py:261:23-42: Object of class `NoneType` has no attribute `library` [missing-attribute] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_browser.py:373:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/plex/media_player.py:226:56-68: No matching overload found for function `str.join` called with arguments: (list[None]) [no-matching-overload] +ERROR homeassistant/components/plex/media_player.py:226:56-68: No matching overload found for function `str.join` called with arguments: (list[Unknown | None]) [no-matching-overload] ERROR homeassistant/components/plex/media_player.py:392:28-76: `in` is not supported between `Literal['playback']` and `None` [not-iterable] ERROR homeassistant/components/plex/media_player.py:412:28-76: `in` is not supported between `Literal['playback']` and `None` [not-iterable] ERROR homeassistant/components/plex/media_player.py:414:34-40: `float` is not assignable to attribute `_volume_level` with type `int` [bad-assignment] @@ -21128,21 +20621,7 @@ ERROR homeassistant/components/plex/media_player.py:478:28-76: `in` is not suppo ERROR homeassistant/components/plex/media_player.py:485:33-81: `in` is not supported between `Literal['playback']` and `None` [not-iterable] ERROR homeassistant/components/plex/models.py:48:31-50: Object of class `NoneType` has no attribute `product` [missing-attribute] ERROR homeassistant/components/plex/models.py:51:22-39: Object of class `NoneType` has no attribute `state` [missing-attribute] -ERROR homeassistant/components/plex/models.py:74:35-61: `int` is not assignable to attribute `media_duration` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:77:40-80: `str` is not assignable to attribute `media_library_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:79:40-55: `Literal['Unknown']` is not assignable to attribute `media_library_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:90:17-84: `Literal[''] | Unknown` is not assignable to attribute `media_library_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:94:39-55: `Literal[MediaType.TVSHOW]` is not assignable to attribute `media_content_type` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:100:17-102:39: `str` is not assignable to attribute `sensor_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:105:39-54: `Literal[MediaType.MOVIE]` is not assignable to attribute `media_content_type` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:110:39-54: `Literal[MediaType.MUSIC]` is not assignable to attribute `media_content_type` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:116:17-86: `str` is not assignable to attribute `sensor_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:119:39-54: `Literal[MediaType.VIDEO]` is not assignable to attribute `media_content_type` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/models.py:122:33-42: `Literal['Unknown']` is not assignable to attribute `sensor_title` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/server.py:116:38-85: `MyPlexAccount` is not assignable to attribute `_plex_account` with type `None` [bad-assignment] ERROR homeassistant/components/plex/server.py:130:45-48: `float` is not assignable to attribute `_plextv_client_timestamp` with type `int` [bad-assignment] -ERROR homeassistant/components/plex/server.py:131:36-135:14: `list[Unknown]` is not assignable to attribute `_plextv_clients` with type `None` [bad-assignment] -ERROR homeassistant/components/plex/server.py:170:33-172:14: `PlexServer` is not assignable to attribute `_plex_server` with type `None` [bad-assignment] ERROR homeassistant/components/plex/server.py:192:17-193:46: `BaseException | SSLError | None` is not assignable to `SSLError` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR homeassistant/components/plex/server.py:218:31-63: Object of class `NoneType` has no attribute `systemAccounts` [missing-attribute] ERROR homeassistant/components/plex/server.py:243:25-50: Object of class `NoneType` has no attribute `version` [missing-attribute] @@ -21165,7 +20644,6 @@ ERROR homeassistant/components/plex/server.py:606:16-43: Object of class `NoneTy ERROR homeassistant/components/plex/server.py:622:16-43: Object of class `NoneType` has no attribute `fetchItem` [missing-attribute] ERROR homeassistant/components/plex/server.py:644:50-63: `playlist_name` is uninitialized [unbound-name] ERROR homeassistant/components/plex/server.py:654:29-41: `library_name` is uninitialized [unbound-name] -ERROR homeassistant/components/plex/server.py:669:29-40: `PlexServer` is not assignable to attribute `_plex_server` with type `None` [bad-assignment] ERROR homeassistant/components/plex/services.py:162:5-19: Object of class `str` has no attribute `update` [missing-attribute] ERROR homeassistant/components/plex/services.py:164:24-35: Object of class `str` has no attribute `pop` [missing-attribute] ERROR homeassistant/components/plex/services.py:175:20-32: Object of class `str` has no attribute `copy` [missing-attribute] @@ -21293,7 +20771,6 @@ ERROR homeassistant/components/plugwise/switch.py:52:9-24: Unexpected keyword ar ERROR homeassistant/components/plugwise/switch.py:86:5-23: Class member `PlugwiseSwitchEntity.entity_description` overrides parent class `PlugwiseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/plugwise/switch.py:86:5-23: Class member `PlugwiseSwitchEntity.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/pocketcasts/sensor.py:8:1-36: Could not find import of `pycketcasts` [missing-import] -ERROR homeassistant/components/pocketcasts/sensor.py:74:27-54: `int` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/point/__init__.py:113:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/point/binary_sensor.py:78:14-32: Class member `MinutPointBinarySensor._attr_device_class` overrides parent class `MinutPointEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/point/sensor.py:26:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -21681,7 +21158,6 @@ ERROR homeassistant/components/proliphix/climate.py:7:8-17: Could not find impor ERROR homeassistant/components/prometheus/__init__.py:449:15-19: `temp` may be uninitialized [unbound-name] ERROR homeassistant/components/prometheus/__init__.py:536:20-25: `value` may be uninitialized [unbound-name] ERROR homeassistant/components/prometheus/__init__.py:588:17-22: `value` may be uninitialized [unbound-name] -ERROR homeassistant/components/proximity/config_flow.py:90:9-31: Class member `ProximityConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/proximity/coordinator.py:75:5-17: Class member `ProximityDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/proximity/sensor.py:33:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/proximity/sensor.py:34:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -21699,7 +21175,6 @@ ERROR homeassistant/components/proxmoxve/__init__.py:8:1-54: Could not find impo ERROR homeassistant/components/proxmoxve/binary_sensor.py:78:5-23: Class member `ProxmoxBinarySensor._attr_device_class` overrides parent class `ProxmoxEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/proxmoxve/common.py:7:1-33: Could not find import of `proxmoxer` [missing-import] ERROR homeassistant/components/proxmoxve/common.py:8:1-45: Could not find import of `proxmoxer.core` [missing-import] -ERROR homeassistant/components/proxy/camera.py:278:32-43: `bytes` is not assignable to attribute `_last_image` with type `None` [bad-assignment] ERROR homeassistant/components/prusalink/__init__.py:128:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/prusalink/binary_sensor.py:48:13-16: Unexpected keyword argument `key` in function `PrusaLinkBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/prusalink/binary_sensor.py:49:13-28: Unexpected keyword argument `translation_key` in function `PrusaLinkBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -21772,7 +21247,6 @@ ERROR homeassistant/components/prusalink/sensor.py:230:5-23: Class member `Prusa ERROR homeassistant/components/prusalink/sensor.py:230:5-23: Class member `PrusaLinkSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ps4/config_flow.py:67:56-86: Unpacked argument `tuple[dict_keys[int, str]]` is not assignable to parameter `*args` with type `tuple[list[Unknown]]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/ps4/config_flow.py:173:72-180:14: Unpacked argument `tuple[Any, str | None, str, Literal['Home-Assistant'], Literal[1988]]` is not assignable to parameter `*args` with type `tuple[str, str, str, Unknown | None, int | Unknown]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/ps4/media_player.py:156:38-71: `DDPProtocol` is not assignable to attribute `ddp_protocol` with type `None` [bad-assignment] ERROR homeassistant/components/ps4/media_player.py:205:54-75: Cannot index into `dict[str, JsonValueType]` [bad-index] ERROR homeassistant/components/ps4/media_player.py:289:54-75: Cannot index into `dict[str, JsonValueType]` [bad-index] ERROR homeassistant/components/ps4/media_player.py:295:32-55: No matching overload found for function `dict.pop` called with arguments: (str | None) [no-matching-overload] @@ -21836,7 +21310,6 @@ ERROR homeassistant/components/pure_energie/sensor.py:55:9-24: Unexpected keywor ERROR homeassistant/components/pure_energie/sensor.py:85:5-23: Class member `PureEnergieSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/pure_energie/sensor.py:85:5-23: Class member `PureEnergieSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/purpleair/config_flow.py:194:34-55: `nearby_sensor_results` may be uninitialized [unbound-name] -ERROR homeassistant/components/purpleair/config_flow.py:208:9-31: Class member `PurpleAirConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/purpleair/coordinator.py:55:5-17: Class member `PurpleAirDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/purpleair/sensor.py:45:9-12: Unexpected keyword argument `key` in function `PurpleAirSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/purpleair/sensor.py:52:9-12: Unexpected keyword argument `key` in function `PurpleAirSensorEntityDescription.__init__` [unexpected-keyword] @@ -21874,14 +21347,15 @@ ERROR homeassistant/components/purpleair/sensor.py:156:9-12: Unexpected keyword ERROR homeassistant/components/purpleair/sensor.py:157:9-24: Unexpected keyword argument `translation_key` in function `PurpleAirSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/purpleair/sensor.py:181:5-23: Class member `PurpleAirSensorEntity.entity_description` overrides parent class `PurpleAirEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/purpleair/sensor.py:181:5-23: Class member `PurpleAirSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/push/camera.py:151:31-47: `datetime` is not assignable to attribute `_last_trip` with type `None` [bad-assignment] -ERROR homeassistant/components/push/camera.py:168:34-170:10: `() -> None` is not assignable to attribute `_expired_listener` with type `None` [bad-assignment] ERROR homeassistant/components/pushbullet/__init__.py:42:55-44:10: Unpacked argument `tuple[Any]` is not assignable to parameter `*args` with type `tuple[Unknown, Unknown | None, Unknown | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/pushbullet/__init__.py:81:43-60: Argument `BoundMethod[PushBulletNotificationProvider, (self: PushBulletNotificationProvider, **kwargs: Unknown) -> None]` is not assignable to parameter `target` with type `(**tuple[*@_]) -> @_` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/pushbullet/__init__.py:82:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/pushbullet/config_flow.py:37:68-39:18: Unpacked argument `tuple[Any]` is not assignable to parameter `*args` with type `tuple[Unknown, Unknown | None, Unknown | None]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/pushbullet/config_flow.py:46:48-58: `pushbullet` may be uninitialized [unbound-name] ERROR homeassistant/components/pushbullet/notify.py:116:51-79: Argument `Channel | Device` is not assignable to parameter `pusher` with type `Pushbullet` in function `PushBulletNotificationService._push_data` [bad-argument-type] +ERROR homeassistant/components/pushbullet/notify.py:148:33-43: Missing argument `file_name` in function `pushbullet.pushbullet.Pushbullet.push_file` [missing-argument] +ERROR homeassistant/components/pushbullet/notify.py:148:33-43: Missing argument `file_url` in function `pushbullet.pushbullet.Pushbullet.push_file` [missing-argument] +ERROR homeassistant/components/pushbullet/notify.py:148:33-43: Missing argument `file_type` in function `pushbullet.pushbullet.Pushbullet.push_file` [missing-argument] ERROR homeassistant/components/pushbullet/sensor.py:18:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/pushbullet/sensor.py:19:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/pushbullet/sensor.py:20:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -21931,7 +21405,6 @@ ERROR homeassistant/components/pvoutput/sensor.py:82:9-12: Unexpected keyword ar ERROR homeassistant/components/pvoutput/sensor.py:89:9-12: Unexpected keyword argument `key` in function `PVOutputSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/pvoutput/sensor.py:123:5-23: Class member `PVOutputSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/pvoutput/sensor.py:123:5-23: Class member `PVOutputSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/pvpc_hourly_pricing/config_flow.py:55:9-31: Class member `TariffSelectorConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/pvpc_hourly_pricing/coordinator.py:26:5-17: Class member `ElecPricesDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/pvpc_hourly_pricing/sensor.py:33:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/pvpc_hourly_pricing/sensor.py:34:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -22096,10 +21569,6 @@ ERROR homeassistant/components/qingping/sensor.py:160:7-36: Field `entity_descri `, which is not assignable to the type `SensorEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/qld_bushfire/geo_location.py:215:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/qld_bushfire/geo_location.py:216:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/qld_bushfire/geo_location.py:218:26-45: `str | None` is not assignable to attribute `_category` with type `None` [bad-assignment] -ERROR homeassistant/components/qld_bushfire/geo_location.py:219:34-54: `datetime | None` is not assignable to attribute `_publication_date` with type `None` [bad-assignment] -ERROR homeassistant/components/qld_bushfire/geo_location.py:220:30-48: `datetime | None` is not assignable to attribute `_updated_date` with type `None` [bad-assignment] -ERROR homeassistant/components/qld_bushfire/geo_location.py:221:24-41: `str` is not assignable to attribute `_status` with type `None` [bad-assignment] ERROR homeassistant/components/qnap/__init__.py:34:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/qnap/sensor.py:47:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/qnap/sensor.py:48:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -22302,7 +21771,6 @@ ERROR homeassistant/components/rachio/binary_sensor.py:141:5-23: Class member `R ERROR homeassistant/components/rachio/binary_sensor.py:141:5-23: Class member `RachioControllerBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rachio/binary_sensor.py:192:5-23: Class member `RachioHoseTimerBinarySensor.entity_description` overrides parent class `RachioHoseTimerEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rachio/binary_sensor.py:192:5-23: Class member `RachioHoseTimerBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/rachio/config_flow.py:113:9-31: Class member `RachioConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/rachio/device.py:285:15-38: Object of class `Rachio` has no attribute `webhook_url` [missing-attribute] ERROR homeassistant/components/rachio/device.py:286:35-59: Object of class `Rachio` has no attribute `webhook_auth` [missing-attribute] ERROR homeassistant/components/rachio/webhooks.py:99:20-46: Object of class `Rachio` has no attribute `webhook_auth` [missing-attribute] @@ -22320,7 +21788,6 @@ ERROR homeassistant/components/radarr/calendar.py:31:7-27: Field `entity_descrip `, which is not assignable to the type `CalendarEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/radarr/calendar.py:34:5-16: Class member `RadarrCalendarEntity.coordinator` overrides parent class `RadarrEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/radarr/coordinator.py:63:5-17: Class member `RadarrDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/radarr/coordinator.py:64:5-21: Class member `RadarrDataUpdateCoordinator._update_interval` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/radarr/sensor.py:73:9-12: Unexpected keyword argument `key` in function `RadarrSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/radarr/sensor.py:74:9-13: Unexpected keyword argument `name` in function `RadarrSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/radarr/sensor.py:77:9-13: Unexpected keyword argument `icon` in function `RadarrSensorEntityDescription.__init__` [unexpected-keyword] @@ -22349,7 +21816,6 @@ ERROR homeassistant/components/rainbird/calendar.py:85:19-42: Object of class `T ERROR homeassistant/components/rainbird/calendar.py:97:39-56: Argument `tzinfo | None` is not assignable to parameter `tzinfo` with type `tzinfo` in function `pyrainbird.data.Schedule.timeline_tz` [bad-argument-type] ERROR homeassistant/components/rainbird/calendar.py:103:25-49: Object of class `Timespan` has no attribute `program_id` [missing-attribute] ERROR homeassistant/components/rainbird/calendar.py:106:23-46: Object of class `Timespan` has no attribute `rrule_str` [missing-attribute] -ERROR homeassistant/components/rainbird/config_flow.py:67:9-31: Class member `RainbirdConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainbird/coordinator.py:61:5-17: Class member `RainbirdUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainbird/coordinator.py:145:5-17: Class member `RainbirdScheduleUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainbird/number.py:67:62-67: Argument `float` is not assignable to parameter `days` with type `int` in function `pyrainbird.async_client.AsyncRainbirdController.set_rain_delay` [bad-argument-type] @@ -22357,9 +21823,6 @@ ERROR homeassistant/components/rainbird/sensor.py:20:5-8: Unexpected keyword arg ERROR homeassistant/components/rainbird/sensor.py:21:5-20: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/rainbird/sensor.py:53:14-32: Class member `RainBirdSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/raincloud/__init__.py:6:1-39: Could not find import of `raincloudy.core` [missing-import] -ERROR homeassistant/components/raincloud/switch.py:82:23-27: `Literal[True]` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/raincloud/switch.py:90:23-28: `Literal[False]` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/raincloud/switch.py:96:27-56: `bool` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/rainforest_eagle/coordinator.py:32:5-17: Class member `EagleDataCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainforest_eagle/coordinator.py:89:26-40: `eagle200_meter` may be uninitialized [unbound-name] ERROR homeassistant/components/rainforest_eagle/coordinator.py:92:35-49: `eagle200_meter` may be uninitialized [unbound-name] @@ -22416,7 +21879,6 @@ ERROR homeassistant/components/rainmachine/button.py:46:9-12: Unexpected keyword ERROR homeassistant/components/rainmachine/button.py:69:5-23: Class member `RainMachineButton._attr_device_class` overrides parent class `RainMachineEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainmachine/button.py:72:5-23: Class member `RainMachineButton.entity_description` overrides parent class `RainMachineEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainmachine/button.py:72:5-23: Class member `RainMachineButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/rainmachine/config_flow.py:62:9-31: Class member `RainMachineFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainmachine/coordinator.py:28:5-17: Class member `RainMachineDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/rainmachine/select.py:52:9-12: Unexpected keyword argument `key` in function `FreezeProtectionSelectDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/rainmachine/select.py:53:9-24: Unexpected keyword argument `translation_key` in function `FreezeProtectionSelectDescription.__init__` [unexpected-keyword] @@ -22521,7 +21983,6 @@ ERROR homeassistant/components/rdw/sensor.py:43:9-12: Unexpected keyword argumen ERROR homeassistant/components/rdw/sensor.py:44:9-24: Unexpected keyword argument `translation_key` in function `RDWSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/rdw/sensor.py:71:5-23: Class member `RDWSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rdw/sensor.py:71:5-23: Class member `RDWSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/recollect_waste/config_flow.py:35:9-31: Class member `RecollectWasteConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/recollect_waste/sensor.py:31:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/recollect_waste/sensor.py:32:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/recollect_waste/sensor.py:35:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -22531,7 +21992,7 @@ ERROR homeassistant/components/recollect_waste/sensor.py:77:14-32: Class member ERROR homeassistant/components/recollect_waste/sensor.py:93:65-70: `event` may be uninitialized [unbound-name] ERROR homeassistant/components/recollect_waste/sensor.py:95:58-63: `event` may be uninitialized [unbound-name] ERROR homeassistant/components/recollect_waste/sensor.py:97:39-44: `event` may be uninitialized [unbound-name] -ERROR homeassistant/components/recorder/core.py:1419:54-74: Cannot set item in `dict[str, str]` [unsupported-operation] +ERROR homeassistant/components/recorder/core.py:1419:54-74: `dict[Unknown, Unknown]` is not assignable to TypedDict key `conv` with type `str` [bad-typed-dict-key] ERROR homeassistant/components/recorder/db_schema.py:646:13-24: Unexpected keyword argument `metadata_id` in function `object.__init__` [unexpected-keyword] ERROR homeassistant/components/recorder/db_schema.py:647:13-20: Unexpected keyword argument `created` in function `object.__init__` [unexpected-keyword] ERROR homeassistant/components/recorder/db_schema.py:648:13-23: Unexpected keyword argument `created_ts` in function `object.__init__` [unexpected-keyword] @@ -22983,10 +22444,8 @@ ERROR homeassistant/components/reolink/camera.py:95:9-40: Unexpected keyword arg ERROR homeassistant/components/reolink/camera.py:127:5-23: Class member `ReolinkCamera.entity_description` overrides parent class `ReolinkChannelCoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/reolink/camera.py:127:5-23: Class member `ReolinkCamera.entity_description` overrides parent class `Camera` in an inconsistent manner [bad-override] ERROR homeassistant/components/reolink/camera.py:141:18-42: Class member `ReolinkCamera._attr_supported_features` overrides parent class `ReolinkChannelCoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/reolink/config_flow.py:119:9-31: Class member `ReolinkFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/reolink/entity.py:60:5-23: Class member `ReolinkHostCoordinatorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/reolink/entity.py:73:14-29: Class member `ReolinkHostCoordinatorEntity._attr_unique_id` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/reolink/entity.py:81:30-87: `str` is not assignable to attribute `_conf_url` with type `None` [bad-assignment] ERROR homeassistant/components/reolink/light.py:62:9-12: Unexpected keyword argument `key` in function `ReolinkLightEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/reolink/light.py:65:9-24: Unexpected keyword argument `translation_key` in function `ReolinkLightEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/reolink/light.py:77:9-12: Unexpected keyword argument `key` in function `ReolinkLightEntityDescription.__init__` [unexpected-keyword] @@ -23504,7 +22963,6 @@ ERROR homeassistant/components/rflink/__init__.py:270:56-70: Argument `HassJob[[ ERROR homeassistant/components/rflink/__init__.py:278:43-51: Argument `Protocol` is not assignable to parameter `protocol` with type `ProtocolBase | None` in function `homeassistant.components.rflink.entity.RflinkCommand.set_rflink_protocol` [bad-argument-type] ERROR homeassistant/components/rflink/binary_sensor.py:89:14-32: Class member `RflinkBinarySensor._attr_device_class` overrides parent class `RflinkDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/rflink/binary_sensor.py:89:14-32: Class member `RflinkBinarySensor._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/rflink/binary_sensor.py:123:36-125:14: `() -> None` is not assignable to attribute `_delay_listener` with type `None` [bad-assignment] ERROR homeassistant/components/rflink/entity.py:219:22-52: Object of class `NoneType` has no attribute `send_command_ack` Object of class `ProtocolBase` has no attribute `send_command_ack` [missing-attribute] ERROR homeassistant/components/rflink/entity.py:260:40-43: `cmd` may be uninitialized [unbound-name] @@ -23608,7 +23066,6 @@ ERROR homeassistant/components/rfxtrx/config_flow.py:229:48-59: `command_off` ma ERROR homeassistant/components/rfxtrx/config_flow.py:537:69-73: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/rfxtrx/config_flow.py:569:69-73: `data` may be uninitialized [unbound-name] ERROR homeassistant/components/rfxtrx/config_flow.py:601:69-73: `data` may be uninitialized [unbound-name] -ERROR homeassistant/components/rfxtrx/config_flow.py:634:9-31: Class member `RfxtrxConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/rfxtrx/cover.py:52:23-46: Argument `RFXtrxEvent | None` is not assignable to parameter `event` with type `RFXtrxEvent` in function `RfxtrxCover.__init__` [bad-argument-type] ERROR homeassistant/components/rfxtrx/cover.py:64:5-12: Class member `RfxtrxCover._device` overrides parent class `RfxtrxCommandEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/rfxtrx/cover.py:70:40-44: Default `None` is not assignable to parameter `event` with type `RFXtrxEvent` [bad-function-definition] @@ -23701,7 +23158,6 @@ ERROR homeassistant/components/rfxtrx/switch.py:140:36-56: Object of class `RFXt ERROR homeassistant/components/rfxtrx/switch.py:147:36-61: Object of class `RFXtrxDevice` has no attribute `send_command` [missing-attribute] ERROR homeassistant/components/rfxtrx/switch.py:149:36-57: Object of class `RFXtrxDevice` has no attribute `send_off` [missing-attribute] ERROR homeassistant/components/ridwell/__init__.py:40:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/ridwell/config_flow.py:109:9-31: Class member `RidwellConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/ridwell/config_flow.py:122:16-43: `schema_options_flow_handler` may be uninitialized [unbound-name] ERROR homeassistant/components/ridwell/coordinator.py:30:5-17: Class member `RidwellDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/ridwell/sensor.py:30:5-8: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -23806,7 +23262,6 @@ ERROR homeassistant/components/risco/binary_sensor.py:66:9-12: Unexpected keywor ERROR homeassistant/components/risco/binary_sensor.py:67:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/risco/binary_sensor.py:112:5-23: Class member `RiscoCloudBinarySensor._attr_device_class` overrides parent class `RiscoCloudZoneEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/risco/binary_sensor.py:130:5-23: Class member `RiscoLocalBinarySensor._attr_device_class` overrides parent class `RiscoLocalZoneEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/risco/config_flow.py:128:9-31: Class member `RiscoConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/risco/config_flow.py:272:51-75: Cannot index into `bool` [bad-index] ERROR homeassistant/components/risco/config_flow.py:272:63-74: Cannot index into `dict[AlarmControlPanelState, str]` [bad-index] ERROR homeassistant/components/risco/config_flow.py:294:32-50: Object of class `bool` has no attribute `values` [missing-attribute] @@ -23887,7 +23342,6 @@ ERROR homeassistant/components/roborock/button.py:93:25-29: Unexpected keyword a ERROR homeassistant/components/roborock/button.py:108:5-23: Class member `RoborockButtonEntity.entity_description` overrides parent class `RoborockEntityV1` in an inconsistent manner [bad-override] ERROR homeassistant/components/roborock/button.py:108:5-23: Class member `RoborockButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/roborock/button.py:144:5-23: Class member `RoborockRoutineButtonEntity.entity_description` overrides parent class `RoborockEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/roborock/config_flow.py:194:9-31: Class member `RoborockFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/roborock/coordinator.py:69:5-17: Class member `RoborockDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/roborock/coordinator.py:328:5-17: Class member `RoborockDataUpdateCoordinatorA01.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/roborock/image.py:52:5-15: Class member `RoborockMap._attr_name` overrides parent class `RoborockCoordinatedEntityV1` in an inconsistent manner [bad-override] @@ -24047,7 +23501,6 @@ ERROR homeassistant/components/roku/binary_sensor.py:53:9-24: Unexpected keyword ERROR homeassistant/components/roku/binary_sensor.py:77:5-23: Class member `RokuBinarySensorEntity.entity_description` overrides parent class `RokuEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/roku/binary_sensor.py:77:5-23: Class member `RokuBinarySensorEntity.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/roku/browse_media.py:252:18-26: Argument `Literal['', False] | Unknown` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roku/config_flow.py:198:9-31: Class member `RokuConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/roku/coordinator.py:32:5-17: Class member `RokuDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/roku/media_player.py:108:7-22: Field `entity_description` is declared `EntityDescription` in ancestor `class RokuEntity: ... `, which is not assignable to the type `MediaPlayerEntityDescription` implied by multiple inheritance [inconsistent-inheritance] @@ -24104,7 +23557,6 @@ ERROR homeassistant/components/romy/sensor.py:69:9-24: Unexpected keyword argume ERROR homeassistant/components/romy/sensor.py:72:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/romy/sensor.py:96:5-23: Class member `RomySensor.entity_description` overrides parent class `RomyEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/romy/vacuum.py:65:5-29: Class member `RomyVacuumEntity._attr_supported_features` overrides parent class `RomyEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/roomba/config_flow.py:92:9-31: Class member `RoombaConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/roomba/config_flow.py:134:30-53: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/roomba/sensor.py:34:9-12: Unexpected keyword argument `key` in function `RoombaSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/roomba/sensor.py:35:9-24: Unexpected keyword argument `translation_key` in function `RoombaSensorEntityDescription.__init__` [unexpected-keyword] @@ -24153,23 +23605,14 @@ ERROR homeassistant/components/roomba/vacuum.py:119:5-29: Class member `IRobotVa ERROR homeassistant/components/roomba/vacuum.py:200:17-30: `cleaning_time` may be uninitialized [unbound-name] ERROR homeassistant/components/roomba/vacuum.py:200:32-44: `cleaned_area` may be uninitialized [unbound-name] ERROR homeassistant/components/roomba/vacuum.py:363:77-82: `split` is uninitialized [unbound-name] -ERROR homeassistant/components/roon/event.py:66:25-51: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/roon/event.py:65:44-74:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], name=str | None, manufacturer=Literal['RoonLabs'], model=Unknown, via_device=tuple[Literal['roon'], Unknown]) [no-matching-overload] ERROR homeassistant/components/roon/event.py:72:19-28: `dev_model` may be uninitialized [unbound-name] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `media_class` with type `MediaClass | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `media_content_id` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `media_content_type` with type `MediaType | str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `title` with type `str` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `can_play` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `can_expand` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `children` with type `Sequence[BrowseMedia] | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `children_media_class` with type `MediaClass | str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `thumbnail` with type `str | None` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `not_shown` with type `int` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] -ERROR homeassistant/components/roon/media_browser.py:94:24-33: Unpacked keyword argument `MediaClass | bool | str | Unknown | None` is not assignable to parameter `can_search` with type `bool` in function `homeassistant.components.media_player.browse_media.BrowseMedia.__init__` [bad-argument-type] ERROR homeassistant/components/roon/media_browser.py:154:9-37: Object of class `NoneType` has no attribute `append` Object of class `Sequence` has no attribute `append` [missing-attribute] ERROR homeassistant/components/roon/media_player.py:169:19-28: `dev_model` may be uninitialized [unbound-name] -ERROR homeassistant/components/roon/media_player.py:207:26-66: Cannot set item in `dict[str, bool | int]` [unsupported-operation] +ERROR homeassistant/components/roon/media_player.py:207:26-66: `int | None` is not assignable to TypedDict key `step` with type `int` [bad-typed-dict-key] +ERROR homeassistant/components/roon/media_player.py:253:39-53: `int | None` is not assignable to TypedDict key `position` with type `int` [bad-typed-dict-key] +ERROR homeassistant/components/roon/media_player.py:254:39-53: `int | None` is not assignable to TypedDict key `duration` with type `int` [bad-typed-dict-key] ERROR homeassistant/components/roon/server.py:88:16-34: Object of class `NoneType` has no attribute `zones` [missing-attribute] ERROR homeassistant/components/roon/server.py:105:9-26: Object of class `NoneType` has no attribute `stop` [missing-attribute] ERROR homeassistant/components/roon/server.py:124:31-49: Object of class `NoneType` has no attribute `zones` [missing-attribute] @@ -24352,7 +23795,6 @@ ERROR homeassistant/components/sanix/sensor.py:101:5-23: Class member `SanixSens ERROR homeassistant/components/satel_integra/__init__.py:243:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/satel_integra/alarm_control_panel.py:81:5-29: Class member `SatelIntegraAlarmPanel._attr_supported_features` overrides parent class `SatelIntegraEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/satel_integra/binary_sensor.py:105:14-32: Class member `SatelIntegraBinarySensor._attr_device_class` overrides parent class `SatelIntegraEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/satel_integra/config_flow.py:98:9-31: Class member `SatelConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/saunum/__init__.py:51:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/saunum/climate.py:56:5-29: Class member `LeilSaunaClimate._attr_supported_features` overrides parent class `LeilSaunaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/saunum/coordinator.py:24:5-17: Class member `LeilSaunaCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -24473,12 +23915,8 @@ ERROR homeassistant/components/screenlogic/climate.py:76:5-23: Class member `Scr ERROR homeassistant/components/screenlogic/climate.py:76:5-23: Class member `ScreenLogicClimate.entity_description` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/screenlogic/climate.py:78:5-29: Class member `ScreenLogicClimate._attr_supported_features` overrides parent class `ScreenLogicPushEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/screenlogic/climate.py:78:5-29: Class member `ScreenLogicClimate._attr_supported_features` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/screenlogic/climate.py:140:30-47: Argument `None` is not assignable to parameter `value` with type `int` in function `enum.IntEnum.__new__` [bad-argument-type] -ERROR homeassistant/components/screenlogic/climate.py:181:29-39: `int` is not assignable to attribute `_last_preset` with type `None` [bad-assignment] +ERROR homeassistant/components/screenlogic/climate.py:140:30-47: Argument `Unknown | None` is not assignable to parameter `value` with type `int` in function `enum.IntEnum.__new__` [bad-argument-type] ERROR homeassistant/components/screenlogic/climate.py:207:36-79: Argument `Any | None` is not assignable to parameter `value` with type `str` in function `screenlogicpy.const.common.SLIntEnum.parse` [bad-argument-type] -ERROR homeassistant/components/screenlogic/climate.py:212:33-43: `int` is not assignable to attribute `_last_preset` with type `None` [bad-assignment] -ERROR homeassistant/components/screenlogic/climate.py:219:33-43: `int` is not assignable to attribute `_last_preset` with type `None` [bad-assignment] -ERROR homeassistant/components/screenlogic/config_flow.py:80:9-31: Class member `ScreenlogicConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/screenlogic/config_flow.py:169:48-51: `mac` may be uninitialized [unbound-name] ERROR homeassistant/components/screenlogic/config_flow.py:172:40-43: `mac` may be uninitialized [unbound-name] ERROR homeassistant/components/screenlogic/coordinator.py:39:36-39: Cannot index into `dict[str, dict[str, Any]]` [bad-index] @@ -24689,9 +24127,6 @@ ERROR homeassistant/components/sensibo/select.py:34:9-12: Unexpected keyword arg ERROR homeassistant/components/sensibo/select.py:38:9-24: Unexpected keyword argument `translation_key` in function `SensiboSelectEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sensibo/select.py:77:5-23: Class member `SensiboSelect.entity_description` overrides parent class `SensiboDeviceBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/sensibo/select.py:77:5-23: Class member `SensiboSelect.entity_description` overrides parent class `SelectEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sensibo/select.py:132:13-25: Argument `bool | dict[str, Any] | str | Any` is not assignable to parameter `name` with type `str` in function `pysensibo.SensiboClient.async_set_ac_state_property` [bad-argument-type] -ERROR homeassistant/components/sensibo/select.py:134:13-30: Argument `bool | dict[str, Any] | str | Any` is not assignable to parameter `ac_state` with type `dict[str, Any]` in function `pysensibo.SensiboClient.async_set_ac_state_property` [bad-argument-type] -ERROR homeassistant/components/sensibo/select.py:135:13-34: Argument `bool | dict[str, Any] | str | Any` is not assignable to parameter `assumed_state` with type `bool` in function `pysensibo.SensiboClient.async_set_ac_state_property` [bad-argument-type] ERROR homeassistant/components/sensibo/sensor.py:62:5-8: Unexpected keyword argument `key` in function `SensiboDeviceSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sensibo/sensor.py:63:5-20: Unexpected keyword argument `translation_key` in function `SensiboDeviceSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sensibo/sensor.py:71:9-12: Unexpected keyword argument `key` in function `SensiboMotionSensorEntityDescription.__init__` [unexpected-keyword] @@ -24811,19 +24246,14 @@ ERROR homeassistant/components/sensoterra/sensor.py:73:9-12: Unexpected keyword ERROR homeassistant/components/sensoterra/sensor.py:78:9-24: Unexpected keyword argument `entity_category` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sensoterra/sensor.py:79:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sensoterra/sensor.py:137:14-32: Class member `SensoterraEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sentry/config_flow.py:48:9-31: Class member `SentryConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/senz/climate.py:45:5-29: Class member `SENZClimate._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/senz/sensor.py:35:9-12: Unexpected keyword argument `key` in function `SenzSensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/senz/sensor.py:62:5-23: Class member `SENZSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/senz/sensor.py:62:5-23: Class member `SENZSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/serial/sensor.py:150:34-161:10: `Task[Unknown]` is not assignable to attribute `_serial_loop_task` with type `None` [bad-assignment] -ERROR homeassistant/components/serial/sensor.py:218:52-56: `dict[Unknown, Unknown]` is not assignable to attribute `_attributes` with type `None` [bad-assignment] -ERROR homeassistant/components/serial/sensor.py:226:39-43: `str | Unknown` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/serial_pm/sensor.py:7:1-37: Could not find import of `pmsensor` [missing-import] ERROR homeassistant/components/sesame/lock.py:7:8-17: Could not find import of `pysesame2` [missing-import] -ERROR homeassistant/components/seventeentrack/config_flow.py:56:9-31: Class member `SeventeenTrackConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/seventeentrack/coordinator.py:35:5-17: Class member `SeventeenTrackCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/seventeentrack/sensor.py:42:25-59: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/seventeentrack/sensor.py:41:44-45:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], entry_type=Literal[DeviceEntryType.SERVICE], name=Literal['17Track']) [no-matching-overload] ERROR homeassistant/components/seventeentrack/services.py:141:34-53: Object of class `str` has no attribute `isoformat` [missing-attribute] ERROR homeassistant/components/sfr_box/binary_sensor.py:36:9-12: Unexpected keyword argument `key` in function `SFRBoxBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sfr_box/binary_sensor.py:38:9-24: Unexpected keyword argument `entity_category` in function `SFRBoxBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -25046,12 +24476,11 @@ ERROR homeassistant/components/shelly/config_flow.py:600:25-44: Object of class ERROR homeassistant/components/shelly/config_flow.py:614:21-40: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/shelly/config_flow.py:615:21-40: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/components/shelly/config_flow.py:1075:16-19: `mac` may be uninitialized [unbound-name] -ERROR homeassistant/components/shelly/config_flow.py:1224:9-31: Class member `ShellyConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/shelly/coordinator.py:109:5-17: Class member `ShellyCoordinatorBase.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/shelly/coordinator.py:246:12-28: `new_sleep_period` may be uninitialized [unbound-name] ERROR homeassistant/components/shelly/coordinator.py:247:39-55: `new_sleep_period` may be uninitialized [unbound-name] -ERROR homeassistant/components/shelly/coordinator.py:377:74-84: Cannot index into `dict[str, str]` [bad-index] -ERROR homeassistant/components/shelly/coordinator.py:385:61-71: Cannot index into `dict[str, str]` [bad-index] +ERROR homeassistant/components/shelly/coordinator.py:377:74-84: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR homeassistant/components/shelly/coordinator.py:385:61-71: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/shelly/cover.py:51:9-12: Unexpected keyword argument `key` in function `BlockCoverDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/shelly/cover.py:57:9-12: Unexpected keyword argument `key` in function `RpcCoverDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/shelly/cover.py:107:5-23: Class member `BlockShellyCover.entity_description` overrides parent class `ShellyBlockAttributeEntity` in an inconsistent manner [bad-override] @@ -25579,7 +25008,6 @@ ERROR homeassistant/components/sia/binary_sensor.py:79:5-8: Unexpected keyword a ERROR homeassistant/components/sia/binary_sensor.py:81:5-20: Unexpected keyword argument `entity_category` in function `SIABinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sia/binary_sensor.py:117:5-23: Class member `SIABinarySensor.entity_description` overrides parent class `SIABaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/sia/binary_sensor.py:117:5-23: Class member `SIABinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sia/config_flow.py:102:9-31: Class member `SIAConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/sia/entity.py:55:5-23: Class member `SIABaseEntity.entity_description` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/sia/hub.py:103:34-105:38: Argument `tuple[Literal[80], Literal[40]] | None` is not assignable to parameter `allowed_timeband` with type `tuple[int, int]` in function `pysiaalarm.account.SIAAccount.__init__` [bad-argument-type] ERROR homeassistant/components/sia/hub.py:113:36-119:10: Cannot instantiate `SIAClient` because the following members are abstract: `async_start`, `async_stop` [bad-instantiation] @@ -25611,7 +25039,6 @@ ERROR homeassistant/components/simplisafe/button.py:41:9-12: Unexpected keyword ERROR homeassistant/components/simplisafe/button.py:42:9-24: Unexpected keyword argument `translation_key` in function `SimpliSafeButtonDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/simplisafe/button.py:70:5-23: Class member `SimpliSafeButton.entity_description` overrides parent class `SimpliSafeEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/simplisafe/button.py:70:5-23: Class member `SimpliSafeButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/simplisafe/config_flow.py:70:9-31: Class member `SimpliSafeFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/simplisafe/config_flow.py:143:34-44: `simplisafe` may be uninitialized [unbound-name] ERROR homeassistant/components/simplisafe/config_flow.py:144:64-74: `simplisafe` may be uninitialized [unbound-name] ERROR homeassistant/components/simplisafe/lock.py:58:5-12: Class member `SimpliSafeLock._device` overrides parent class `SimpliSafeEntity` in an inconsistent manner [bad-override] @@ -25628,7 +25055,7 @@ ERROR homeassistant/components/sky_hub/device_tracker.py:7:1-39: Could not find ERROR homeassistant/components/skybeacon/sensor.py:9:1-34: Could not find import of `pygatt` [missing-import] ERROR homeassistant/components/skybeacon/sensor.py:10:1-60: Could not find import of `pygatt.backends` [missing-import] ERROR homeassistant/components/skybeacon/sensor.py:11:1-79: Could not find import of `pygatt.exceptions` [missing-import] -ERROR homeassistant/components/skybeacon/sensor.py:187:29-60: Cannot set item in `dict[str, str]` [unsupported-operation] +ERROR homeassistant/components/skybeacon/sensor.py:187:29-60: `float` is not assignable to TypedDict key `temp` with type `str` [bad-typed-dict-key] ERROR homeassistant/components/skybell/__init__.py:66:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/skybell/binary_sensor.py:22:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/skybell/binary_sensor.py:23:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -25739,7 +25166,6 @@ ERROR homeassistant/components/sleepiq/number.py:170:9-13: Unexpected keyword ar ERROR homeassistant/components/sleepiq/number.py:234:5-23: Class member `SleepIQNumberEntity.entity_description` overrides parent class `SleepIQBedEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/sleepiq/number.py:234:5-23: Class member `SleepIQNumberEntity.entity_description` overrides parent class `NumberEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/slide/cover.py:90:16-19: `pos` may be uninitialized [unbound-name] -ERROR homeassistant/components/slide_local/config_flow.py:45:9-31: Class member `SlideConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/slide_local/coordinator.py:41:5-17: Class member `SlideCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/slide_local/cover.py:45:5-23: Class member `SlideCoverLocal._attr_device_class` overrides parent class `SlideEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/slide_local/switch.py:44:5-23: Class member `SlideSwitch._attr_device_class` overrides parent class `SlideEntity` in an inconsistent manner [bad-override] @@ -26503,7 +25929,6 @@ ERROR homeassistant/components/smhi/sensor.py:269:5-23: Class member `SMHIWeathe ERROR homeassistant/components/smhi/sensor.py:269:5-23: Class member `SMHIWeatherSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/smhi/sensor.py:296:5-23: Class member `SMHIFireSensor.entity_description` overrides parent class `SmhiFireEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/smhi/sensor.py:296:5-23: Class member `SMHIFireSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/smhi/weather.py:168:17-183:18: Expected argument `datetime` to be passed by name in function `homeassistant.components.weather.Forecast.__init__` [unexpected-positional-argument] ERROR homeassistant/components/smlight/binary_sensor.py:38:9-12: Unexpected keyword argument `key` in function `SmBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/smlight/binary_sensor.py:39:9-24: Unexpected keyword argument `translation_key` in function `SmBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/smlight/binary_sensor.py:43:9-12: Unexpected keyword argument `key` in function `SmBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -26849,9 +26274,7 @@ ERROR homeassistant/components/soma/cover.py:132:5-23: Class member `SomaShade._ ERROR homeassistant/components/soma/cover.py:133:5-29: Class member `SomaShade._attr_supported_features` overrides parent class `SomaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/soma/sensor.py:35:5-23: Class member `SomaSensor._attr_device_class` overrides parent class `SomaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/somfy_mylink/__init__.py:59:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/somfy_mylink/config_flow.py:121:9-31: Class member `SomfyConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/somfy_mylink/cover.py:85:14-32: Class member `SomfyShade._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sonarr/config_flow.py:64:9-31: Class member `SonarrConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/sonarr/coordinator.py:46:5-17: Class member `SonarrDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/sonarr/sensor.py:91:9-12: Unexpected keyword argument `key` in function `SonarrSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/sonarr/sensor.py:92:9-24: Unexpected keyword argument `translation_key` in function `SonarrSensorEntityDescription.__init__` [unexpected-keyword] @@ -26876,7 +26299,7 @@ ERROR homeassistant/components/songpal/media_player.py:253:16-37: Object of clas ERROR homeassistant/components/songpal/media_player.py:253:41-70: Object of class `NoneType` has no attribute `wirelessMacAddr` [missing-attribute] ERROR homeassistant/components/songpal/media_player.py:259:12-33: Object of class `NoneType` has no attribute `macAddr` [missing-attribute] ERROR homeassistant/components/songpal/media_player.py:261:12-41: Object of class `NoneType` has no attribute `wirelessMacAddr` [missing-attribute] -ERROR homeassistant/components/songpal/media_player.py:264:25-36: Argument `set[tuple[str, object]]` is not assignable to parameter `connections` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/songpal/media_player.py:263:26-270:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (connections=set[tuple[str, object | Unknown]], identifiers=set[tuple[str, Unknown]], manufacturer=Literal['Sony Corporation'], model=Unknown | None, name=Unknown, sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/songpal/media_player.py:269:24-45: Object of class `NoneType` has no attribute `version` [missing-attribute] ERROR homeassistant/components/songpal/media_player.py:394:22-53: Object of class `NoneType` has no attribute `set_volume` [missing-attribute] ERROR homeassistant/components/songpal/media_player.py:398:22-53: Object of class `NoneType` has no attribute `set_volume` [missing-attribute] @@ -26898,11 +26321,11 @@ ERROR homeassistant/components/sonos/media_browser.py:304:21-38: Expected a call ERROR homeassistant/components/sonos/media_browser.py:497:26-34: Argument `DidlFavorite` is not assignable to parameter `item` with type `MusicServiceItem | None` in function `get_thumbnail_url_full` [bad-argument-type] ERROR homeassistant/components/sonos/media_player.py:116:5-29: Class member `SonosMediaPlayerEntity._attr_supported_features` overrides parent class `SonosEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/sonos/media_player.py:136:5-23: Class member `SonosMediaPlayerEntity._attr_device_class` overrides parent class `SonosEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sonos/media_player.py:230:27-47: Cannot index into `dict[str, tuple[bool, bool] | tuple[bool, str]]` [bad-index] -ERROR homeassistant/components/sonos/media_player.py:235:35-55: Cannot index into `dict[str, tuple[bool, bool] | tuple[bool, str]]` [bad-index] -ERROR homeassistant/components/sonos/media_player.py:317:35-55: Cannot index into `dict[str, tuple[bool, bool] | tuple[bool, str]]` [bad-index] +ERROR homeassistant/components/sonos/media_player.py:230:27-47: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR homeassistant/components/sonos/media_player.py:235:35-55: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR homeassistant/components/sonos/media_player.py:317:35-55: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/sonos/media_player.py:319:13-42: Cannot index into `dict[tuple[bool, bool] | tuple[bool, str], str]` [bad-index] -ERROR homeassistant/components/sonos/media_player.py:325:36-56: Cannot index into `dict[str, tuple[bool, bool] | tuple[bool, str]]` [bad-index] +ERROR homeassistant/components/sonos/media_player.py:325:36-56: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/sonos/media_player.py:328:13-42: Cannot index into `dict[tuple[bool, bool] | tuple[bool, str], str]` [bad-index] ERROR homeassistant/components/sonos/media_player.py:381:22-49: Object of class `DidlFavorite` has no attribute `resource_meta_data` [missing-attribute] ERROR homeassistant/components/sonos/media_player.py:487:46-490:22: Argument `dict[str, dict[str, Any] | str]` is not assignable to parameter `translation_placeholders` with type `dict[str, str] | None` in function `homeassistant.exceptions.HomeAssistantError.__init__` [bad-argument-type] @@ -26916,8 +26339,6 @@ ERROR homeassistant/components/sonos/statistics.py:75:44-73: Cannot set item in ERROR homeassistant/components/sonos/statistics.py:76:43-71: Cannot set item in `dict[str, dict[str, float | int]]` [unsupported-operation] ERROR homeassistant/components/sonos/switch.py:257:16-259:10: Returned type `Alarm | None` is not assignable to declared return type `Alarm` [bad-return] ERROR homeassistant/components/sony_projector/switch.py:8:8-14: Could not find import of `pysdcp` [missing-import] -ERROR homeassistant/components/sony_projector/switch.py:100:27-35: `Literal['on']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/sony_projector/switch.py:109:27-36: `Literal['off']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/soundtouch/__init__.py:136:51-138:10: Unpacked argument `tuple[Any]` is not assignable to parameter `*args` with type `tuple[Unknown, int | Unknown]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/soundtouch/__init__.py:154:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/soundtouch/config_flow.py:84:56-86: Unpacked argument `tuple[str | None]` is not assignable to parameter `*args` with type `tuple[Unknown, int | Unknown]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] @@ -26934,7 +26355,6 @@ ERROR homeassistant/components/soundtouch/media_player.py:215:16-34: Object of c ERROR homeassistant/components/soundtouch/media_player.py:220:16-34: Object of class `NoneType` has no attribute `album` [missing-attribute] ERROR homeassistant/components/spaceapi/__init__.py:305:32-308:14: Cannot set item in `dict[str, int | str]` [unsupported-operation] ERROR homeassistant/components/spaceapi/__init__.py:348:21-48: Object of class `float` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/speedtestdotnet/config_flow.py:33:9-31: Class member `SpeedTestFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/speedtestdotnet/coordinator.py:23:5-17: Class member `SpeedTestDataCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/speedtestdotnet/sensor.py:44:9-12: Unexpected keyword argument `key` in function `SpeedtestSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/speedtestdotnet/sensor.py:45:9-24: Unexpected keyword argument `translation_key` in function `SpeedtestSensorEntityDescription.__init__` [unexpected-keyword] @@ -26946,7 +26366,6 @@ ERROR homeassistant/components/speedtestdotnet/sensor.py:85:5-23: Class member ` ERROR homeassistant/components/speedtestdotnet/sensor.py:85:5-23: Class member `SpeedtestSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/splunk/__init__.py:9:1-56: Could not find import of `hass_splunk` [missing-import] ERROR homeassistant/components/spotify/coordinator.py:57:5-17: Class member `SpotifyCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/sql/config_flow.py:173:9-31: Class member `SQLConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/sql/config_flow.py:198:31-52: `db_url_for_validation` may be uninitialized [unbound-name] ERROR homeassistant/components/sql/sensor.py:284:17-31: `rendered_query` is uninitialized [unbound-name] ERROR homeassistant/components/sql/sensor.py:295:51-54: Cannot set item in `dict[str, Any]` [unsupported-operation] @@ -27016,7 +26435,6 @@ ERROR homeassistant/components/squeezebox/button.py:90:9-12: Unexpected keyword ERROR homeassistant/components/squeezebox/button.py:91:9-24: Unexpected keyword argument `translation_key` in function `SqueezeboxButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/squeezebox/button.py:145:5-23: Class member `SqueezeboxButtonEntity.entity_description` overrides parent class `SqueezeboxEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/squeezebox/button.py:145:5-23: Class member `SqueezeboxButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/squeezebox/config_flow.py:101:9-31: Class member `SqueezeboxConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/squeezebox/config_flow.py:159:44-58: Argument `int | list[Unknown] | str | Unknown` is not assignable to parameter `unique_id` with type `str | None` in function `homeassistant.config_entries.ConfigFlow.async_set_unique_id` [bad-argument-type] ERROR homeassistant/components/squeezebox/coordinator.py:36:5-17: Class member `LMSStatusDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/squeezebox/coordinator.py:46:18-26: Argument `str | None` is not assignable to parameter `name` with type `str` in function `homeassistant.helpers.update_coordinator.DataUpdateCoordinator.__init__` [bad-argument-type] @@ -27096,7 +26514,7 @@ ERROR homeassistant/components/starline/button.py:54:5-23: Class member `Starlin ERROR homeassistant/components/starline/config_flow.py:194:68-196:14: Unpacked argument `tuple[str | None, str | None]` is not assignable to parameter `*args` with type `tuple[str, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/starline/config_flow.py:197:69-199:14: Unpacked argument `tuple[str | None, str | None, str]` is not assignable to parameter `*args` with type `tuple[str, str, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/starline/config_flow.py:210:65-218:14: Unpacked argument `tuple[str, str | None, str | None, str | None, str | None, str | None]` is not assignable to parameter `*args` with type `tuple[str, str, str, str, str, str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/starline/config_flow.py:246:51-248:10: Unpacked argument `tuple[None]` is not assignable to parameter `*args` with type `tuple[str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] +ERROR homeassistant/components/starline/config_flow.py:246:51-248:10: Unpacked argument `tuple[Unknown | None]` is not assignable to parameter `*args` with type `tuple[str]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/starline/sensor.py:30:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starline/sensor.py:31:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starline/sensor.py:37:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -27162,7 +26580,6 @@ ERROR homeassistant/components/starlink/button.py:43:5-23: Class member `Starlin ERROR homeassistant/components/starlink/button.py:52:9-12: Unexpected keyword argument `key` in function `StarlinkButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starlink/button.py:54:9-24: Unexpected keyword argument `entity_category` in function `StarlinkButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starlink/coordinator.py:56:5-17: Class member `StarlinkUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/starlink/coordinator.py:83:36-56: `int` is not assignable to attribute `history_stats_start` with type `None` [bad-assignment] ERROR homeassistant/components/starlink/device_tracker.py:42:9-12: Unexpected keyword argument `key` in function `StarlinkDeviceTrackerEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starlink/device_tracker.py:43:9-24: Unexpected keyword argument `translation_key` in function `StarlinkDeviceTrackerEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/starlink/device_tracker.py:44:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `StarlinkDeviceTrackerEntityDescription.__init__` [unexpected-keyword] @@ -27252,7 +26669,6 @@ ERROR homeassistant/components/statistics/config_flow.py:198:73-200:10: No match ERROR homeassistant/components/statistics/config_flow.py:205:60-82: Argument `_HandlerT` is not assignable to parameter `entry_id` with type `str` in function `homeassistant.config_entries.ConfigEntries.async_get_entry` [bad-argument-type] ERROR homeassistant/components/statistics/config_flow.py:211:60-82: Argument `_HandlerT` is not assignable to parameter `entry_id` with type `str` in function `homeassistant.config_entries.ConfigEntries.async_get_entry` [bad-argument-type] ERROR homeassistant/components/statistics/sensor.py:674:14-24: Class member `StatisticsSensor._attr_name` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/steam_online/config_flow.py:41:9-31: Class member `SteamFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/steam_online/config_flow.py:76:27-31: `name` may be uninitialized [unbound-name] ERROR homeassistant/components/steam_online/config_flow.py:78:72-76: `name` may be uninitialized [unbound-name] ERROR homeassistant/components/steam_online/coordinator.py:26:5-17: Class member `SteamDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -27308,7 +26724,6 @@ ERROR homeassistant/components/streamlabswater/sensor.py:51:9-24: Unexpected key ERROR homeassistant/components/streamlabswater/sensor.py:78:5-23: Class member `StreamLabsSensor.entity_description` overrides parent class `StreamlabsWaterEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/streamlabswater/sensor.py:78:5-23: Class member `StreamLabsSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/subaru/__init__.py:60:13-17: Argument `None` is not assignable to parameter `device_name` with type `str` in function `subarulink.controller.Controller.__init__` [bad-argument-type] -ERROR homeassistant/components/subaru/config_flow.py:105:9-31: Class member `SubaruConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/subaru/config_flow.py:128:17-21: Argument `None` is not assignable to parameter `pin` with type `str` in function `subarulink.controller.Controller.__init__` [bad-argument-type] ERROR homeassistant/components/subaru/device_tracker.py:58:14-31: Class member `SubaruDeviceTracker._attr_device_info` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/subaru/sensor.py:54:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -27334,8 +26749,8 @@ ERROR homeassistant/components/subaru/sensor.py:128:9-24: Unexpected keyword arg ERROR homeassistant/components/subaru/sensor.py:134:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/subaru/sensor.py:135:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/subaru/sensor.py:199:14-32: Class member `SubaruSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/subaru/sensor.py:262:67-70: Cannot index into `dict[str, str]` [bad-index] -ERROR homeassistant/components/subaru/sensor.py:265:75-78: Cannot index into `dict[str, str]` [bad-index] +ERROR homeassistant/components/subaru/sensor.py:262:67-70: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR homeassistant/components/subaru/sensor.py:265:75-78: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/suez_water/coordinator.py:63:5-17: Class member `SuezWaterCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/suez_water/sensor.py:36:9-12: Unexpected keyword argument `key` in function `SuezWaterSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/suez_water/sensor.py:37:9-24: Unexpected keyword argument `translation_key` in function `SuezWaterSensorEntityDescription.__init__` [unexpected-keyword] @@ -27376,8 +26791,7 @@ ERROR homeassistant/components/surepetcare/sensor.py:91:5-23: Class member `Fela ERROR homeassistant/components/swiss_hydrological_data/sensor.py:8:1-42: Could not find import of `swisshydrodata` [missing-import] ERROR homeassistant/components/swiss_hydrological_data/sensor.py:106:19-48: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/swiss_public_transport/coordinator.py:59:5-17: Class member `SwissPublicTransportDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/swiss_public_transport/coordinator.py:114:23-47: Argument `None` is not assignable to parameter `start` with type `str` in function `DataConnection.__init__` [bad-argument-type] -ERROR homeassistant/components/swiss_public_transport/coordinator.py:115:29-51: Argument `None` is not assignable to parameter `destination` with type `str` in function `DataConnection.__init__` [bad-argument-type] +ERROR homeassistant/components/swiss_public_transport/coordinator.py:108:27-119:14: No matching overload found for function `DataConnection.__init__` called with arguments: (departure=datetime | None, train_number=Unknown, platform=Unknown, transfers=Unknown, duration=int | None, start=None, destination=None, remaining_time=str, delay=Unknown, line=Unknown) [no-matching-overload] ERROR homeassistant/components/swiss_public_transport/sensor.py:49:13-16: Unexpected keyword argument `key` in function `SwissPublicTransportSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/swiss_public_transport/sensor.py:50:13-28: Unexpected keyword argument `translation_key` in function `SwissPublicTransportSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/swiss_public_transport/sensor.py:58:9-12: Unexpected keyword argument `key` in function `SwissPublicTransportSensorEntityDescription.__init__` [unexpected-keyword] @@ -27485,7 +26899,6 @@ ERROR homeassistant/components/switchbot/climate.py:122:16-47: Object of class ` ERROR homeassistant/components/switchbot/climate.py:127:22-48: Object of class `SwitchbotDevice` has no attribute `set_hvac_mode` [missing-attribute] ERROR homeassistant/components/switchbot/climate.py:134:22-50: Object of class `SwitchbotDevice` has no attribute `set_preset_mode` [missing-attribute] ERROR homeassistant/components/switchbot/climate.py:140:22-57: Object of class `SwitchbotDevice` has no attribute `set_target_temperature` [missing-attribute] -ERROR homeassistant/components/switchbot/config_flow.py:83:9-31: Class member `SwitchbotConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/switchbot/const.py:146:5-164:2: `dict[SwitchbotModel, type[SwitchbotAirPurifier] | type[SwitchbotEvaporativeHumidifier] | type[SwitchbotLock] | type[SwitchbotRelaySwitch] | type[SwitchbotRelaySwitch2PM] | type[SwitchbotRgbicLight] | type[SwitchbotSmartThermostatRadiator] | type[SwitchbotStripLight3]]` is not assignable to `dict[SwitchbotModel, SwitchbotEncryptedDevice]` [bad-assignment] ERROR homeassistant/components/switchbot/cover.py:51:5-12: Class member `SwitchBotCurtainEntity._device` overrides parent class `SwitchbotEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/switchbot/cover.py:52:5-23: Class member `SwitchBotCurtainEntity._attr_device_class` overrides parent class `SwitchbotEntity` in an inconsistent manner [bad-override] @@ -27645,15 +27058,12 @@ ERROR homeassistant/components/switcher_kis/sensor.py:129:14-32: Class member `S ERROR homeassistant/components/switcher_kis/switch.py:166:5-23: Class member `SwitcherShutterChildLockBaseSwitchEntity._attr_device_class` overrides parent class `SwitcherEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/switchmate/switch.py:8:1-34: Could not find import of `switchmate` [missing-import] ERROR homeassistant/components/syncthing/__init__.py:48:12-35: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR homeassistant/components/syncthing/__init__.py:112:29-64: `Task[Unknown]` is not assignable to attribute `_listen_task` with type `None` [bad-assignment] ERROR homeassistant/components/syncthing/__init__.py:155:20-43: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/syncthing/__init__.py:174:16-39: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/syncthing/config_flow.py:36:12-35: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/syncthing/sensor.py:36:12-35: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/syncthing/sensor.py:111:16-36: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/syncthing/sensor.py:127:16-39: Module `aiosyncthing.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR homeassistant/components/syncthing/sensor.py:141:33-143:14: `() -> None` is not assignable to attribute `_unsub_timer` with type `None` [bad-assignment] -ERROR homeassistant/components/syncthing/sensor.py:150:33-37: `None` is not assignable to attribute `_unsub_timer` with type `Never` [bad-assignment] ERROR homeassistant/components/syncthru/binary_sensor.py:41:9-12: Unexpected keyword argument `key` in function `SyncThruBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/syncthru/binary_sensor.py:46:9-12: Unexpected keyword argument `key` in function `SyncThruBinarySensorDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/syncthru/binary_sensor.py:70:5-23: Class member `SyncThruBinarySensor.entity_description` overrides parent class `SyncthruEntity` in an inconsistent manner [bad-override] @@ -27711,19 +27121,10 @@ ERROR homeassistant/components/synology_dsm/camera.py:65:5-23: Class member `Syn ERROR homeassistant/components/synology_dsm/camera.py:76:13-16: Unexpected keyword argument `key` in function `SynologyDSMCameraEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/synology_dsm/camera.py:78:13-17: Unexpected keyword argument `name` in function `SynologyDSMCameraEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/synology_dsm/camera.py:79:13-44: Unexpected keyword argument `entity_registry_enabled_default` in function `SynologyDSMCameraEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/synology_dsm/config_flow.py:133:9-31: Class member `SynologyDSMFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/synology_dsm/config_flow.py:243:57-63: `serial` may be uninitialized [unbound-name] ERROR homeassistant/components/synology_dsm/coordinator.py:75:5-17: Class member `SynologyDSMUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/synology_dsm/entity.py:32:5-23: Class member `SynologyDSMBaseEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/synology_dsm/entity.py:54:14-29: Class member `SynologyDSMBaseEntity._attr_unique_id` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/synology_dsm/entity.py:115:17-118:39: `str` is not assignable to attribute `_device_type` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/entity.py:130:33-49: `str` is not assignable to attribute `_device_type` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/entity.py:140:41-59: `str` is not assignable to attribute `_device_type` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/media_source.py:56:29-43: `str` is not assignable to attribute `album_id` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/media_source.py:61:30-38: `str` is not assignable to attribute `cache_key` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/media_source.py:64:30-38: `str` is not assignable to attribute `file_name` with type `None` [bad-assignment] -ERROR homeassistant/components/synology_dsm/media_source.py:65:16-39: Object of class `NoneType` has no attribute `endswith` [missing-attribute] -ERROR homeassistant/components/synology_dsm/media_source.py:67:34-61: Object of class `NoneType` has no attribute `removesuffix` [missing-attribute] ERROR homeassistant/components/synology_dsm/media_source.py:304:70-76: `shared` may be uninitialized [unbound-name] ERROR homeassistant/components/synology_dsm/sensor.py:57:9-12: Unexpected keyword argument `key` in function `SynologyDSMSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/synology_dsm/sensor.py:58:9-24: Unexpected keyword argument `translation_key` in function `SynologyDSMSensorEntityDescription.__init__` [unexpected-keyword] @@ -28025,7 +27426,6 @@ ERROR homeassistant/components/tado/config_flow.py:75:29-44: Argument `str | Non ERROR homeassistant/components/tado/config_flow.py:110:38-113:14: Argument `dict[str, str | None]` is not assignable to parameter `description_placeholders` with type `Mapping[str, str] | None` in function `homeassistant.data_entry_flow.FlowHandler.async_show_progress` [bad-argument-type] ERROR homeassistant/components/tado/config_flow.py:111:24-39: `tado_device_url` may be uninitialized [unbound-name] ERROR homeassistant/components/tado/config_flow.py:112:25-34: `user_code` may be uninitialized [unbound-name] -ERROR homeassistant/components/tado/config_flow.py:178:9-31: Class member `TadoConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/tado/coordinator.py:43:5-17: Class member `TadoDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/tado/coordinator.py:200:16-20: Returned type `object` is not assignable to declared return type `dict[str, str]` [bad-return] ERROR homeassistant/components/tado/coordinator.py:218:16-58: Returned type `dict[str, object]` is not assignable to declared return type `dict[str, dict[Unknown, Unknown]]` [bad-return] @@ -28141,7 +27541,6 @@ ERROR homeassistant/components/tami4/sensor.py:74:7-28: Field `entity_descriptio ERROR homeassistant/components/tank_utility/sensor.py:9:1-54: Could not find import of `tank_utility` [missing-import] ERROR homeassistant/components/tank_utility/sensor.py:69:53-58: `token` may be uninitialized [unbound-name] ERROR homeassistant/components/tankerkoenig/binary_sensor.py:46:5-23: Class member `StationOpenBinarySensorEntity._attr_device_class` overrides parent class `TankerkoenigCoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/tankerkoenig/config_flow.py:73:9-31: Class member `FlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/tankerkoenig/coordinator.py:37:5-17: Class member `TankerkoenigDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/tapsaff/binary_sensor.py:8:1-28: Could not find import of `tapsaff` [missing-import] ERROR homeassistant/components/tasmota/binary_sensor.py:64:5-20: Class member `TasmotaBinarySensor._tasmota_entity` overrides parent class `TasmotaAvailability` in an inconsistent manner [bad-override] @@ -28176,7 +27575,7 @@ ERROR homeassistant/components/tasmota/switch.py:58:5-20: Class member `TasmotaS ERROR homeassistant/components/tasmota/switch.py:58:5-20: Class member `TasmotaSwitch._tasmota_entity` overrides parent class `TasmotaDiscoveryUpdate` in an inconsistent manner [bad-override] ERROR homeassistant/components/tasmota/switch.py:58:5-20: Class member `TasmotaSwitch._tasmota_entity` overrides parent class `TasmotaOnOffEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tautulli/coordinator.py:33:5-17: Class member `TautulliDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/tautulli/entity.py:35:25-71: Argument `set[tuple[str, int | str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/tautulli/entity.py:32:44-38:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (configuration_url=URL, entry_type=Literal[DeviceEntryType.SERVICE], identifiers=set[tuple[str, int | str | None]], manufacturer=Literal['Tautulli'], name=str | None) [no-matching-overload] ERROR homeassistant/components/tautulli/sensor.py:42:17-27: Type `PyTautulliApiHomeStats` is not iterable [not-iterable] ERROR homeassistant/components/tautulli/sensor.py:59:9-12: Unexpected keyword argument `key` in function `TautulliSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/tautulli/sensor.py:60:9-24: Unexpected keyword argument `translation_key` in function `TautulliSensorEntityDescription.__init__` [unexpected-keyword] @@ -28336,7 +27735,6 @@ ERROR homeassistant/components/tedee/sensor.py:75:5-23: Class member `TedeeSenso ERROR homeassistant/components/telegram_bot/bot.py:455:50-59: Object of class `NoneType` has no attribute `split` [missing-attribute] ERROR homeassistant/components/telegram_bot/bot.py:1112:40-43: `req` may be uninitialized [unbound-name] ERROR homeassistant/components/telegram_bot/bot.py:1115:56-59: `req` may be uninitialized [unbound-name] -ERROR homeassistant/components/telegram_bot/config_flow.py:180:9-31: Class member `TelgramBotConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/telegram_bot/event.py:31:7-29: Field `entity_description` is declared `EntityDescription` in ancestor `class TelegramBotEntity: ... `, which is not assignable to the type `EventEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/telegram_bot/event.py:50:36-39: Unexpected keyword argument `key` in function `homeassistant.components.event.EventEntityDescription.__init__` [unexpected-keyword] @@ -28370,9 +27768,6 @@ ERROR homeassistant/components/tellstick/__init__.py:6:1-68: Could not find impo ERROR homeassistant/components/tellstick/__init__.py:7:1-39: Could not find import of `tellcorenet` [missing-import] ERROR homeassistant/components/tellstick/entity.py:6:1-82: Could not find import of `tellcore.constants` [missing-import] ERROR homeassistant/components/tellstick/entity.py:7:1-42: Could not find import of `tellcore.library` [missing-import] -ERROR homeassistant/components/tellstick/light.py:77:31-51: `bool` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/tellstick/light.py:79:31-35: `Literal[True]` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/tellstick/light.py:81:27-32: `Literal[False]` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/tellstick/sensor.py:8:1-29: Could not find import of `tellcore` [missing-import] ERROR homeassistant/components/tellstick/sensor.py:9:8-48: Could not find import of `tellcore.constants` [missing-import] ERROR homeassistant/components/tellstick/sensor.py:136:38-51: `named_sensors` may be uninitialized [unbound-name] @@ -29599,24 +28994,11 @@ ERROR homeassistant/components/thinkingcleaner/switch.py:36:9-12: Unexpected key ERROR homeassistant/components/thinkingcleaner/switch.py:37:9-13: Unexpected keyword argument `name` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/thinkingcleaner/switch.py:40:9-12: Unexpected keyword argument `key` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/thinkingcleaner/switch.py:41:9-13: Unexpected keyword argument `name` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] -ERROR homeassistant/components/thinkingcleaner/switch.py:101:31-42: `float` is not assignable to attribute `last_lock_time` with type `None` [bad-assignment] -ERROR homeassistant/components/thinkingcleaner/switch.py:120:35-39: `None` is not assignable to attribute `last_lock_time` with type `Never` [bad-assignment] ERROR homeassistant/components/thomson/device_tracker.py:93:29-43: `list[Unknown]` is not assignable to attribute `last_results` with type `dict[Unknown, Unknown]` [bad-assignment] -ERROR homeassistant/components/thread/dataset_store.py:177:32-48: Type `None` is not iterable [not-iterable] ERROR homeassistant/components/thread/dataset_store.py:181:16-20: `data` may be uninitialized [unbound-name] -ERROR homeassistant/components/thread/diagnostics.py:73:10-13: Expected a type form, got instance of `Module[pyroute2.NDB]` [not-a-type] -ERROR homeassistant/components/thread/diagnostics.py:104:26-29: Expected a type form, got instance of `Module[pyroute2.NDB]` [not-a-type] -ERROR homeassistant/components/thread/diagnostics.py:122:10-13: Expected a callable, got `Module[pyroute2.NDB]` [not-callable] +ERROR homeassistant/components/thread/diagnostics.py:32:26-29: Could not import `NDB` from `pyroute2` [missing-module-attribute] +ERROR homeassistant/components/thread/diagnostics.py:120:26-29: Could not import `NDB` from `pyroute2` [missing-module-attribute] ERROR homeassistant/components/thread/diagnostics.py:179:18-49: Cannot set item in `dict[str, Router]` [unsupported-operation] -ERROR homeassistant/components/thread/diagnostics.py:195:21-44: Object of class `NoneType` has no attribute `update` -Object of class `list` has no attribute `update` -Object of class `str` has no attribute `update` [missing-attribute] -ERROR homeassistant/components/thread/diagnostics.py:198:21-50: Cannot set item in `list[str]` [unsupported-operation] -ERROR homeassistant/components/thread/diagnostics.py:198:21-50: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/thread/diagnostics.py:198:21-50: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/thread/diagnostics.py:200:36-57: Object of class `NoneType` has no attribute `keys` -Object of class `list` has no attribute `keys` -Object of class `str` has no attribute `keys` [missing-attribute] ERROR homeassistant/components/threshold/config_flow.py:121:60-82: Argument `_HandlerT` is not assignable to parameter `entry_id` with type `str` in function `homeassistant.config_entries.ConfigEntries.async_get_entry` [bad-argument-type] ERROR homeassistant/components/tibber/coordinator.py:39:5-17: Class member `TibberDataCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/tibber/sensor.py:86:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -29675,7 +29057,7 @@ ERROR homeassistant/components/tibber/sensor.py:255:9-24: Unexpected keyword arg ERROR homeassistant/components/tibber/sensor.py:452:14-32: Class member `TibberDataSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tibber/sensor.py:480:14-32: Class member `TibberSensorRT.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tibber/sensor.py:555:33-56: Object of class `NoneType` has no attribute `replace` [missing-attribute] -ERROR homeassistant/components/tibber/sensor.py:561:64-79: Cannot index into `dict[str, str]` [bad-index] +ERROR homeassistant/components/tibber/sensor.py:561:64-79: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] ERROR homeassistant/components/tikteck/light.py:8:8-15: Could not find import of `tikteck` [missing-import] ERROR homeassistant/components/tikteck/light.py:73:31-37: `list[int]` is not assignable to attribute `_attr_hs_color` with type `tuple[float, float] | None` [bad-assignment] ERROR homeassistant/components/tile/binary_sensor.py:30:9-12: Unexpected keyword argument `key` in function `TileBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -29777,7 +29159,6 @@ ERROR homeassistant/components/tolo/switch.py:58:5-23: Class member `ToloSwitchE ERROR homeassistant/components/tolo/switch.py:58:5-23: Class member `ToloSwitchEntity.entity_description` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tomato/device_tracker.py:69:18-31: Module `requests.auth` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/tomorrowio/__init__.py:35:11-22: `coordinator` may be uninitialized [unbound-name] -ERROR homeassistant/components/tomorrowio/config_flow.py:120:9-31: Class member `TomorrowioConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/tomorrowio/coordinator.py:119:5-17: Class member `TomorrowioDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/tomorrowio/sensor.py:111:9-12: Unexpected keyword argument `key` in function `TomorrowioSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/tomorrowio/sensor.py:112:9-24: Unexpected keyword argument `translation_key` in function `TomorrowioSensorEntityDescription.__init__` [unexpected-keyword] @@ -29864,21 +29245,15 @@ ERROR homeassistant/components/toon/climate.py:91:27-74: No matching overload fo ERROR homeassistant/components/toon/climate.py:112:58-69: Argument `Any | None` is not assignable to parameter `temperature` with type `float` in function `toonapi.toon.Toon.set_current_setpoint` [bad-argument-type] ERROR homeassistant/components/toon/coordinator.py:31:5-17: Class member `ToonDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/toon/coordinator.py:153:20-44: Returned type `Status | None` is not assignable to declared return type `Status` [bad-return] -ERROR homeassistant/components/toon/entity.py:26:25-59: Argument `set[tuple[str, str | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/toon/entity.py:25:26-31:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | None]], manufacturer=Literal['Eneco'], model=Unknown, name=Literal['Toon Display'], sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/toon/entity.py:28:19-64: Object of class `NoneType` has no attribute `rpartition` [missing-attribute] ERROR homeassistant/components/toon/entity.py:30:24-69: Object of class `NoneType` has no attribute `rpartition` [missing-attribute] -ERROR homeassistant/components/toon/entity.py:43:25-45:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:46:24-50:14: Argument `tuple[Literal['toon'], str | None, Literal['meter_adapter']]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:63:25-65:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:66:24-70:14: Argument `tuple[Literal['toon'], str | None, Literal['electricity']]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:83:25-85:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:86:24-90:14: Argument `tuple[Literal['toon'], str | None, Literal['electricity']]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:103:25-105:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:106:24-110:14: Argument `tuple[Literal['toon'], str | None, Literal['meter_adapter']]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:124:25-130:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:131:24-46: Argument `tuple[Literal['toon'], str | None]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:144:25-146:14: Argument `set[tuple[str, str | None, str]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] -ERROR homeassistant/components/toon/entity.py:147:24-151:14: Argument `tuple[Literal['toon'], str | None, Literal['boiler_module']]` is not assignable to parameter `via_device` with type `tuple[str, str]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/toon/entity.py:41:26-51:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Electricity Meter'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None, Literal['meter_adapter']]) [no-matching-overload] +ERROR homeassistant/components/toon/entity.py:61:26-71:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Gas Meter'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None, Literal['electricity']]) [no-matching-overload] +ERROR homeassistant/components/toon/entity.py:81:26-91:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Water Meter'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None, Literal['electricity']]) [no-matching-overload] +ERROR homeassistant/components/toon/entity.py:101:26-111:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Solar Panels'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None, Literal['meter_adapter']]) [no-matching-overload] +ERROR homeassistant/components/toon/entity.py:121:26-132:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Boiler Module'], manufacturer=Literal['Eneco'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None]) [no-matching-overload] +ERROR homeassistant/components/toon/entity.py:142:26-152:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (name=Literal['Boiler'], identifiers=set[tuple[str, str | None, str]], via_device=tuple[Literal['toon'], str | None, Literal['boiler_module']]) [no-matching-overload] ERROR homeassistant/components/toon/sensor.py:72:5-23: Class member `ToonSensor.entity_description` overrides parent class `ToonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/toon/sensor.py:72:5-23: Class member `ToonSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/toon/sensor.py:134:9-12: Unexpected keyword argument `key` in function `ToonSensorEntityDescription.__init__` [unexpected-keyword] @@ -30020,19 +29395,14 @@ ERROR homeassistant/components/totalconnect/button.py:86:5-23: Class member `Tot ERROR homeassistant/components/totalconnect/button.py:86:5-23: Class member `TotalConnectPanelButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/totalconnect/config_flow.py:55:64-57:18: Unpacked argument `tuple[str, str, None]` is not assignable to parameter `*args` with type `tuple[str, str, dict[str, str] | None, bool, int, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/totalconnect/config_flow.py:156:51-161:14: Unpacked argument `tuple[str | None, str, dict[int, str | None]]` is not assignable to parameter `*args` with type `tuple[str, str, dict[str, str] | None, bool, int, bool]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/totalconnect/config_flow.py:188:9-31: Class member `TotalConnectConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/totalconnect/coordinator.py:29:5-17: Class member `TotalConnectDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/totalconnect/diagnostics.py:40:19-44: Object of class `NoneType` has no attribute `_master_user` [missing-attribute] ERROR homeassistant/components/totalconnect/diagnostics.py:41:23-47: Object of class `NoneType` has no attribute `_user_admin` [missing-attribute] ERROR homeassistant/components/totalconnect/diagnostics.py:42:25-51: Object of class `NoneType` has no attribute `_config_admin` [missing-attribute] ERROR homeassistant/components/totalconnect/diagnostics.py:43:29-58: Object of class `NoneType` has no attribute `security_problem` [missing-attribute] ERROR homeassistant/components/totalconnect/diagnostics.py:44:21-43: Object of class `NoneType` has no attribute `_features` [missing-attribute] -ERROR homeassistant/components/totalconnect/diagnostics.py:61:35-37: Cannot set item in `dict[str, ArmingState | bool | dict[Unknown, Unknown] | int | str | None]` [unsupported-operation] -ERROR homeassistant/components/totalconnect/diagnostics.py:74:38-40: Cannot set item in `dict[str, ArmingState | bool | dict[Unknown, Unknown] | int | str | None]` [unsupported-operation] -ERROR homeassistant/components/totalconnect/diagnostics.py:90:33-35: Cannot set item in `dict[str, ArmingState | bool | dict[Unknown, Unknown] | int | str | None]` [unsupported-operation] -ERROR homeassistant/components/totalconnect/entity.py:32:25-57: Argument `set[tuple[str, Any | None]]` is not assignable to parameter `identifiers` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/totalconnect/entity.py:31:44-35:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Any | None]], name=Any | None, serial_number=Any | None) [no-matching-overload] ERROR homeassistant/components/touchline/climate.py:7:1-45: Could not find import of `pytouchline_extended` [missing-import] -ERROR homeassistant/components/touchline/climate.py:101:40-53: `Literal[HVACMode.HEAT]` is not assignable to attribute `_current_operation_mode` with type `None` [bad-assignment] ERROR homeassistant/components/touchline_sl/climate.py:43:5-29: Class member `TouchlineSLZone._attr_supported_features` overrides parent class `TouchlineSLZoneEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/touchline_sl/climate.py:102:38-51: Object of class `LocalScheduleModel` has no attribute `name` Object of class `NoneType` has no attribute `name` [missing-attribute] @@ -30069,6 +29439,7 @@ ERROR homeassistant/components/tplink/camera.py:46:9-24: Unexpected keyword argu ERROR homeassistant/components/tplink/camera.py:95:5-29: Class member `TPLinkCameraEntity._attr_supported_features` overrides parent class `CoordinatedTPLinkModuleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tplink/camera.py:97:5-23: Class member `TPLinkCameraEntity.entity_description` overrides parent class `CoordinatedTPLinkModuleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tplink/camera.py:97:5-23: Class member `TPLinkCameraEntity.entity_description` overrides parent class `Camera` in an inconsistent manner [bad-override] +ERROR homeassistant/components/tplink/camera.py:157:38-159:22: No matching overload found for function `homeassistant.config_entries.ConfigFlowContext.__init__` called with arguments: (reauth_source=Literal['camera_credentials']) [no-matching-overload] ERROR homeassistant/components/tplink/camera.py:228:17-30: Argument `asyncio.streams.StreamReader` is not assignable to parameter `stream` with type `aiohttp.streams.StreamReader` in function `homeassistant.helpers.aiohttp_client.async_aiohttp_proxy_stream` [bad-argument-type] ERROR homeassistant/components/tplink/climate.py:64:9-12: Unexpected keyword argument `key` in function `TPLinkClimateEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/tplink/climate.py:105:5-29: Class member `TPLinkClimateEntity._attr_supported_features` overrides parent class `CoordinatedTPLinkModuleEntity` in an inconsistent manner [bad-override] @@ -30087,7 +29458,7 @@ ERROR homeassistant/components/tplink/config_flow.py:486:66-68: `pw` may be unin ERROR homeassistant/components/tplink/config_flow.py:491:58-60: `un` may be uninitialized [unbound-name] ERROR homeassistant/components/tplink/config_flow.py:491:62-64: `pw` may be uninitialized [unbound-name] ERROR homeassistant/components/tplink/config_flow.py:580:16-27: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/components/tplink/config_flow.py:582:24-43: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/components/tplink/config_flow.py:582:24-43: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/components/tplink/coordinator.py:42:5-17: Class member `TPLinkDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/tplink/coordinator.py:122:41-57: `stale_device_ids` may be uninitialized [unbound-name] ERROR homeassistant/components/tplink/coordinator.py:142:20-37: `child_coordinator` may be uninitialized [unbound-name] @@ -30245,7 +29616,6 @@ ERROR homeassistant/components/traccar/__init__.py:93:31-42: `requestdata` may b ERROR homeassistant/components/traccar/__init__.py:95:39-50: `requestdata` may be uninitialized [unbound-name] ERROR homeassistant/components/traccar/device_tracker.py:129:14-31: Class member `TraccarEntity._attr_device_info` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/traccar/device_tracker.py:129:34-132:10: `DeviceInfo` is not assignable to attribute `_attr_device_info` with type `None` [bad-assignment] -ERROR homeassistant/components/traccar/device_tracker.py:142:34-144:10: `() -> None` is not assignable to attribute `_unsub_dispatcher` with type `None` [bad-assignment] ERROR homeassistant/components/traccar/device_tracker.py:176:9-31: Expected a callable, got `None` [not-callable] ERROR homeassistant/components/traccar_server/__init__.py:93:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/traccar_server/binary_sensor.py:40:9-12: Unexpected keyword argument `key` in function `TraccarServerBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -30254,7 +29624,6 @@ ERROR homeassistant/components/traccar_server/binary_sensor.py:47:9-12: Unexpect ERROR homeassistant/components/traccar_server/binary_sensor.py:49:9-24: Unexpected keyword argument `translation_key` in function `TraccarServerBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/traccar_server/binary_sensor.py:77:5-23: Class member `TraccarServerBinarySensor.entity_description` overrides parent class `TraccarServerEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/traccar_server/binary_sensor.py:77:5-23: Class member `TraccarServerBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/traccar_server/config_flow.py:219:9-31: Class member `TraccarServerConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/traccar_server/coordinator.py:54:5-17: Class member `TraccarServerCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/traccar_server/coordinator.py:180:31-40: `device_id` may be uninitialized [unbound-name] ERROR homeassistant/components/traccar_server/coordinator.py:186:21-30: `device_id` may be uninitialized [unbound-name] @@ -30275,6 +29644,7 @@ ERROR homeassistant/components/traccar_server/sensor.py:75:9-12: Unexpected keyw ERROR homeassistant/components/traccar_server/sensor.py:77:9-24: Unexpected keyword argument `translation_key` in function `TraccarServerSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/traccar_server/sensor.py:105:5-23: Class member `TraccarServerSensor.entity_description` overrides parent class `TraccarServerEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/traccar_server/sensor.py:105:5-23: Class member `TraccarServerSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/trace/models.py:101:31-70: Cannot set item in `dict[str, Materialization]` [unsupported-operation] ERROR homeassistant/components/tractive/__init__.py:62:14-33: Module `aiotractive.tracker` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/tractive/__init__.py:92:12-34: Module `aiotractive.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/tractive/__init__.py:95:12-34: Module `aiotractive.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -30385,7 +29755,6 @@ ERROR homeassistant/components/trafikverket_ferry/sensor.py:83:9-24: Unexpected ERROR homeassistant/components/trafikverket_ferry/sensor.py:87:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `TrafikverketSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/trafikverket_ferry/sensor.py:112:5-23: Class member `FerrySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/trafikverket_ferry/sensor.py:112:5-23: Class member `FerrySensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/trafikverket_train/config_flow.py:111:9-31: Class member `TVTrainConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/trafikverket_train/coordinator.py:74:5-17: Class member `TVDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/trafikverket_train/sensor.py:40:9-12: Unexpected keyword argument `key` in function `TrafikverketSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/trafikverket_train/sensor.py:41:9-24: Unexpected keyword argument `translation_key` in function `TrafikverketSensorEntityDescription.__init__` [unexpected-keyword] @@ -30460,7 +29829,6 @@ ERROR homeassistant/components/trafikverket_weatherstation/sensor.py:199:9-40: U ERROR homeassistant/components/trafikverket_weatherstation/sensor.py:227:5-23: Class member `TrafikverketWeatherStation.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/trafikverket_weatherstation/sensor.py:227:5-23: Class member `TrafikverketWeatherStation.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/transmission/__init__.py:151:32-35: `new` may be uninitialized [unbound-name] -ERROR homeassistant/components/transmission/config_flow.py:62:9-31: Class member `TransmissionFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/transmission/coordinator.py:36:5-17: Class member `TransmissionDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/transmission/coordinator.py:118:36-62: `list[Never]` is not assignable to attribute `_completed_torrents` with type `list[Torrent]` [bad-assignment] ERROR homeassistant/components/transmission/coordinator.py:139:34-58: `list[Never]` is not assignable to attribute `_started_torrents` with type `list[Torrent]` [bad-assignment] @@ -30512,6 +29880,7 @@ ERROR homeassistant/components/travisci/sensor.py:66:9-12: Unexpected keyword ar ERROR homeassistant/components/travisci/sensor.py:67:9-13: Unexpected keyword argument `name` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/travisci/sensor.py:68:9-13: Unexpected keyword argument `icon` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/trend/binary_sensor.py:197:14-32: Class member `SensorTrend._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] +ERROR homeassistant/components/tts/__init__.py:86:5-19: Name `SampleFormat` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR homeassistant/components/tts/__init__.py:292:53-72: Unpacked keyword argument `object` is not assignable to parameter `engine` with type `str` in function `SpeechManager.async_create_result_stream` [bad-argument-type] ERROR homeassistant/components/tts/__init__.py:292:53-72: Unpacked keyword argument `object` is not assignable to parameter `use_file_cache` with type `bool | None` in function `SpeechManager.async_create_result_stream` [bad-argument-type] ERROR homeassistant/components/tts/__init__.py:292:53-72: Unpacked keyword argument `object` is not assignable to parameter `language` with type `str | None` in function `SpeechManager.async_create_result_stream` [bad-argument-type] @@ -30682,28 +30051,6 @@ ERROR homeassistant/components/tuya/cover.py:350:5-23: Class member `TuyaCoverEn ERROR homeassistant/components/tuya/cover.py:368:14-38: Class member `TuyaCoverEntity._attr_supported_features` overrides parent class `TuyaEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/tuya/diagnostics.py:51:8-25: Object of class `NoneType` has no attribute `client` [missing-attribute] ERROR homeassistant/components/tuya/diagnostics.py:52:26-56: Object of class `object` has no attribute `is_connected` [missing-attribute] -ERROR homeassistant/components/tuya/diagnostics.py:108:13-35: Cannot set item in `bool` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:108:13-35: Cannot set item in `set[str]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:108:13-35: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:108:13-35: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:108:38-46: Cannot set item in `dict[str, dict[str, dict[str, Any] | str]]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:111:9-31: Cannot set item in `bool` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:111:9-31: Cannot set item in `set[str]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:111:9-31: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:111:9-31: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:115:9-40: Cannot set item in `bool` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:115:9-40: Cannot set item in `set[str]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:115:9-40: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:115:9-40: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:122:9-48: Cannot set item in `bool` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:122:9-48: Cannot set item in `set[str]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:122:9-48: Cannot set item in `str` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:122:9-48: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:132:34-138:10: Cannot set item in `dict[str, bool | dict[str, dict[str, dict[str, Any] | str]] | set[str] | str | None]` [unsupported-operation] -ERROR homeassistant/components/tuya/diagnostics.py:162:13-54: Object of class `DeviceEntryDisabler` has no attribute `append` -Object of class `NoneType` has no attribute `append` -Object of class `bool` has no attribute `append` -Object of class `str` has no attribute `append` [missing-attribute] ERROR homeassistant/components/tuya/event.py:111:13-16: Unexpected keyword argument `key` in function `TuyaEventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/tuya/event.py:113:13-28: Unexpected keyword argument `translation_key` in function `TuyaEventEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/tuya/event.py:117:13-16: Unexpected keyword argument `key` in function `TuyaEventEntityDescription.__init__` [unexpected-keyword] @@ -32209,17 +31556,9 @@ ERROR homeassistant/components/twitch/coordinator.py:49:5-17: Class member `Twit ERROR homeassistant/components/twitch/sensor.py:50:5-23: Class member `TwitchSensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/twitter/notify.py:13:1-34: Could not find import of `TwitterAPI` [missing-import] ERROR homeassistant/components/ubus/device_tracker.py:8:1-30: Could not find import of `openwrt.ubus` [missing-import] -ERROR homeassistant/components/ubus/device_tracker.py:101:25-27: `dict[@_, @_]` is not assignable to attribute `mac2name` with type `None` [bad-assignment] ERROR homeassistant/components/ubus/device_tracker.py:132:29-31: `list[@_]` is not assignable to attribute `last_results` with type `dict[Unknown, Unknown]` [bad-assignment] ERROR homeassistant/components/ubus/device_tracker.py:142:25-49: Object of class `dict` has no attribute `append` [missing-attribute] -ERROR homeassistant/components/ubus/device_tracker.py:165:29-31: `dict[@_, @_]` is not assignable to attribute `mac2name` with type `None` [bad-assignment] -ERROR homeassistant/components/ubus/device_tracker.py:168:17-48: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/ubus/device_tracker.py:179:29-31: `dict[@_, @_]` is not assignable to attribute `mac2name` with type `None` [bad-assignment] -ERROR homeassistant/components/ubus/device_tracker.py:185:21-47: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/uk_transport/sensor.py:146:31-54: `Literal['Usage limits exceeded']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/uk_transport/sensor.py:148:31-52: `Literal['Credentials invalid']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/uk_transport/sensor.py:212:30-49: Cannot set item in `dict[str, list[Unknown]]` [unsupported-operation] -ERROR homeassistant/components/uk_transport/sensor.py:249:31-46: `Literal['No departures']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/ukraine_alarm/__init__.py:42:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/ukraine_alarm/binary_sensor.py:32:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/ukraine_alarm/binary_sensor.py:33:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -32251,7 +31590,6 @@ ERROR homeassistant/components/unifi/button.py:121:9-24: Unexpected keyword argu ERROR homeassistant/components/unifi/button.py:122:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `UnifiButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/unifi/button.py:150:5-23: Class member `UnifiButtonEntity.entity_description` overrides parent class `UnifiEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifi/button.py:150:5-23: Class member `UnifiButtonEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/unifi/config_flow.py:84:9-31: Class member `UnifiFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifi/config_flow.py:141:45-49: `host` may be uninitialized [unbound-name] ERROR homeassistant/components/unifi/device_tracker.py:153:9-12: Unexpected keyword argument `key` in function `UnifiTrackerEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/unifi/device_tracker.py:173:9-12: Unexpected keyword argument `key` in function `UnifiTrackerEntityDescription.__init__` [unexpected-keyword] @@ -32625,7 +31963,6 @@ ERROR homeassistant/components/unifiprotect/button.py:169:5-23: Class member `Pr ERROR homeassistant/components/unifiprotect/button.py:169:5-23: Class member `ProtectButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifiprotect/camera.py:171:5-11: Class member `ProtectCamera.device` overrides parent class `ProtectDeviceEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifiprotect/camera.py:218:14-38: Class member `ProtectCamera._attr_supported_features` overrides parent class `ProtectDeviceEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/unifiprotect/config_flow.py:225:9-31: Class member `ProtectFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifiprotect/entity.py:228:25-45: `last_updated_success` may be uninitialized [unbound-name] ERROR homeassistant/components/unifiprotect/entity.py:237:25-45: `last_updated_success` may be uninitialized [unbound-name] ERROR homeassistant/components/unifiprotect/entity.py:282:5-23: Class member `ProtectIsOnEntity.entity_description` overrides parent class `BaseProtectEntity` in an inconsistent manner [bad-override] @@ -33180,9 +32517,6 @@ ERROR homeassistant/components/unifiprotect/text.py:95:5-23: Class member `Prote ERROR homeassistant/components/unifiprotect/text.py:95:5-23: Class member `ProtectDeviceText.entity_description` overrides parent class `TextEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/unifiprotect/views.py:174:16-22: `camera` may be uninitialized [unbound-name] ERROR homeassistant/components/universal/media_player.py:174:29-33: Argument `None` is not assignable to parameter `object` with type `str` in function `list.append` [bad-argument-type] -ERROR homeassistant/components/universal/media_player.py:669:33-89: `State | None` is not assignable to attribute `_child_state` with type `None` [bad-assignment] -ERROR homeassistant/components/universal/media_player.py:680:45-56: `State` is not assignable to attribute `_child_state` with type `None` [bad-assignment] -ERROR homeassistant/components/universal/media_player.py:682:41-52: `State` is not assignable to attribute `_child_state` with type `None` [bad-assignment] ERROR homeassistant/components/upb/__init__.py:55:9-29: Object of class `NoneType` has no attribute `add_callback` [missing-attribute] ERROR homeassistant/components/upb/config_flow.py:103:52-62: `network_id` may be uninitialized [unbound-name] ERROR homeassistant/components/upb/config_flow.py:107:27-31: `info` may be uninitialized [unbound-name] @@ -33191,7 +32525,6 @@ ERROR homeassistant/components/upb/light.py:61:14-30: Class member `UpbLight._at ERROR homeassistant/components/upc_connect/device_tracker.py:7:1-35: Could not find import of `connect_box` [missing-import] ERROR homeassistant/components/upc_connect/device_tracker.py:8:1-73: Could not find import of `connect_box.exceptions` [missing-import] ERROR homeassistant/components/upcloud/binary_sensor.py:28:5-23: Class member `UpCloudBinarySensor._attr_device_class` overrides parent class `UpCloudServerEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/upcloud/config_flow.py:90:9-31: Class member `UpCloudConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/upcloud/entity.py:75:13-31: Object of class `Server` has no attribute `state` [missing-attribute] ERROR homeassistant/components/upcloud/entity.py:75:33-51: Object of class `Server` has no attribute `state` [missing-attribute] ERROR homeassistant/components/update/__init__.py:181:5-17: Class member `UpdateEntityDescription.device_class` overrides parent class `EntityDescription` in an inconsistent manner [bad-override] @@ -33206,7 +32539,6 @@ ERROR homeassistant/components/upnp/binary_sensor.py:31:9-24: Unexpected keyword ERROR homeassistant/components/upnp/binary_sensor.py:33:9-24: Unexpected keyword argument `entity_category` in function `UpnpBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/upnp/binary_sensor.py:61:5-23: Class member `UpnpStatusBinarySensor.entity_description` overrides parent class `UpnpEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/upnp/binary_sensor.py:61:5-23: Class member `UpnpStatusBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/upnp/config_flow.py:101:9-31: Class member `UpnpFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/upnp/coordinator.py:25:5-17: Class member `UpnpDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/upnp/entity.py:29:5-23: Class member `UpnpEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/upnp/sensor.py:51:9-12: Unexpected keyword argument `key` in function `UpnpSensorEntityDescription.__init__` [unexpected-keyword] @@ -33292,25 +32624,11 @@ ERROR homeassistant/components/uptimerobot/switch.py:58:7-24: Field `entity_desc `, which is not assignable to the type `SwitchEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:264:31-56: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:265:32-57: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:267:23-39: `str` is not assignable to attribute `_place` with type `None` [bad-assignment] -ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:268:27-47: `float` is not assignable to attribute `_magnitude` with type `None` [bad-assignment] -ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:271:24-41: `str` is not assignable to attribute `_status` with type `None` [bad-assignment] -ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:272:22-37: `str` is not assignable to attribute `_type` with type `None` [bad-assignment] -ERROR homeassistant/components/usgs_earthquakes_feed/geo_location.py:273:23-39: `str` is not assignable to attribute `_alert` with type `None` [bad-assignment] ERROR homeassistant/components/utility_meter/__init__.py:277:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/utility_meter/sensor.py:383:26-45: `Unknown | None` is not assignable to attribute `entity_id` with type `str` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:528:34-47: `Decimal` is not assignable to attribute `_last_valid_state` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:541:32-543:14: `() -> None` is not assignable to attribute `_collecting` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:566:32-52: `datetime` is not assignable to attribute `_next_reset` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:573:21-37: Argument `None` is not assignable to parameter `point_in_time` with type `datetime` in function `homeassistant.helpers.event.async_track_point_in_time` [bad-argument-type] +ERROR homeassistant/components/utility_meter/sensor.py:573:21-37: Argument `Unknown | None` is not assignable to parameter `point_in_time` with type `datetime` in function `homeassistant.helpers.event.async_track_point_in_time` [bad-argument-type] ERROR homeassistant/components/utility_meter/sensor.py:598:21-38: Argument `Decimal | date | datetime | float | int | str` is not assignable to parameter `value` with type `Decimal | float | str | tuple[int, Sequence[int], int]` in function `decimal.Decimal.__new__` [bad-argument-type] -ERROR homeassistant/components/utility_meter/sensor.py:615:28-54: `str` is not assignable to attribute `_current_tz` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:627:40-75: `SensorDeviceClass | None` is not assignable to attribute `_input_device_class` with type `None` [bad-assignment] ERROR homeassistant/components/utility_meter/sensor.py:632:32-59: `datetime | None` is not assignable to attribute `_last_reset` with type `datetime` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:633:38-71: `Decimal | None` is not assignable to attribute `_last_valid_state` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:636:36-48: `() -> None` is not assignable to attribute `_collecting` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:665:32-667:14: `() -> None` is not assignable to attribute `_collecting` with type `None` [bad-assignment] -ERROR homeassistant/components/utility_meter/sensor.py:675:36-62: `str` is not assignable to attribute `_current_tz` with type `None` [bad-assignment] ERROR homeassistant/components/v2c/binary_sensor.py:31:9-12: Unexpected keyword argument `key` in function `V2CBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/v2c/binary_sensor.py:32:9-24: Unexpected keyword argument `translation_key` in function `V2CBinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/v2c/binary_sensor.py:37:9-12: Unexpected keyword argument `key` in function `V2CBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -33442,9 +32760,6 @@ ERROR homeassistant/components/valve/__init__.py:133:5-23: Class member `ValveEn ERROR homeassistant/components/valve/__init__.py:135:5-23: Class member `ValveEntity._attr_device_class` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/valve/__init__.py:140:5-29: Class member `ValveEntity._attr_supported_features` overrides parent class `Entity` in an inconsistent manner [bad-override] ERROR homeassistant/components/vasttrafik/sensor.py:8:8-18: Could not find import of `vasttrafik` [missing-import] -ERROR homeassistant/components/vasttrafik/sensor.py:149:32-34: `dict[@_, @_]` is not assignable to attribute `_attributes` with type `None` [bad-assignment] -ERROR homeassistant/components/vasttrafik/sensor.py:160:43-162:48: `str` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/vasttrafik/sensor.py:184:40-78: `dict[str, int | str | Unknown]` is not assignable to attribute `_attributes` with type `None` [bad-assignment] ERROR homeassistant/components/vegehub/__init__.py:44:26-46:6: `VegeHubCoordinator` is not assignable to attribute `runtime_data` with type `VegeHub` [bad-assignment] ERROR homeassistant/components/vegehub/__init__.py:59:61-79: Argument `VegeHub` is not assignable to parameter `coordinator` with type `VegeHubCoordinator` in function `get_webhook_handler` [bad-argument-type] ERROR homeassistant/components/vegehub/coordinator.py:22:5-17: Class member `VegeHubCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -33491,7 +32806,7 @@ ERROR homeassistant/components/velux/cover.py:67:14-32: Class member `VeluxCover ERROR homeassistant/components/velux/light.py:40:5-9: Class member `VeluxLight.node` overrides parent class `VeluxEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/venstar/binary_sensor.py:34:5-23: Class member `VenstarBinarySensor._attr_device_class` overrides parent class `VenstarEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/venstar/binary_sensor.py:46:22-41: Type `None` is not iterable [not-iterable] -ERROR homeassistant/components/venstar/config_flow.py:46:12-23: Returned type `None` is not assignable to declared return type `str` [bad-return] +ERROR homeassistant/components/venstar/config_flow.py:46:12-23: Returned type `Unknown | None` is not assignable to declared return type `str` [bad-return] ERROR homeassistant/components/venstar/coordinator.py:21:5-17: Class member `VenstarDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/venstar/sensor.py:140:5-23: Class member `VenstarSensor.entity_description` overrides parent class `VenstarEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/venstar/sensor.py:140:5-23: Class member `VenstarSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] @@ -33514,7 +32829,6 @@ ERROR homeassistant/components/vera/climate.py:39:28-34: Argument `VeraDevice` i ERROR homeassistant/components/vera/climate.py:51:5-29: Class member `VeraThermostat._attr_supported_features` overrides parent class `VeraEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/vera/climate.py:114:16-48: Returned type `str | None` is not assignable to declared return type `str` [bad-return] ERROR homeassistant/components/vera/climate.py:124:46-74: Argument `Any | None` is not assignable to parameter `temp` with type `float` in function `pyvera.VeraThermostat.set_temperature` [bad-argument-type] -ERROR homeassistant/components/vera/config_flow.py:105:9-31: Class member `VeraFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/vera/cover.py:28:23-29: Argument `VeraDevice` is not assignable to parameter `vera_device` with type `VeraCurtain` in function `VeraCover.__init__` [bad-argument-type] ERROR homeassistant/components/vera/cover.py:60:36-61: Argument `Any | None` is not assignable to parameter `level` with type `int` in function `pyvera.VeraCurtain.set_level` [bad-argument-type] ERROR homeassistant/components/vera/entity.py:49:52-73: Argument `BoundMethod[Self@VeraEntity, (self: Self@VeraEntity, _device: _DeviceTypeT) -> None]` is not assignable to parameter `callback` with type `(VeraDevice) -> None` in function `pyvera.VeraController.register` [bad-argument-type] @@ -33528,12 +32842,10 @@ ERROR homeassistant/components/vera/light.py:74:40-43: Argument `tuple[int, int, ERROR homeassistant/components/vera/lock.py:31:22-28: Argument `VeraDevice` is not assignable to parameter `vera_device` with type `VeraLock` in function `VeraLock.__init__` [bad-argument-type] ERROR homeassistant/components/vera/sensor.py:41:24-30: Argument `VeraDevice` is not assignable to parameter `vera_device` with type `VeraSensor` in function `VeraSensor.__init__` [bad-argument-type] ERROR homeassistant/components/vera/sensor.py:60:18-36: Class member `VeraSensor._attr_device_class` overrides parent class `VeraEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/vera/sensor.py:104:38-42: `str` is not assignable to attribute `last_changed_time` with type `None` [bad-assignment] ERROR homeassistant/components/vera/switch.py:28:24-30: Argument `VeraDevice` is not assignable to parameter `vera_device` with type `VeraSwitch` in function `VeraSwitch.__init__` [bad-argument-type] ERROR homeassistant/components/verisure/alarm_control_panel.py:40:5-29: Class member `VerisureAlarm._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/verisure/binary_sensor.py:45:5-23: Class member `VerisureDoorWindowSensor._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/verisure/binary_sensor.py:99:5-23: Class member `VerisureEthernetStatus._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/verisure/config_flow.py:46:9-31: Class member `VerisureConfigFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/verisure/coordinator.py:28:5-17: Class member `VerisureDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/verisure/sensor.py:50:5-23: Class member `VerisureThermometer._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/verisure/sensor.py:100:5-23: Class member `VerisureHygrometer._attr_device_class` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] @@ -33669,11 +32981,6 @@ ERROR homeassistant/components/vesync/switch.py:136:38-71: Object of class `None ERROR homeassistant/components/vesync/switch.py:143:38-71: Object of class `NoneType` has no attribute `message` [missing-attribute] ERROR homeassistant/components/vesync/update.py:58:5-23: Class member `VeSyncDeviceUpdate._attr_device_class` overrides parent class `VeSyncBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/viaggiatreno/sensor.py:78:66-70: `name` may be uninitialized [unbound-name] -ERROR homeassistant/components/viaggiatreno/sensor.py:174:31-52: `Literal['No information for this train now']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/viaggiatreno/sensor.py:177:31-55: `str` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/viaggiatreno/sensor.py:184:31-47: `Literal['Cancelled']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/viaggiatreno/sensor.py:188:31-50: `Literal['Not departed yet']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/viaggiatreno/sensor.py:191:31-45: `Literal['Arrived']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/vicare/__init__.py:39:30-41:10: `PyViCare` is not assignable to attribute `runtime_data` with type `ViCareData` [bad-assignment] ERROR homeassistant/components/vicare/__init__.py:81:12-54: Returned type `ViCareData` is not assignable to declared return type `PyViCare` [bad-return] ERROR homeassistant/components/vicare/binary_sensor.py:55:9-12: Unexpected keyword argument `key` in function `ViCareBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -34616,22 +33923,14 @@ ERROR homeassistant/components/victron_remote_monitoring/sensor.py:229:9-12: Une ERROR homeassistant/components/victron_remote_monitoring/sensor.py:230:9-24: Unexpected keyword argument `translation_key` in function `VRMForecastsSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/victron_remote_monitoring/sensor.py:266:5-23: Class member `VRMForecastsSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/victron_remote_monitoring/sensor.py:266:5-23: Class member `VRMForecastsSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/vilfo/config_flow.py:45:26-47: Cannot set item in `dict[str, dict[@_, @_] | None]` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:46:26-39: Cannot set item in `dict[str, dict[Unknown, Unknown] | None]` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:53:26-45: Cannot set item in `dict[str, dict[Unknown, Unknown] | None]` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:54:26-37: Cannot set item in `dict[str, dict[Unknown, Unknown] | None]` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:58:9-32: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:59:9-33: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:61:9-32: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:62:9-33: Cannot set item in `None` [unsupported-operation] -ERROR homeassistant/components/vilfo/config_flow.py:64:22-36: Cannot set item in `dict[str, dict[Unknown, Unknown] | None]` [unsupported-operation] +ERROR homeassistant/components/vilfo/config_flow.py:46:26-39: `type[CannotConnect]` is not assignable to TypedDict key `data` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] +ERROR homeassistant/components/vilfo/config_flow.py:54:26-37: `type[InvalidAuth]` is not assignable to TypedDict key `data` with type `dict[Unknown, Unknown]` [bad-typed-dict-key] ERROR homeassistant/components/vilfo/sensor.py:37:9-12: Unexpected keyword argument `key` in function `VilfoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vilfo/sensor.py:38:9-24: Unexpected keyword argument `translation_key` in function `VilfoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vilfo/sensor.py:43:9-12: Unexpected keyword argument `key` in function `VilfoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vilfo/sensor.py:44:9-24: Unexpected keyword argument `translation_key` in function `VilfoSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vilfo/sensor.py:67:5-23: Class member `VilfoRouterSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/vivotek/config_flow.py:104:9-31: Class member `VivotekConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/vizio/config_flow.py:179:9-31: Class member `VizioConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] +ERROR homeassistant/components/vilfo/sensor.py:74:44-80:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, Unknown, Unknown]], name=Literal['Vilfo Router'], manufacturer=Literal['Vilfo AB'], model=Literal['Vilfo Router'], sw_version=Unknown) [no-matching-overload] ERROR homeassistant/components/vizio/config_flow.py:244:25-58: Argument `Any | None` is not assignable to parameter `auth_token` with type `str` in function `pyvizio.VizioAsync.validate_ha_config` [bad-argument-type] ERROR homeassistant/components/vizio/config_flow.py:343:17-30: Argument `str | None` is not assignable to parameter `ch_type` with type `int | str` in function `pyvizio.VizioAsync.pair` [bad-argument-type] ERROR homeassistant/components/vizio/config_flow.py:343:32-51: Argument `str | None` is not assignable to parameter `token` with type `int | str` in function `pyvizio.VizioAsync.pair` [bad-argument-type] @@ -34655,7 +33954,6 @@ ERROR homeassistant/components/vodafone_station/button.py:69:9-24: Unexpected ke ERROR homeassistant/components/vodafone_station/button.py:71:9-24: Unexpected keyword argument `entity_category` in function `VodafoneStationEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vodafone_station/button.py:105:5-23: Class member `VodafoneStationSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/vodafone_station/button.py:105:5-23: Class member `VodafoneStationSensorEntity.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/vodafone_station/config_flow.py:86:9-31: Class member `VodafoneStationConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/vodafone_station/coordinator.py:62:5-17: Class member `VodafoneStationRouter.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/vodafone_station/sensor.py:86:9-12: Unexpected keyword argument `key` in function `VodafoneStationEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/vodafone_station/sensor.py:87:9-24: Unexpected keyword argument `translation_key` in function `VodafoneStationEntityDescription.__init__` [unexpected-keyword] @@ -34858,7 +34156,6 @@ ERROR homeassistant/components/volvo/sensor.py:415:5-23: Class member `VolvoSens ERROR homeassistant/components/volvo/sensor.py:415:5-23: Class member `VolvoSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/w800rf32/__init__.py:6:8-24: Could not find import of `W800rf32` [missing-import] ERROR homeassistant/components/w800rf32/binary_sensor.py:8:8-24: Could not find import of `W800rf32` [missing-import] -ERROR homeassistant/components/w800rf32/binary_sensor.py:130:36-132:14: `() -> None` is not assignable to attribute `_delay_listener` with type `None` [bad-assignment] ERROR homeassistant/components/wallbox/__init__.py:40:28-61: `Any | None` is not assignable to attribute `jwtToken` with type `str` [bad-assignment] ERROR homeassistant/components/wallbox/__init__.py:41:35-76: `Any | None` is not assignable to attribute `jwtRefreshToken` with type `str` [bad-assignment] ERROR homeassistant/components/wallbox/__init__.py:42:31-62: `Any | None` is not assignable to attribute `jwtTokenTtl` with type `int` [bad-assignment] @@ -35086,13 +34383,11 @@ ERROR homeassistant/components/watergate/valve.py:33:5-29: Class member `SonicVa ERROR homeassistant/components/watergate/valve.py:36:5-23: Class member `SonicValve._attr_device_class` overrides parent class `WatergateEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/watson_tts/tts.py:5:1-63: Could not find import of `ibm_cloud_sdk_core.authenticators` [missing-import] ERROR homeassistant/components/watson_tts/tts.py:6:1-38: Could not find import of `ibm_watson` [missing-import] -ERROR homeassistant/components/watttime/config_flow.py:129:9-31: Class member `WattTimeConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/watttime/sensor.py:40:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/watttime/sensor.py:41:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/watttime/sensor.py:46:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/watttime/sensor.py:47:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/watttime/sensor.py:85:14-32: Class member `RealtimeEmissionsSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/waze_travel_time/config_flow.py:143:9-31: Class member `WazeConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/waze_travel_time/coordinator.py:71:26-38: Argument `str` is not assignable to parameter `vehicle_type` with type `Literal['MOTORCYCLE', 'TAXI'] | None` in function `pywaze.route_calculator.WazeRouteCalculator.calc_routes` [bad-argument-type] ERROR homeassistant/components/waze_travel_time/coordinator.py:161:5-17: Class member `WazeTravelTimeCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/waze_travel_time/helpers.py:23:34-49: Argument `str | None` is not assignable to parameter `start` with type `str` in function `pywaze.route_calculator.WazeRouteCalculator.calc_routes` [bad-argument-type] @@ -35323,12 +34618,10 @@ ERROR homeassistant/components/webmin/sensor.py:227:5-23: Class member `WebminSe ERROR homeassistant/components/webmin/sensor.py:249:5-23: Class member `WebminFSSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/webmin/sensor.py:249:5-23: Class member `WebminFSSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/webostv/__init__.py:92:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/webostv/config_flow.py:67:9-31: Class member `FlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/webostv/media_player.py:156:5-23: Class member `LgWebOSMediaPlayerEntity._attr_device_class` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/webostv/media_player.py:219:14-25: Class member `LgWebOSMediaPlayerEntity._attr_state` overrides parent class `RestoreEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/webostv/media_player.py:245:39-62: Cannot index into `dict[str, Any]` [bad-index] ERROR homeassistant/components/webostv/media_player.py:247:38-61: Cannot index into `dict[str, Any]` [bad-index] -ERROR homeassistant/components/webostv/media_player.py:342:40-52: `str` is not assignable to attribute `_current_source` with type `None` [bad-assignment] ERROR homeassistant/components/websocket_api/__init__.py:67:5-13: `handlers` may be uninitialized [unbound-name] ERROR homeassistant/components/websocket_api/connection.py:31:33-58: Expected a type form, got instance of `Literal['ActiveConnection | None']` [not-a-type] ERROR homeassistant/components/websocket_api/connection.py:282:27-39: Module `voluptuous.humanize` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -35405,7 +34698,6 @@ ERROR homeassistant/components/wemo/fan.py:118:36-47: Argument `tuple[Literal[Fa ERROR homeassistant/components/wemo/fan.py:152:54-65: Argument `tuple[Literal[FanMode.Minimum], Literal[FanMode.Maximum]]` is not assignable to parameter `low_high_range` with type `tuple[float, float]` in function `homeassistant.util.percentage.percentage_to_ranged_value` [bad-argument-type] ERROR homeassistant/components/wemo/fan.py:172:36-51: `pywemo_humidity` may be uninitialized [unbound-name] ERROR homeassistant/components/wemo/light.py:84:5-29: Class member `WemoLight._attr_supported_features` overrides parent class `WemoEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/wemo/light.py:196:32-48: Unpacked keyword argument `bool | int | Any` is not assignable to parameter `force_update` with type `bool` in function `pywemo.ouimeaux_device.bridge.Light.turn_on` [bad-argument-type] ERROR homeassistant/components/wemo/light.py:211:5-9: Class member `WemoDimmer.wemo` overrides parent class `WemoBinaryStateEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/wemo/sensor.py:32:5-9: Class member `AttributeSensorDescription.name` overrides parent class `SensorEntityDescription` in an inconsistent manner [bad-override] ERROR homeassistant/components/wemo/sensor.py:43:9-12: Unexpected keyword argument `key` in function `AttributeSensorDescription.__init__` [unexpected-keyword] @@ -35498,12 +34790,6 @@ ERROR homeassistant/components/whois/sensor.py:152:9-24: Unexpected keyword argu ERROR homeassistant/components/whois/sensor.py:155:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `WhoisSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/whois/sensor.py:187:5-23: Class member `WhoisSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/whois/sensor.py:187:5-23: Class member `WhoisSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/whois/sensor.py:241:16-21: Returned type `dict[str, Never]` is not assignable to declared return type `dict[str, float | int | None] | None` [bad-return] -ERROR homeassistant/components/wiffi/__init__.py:79:24-74: `WiffiTcpServer` is not assignable to attribute `_server` with type `None` [bad-assignment] -ERROR homeassistant/components/wiffi/__init__.py:80:35-82:10: `() -> None` is not assignable to attribute `_periodic_callback` with type `None` [bad-assignment] -ERROR homeassistant/components/wiffi/config_flow.py:33:9-31: Class member `WiffiFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] -ERROR homeassistant/components/wiffi/entity.py:64:33-76: `datetime` is not assignable to attribute `_expiration_date` with type `None` [bad-assignment] -ERROR homeassistant/components/wiffi/entity.py:82:27-31: `None` is not assignable to attribute `_value` with type `Never` [bad-assignment] ERROR homeassistant/components/wiffi/entity.py:88:17-41: Object of class `NoneType` has no attribute `endswith` [missing-attribute] ERROR homeassistant/components/wiffi/entity.py:93:16-40: Object of class `NoneType` has no attribute `endswith` [missing-attribute] ERROR homeassistant/components/wiffi/entity.py:93:54-78: Object of class `NoneType` has no attribute `endswith` [missing-attribute] @@ -35530,7 +34816,7 @@ ERROR homeassistant/components/wirelesstag/switch.py:39:9-13: Unexpected keyword ERROR homeassistant/components/wirelesstag/switch.py:42:9-12: Unexpected keyword argument `key` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/wirelesstag/switch.py:43:9-13: Unexpected keyword argument `name` in function `homeassistant.components.switch.SwitchEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/wirelesstag/switch.py:88:14-32: Class member `WirelessTagSwitch.entity_description` overrides parent class `WirelessTagBaseSensor` in an inconsistent manner [bad-override] -ERROR homeassistant/components/wirelesstag/switch.py:103:16-27: Returned type `None` is not assignable to declared return type `bool` [bad-return] +ERROR homeassistant/components/wirelesstag/switch.py:103:16-27: Returned type `Unknown | None` is not assignable to declared return type `bool` [bad-return] ERROR homeassistant/components/wirelesstag/util.py:5:1-46: Could not find import of `wirelesstagpy.sensortag` [missing-import] ERROR homeassistant/components/withings/binary_sensor.py:52:5-23: Class member `WithingsBinarySensor._attr_device_class` overrides parent class `WithingsEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/withings/coordinator.py:41:5-17: Class member `WithingsDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -35695,7 +34981,7 @@ ERROR homeassistant/components/wiz/binary_sensor.py:68:5-23: Class member `WizOc ERROR homeassistant/components/wiz/binary_sensor.py:79:12-41: Object of class `NoneType` has no attribute `get_source` [missing-attribute] ERROR homeassistant/components/wiz/config_flow.py:180:66-69: Argument `str | None` is not assignable to parameter `mac` with type `str` in function `homeassistant.components.wiz.utils.name_from_bulb_type_and_mac` [bad-argument-type] ERROR homeassistant/components/wiz/entity.py:31:31-52: `BulbType | None` is not assignable to `BulbType` [bad-assignment] -ERROR homeassistant/components/wiz/entity.py:34:25-69: Argument `set[tuple[str, str | None]]` is not assignable to parameter `connections` with type `set[tuple[str, str]]` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/wiz/entity.py:33:44-38:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (connections=set[tuple[str, str | None]], name=str, manufacturer=Literal['WiZ'], sw_version=str | None) [no-matching-overload] ERROR homeassistant/components/wiz/fan.py:37:8-49: Object of class `NoneType` has no attribute `features` [missing-attribute] ERROR homeassistant/components/wiz/fan.py:53:31-52: `BulbType | None` is not assignable to `BulbType` [bad-assignment] ERROR homeassistant/components/wiz/fan.py:67:14-38: Class member `WizFanEntity._attr_supported_features` overrides parent class `WizEntity` in an inconsistent manner [bad-override] @@ -35737,7 +35023,6 @@ ERROR homeassistant/components/wiz/sensor.py:94:22-50: Object of class `NoneType ERROR homeassistant/components/wiz/switch.py:25:8-50: Object of class `NoneType` has no attribute `bulb_type` [missing-attribute] ERROR homeassistant/components/wled/__init__.py:65:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/wled/button.py:29:5-23: Class member `WLEDRestartButton._attr_device_class` overrides parent class `WLEDEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/wled/config_flow.py:36:9-31: Class member `WLEDFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/wled/coordinator.py:39:5-17: Class member `WLEDDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/wled/light.py:64:5-29: Class member `WLEDMainLight._attr_supported_features` overrides parent class `WLEDEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/wled/light.py:113:5-29: Class member `WLEDSegmentLight._attr_supported_features` overrides parent class `WLEDEntity` in an inconsistent manner [bad-override] @@ -35805,7 +35090,6 @@ ERROR homeassistant/components/wolflink/sensor.py:121:9-12: Unexpected keyword a ERROR homeassistant/components/wolflink/sensor.py:127:9-12: Unexpected keyword argument `key` in function `WolflinkSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/wolflink/sensor.py:156:5-23: Class member `WolfLinkSensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/wolflink/sensor.py:156:5-23: Class member `WolfLinkSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/workday/config_flow.py:223:9-31: Class member `WorkdayConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/workday/util.py:38:53-80: Unpacked argument `tuple[str]` is not assignable to parameter `*args` with type `tuple[str, str | None, Iterable[int] | int | None, bool, bool, str | None, str | None, str | None, Iterable[str] | str | None]` in function `homeassistant.core.HomeAssistant.async_add_import_executor_job` [bad-argument-type] ERROR homeassistant/components/worldtidesinfo/sensor.py:58:8-22: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/worldtidesinfo/sensor.py:88:26-47: `None` is not subscriptable [unsupported-operation] @@ -35818,12 +35102,7 @@ ERROR homeassistant/components/worldtidesinfo/sensor.py:94:42-63: `None` is not ERROR homeassistant/components/worldtidesinfo/sensor.py:95:40-61: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/worldtidesinfo/sensor.py:96:41-62: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/components/worldtidesinfo/sensor.py:97:39-60: `None` is not subscriptable [unsupported-operation] -ERROR homeassistant/components/worxlandroid/sensor.py:113:31-36: `Literal['yes']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/worxlandroid/sensor.py:115:31-49: `Literal['connection-error']` is not assignable to attribute `_state` with type `None` [bad-assignment] ERROR homeassistant/components/worxlandroid/sensor.py:121:26-40: `mower_response` may be uninitialized [unbound-name] -ERROR homeassistant/components/worxlandroid/sensor.py:129:31-78: `Literal['no', 'yes']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/worxlandroid/sensor.py:136:27-31: `Literal['no']` is not assignable to attribute `_state` with type `None` [bad-assignment] -ERROR homeassistant/components/ws66i/config_flow.py:129:9-31: Class member `WS66iConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/ws66i/coordinator.py:21:5-17: Class member `Ws66iDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/ws66i/media_player.py:50:5-29: Class member `Ws66iZone._attr_supported_features` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/ws66i/media_player.py:102:14-25: Class member `Ws66iZone._attr_state` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] @@ -35912,29 +35191,19 @@ ERROR homeassistant/components/xbox/sensor.py:297:5-23: Class member `XboxSensor ERROR homeassistant/components/xbox/sensor.py:311:5-23: Class member `XboxStorageDeviceSensorEntity.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xbox/sensor.py:311:5-23: Class member `XboxStorageDeviceSensorEntity.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xeoma/camera.py:7:1-44: Could not find import of `pyxeoma.xeoma` [missing-import] -ERROR homeassistant/components/xiaomi/camera.py:166:32-172:14: `bytes | None` is not assignable to attribute `_last_image` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi/camera.py:181:34-48: Argument `None` is not assignable to parameter `input_source` with type `str` in function `haffmpeg.camera.CameraMjpeg.open_camera` [bad-argument-type] +ERROR homeassistant/components/xiaomi/camera.py:181:34-48: Argument `Unknown | None` is not assignable to parameter `input_source` with type `str` in function `haffmpeg.camera.CameraMjpeg.open_camera` [bad-argument-type] ERROR homeassistant/components/xiaomi/camera.py:188:17-30: Argument `asyncio.streams.StreamReader` is not assignable to parameter `stream` with type `aiohttp.streams.StreamReader` in function `homeassistant.helpers.aiohttp_client.async_aiohttp_proxy_stream` [bad-argument-type] -ERROR homeassistant/components/xiaomi/device_tracker.py:69:33-52: `dict[Unknown, Unknown]` is not assignable to attribute `mac2name` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi/device_tracker.py:73:16-33: Object of class `NoneType` has no attribute `get` [missing-attribute] ERROR homeassistant/components/xiaomi/device_tracker.py:105:29-31: `list[@_]` is not assignable to attribute `last_results` with type `dict[Unknown, Unknown]` [bad-assignment] ERROR homeassistant/components/xiaomi/device_tracker.py:109:17-41: Object of class `dict` has no attribute `append` [missing-attribute] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:154:14-32: Class member `XiaomiBinarySensor._attr_device_class` overrides parent class `XiaomiDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:187:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:198:29-51: `int` is not assignable to attribute `_density` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:249:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:309:45-311:18: `() -> None` is not assignable to attribute `_unsub_set_no_motion` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:355:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:468:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:517:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:539:29-34: `Literal['actively', 'free_fall', 'tilt', 'vibrate']` is not assignable to attribute `_last_action` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:565:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:607:29-39: `Literal['both', 'double', 'double_both', 'hold', 'long', 'long_both', 'long_click_press', 'shake', 'single']` is not assignable to attribute `_last_action` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:635:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:666:33-41: `Literal['rotate']` is not assignable to attribute `_last_action` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_aqara/binary_sensor.py:682:33-41: `Literal['rotate']` is not assignable to attribute `_last_action` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/config_flow.py:130:25-40: `defaultdict[Unknown, list[Unknown]]` is not assignable to attribute `gateways` with type `dict[str, XiaomiGateway]` [bad-assignment] -ERROR homeassistant/components/xiaomi_aqara/entity.py:130:47-132:10: `() -> None` is not assignable to attribute `_remove_unavailability_tracker` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/light.py:89:20-52: `tuple[float, float]` is not assignable to attribute `_hs` with type `tuple[Literal[0], Literal[0]]` [bad-assignment] ERROR homeassistant/components/xiaomi_aqara/sensor.py:35:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/xiaomi_aqara/sensor.py:41:9-12: Unexpected keyword argument `key` in function `homeassistant.components.sensor.SensorEntityDescription.__init__` [unexpected-keyword] @@ -35950,10 +35219,6 @@ ERROR homeassistant/components/xiaomi_aqara/sensor.py:180:14-32: Class member `X ERROR homeassistant/components/xiaomi_aqara/sensor.py:212:5-23: Class member `XiaomiBatterySensor._attr_device_class` overrides parent class `XiaomiDevice` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_aqara/switch.py:178:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] ERROR homeassistant/components/xiaomi_aqara/switch.py:178:21-53: No matching overload found for function `typing.MutableMapping.update` called with arguments: (Mapping[str, Any] | None) [no-matching-overload] -ERROR homeassistant/components/xiaomi_aqara/switch.py:196:28-45: `int` is not assignable to attribute `_in_use` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_aqara/switch.py:198:36-37: `Literal[0]` is not assignable to attribute `_load_power` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_aqara/switch.py:202:40-66: `float` is not assignable to attribute `_power_consumed` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_aqara/switch.py:206:32-65: `float` is not assignable to attribute `_load_power` with type `None` [bad-assignment] ERROR homeassistant/components/xiaomi_ble/binary_sensor.py:30:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/xiaomi_ble/binary_sensor.py:34:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/xiaomi_ble/binary_sensor.py:38:9-12: Unexpected keyword argument `key` in function `homeassistant.components.binary_sensor.BinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -36114,11 +35379,10 @@ ERROR homeassistant/components/xiaomi_miio/button.py:99:9-24: Unexpected keyword ERROR homeassistant/components/xiaomi_miio/button.py:159:5-23: Class member `XiaomiGenericCoordinatedButton.entity_description` overrides parent class `XiaomiCoordinatedMiioEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/button.py:159:5-23: Class member `XiaomiGenericCoordinatedButton.entity_description` overrides parent class `ButtonEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/button.py:161:5-23: Class member `XiaomiGenericCoordinatedButton._attr_device_class` overrides parent class `XiaomiCoordinatedMiioEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/xiaomi_miio/config_flow.py:123:9-31: Class member `XiaomiMiioFlowHandler.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/config_flow.py:258:69-260:18: Unpacked argument `tuple[Any]` is not assignable to parameter `*args` with type `tuple[Unknown | None, bool | Unknown, bool | Unknown, str | Unknown]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] -ERROR homeassistant/components/xiaomi_miio/config_flow.py:389:24-59: `str` is not assignable to attribute `mac` with type `Never` [bad-assignment] -ERROR homeassistant/components/xiaomi_miio/device.py:37:28-47: `Device` is not assignable to attribute `_device` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_miio/device.py:40:17-34: Object of class `NoneType` has no attribute `info` [missing-attribute] +ERROR homeassistant/components/xiaomi_miio/config_flow.py:414:16-37: Object of class `NoneType` has no attribute `startswith` [missing-attribute] +ERROR homeassistant/components/xiaomi_miio/config_flow.py:419:20-41: Object of class `NoneType` has no attribute `startswith` [missing-attribute] +ERROR homeassistant/components/xiaomi_miio/config_flow.py:424:23-32: Argument `Unknown | None` is not assignable to parameter `title` with type `str` in function `homeassistant.config_entries.ConfigFlow.async_create_entry` [bad-argument-type] ERROR homeassistant/components/xiaomi_miio/device_tracker.py:68:34-66: Object of class `NoneType` has no attribute `async_add_executor_job` [missing-attribute] ERROR homeassistant/components/xiaomi_miio/fan.py:306:5-23: Class member `XiaomiGenericDevice._attr_preset_modes` overrides parent class `FanEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/fan.py:566:13-38: Object of class `Device` has no attribute `reset_filter` [missing-attribute] @@ -36127,12 +35391,8 @@ ERROR homeassistant/components/xiaomi_miio/fan.py:916:29-38: `tuple[Literal[60], ERROR homeassistant/components/xiaomi_miio/gateway.py:64:13-37: Object of class `NoneType` has no attribute `model` [missing-attribute] ERROR homeassistant/components/xiaomi_miio/gateway.py:65:13-48: Object of class `NoneType` has no attribute `firmware_version` [missing-attribute] ERROR homeassistant/components/xiaomi_miio/gateway.py:66:13-48: Object of class `NoneType` has no attribute `hardware_version` [missing-attribute] -ERROR homeassistant/components/xiaomi_miio/gateway.py:72:36-76: `Gateway` is not assignable to attribute `_gateway_device` with type `None` [bad-assignment] -ERROR homeassistant/components/xiaomi_miio/gateway.py:72:52-62: Argument `None` is not assignable to parameter `ip` with type `str` in function `miio.gateway.gateway.Gateway.__init__` [bad-argument-type] -ERROR homeassistant/components/xiaomi_miio/gateway.py:72:64-75: Argument `None` is not assignable to parameter `token` with type `str` in function `miio.gateway.gateway.Gateway.__init__` [bad-argument-type] -ERROR homeassistant/components/xiaomi_miio/gateway.py:74:34-59: Object of class `NoneType` has no attribute `info` [missing-attribute] -ERROR homeassistant/components/xiaomi_miio/gateway.py:88:17-54: Object of class `NoneType` has no attribute `discover_devices` [missing-attribute] -ERROR homeassistant/components/xiaomi_miio/gateway.py:121:17-59: Object of class `NoneType` has no attribute `get_devices_from_dict` [missing-attribute] +ERROR homeassistant/components/xiaomi_miio/gateway.py:72:52-62: Argument `Unknown | None` is not assignable to parameter `ip` with type `str` in function `miio.gateway.gateway.Gateway.__init__` [bad-argument-type] +ERROR homeassistant/components/xiaomi_miio/gateway.py:72:64-75: Argument `Unknown | None` is not assignable to parameter `token` with type `str` in function `miio.gateway.gateway.Gateway.__init__` [bad-argument-type] ERROR homeassistant/components/xiaomi_miio/humidifier.py:118:5-23: Class member `XiaomiGenericHumidifier._attr_device_class` overrides parent class `XiaomiCoordinatedMiioEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/humidifier.py:119:5-29: Class member `XiaomiGenericHumidifier._attr_supported_features` overrides parent class `XiaomiCoordinatedMiioEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/xiaomi_miio/light.py:262:5-12: Class member `XiaomiPhilipsAbstractLight._device` overrides parent class `XiaomiMiioEntity` in an inconsistent manner [bad-override] @@ -36573,13 +35833,9 @@ ERROR homeassistant/components/yale/camera.py:76:49-61: Argument `DoorbellDetail ERROR homeassistant/components/yale/camera.py:76:63-80: Argument `Activity` is not assignable to parameter `activity` with type `BridgeOperationActivity | DoorbellImageCaptureActivity | DoorbellMotionActivity` in function `yalexs.util.update_doorbell_image_from_activity` [bad-argument-type] ERROR homeassistant/components/yale/camera.py:84:35-57: Object of class `LockDetail` has no attribute `image_url` [missing-attribute] ERROR homeassistant/components/yale/camera.py:88:31-53: Object of class `LockDetail` has no attribute `image_url` [missing-attribute] -ERROR homeassistant/components/yale/data.py:29:36-37:14: Missing argument `address` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/yale/data.py:29:36-37:14: Missing argument `serial` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/yale/data.py:29:36-37:14: Missing argument `key` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/yale/data.py:29:36-37:14: Missing argument `slot` in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [missing-argument] -ERROR homeassistant/components/yale/data.py:30:17-36:18: Expected argument `name` to be passed by name in function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` [unexpected-positional-argument] +ERROR homeassistant/components/yale/data.py:29:36-37:14: No matching overload found for function `yalexs_ble.const.YaleXSBLEDiscovery.__init__` called with arguments: (dict[str, int | str | Unknown | None]) [no-matching-overload] ERROR homeassistant/components/yale/data.py:47:40-58: Argument `type[HomeAssistantError]` is not assignable to parameter `error_exception_class` with type `Exception` in function `yalexs.manager.data.YaleXSData.__init__` [bad-argument-type] -ERROR homeassistant/components/yale/entity.py:43:19-31: Argument `int | str | Unknown | None` is not assignable to parameter `model` with type `str | None` in function `homeassistant.helpers.device_registry.DeviceInfo.__init__` [bad-argument-type] +ERROR homeassistant/components/yale/entity.py:40:44-48:10: No matching overload found for function `homeassistant.helpers.device_registry.DeviceInfo.__init__` called with arguments: (identifiers=set[tuple[str, str | Unknown]], manufacturer=Literal['Yale Home Inc.'], model=int | str | Unknown | None, name=str | Unknown, sw_version=Unknown, suggested_area=str, configuration_url=str) [no-matching-overload] ERROR homeassistant/components/yale/entity.py:59:21-40: Object of class `DoorbellDetail` has no attribute `bridge` [missing-attribute] ERROR homeassistant/components/yale/entity.py:59:45-77: Object of class `object` has no attribute `hyper_bridge` [missing-attribute] ERROR homeassistant/components/yale/event.py:39:9-12: Unexpected keyword argument `key` in function `YaleEventEntityDescription.__init__` [unexpected-keyword] @@ -36641,7 +35897,6 @@ ERROR homeassistant/components/yale_smart_alarm/binary_sensor.py:103:5-23: Class ERROR homeassistant/components/yale_smart_alarm/button.py:19:9-12: Unexpected keyword argument `key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/yale_smart_alarm/button.py:20:9-24: Unexpected keyword argument `translation_key` in function `homeassistant.components.button.ButtonEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/yale_smart_alarm/button.py:42:5-23: Class member `YalePanicButton.entity_description` overrides parent class `YaleAlarmEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/yale_smart_alarm/config_flow.py:73:9-31: Class member `YaleConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/yale_smart_alarm/coordinator.py:27:5-17: Class member `YaleDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/yale_smart_alarm/coordinator.py:44:63-48:14: Unpacked argument `tuple[Any, Any]` is not assignable to parameter `*args` with type `tuple[str, str, int]` in function `homeassistant.core.HomeAssistant.async_add_executor_job` [bad-argument-type] ERROR homeassistant/components/yale_smart_alarm/entity.py:22:14-29: Class member `YaleEntity._attr_unique_id` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] @@ -36651,7 +35906,6 @@ ERROR homeassistant/components/yale_smart_alarm/select.py:42:14-29: Class member ERROR homeassistant/components/yale_smart_alarm/sensor.py:35:5-23: Class member `YaleTemperatureSensor._attr_device_class` overrides parent class `YaleEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/yale_smart_alarm/switch.py:42:14-29: Class member `YaleAutolockSwitch._attr_unique_id` overrides parent class `SwitchEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/yalexs_ble/binary_sensor.py:33:5-23: Class member `YaleXSBLEDoorSensor._attr_device_class` overrides parent class `YALEXSBLEEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/yalexs_ble/config_flow.py:356:9-31: Class member `YalexsConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/yalexs_ble/sensor.py:39:9-12: Unexpected keyword argument `key` in function `YaleXSBLESensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/yalexs_ble/sensor.py:41:9-24: Unexpected keyword argument `entity_category` in function `YaleXSBLESensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/yalexs_ble/sensor.py:43:9-24: Unexpected keyword argument `has_entity_name` in function `YaleXSBLESensorEntityDescription.__init__` [unexpected-keyword] @@ -36666,10 +35920,6 @@ ERROR homeassistant/components/yalexs_ble/sensor.py:65:9-24: Unexpected keyword ERROR homeassistant/components/yalexs_ble/sensor.py:67:9-40: Unexpected keyword argument `entity_registry_enabled_default` in function `YaleXSBLESensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/yalexs_ble/sensor.py:88:5-23: Class member `YaleXSBLESensor.entity_description` overrides parent class `YALEXSBLEEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/yalexs_ble/sensor.py:88:5-23: Class member `YaleXSBLESensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] -ERROR homeassistant/components/yalexs_ble/util.py:29:41-65: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] -ERROR homeassistant/components/yalexs_ble/util.py:33:37-55: Expected 0 positional arguments, got 1 in function `homeassistant.components.bluetooth.match.BluetoothCallbackMatcher.__init__` [bad-argument-count] -ERROR homeassistant/components/yamaha/media_player.py:254:36-60: `Literal[MediaPlayerState.PLAYING]` is not assignable to attribute `_attr_state` with type `Never` [bad-assignment] -ERROR homeassistant/components/yamaha/media_player.py:256:36-57: `Literal[MediaPlayerState.IDLE]` is not assignable to attribute `_attr_state` with type `Never` [bad-assignment] ERROR homeassistant/components/yamaha/media_player.py:369:16-30: Module `rxv.exceptions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR homeassistant/components/yamaha_musiccast/config_flow.py:92:13-41: Argument `str | None` is not assignable to parameter `location` with type `str` in function `aiomusiccast.musiccast_device.MusicCastDevice.check_yamaha_ssdp` [bad-argument-type] ERROR homeassistant/components/yamaha_musiccast/coordinator.py:29:5-17: Class member `MusicCastDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] @@ -36706,7 +35956,6 @@ ERROR homeassistant/components/yardian/binary_sensor.py:98:13-37: Unexpected key ERROR homeassistant/components/yardian/binary_sensor.py:116:5-23: Class member `YardianBinarySensor.entity_description` overrides parent class `CoordinatorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/yardian/binary_sensor.py:116:5-23: Class member `YardianBinarySensor.entity_description` overrides parent class `BinarySensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/yardian/coordinator.py:43:5-17: Class member `YardianUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] -ERROR homeassistant/components/yeelight/config_flow.py:64:9-31: Class member `YeelightConfigFlow.async_get_options_flow` overrides parent class `ConfigFlow` in an inconsistent manner [bad-override] ERROR homeassistant/components/yeelight/config_flow.py:323:12-28: `is_unknown_model` may be uninitialized [unbound-name] ERROR homeassistant/components/yeelight/device.py:200:29-83: `CaseInsensitiveDict | dict[str, Any]` is not assignable to attribute `capabilities` with type `dict[str, Any]` [bad-assignment] ERROR homeassistant/components/yeelight/light.py:424:5-29: Class member `YeelightBaseLight._attr_supported_features` overrides parent class `YeelightEntity` in an inconsistent manner [bad-override] @@ -36714,11 +35963,10 @@ ERROR homeassistant/components/yeelight/light.py:733:77-85: `duration` may be un ERROR homeassistant/components/yeelight/light.py:734:28-64: Argument `SleepTransition` is not assignable to parameter `object` with type `RGBTransition` in function `list.append` [bad-argument-type] ERROR homeassistant/components/yeelight/light.py:737:72-80: `duration` may be uninitialized [unbound-name] ERROR homeassistant/components/yeelight/light.py:741:27-32: `count` may be uninitialized [unbound-name] -ERROR homeassistant/components/yeelight/light.py:834:40-836:10: `() -> None` is not assignable to attribute `_unexpected_state_check` with type `None` [bad-assignment] ERROR homeassistant/components/yeelight/light.py:1105:38-45: `bg_prop` may be uninitialized [unbound-name] ERROR homeassistant/components/yeelightsunflower/light.py:9:8-25: Could not find import of `yeelightsunflower` [missing-import] ERROR homeassistant/components/yi/camera.py:7:1-43: Could not find import of `aioftp` [missing-import] -ERROR homeassistant/components/yi/camera.py:144:34-48: Argument `None` is not assignable to parameter `input_source` with type `str` in function `haffmpeg.camera.CameraMjpeg.open_camera` [bad-argument-type] +ERROR homeassistant/components/yi/camera.py:144:34-48: Argument `Unknown | None` is not assignable to parameter `input_source` with type `str` in function `haffmpeg.camera.CameraMjpeg.open_camera` [bad-argument-type] ERROR homeassistant/components/yi/camera.py:151:17-30: Argument `asyncio.streams.StreamReader` is not assignable to parameter `stream` with type `aiohttp.streams.StreamReader` in function `homeassistant.helpers.aiohttp_client.async_aiohttp_proxy_stream` [bad-argument-type] ERROR homeassistant/components/yolink/__init__.py:212:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/yolink/binary_sensor.py:63:9-12: Unexpected keyword argument `key` in function `YoLinkBinarySensorEntityDescription.__init__` [unexpected-keyword] @@ -36877,7 +36125,6 @@ ERROR homeassistant/components/youless/sensor.py:291:9-24: Unexpected keyword ar ERROR homeassistant/components/youless/sensor.py:326:5-23: Class member `YouLessSensor.entity_description` overrides parent class `YouLessEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/youless/sensor.py:326:5-23: Class member `YouLessSensor.entity_description` overrides parent class `SensorEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/youtube/__init__.py:66:12-21: `unload_ok` may be uninitialized [unbound-name] -ERROR homeassistant/components/youtube/config_flow.py:52:9-31: Class member `OAuth2FlowHandler.async_get_options_flow` overrides parent class `AbstractOAuth2FlowHandler` in an inconsistent manner [bad-override] ERROR homeassistant/components/youtube/coordinator.py:36:5-17: Class member `YouTubeDataUpdateCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/youtube/sensor.py:47:9-12: Unexpected keyword argument `key` in function `YouTubeSensorEntityDescription.__init__` [unexpected-keyword] ERROR homeassistant/components/youtube/sensor.py:48:9-24: Unexpected keyword argument `translation_key` in function `YouTubeSensorEntityDescription.__init__` [unexpected-keyword] @@ -36933,8 +36180,8 @@ ERROR homeassistant/components/zamg/sensor.py:234:27-38: `update_time` may be un ERROR homeassistant/components/zamg/weather.py:47:26-37: Argument `ZamgDataUpdateCoordinator` is not assignable to parameter `coordinator` with type `DataUpdateCoordinator[dict[str, Any]]` in function `homeassistant.helpers.update_coordinator.CoordinatorEntity.__init__` [bad-argument-type] ERROR homeassistant/components/zeroconf/discovery.py:164:8-21: `TYPE_CHECKING` may be uninitialized [unbound-name] ERROR homeassistant/components/zeroconf/discovery.py:487:38-491:14: Argument `dict[str, str | Any | None]` is not assignable to parameter `translation_placeholders` with type `dict[str, str] | None` in function `homeassistant.helpers.issue_registry.async_create_issue` [bad-argument-type] -ERROR homeassistant/components/zestimate/sensor.py:97:32-43: Argument `None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] -ERROR homeassistant/components/zestimate/sensor.py:137:21-28: `dict[str, Unknown]` is not assignable to attribute `data` with type `None` [bad-assignment] + WARN homeassistant/components/zerproc/light.py:67:26-31: Identity comparison `False is False` is always True [unnecessary-comparison] +ERROR homeassistant/components/zestimate/sensor.py:97:32-43: Argument `Unknown | None` is not assignable to parameter `x` with type `Buffer | SupportsFloat | SupportsIndex | str` in function `float.__new__` [bad-argument-type] ERROR homeassistant/components/zeversolar/__init__.py:26:12-21: `unload_ok` may be uninitialized [unbound-name] ERROR homeassistant/components/zeversolar/coordinator.py:23:5-17: Class member `ZeversolarCoordinator.config_entry` overrides parent class `DataUpdateCoordinator` in an inconsistent manner [bad-override] ERROR homeassistant/components/zeversolar/sensor.py:35:9-12: Unexpected keyword argument `key` in function `ZeversolarEntityDescription.__init__` [unexpected-keyword] @@ -37223,8 +36470,7 @@ ERROR homeassistant/components/zha/websocket_api.py:1023:59-67: Argument `list[h ERROR homeassistant/components/zha/websocket_api.py:1444:23-49: Cannot index into `Endpoint` [bad-index] ERROR homeassistant/components/zhong_hong/climate.py:9:1-49: Could not find import of `zhong_hong_hvac.hub` [missing-import] ERROR homeassistant/components/zhong_hong/climate.py:10:1-55: Could not find import of `zhong_hong_hvac.hvac` [missing-import] -ERROR homeassistant/components/zhong_hong/climate.py:175:39-177:14: `HVACMode` is not assignable to attribute `_current_operation` with type `None` [bad-assignment] -ERROR homeassistant/components/zhong_hong/climate.py:200:20-43: Returned type `None` is not assignable to declared return type `HVACMode` [bad-return] +ERROR homeassistant/components/zhong_hong/climate.py:200:20-43: Returned type `Unknown | None` is not assignable to declared return type `HVACMode` [bad-return] ERROR homeassistant/components/ziggo_mediabox_xl/media_player.py:9:1-46: Could not find import of `ziggo_mediabox_xl` [missing-import] ERROR homeassistant/components/zimi/config_flow.py:47:25-29: `None` is not assignable to `ControlPoint` [bad-assignment] ERROR homeassistant/components/zimi/cover.py:41:5-23: Class member `ZimiCover._attr_device_class` overrides parent class `ZimiEntity` in an inconsistent manner [bad-override] @@ -37351,12 +36597,14 @@ ERROR homeassistant/components/zwave_js/cover.py:82:7-25: Field `entity_descript `, which is not assignable to the type `CoverEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/zwave_js/cover.py:96:14-38: Class member `CoverPositionMixin._attr_supported_features` overrides parent class `ZWaveBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/zwave_js/cover.py:97:13-100:46: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] +ERROR homeassistant/components/zwave_js/cover.py:109:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/zwave_js/cover.py:109:13-69: `|=` is not supported between `None` and `Literal[CoverEntityFeature.STOP]` [unsupported-operation] ERROR homeassistant/components/zwave_js/cover.py:114:26-44: No matching overload found for function `min` called with arguments: (Literal[1], float) [no-matching-overload] ERROR homeassistant/components/zwave_js/cover.py:188:7-21: Field `entity_description` is declared `EntityDescription` in ancestor `class ZWaveBaseEntity: ... `, which is not assignable to the type `CoverEntityDescription` implied by multiple inheritance [inconsistent-inheritance] ERROR homeassistant/components/zwave_js/cover.py:202:14-38: Class member `CoverTiltMixin._attr_supported_features` overrides parent class `ZWaveBaseEntity` in an inconsistent manner [bad-override] ERROR homeassistant/components/zwave_js/cover.py:203:13-206:51: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] +ERROR homeassistant/components/zwave_js/cover.py:215:13-42: `CoverEntityFeature | int` is not assignable to attribute `_attr_supported_features` with type `CoverEntityFeature | None` [bad-assignment] ERROR homeassistant/components/zwave_js/cover.py:215:13-74: `|=` is not supported between `None` and `Literal[CoverEntityFeature.STOP_TILT]` [unsupported-operation] ERROR homeassistant/components/zwave_js/cover.py:220:26-44: No matching overload found for function `min` called with arguments: (Literal[1], float) [no-matching-overload] ERROR homeassistant/components/zwave_js/cover.py:439:7-28: Field `entity_description` is declared `EntityDescription` in ancestor `class ZWaveBaseEntity: ... @@ -37608,16 +36856,16 @@ ERROR homeassistant/config_entries.py:1114:57-64: `handler` may be uninitialized ERROR homeassistant/config_entries.py:1114:57-78: Object of class `FunctionType` has no attribute `MINOR_VERSION` [missing-attribute] ERROR homeassistant/config_entries.py:1119:27-38: `integration` may be uninitialized [unbound-name] ERROR homeassistant/config_entries.py:1311:16-35: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/config_entries.py:1465:25-32: Argument `str` is not assignable to parameter `handler` with type `_HandlerT` in function `ConfigFlowResult.__init__` [bad-argument-type] +ERROR homeassistant/config_entries.py:1462:36-1468:14: No matching overload found for function `ConfigFlowResult.__init__` called with arguments: (type=Literal[FlowResultType.ABORT], flow_id=str, handler=str, reason=Literal['single_instance_allowed'], translation_domain=Literal['homeassistant']) [no-matching-overload] ERROR homeassistant/config_entries.py:1589:25-42: Argument `_HandlerT` is not assignable to parameter `domain` with type `str` in function `ConfigEntries.async_entry_for_domain_unique_id` [bad-argument-type] -ERROR homeassistant/config_entries.py:1635:25-37: Argument `str` is not assignable to parameter `handler` with type `_HandlerT` in function `ConfigFlowResult.__init__` [bad-argument-type] +ERROR homeassistant/config_entries.py:1632:36-1638:14: No matching overload found for function `ConfigFlowResult.__init__` called with arguments: (type=Literal[FlowResultType.ABORT], flow_id=str, handler=str, reason=Literal['single_instance_allowed'], translation_domain=Literal['homeassistant']) [no-matching-overload] ERROR homeassistant/config_entries.py:1646:34-62: Object of class `object` has no attribute `get` [missing-attribute] ERROR homeassistant/config_entries.py:1671:17-34: Argument `_HandlerT` is not assignable to parameter `domain` with type `str` in function `ConfigEntries.async_entry_for_domain_unique_id` [bad-argument-type] ERROR homeassistant/config_entries.py:1709:20-37: Argument `_HandlerT` is not assignable to parameter `domain` with type `str` in function `ConfigEntry.__init__` [bad-argument-type] ERROR homeassistant/config_entries.py:1833:9-20: Class member `ConfigEntryItems.__setitem__` overrides parent class `UserDict` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/config_entries.py:1904:9-20: Class member `ConfigEntryItems.__delitem__` overrides parent class `UserDict` in an inconsistent manner [bad-param-name-override] ERROR homeassistant/config_entries.py:2724:16-2726:10: Returned type `dict[str, list[Fragment]]` is not assignable to declared return type `dict[str, list[dict[str, Any]]]` [bad-return] -ERROR homeassistant/config_entries.py:3009:17-42: `_FlowContextT` is not subscriptable [unsupported-operation] +ERROR homeassistant/config_entries.py:3009:17-42: Cannot index into `_FlowContextT` [bad-index] ERROR homeassistant/core.py:582:9-22: Implementation signature `(self: Self@HomeAssistant, target: ((**tuple[*_Ts]) -> Coroutine[Any, Any, _R] | _R) | Coroutine[Any, Any, _R], *args: *_Ts, *, eager_start: bool = False) -> Future[_R] | None` does not accept all arguments that overload signature `(self: Self@HomeAssistant, target: (**tuple[*_Ts]) -> Coroutine[Any, Any, _R], *args: *_Ts, *, eager_start: bool = False) -> Future[_R] | None` accepts [inconsistent-overload] ERROR homeassistant/core.py:591:9-22: Implementation signature `(self: Self@HomeAssistant, target: ((**tuple[*_Ts]) -> Coroutine[Any, Any, _R] | _R) | Coroutine[Any, Any, _R], *args: *_Ts, *, eager_start: bool = False) -> Future[_R] | None` does not accept all arguments that overload signature `(self: Self@HomeAssistant, target: (**tuple[*_Ts]) -> Coroutine[Any, Any, _R] | _R, *args: *_Ts, *, eager_start: bool = False) -> Future[_R] | None` accepts [inconsistent-overload] ERROR homeassistant/core.py:858:48-54: Argument `(**tuple[*_Ts]) -> _T` is not assignable to parameter `func` with type `(**tuple[*@_]) -> @_` in function `asyncio.events.AbstractEventLoop.run_in_executor` [bad-argument-type] @@ -37636,28 +36884,28 @@ ERROR homeassistant/core.py:2577:32-2585:10: Unpacked argument `tuple[str, str, ERROR homeassistant/core_config.py:143:25-28: Argument `Any | None` is not assignable to parameter `element` with type `str` in function `set.add` [bad-argument-type] ERROR homeassistant/core_config.py:373:69-78: `auth_conf` may be uninitialized [unbound-name] ERROR homeassistant/data_entry_flow.py:303:39-61: Object of class `object` has no attribute `items` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:339:48-341:14: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:345:29-43: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:339:48-341:14: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:345:29-43: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:363:28-40: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:388:12-28: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:394:23-42: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:397:12-28: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:401:69-403:14: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:411:69-413:14: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:427:16-35: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:388:12-28: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:394:23-42: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:397:12-28: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:401:69-403:14: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:411:69-413:14: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:427:16-35: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:427:39-49: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:428:17-31: `_FlowResultT` is not subscriptable [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:430:21-48: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:428:17-31: Cannot index into `_FlowResultT` [bad-index] +ERROR homeassistant/data_entry_flow.py:430:21-48: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:430:52-62: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:431:24-60: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:431:24-60: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:432:24-34: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:506:16-30: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:506:16-30: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:511:12-22: Object of class `object` has no attribute `get` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:514:27-41: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:514:27-41: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:545:17-34: Cannot set item in `_FlowResultT` [unsupported-operation] -ERROR homeassistant/data_entry_flow.py:548:54-71: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:548:54-71: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:554:57-68: Object of class `object` has no attribute `copy` [missing-attribute] -ERROR homeassistant/data_entry_flow.py:565:12-26: `_FlowResultT` is not subscriptable [unsupported-operation] +ERROR homeassistant/data_entry_flow.py:565:12-26: Cannot index into `_FlowResultT` [bad-index] ERROR homeassistant/data_entry_flow.py:746:13-35: Cannot set item in `_FlowResultT` [unsupported-operation] ERROR homeassistant/data_entry_flow.py:769:13-33: Cannot set item in `_FlowResultT` [unsupported-operation] ERROR homeassistant/data_entry_flow.py:838:13-35: Cannot set item in `_FlowResultT` [unsupported-operation] @@ -37670,8 +36918,8 @@ ERROR homeassistant/helpers/chat_session.py:159:25-32: `session` may be uninitia ERROR homeassistant/helpers/chat_session.py:160:11-18: `session` may be uninitialized [unbound-name] ERROR homeassistant/helpers/chat_session.py:163:5-12: `session` may be uninitialized [unbound-name] ERROR homeassistant/helpers/chat_session.py:164:37-44: `session` may be uninitialized [unbound-name] -ERROR homeassistant/helpers/collection.py:271:21-41: `_StoreT` is not subscriptable [unsupported-operation] -ERROR homeassistant/helpers/collection.py:279:29-49: `_StoreT` is not subscriptable [unsupported-operation] +ERROR homeassistant/helpers/collection.py:271:21-41: Cannot index into `_StoreT` [bad-index] +ERROR homeassistant/helpers/collection.py:279:29-49: Cannot index into `_StoreT` [bad-index] ERROR homeassistant/helpers/collection.py:651:32-36: `data` is uninitialized [unbound-name] ERROR homeassistant/helpers/condition.py:307:10-36: Function declared to return `dict[str, type[Condition]]` but is missing an explicit `return` [bad-return] ERROR homeassistant/helpers/condition.py:413:16-75: Returned type `tuple[str, ModuleType]` is not assignable to declared return type `tuple[str, ConditionProtocol | None]` [bad-return] @@ -37732,9 +36980,9 @@ ERROR homeassistant/helpers/entity_registry.py:1067:45-58: Argument `UndefinedTy ERROR homeassistant/helpers/entity_registry.py:1071:47-62: Argument `UndefinedType | str | None` is not assignable to parameter `value` with type `UndefinedType | str` in function `none_if_undefined` [bad-argument-type] ERROR homeassistant/helpers/entity_registry.py:1073:51-70: Argument `UndefinedType | str | None` is not assignable to parameter `value` with type `UndefinedType | str` in function `none_if_undefined` [bad-argument-type] ERROR homeassistant/helpers/entity_registry.py:1209:61-76: Cannot index into `dict[str, set[str | None]]` [bad-index] -ERROR homeassistant/helpers/event.py:356:45-68: `_StateEventDataT` is not subscriptable [unsupported-operation] -ERROR homeassistant/helpers/event.py:364:17-40: `_StateEventDataT` is not subscriptable [unsupported-operation] -ERROR homeassistant/helpers/event.py:376:12-35: `_StateEventDataT` is not subscriptable [unsupported-operation] +ERROR homeassistant/helpers/event.py:356:45-68: Cannot index into `_StateEventDataT` [bad-index] +ERROR homeassistant/helpers/event.py:364:17-40: Cannot index into `_StateEventDataT` [bad-index] +ERROR homeassistant/helpers/event.py:376:12-35: Cannot index into `_StateEventDataT` [bad-index] ERROR homeassistant/helpers/event.py:1491:48-57: Argument `HassJob[[utc_now: datetime], None]` is not assignable to parameter `action` with type `((datetime) -> Coroutine[Any, Any, None] | None) | HassJob[[datetime], Coroutine[Any, Any, None] | None]` in function `async_track_point_in_utc_time` [bad-argument-type] ERROR homeassistant/helpers/frame.py:142:21-32: `integration` may be uninitialized [unbound-name] ERROR homeassistant/helpers/frame.py:144:58-63: `index` may be uninitialized [unbound-name] @@ -37751,7 +36999,6 @@ ERROR homeassistant/helpers/intent.py:1162:35-42: `service` may be uninitialized ERROR homeassistant/helpers/issue_registry.py:201:16-21: `issue` may be uninitialized [unbound-name] ERROR homeassistant/helpers/json.py:60:33-38: Function declared to return `bytes` but is missing an explicit `return` [bad-return] ERROR homeassistant/helpers/json.py:194:55-59: `dump` is uninitialized [unbound-name] -ERROR homeassistant/helpers/llm.py:280:32-43: `set[Unknown]` is not assignable to attribute `extra_slots` with type `None` [bad-assignment] ERROR homeassistant/helpers/llm.py:398:17-77: Argument `str` is not assignable to parameter `object` with type `LiteralString` in function `list.append` [bad-argument-type] ERROR homeassistant/helpers/llm.py:400:33-56: Argument `str` is not assignable to parameter `object` with type `LiteralString` in function `list.append` [bad-argument-type] ERROR homeassistant/helpers/llm.py:519:79-84: `extra` may be uninitialized [unbound-name] @@ -37870,13 +37117,13 @@ ERROR homeassistant/helpers/storage.py:436:30-42: Cannot index into `list[Unknow ERROR homeassistant/helpers/storage.py:436:30-42: Cannot index into `str` [bad-index] ERROR homeassistant/helpers/storage.py:436:30-42: `None` is not subscriptable [unsupported-operation] ERROR homeassistant/helpers/sun.py:90:5-105:17: `ValueError | None` is not assignable to `None` (caused by inconsistent types when breaking cycles) [bad-assignment] -ERROR homeassistant/helpers/system_info.py:88:31-35: Cannot set item in `dict[str, bool | str]` [unsupported-operation] +ERROR homeassistant/helpers/system_info.py:88:31-35: `None` is not assignable to TypedDict key `user` with type `bool | str` [bad-typed-dict-key] ERROR homeassistant/helpers/system_info.py:113:37-41: `info` may be uninitialized [unbound-name] -ERROR homeassistant/helpers/system_info.py:113:37-59: Cannot set item in `dict[str, bool | str]` [unsupported-operation] -ERROR homeassistant/helpers/system_info.py:114:34-62: Cannot set item in `dict[str, bool | str]` [unsupported-operation] +ERROR homeassistant/helpers/system_info.py:113:37-59: `Unknown | None` is not assignable to TypedDict key `supervisor` with type `bool | str` [bad-typed-dict-key] +ERROR homeassistant/helpers/system_info.py:114:34-62: `Any | None` is not assignable to TypedDict key `host_os` with type `bool | str` [bad-typed-dict-key] ERROR homeassistant/helpers/system_info.py:115:41-45: `info` may be uninitialized [unbound-name] -ERROR homeassistant/helpers/system_info.py:115:41-59: Cannot set item in `dict[str, bool | str]` [unsupported-operation] -ERROR homeassistant/helpers/system_info.py:116:34-53: Cannot set item in `dict[str, bool | str]` [unsupported-operation] +ERROR homeassistant/helpers/system_info.py:115:41-59: `Unknown | None` is not assignable to TypedDict key `docker_version` with type `bool | str` [bad-typed-dict-key] +ERROR homeassistant/helpers/system_info.py:116:34-53: `Any | None` is not assignable to TypedDict key `chassis` with type `bool | str` [bad-typed-dict-key] ERROR homeassistant/helpers/system_info.py:118:12-16: `info` may be uninitialized [unbound-name] ERROR homeassistant/helpers/template/__init__.py:255:35-41: No matching overload found for function `set.__init__` called with arguments: (Self@gen_result_wrapper.Wrapper) [no-matching-overload] ERROR homeassistant/helpers/template/__init__.py:391:16-19: `ret` may be uninitialized [unbound-name] @@ -38029,14 +37276,9 @@ ERROR homeassistant/util/loop.py:163:29-46: `integration_frame` may be uninitial ERROR homeassistant/util/loop.py:164:16-33: `integration_frame` may be uninitialized [unbound-name] ERROR homeassistant/util/loop.py:164:60-77: `integration_frame` may be uninitialized [unbound-name] ERROR homeassistant/util/loop.py:165:17-34: `integration_frame` may be uninitialized [unbound-name] -ERROR homeassistant/util/read_only_dict.py:16:5-16: Class member `ReadOnlyDict.__setitem__` overrides parent class `dict` in an inconsistent manner [bad-override] -ERROR homeassistant/util/read_only_dict.py:17:5-16: Class member `ReadOnlyDict.__delitem__` overrides parent class `dict` in an inconsistent manner [bad-override] -ERROR homeassistant/util/read_only_dict.py:18:5-8: Class member `ReadOnlyDict.pop` overrides parent class `dict` in an inconsistent manner [bad-override] -ERROR homeassistant/util/read_only_dict.py:21:5-11: Class member `ReadOnlyDict.update` overrides parent class `dict` in an inconsistent manner [bad-override] -ERROR homeassistant/util/read_only_dict.py:22:5-15: Class member `ReadOnlyDict.setdefault` overrides parent class `dict` in an inconsistent manner [bad-override] ERROR homeassistant/util/unit_conversion.py:175:25-42: No matching overload found for function `max` called with arguments: (Literal[0], float) [no-matching-overload] ERROR homeassistant/util/variance.py:41:43-61: `-` is not supported between `_R` and `_R` [unsupported-operation] ERROR homeassistant/util/variance.py:41:43-61: `-` is not supported between `_R` and `_R` [unsupported-operation] ERROR homeassistant/util/variance.py:41:43-61: Argument `float | int | timedelta` is not assignable to parameter `x` with type `SupportsAbs[float]` in function `abs` [bad-argument-type] INFO Checking project configured at `/pyrefly.toml` - INFO 37,402 errors (532 suppressed) + INFO 36,658 errors (523 suppressed) diff --git a/scripts/ty_benchmark/snapshots/homeassistant_Pyright.txt b/scripts/ty_benchmark/snapshots/homeassistant_Pyright.txt index e854c9b3eb..444ce77f6f 100644 --- a/scripts/ty_benchmark/snapshots/homeassistant_Pyright.txt +++ b/scripts/ty_benchmark/snapshots/homeassistant_Pyright.txt @@ -32036,8 +32036,6 @@   Attribute "pid" is unknown (reportAttributeAccessIssue) /homeassistant/components/systemmonitor/coordinator.py:253:33 - error: Cannot access attribute "name" for class "Error"   Attribute "name" is unknown (reportAttributeAccessIssue) - /homeassistant/components/systemmonitor/coordinator.py:266:38 - error: "sensors_temperatures" is not a known attribute of module "psutil" (reportAttributeAccessIssue) - /homeassistant/components/systemmonitor/coordinator.py:274:44 - error: "sensors_fans" is not a known attribute of module "psutil" (reportAttributeAccessIssue) /homeassistant/components/systemmonitor/sensor.py /homeassistant/components/systemmonitor/sensor.py:643:14 - error: "entity_description" overrides symbol of same name in class "Entity"   Variable is mutable so its type is invariant @@ -42035,4 +42033,4 @@ /homeassistant/util/loop.py:164:16 - error: "integration_frame" is possibly unbound (reportPossiblyUnboundVariable) /homeassistant/util/loop.py:164:60 - error: "integration_frame" is possibly unbound (reportPossiblyUnboundVariable) /homeassistant/util/loop.py:165:17 - error: "integration_frame" is possibly unbound (reportPossiblyUnboundVariable) -19459 errors, 18 warnings, 0 informations +19457 errors, 18 warnings, 0 informations diff --git a/scripts/ty_benchmark/snapshots/homeassistant_mypy.txt b/scripts/ty_benchmark/snapshots/homeassistant_mypy.txt index ff6383dc51..d3c3fd6523 100644 --- a/scripts/ty_benchmark/snapshots/homeassistant_mypy.txt +++ b/scripts/ty_benchmark/snapshots/homeassistant_mypy.txt @@ -53,6 +53,6 @@ homeassistant/runner.py:284: error: function asyncio.events.set_event_loop_polic homeassistant/scripts/auth.py:51: error: function asyncio.events.set_event_loop_policy is deprecated: Deprecated since Python 3.14; will be removed in Python 3.16. [deprecated] homeassistant/scripts/__init__.py:64: error: function asyncio.events.set_event_loop_policy is deprecated: Deprecated since Python 3.14; will be removed in Python 3.16. [deprecated] Found 54 errors in 13 files (checked 8626 source files) -/Users/micha/.local/share/uv/python/cpython-3.14.0-macos-aarch64-none/lib/python3.14/importlib/__init__.py:88: UserWarning: Core Pydantic V1 functionality isn't compatible with Python 3.14 or greater. +/home/micha/.local/share/uv/python/cpython-3.14.2-linux-x86_64-gnu/lib/python3.14/importlib/__init__.py:88: UserWarning: Core Pydantic V1 functionality isn't compatible with Python 3.14 or greater. return _bootstrap._gcd_import(name[level:], package, level) Warning: unused section(s) in mypy.ini: [mypy-tests.*] diff --git a/scripts/ty_benchmark/snapshots/homeassistant_ty.txt b/scripts/ty_benchmark/snapshots/homeassistant_ty.txt index e6e771f7e5..dd80795364 100644 --- a/scripts/ty_benchmark/snapshots/homeassistant_ty.txt +++ b/scripts/ty_benchmark/snapshots/homeassistant_ty.txt @@ -92,9 +92,6 @@ homeassistant/components/alert/__init__.py:107:17: error[invalid-argument-type] homeassistant/components/alexa/auth.py:171:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `None` homeassistant/components/alexa/auth.py:173:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `None` homeassistant/components/alexa/auth.py:175:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `None` -homeassistant/components/alexa/state_report.py:341:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/alexa/state_report.py:342:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _async_entity_state_listener(event_: Event[EventStateChangedData]) -> CoroutineType[Any, Any, None]` -homeassistant/components/alexa/state_report.py:343:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _async_entity_state_filter(data: EventStateChangedData) -> bool` homeassistant/components/alpha_vantage/sensor.py:8:6: error[unresolved-import] Cannot resolve imported module `alpha_vantage.foreignexchange` homeassistant/components/alpha_vantage/sensor.py:9:6: error[unresolved-import] Cannot resolve imported module `alpha_vantage.timeseries` homeassistant/components/altruist/sensor.py:274:16: error[unresolved-attribute] Object of type `SensorEntityDescription` has no attribute `native_value_fn` @@ -111,11 +108,7 @@ homeassistant/components/amcrest/camera.py:266:17: error[invalid-argument-type] homeassistant/components/amcrest/sensor.py:9:6: error[unresolved-import] Cannot resolve imported module `amcrest` homeassistant/components/ampio/air_quality.py:8:6: error[unresolved-import] Cannot resolve imported module `asmog` homeassistant/components/analytics/analytics.py:182:16: error[invalid-return-type] Return type does not match returned value: expected `AnalyticsPlatformProtocol | None`, found `ModuleType` -homeassistant/components/androidtv/entity.py:46:43: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/androidtv/entity.py:46:82: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/androidtv/entity.py:54:42: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/androidtv/entity.py:55:43: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/androidtv/entity.py:75:21: error[unresolved-attribute] Object of type `(...) -> Awaitable[Unknown]` has no attribute `__name__` +homeassistant/components/androidtv/entity.py:75:21: error[unresolved-attribute] Object of type `(...) -> Awaitable[_R@adb_decorator]` has no attribute `__name__` homeassistant/components/anel_pwrctrl/switch.py:9:6: error[unresolved-import] Cannot resolve imported module `anel_pwrctrl` homeassistant/components/anglian_water/config_flow.py:82:44: warning[possibly-missing-attribute] Attribute `refresh_token` may be missing on object of type `(str & BaseAuth) | MSOB2CAuth` homeassistant/components/anthemav/config_flow.py:74:47: error[unresolved-attribute] Object of type `Protocol` has no attribute `macaddress` @@ -133,13 +126,10 @@ homeassistant/components/anthropic/entity.py:428:20: error[unresolved-reference] homeassistant/components/anthropic/entity.py:504:21: error[unresolved-reference] Name `current_tool_args` used when not defined homeassistant/components/anthropic/entity.py:655:44: warning[possibly-missing-attribute] Attribute `attachments` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` homeassistant/components/anthropic/entity.py:667:64: warning[possibly-missing-attribute] Attribute `attachments` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` -homeassistant/components/apache_kafka/__init__.py:133:37: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/apache_kafka/__init__.py:133:58: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@start.write(event: Event[EventStateChangedData]) -> CoroutineType[Any, Any, None]` homeassistant/components/api/__init__.py:286:28: error[invalid-argument-type] Argument to bound method `async_set` is incorrect: Expected `str`, found `dict[str, dict[str, Any] | list[Any] | str | ... omitted 3 union elements] | list[dict[str, Any] | list[Any] | str | ... omitted 3 union elements] | str | int | float` homeassistant/components/api/__init__.py:286:39: error[invalid-argument-type] Argument to bound method `async_set` is incorrect: Expected `Mapping[str, Any] | None`, found `dict[str, dict[str, Any] | list[Any] | str | ... omitted 3 union elements] | list[dict[str, Any] | list[Any] | str | ... omitted 3 union elements] | str | ... omitted 3 union elements` homeassistant/components/api/__init__.py:286:51: error[invalid-argument-type] Argument to bound method `async_set` is incorrect: Expected `bool`, found `dict[str, Any] | list[Any] | str | ... omitted 3 union elements` -homeassistant/components/api/__init__.py:431:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/api/__init__.py:432:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _async_save_changed_entities(event: Event[EventStateChangedData]) -> None` +homeassistant/components/api/__init__.py:356:21: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["new_state", "old_state"]` and value of type `State & ~AlwaysFalsy` on object of type `dict[str, JsonValueType]` homeassistant/components/apple_tv/__init__.py:151:10: error[invalid-type-form] Variable of type `Never` is not allowed in a type expression homeassistant/components/apple_tv/__init__.py:284:30: error[invalid-type-form] Variable of type `Never` is not allowed in a type expression homeassistant/components/apple_tv/__init__.py:308:25: error[invalid-type-form] Variable of type `Never` is not allowed in a type expression @@ -236,12 +226,12 @@ homeassistant/components/atag/water_heater.py:68:16: warning[possibly-missing-at homeassistant/components/aten_pe/switch.py:8:6: error[unresolved-import] Cannot resolve imported module `atenpdu` homeassistant/components/atome/sensor.py:8:6: error[unresolved-import] Cannot resolve imported module `pyatome.client` homeassistant/components/august/__init__.py:73:38: error[invalid-argument-type] Argument to bound method `async_setup` is incorrect: Expected `Config`, found `dict[Unknown | str, Unknown | Brand]` -homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'username' in TypedDict `Config` constructor -homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'password' in TypedDict `Config` constructor -homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'login_method' in TypedDict `Config` constructor homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'access_token_cache_file' in TypedDict `Config` constructor homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'install_id' in TypedDict `Config` constructor +homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'login_method' in TypedDict `Config` constructor +homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'password' in TypedDict `Config` constructor homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'timeout' in TypedDict `Config` constructor +homeassistant/components/august/__init__.py:73:38: error[missing-typed-dict-key] Missing required key 'username' in TypedDict `Config` constructor homeassistant/components/august/binary_sensor.py:75:9: error[invalid-argument-type] Argument is incorrect: Expected `(AugustData, DoorbellDetail | LockDetail, /) -> Activity | None`, found `def retrieve_online_state(data: AugustData, detail: DoorbellDetail | LockDetail) -> bool` homeassistant/components/august/binary_sensor.py:103:12: warning[possibly-missing-attribute] Attribute `doorsense` may be missing on object of type `DoorbellDetail | LockDetail` homeassistant/components/august/binary_sensor.py:106:12: warning[possibly-missing-attribute] Attribute `doorbell` may be missing on object of type `DoorbellDetail | LockDetail` @@ -310,6 +300,7 @@ homeassistant/components/azure_storage/backup.py:80:53: error[unresolved-attribu homeassistant/components/azure_storage/backup.py:85:55: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@handle_backup_errors]` has no attribute `__name__` homeassistant/components/azure_storage/backup.py:90:17: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@handle_backup_errors]` has no attribute `__name__` homeassistant/components/azure_storage/backup.py:95:53: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@handle_backup_errors]` has no attribute `__name__` +homeassistant/components/azure_storage/backup.py:145:13: error[invalid-argument-type] Argument is incorrect: Expected `bytes | str | Iterable[AnyStr@upload_blob] | AsyncIterable[AnyStr@upload_blob]`, found `AsyncIterator[bytes]` homeassistant/components/backblaze_b2/__init__.py:51:16: error[invalid-return-type] Return type does not match returned value: expected `b2sdk.v2.bucket.Bucket`, found `b2sdk._internal.bucket.Bucket` homeassistant/components/backblaze_b2/backup.py:95:42: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, T@handle_b2_errors]` has no attribute `__name__` homeassistant/components/backup/manager.py:1610:16: error[invalid-return-type] Return type does not match returned value: expected `StoredKnownBackup`, found `dict[Unknown | str, Unknown | str | list[dict[Unknown | str, Unknown | str | None] | Unknown] | list[str]]` @@ -434,7 +425,6 @@ homeassistant/components/caldav/todo.py:71:39: error[invalid-argument-type] Argu homeassistant/components/caldav/todo.py:75:36: error[invalid-argument-type] Argument to function `get_attr_value` is incorrect: Expected `CalendarObjectResource`, found `~AlwaysFalsy` homeassistant/components/caldav/todo.py:84:28: error[invalid-argument-type] Argument to function `get_attr_value` is incorrect: Expected `CalendarObjectResource`, found `~AlwaysFalsy` homeassistant/components/caldav/todo.py:88:36: error[invalid-argument-type] Argument to function `get_attr_value` is incorrect: Expected `CalendarObjectResource`, found `~AlwaysFalsy` -homeassistant/components/calendar/trigger.py:172:27: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/components/cambridge_audio/entity.py:32:38: error[unresolved-attribute] Object of type `(...) -> Awaitable[None]` has no attribute `__name__` homeassistant/components/canary/camera.py:173:17: error[invalid-argument-type] Argument to function `async_aiohttp_proxy_stream` is incorrect: Expected `StreamReader`, found `StreamReader` homeassistant/components/cast/const.py:27:36: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 @@ -444,9 +434,7 @@ homeassistant/components/cast/discovery.py:64:13: error[invalid-method-override] homeassistant/components/cast/discovery.py:68:13: error[invalid-method-override] Invalid override of method `update_cast`: Definition is incompatible with `AbstractCastListener.update_cast` homeassistant/components/cast/helpers.py:132:13: error[unknown-argument] Argument `is_dynamic_group` does not match any known parameter homeassistant/components/cast/helpers.py:268:12: error[unresolved-attribute] Object of type `object` has no attribute `ClientError` -homeassistant/components/cast/media_player.py:94:39: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/cast/media_player.py:95:34: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/cast/media_player.py:105:46: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__name__` +homeassistant/components/cast/media_player.py:105:46: error[unresolved-attribute] Object of type `(...) -> _R@api_error` has no attribute `__name__` homeassistant/components/cast/media_player.py:353:28: warning[possibly-missing-attribute] Attribute `status` may be missing on object of type `Chromecast | None` homeassistant/components/cast/media_player.py:354:29: warning[possibly-missing-attribute] Attribute `media_controller` may be missing on object of type `Chromecast | None` homeassistant/components/cast/media_player.py:460:35: warning[possibly-missing-attribute] Attribute `get_multizone_memberships` may be missing on object of type `Unknown | None` @@ -475,8 +463,6 @@ homeassistant/components/cloud/__init__.py:314:51: error[invalid-argument-type] homeassistant/components/cloud/__init__.py:314:51: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Literal["development", "production"]`, found `Unknown | str` homeassistant/components/cloud/__init__.py:314:51: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `dict[Literal["acme_directory", "llm_connection_details", "relayer_connect", "remote_access_resolve_dns_cname", "subscription_info", "subscription_migrate_paypal", "voice_connection_details"], str] | None`, found `Unknown | str` homeassistant/components/cloud/ai_task.py:132:16: warning[possibly-missing-attribute] Attribute `content` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` -homeassistant/components/cloud/alexa_config.py:272:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/cloud/alexa_config.py:273:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@async_initialize._handle_entity_registry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> CoroutineType[Any, Any, None]` homeassistant/components/cloud/alexa_config.py:543:28: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" homeassistant/components/cloud/alexa_config.py:547:45: error[invalid-key] Unknown key "old_entity_id" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "old_entity_id" homeassistant/components/cloud/client.py:97:33: error[unresolved-attribute] Object of type `object` has no attribute `AppRunner` @@ -488,10 +474,6 @@ homeassistant/components/cloud/entity.py:127:21: error[invalid-argument-type] Ar homeassistant/components/cloud/entity.py:461:44: warning[possibly-missing-attribute] Attribute `attachments` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` homeassistant/components/cloud/entity.py:462:64: warning[possibly-missing-attribute] Attribute `attachments` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` homeassistant/components/cloud/entity.py:463:31: warning[possibly-missing-attribute] Attribute `content` may be missing on object of type `SystemContent | UserContent | AssistantContent | ToolResultContent` -homeassistant/components/cloud/google_config.py:269:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/cloud/google_config.py:270:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@async_initialize._handle_entity_registry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` -homeassistant/components/cloud/google_config.py:275:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/components/cloud/google_config.py:276:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@async_initialize._handle_device_registry_updated(event: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> None` homeassistant/components/cloud/google_config.py:471:28: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" homeassistant/components/cloud/google_config.py:495:76: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Create`: Unknown key "changes" homeassistant/components/cloud/google_config.py:495:76: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Remove`: Unknown key "changes" @@ -512,12 +494,6 @@ homeassistant/components/conversation/chat_log.py:587:40: error[invalid-key] Unk homeassistant/components/conversation/chat_log.py:588:37: error[invalid-key] Unknown key "tool_name" for TypedDict `AssistantContentDeltaDict`: Unknown key "tool_name" homeassistant/components/conversation/chat_log.py:589:39: error[invalid-key] Unknown key "tool_result" for TypedDict `AssistantContentDeltaDict`: Unknown key "tool_result" homeassistant/components/conversation/default_agent.py:275:33: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" -homeassistant/components/conversation/default_agent.py:290:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventAreaRegistryUpdatedData]` -homeassistant/components/conversation/default_agent.py:294:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` -homeassistant/components/conversation/default_agent.py:298:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/conversation/default_agent.py:300:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `bound method Self@_listen_clear_slot_list._filter_entity_registry_changes(event_data: _EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update) -> bool` -homeassistant/components/conversation/default_agent.py:303:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/conversation/default_agent.py:305:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `bound method Self@_listen_clear_slot_list._filter_state_changes(event_data: EventStateChangedData) -> bool` homeassistant/components/counter/__init__.py:219:53: error[invalid-argument-type] Argument to function `max` is incorrect: Argument type `int | None` does not satisfy upper bound `SupportsDunderLT[Any] | SupportsDunderGT[Any]` of type variable `SupportsRichComparisonT` homeassistant/components/counter/__init__.py:221:53: error[invalid-argument-type] Argument to function `min` is incorrect: Argument type `int | None | Unknown` does not satisfy upper bound `SupportsDunderLT[Any] | SupportsDunderGT[Any]` of type variable `SupportsRichComparisonT` homeassistant/components/cppm_tracker/device_tracker.py:8:6: error[unresolved-import] Cannot resolve imported module `clearpasspy` @@ -547,7 +523,6 @@ homeassistant/components/danfoss_air/__init__.py:7:6: error[unresolved-import] C homeassistant/components/danfoss_air/binary_sensor.py:5:6: error[unresolved-import] Cannot resolve imported module `pydanfossair.commands` homeassistant/components/danfoss_air/sensor.py:7:6: error[unresolved-import] Cannot resolve imported module `pydanfossair.commands` homeassistant/components/danfoss_air/switch.py:8:6: error[unresolved-import] Cannot resolve imported module `pydanfossair.commands` -homeassistant/components/datadog/__init__.py:124:31: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` homeassistant/components/deconz/button.py:104:13: error[unresolved-attribute] Object of type `ButtonEntityDescription` has no attribute `button_fn` homeassistant/components/deconz/light.py:255:12: error[unsupported-operator] Operator `not in` is not supported between objects of type `Unknown | ColorMode` and `set[ColorMode] | set[str] | None` homeassistant/components/deconz/light.py:303:16: error[unsupported-operator] Operator `in` is not supported between objects of type `Literal[ColorMode.XY]` and `set[ColorMode] | set[str] | None` @@ -576,8 +551,6 @@ homeassistant/components/denonavr/receiver.py:102:27: error[unresolved-attribute homeassistant/components/devialet/config_flow.py:51:13: error[invalid-argument-type] Argument to bound method `async_create_entry` is incorrect: Expected `str`, found `str | None` homeassistant/components/devialet/diagnostics.py:16:12: error[invalid-return-type] Return type does not match returned value: expected `dict[str, Any]`, found `Unknown | None` homeassistant/components/devialet/media_player.py:112:16: error[invalid-return-type] Return type does not match returned value: expected `bool`, found `Unknown | bool | None` -homeassistant/components/device_tracker/config_entry.py:166:27: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/components/device_tracker/config_entry.py:166:61: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def handle_device_event(ev: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> None` homeassistant/components/device_tracker/const.py:52:42: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/components/device_tracker/legacy.py:409:12: error[missing-argument] No argument provided for required parameter `config` homeassistant/components/device_tracker/legacy.py:409:34: error[invalid-argument-type] Argument is incorrect: Expected `tuple[str, ...]`, found `str` @@ -716,15 +689,8 @@ homeassistant/components/econet/climate.py:68:30: error[invalid-argument-type] A homeassistant/components/econet/sensor.py:125:16: warning[possibly-missing-attribute] Attribute `energy_type` may be missing on object of type `Unknown | Equipment` homeassistant/components/econet/switch.py:29:33: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Thermostat`, found `Equipment` homeassistant/components/econet/water_heater.py:57:31: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `WaterHeater`, found `Equipment` -homeassistant/components/ecovacs/number.py:111:52: error[invalid-type-arguments] Too many type arguments to class `CapabilitySet`: expected 1, got 2 -homeassistant/components/ecovacs/number.py:111:52: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[int]`? -homeassistant/components/ecovacs/number.py:121:43: error[invalid-type-arguments] Too many type arguments to class `CapabilitySet`: expected 1, got 2 -homeassistant/components/ecovacs/number.py:121:43: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[int]`? homeassistant/components/ecovacs/select.py:87:46: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `CapabilityMap`, found `CapabilityMap | None` -homeassistant/components/ecovacs/select.py:97:57: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[str]`? -homeassistant/components/ecovacs/select.py:97:64: error[invalid-type-arguments] Too many type arguments to class `CapabilitySetTypes`: expected 2, got 3 -homeassistant/components/ecovacs/select.py:108:48: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[str]`? -homeassistant/components/ecovacs/select.py:108:55: error[invalid-type-arguments] Too many type arguments to class `CapabilitySetTypes`: expected 2, got 3 +homeassistant/components/ecovacs/select.py:203:40: error[too-many-positional-arguments] Too many positional arguments: expected 0, got 1 homeassistant/components/ecowitt/binary_sensor.py:51:13: error[invalid-argument-type] Argument to function `replace` is incorrect: Argument type `Unknown | BinarySensorEntityDescription` does not satisfy upper bound `DataclassInstance` of type variable `_DataclassT` homeassistant/components/ecowitt/sensor.py:283:13: error[invalid-argument-type] Argument to function `replace` is incorrect: Argument type `Unknown | SensorEntityDescription` does not satisfy upper bound `DataclassInstance` of type variable `_DataclassT` homeassistant/components/edimax/switch.py:7:6: error[unresolved-import] Cannot resolve imported module `pyedimax.smartplug` @@ -732,6 +698,22 @@ homeassistant/components/efergy/sensor.py:129:17: error[invalid-argument-type] A homeassistant/components/egardia/__init__.py:5:6: error[unresolved-import] Cannot resolve imported module `pythonegardia` homeassistant/components/egardia/alarm_control_panel.py:104:44: warning[possibly-missing-attribute] Attribute `items` may be missing on object of type `Unknown | None` homeassistant/components/ekeybionyx/config_flow.py:110:47: error[invalid-assignment] Object of type `list[dict[Unknown | str, Unknown | str] | Unknown]` is not assignable to `list[SelectOptionDict]` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `VoiceSettings | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `Sequence[PronunciationDictionaryVersionLocator] | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `Sequence[str] | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `Sequence[str] | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | str | VoiceSettings` +homeassistant/components/elevenlabs/tts.py:289:25: error[invalid-argument-type] Argument is incorrect: Expected `RequestOptions | None`, found `Unknown | str | VoiceSettings` homeassistant/components/eliqonline/sensor.py:8:8: error[unresolved-import] Cannot resolve imported module `eliqonline` homeassistant/components/elkm1/config_flow.py:203:9: error[invalid-method-override] Invalid override of method `is_matching`: Definition is incompatible with `ConfigFlow.is_matching` homeassistant/components/elmax/__init__.py:50:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `SSLContext`, found `None | SSLContext` @@ -796,6 +778,7 @@ homeassistant/components/eufy/light.py:102:16: error[unsupported-operator] Opera homeassistant/components/eufy/light.py:149:17: error[non-subscriptable] Cannot subscript object of type `None` with no `__getitem__` method homeassistant/components/eufy/light.py:149:30: error[non-subscriptable] Cannot subscript object of type `None` with no `__getitem__` method homeassistant/components/eufy/switch.py:7:8: error[unresolved-import] Cannot resolve imported module `lakeside` +homeassistant/components/evohome/entity.py:171:21: error[unsupported-operator] Operator `<` is not supported between objects of type `(Unknown & ~None) | datetime | int | float | str` and `datetime` homeassistant/components/evohome/storage.py:116:13: error[unsupported-operator] Operator `|=` is unsupported between objects of type `dict[str, object]` and `SessionIdEntryT` homeassistant/components/ezviz/alarm_control_panel.py:104:17: error[invalid-argument-type] Argument to bound method `api_set_defence_mode` is incorrect: Expected `DefenseModeType`, found `Literal[1]` homeassistant/components/ezviz/alarm_control_panel.py:115:17: error[invalid-argument-type] Argument to bound method `api_set_defence_mode` is incorrect: Expected `DefenseModeType`, found `Literal[2]` @@ -1010,9 +993,6 @@ homeassistant/components/google_assistant/report_state.py:107:47: warning[possib homeassistant/components/google_assistant/report_state.py:111:17: warning[possibly-missing-attribute] Attribute `entity_id` may be missing on object of type `Unknown | State | None` homeassistant/components/google_assistant/report_state.py:164:54: error[invalid-argument-type] Argument to function `create_checker` is incorrect: Expected `ExtraCheckTypeFunc | None`, found `def extra_significant_check(hass: HomeAssistant, old_state: str, old_attrs: dict[Unknown, Unknown], old_extra_arg: dict[Unknown, Unknown], new_state: str, new_attrs: dict[Unknown, Unknown], new_extra_arg: dict[Unknown, Unknown]) -> Unknown` homeassistant/components/google_assistant/report_state.py:178:17: error[invalid-argument-type] Argument to bound method `async_is_significant_change` is incorrect: Expected `State`, found `Unknown | State | None` -homeassistant/components/google_assistant/report_state.py:190:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/google_assistant/report_state.py:191:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _async_entity_state_listener(event: Event[EventStateChangedData]) -> CoroutineType[Any, Any, None]` -homeassistant/components/google_assistant/report_state.py:192:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _async_entity_state_filter(data: EventStateChangedData) -> bool` homeassistant/components/google_assistant/trait.py:381:9: error[invalid-method-override] Invalid override of method `supported`: Definition is incompatible with `_Trait.supported` homeassistant/components/google_assistant/trait.py:420:9: error[invalid-method-override] Invalid override of method `supported`: Definition is incompatible with `_Trait.supported` homeassistant/components/google_assistant/trait.py:478:9: error[invalid-method-override] Invalid override of method `supported`: Definition is incompatible with `_Trait.supported` @@ -1048,8 +1028,6 @@ homeassistant/components/google_maps/device_tracker.py:8:6: error[unresolved-imp homeassistant/components/google_maps/device_tracker.py:9:6: error[unresolved-import] Cannot resolve imported module `locationsharinglib.locationsharinglibexceptions` homeassistant/components/google_maps/device_tracker.py:115:16: error[unsupported-operator] Operator `<` is not supported between objects of type `datetime` and `str | datetime` homeassistant/components/google_maps/device_tracker.py:130:13: error[invalid-assignment] Invalid subscript assignment with key of type `str` and value of type `datetime` on object of type `dict[str, str]` -homeassistant/components/google_pubsub/__init__.py:77:21: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/google_pubsub/__init__.py:77:42: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def send_to_pubsub(event: Event[EventStateChangedData]) -> Unknown` homeassistant/components/google_tasks/api.py:63:28: error[unresolved-attribute] Object of type `Resource` has no attribute `tasklists` homeassistant/components/google_tasks/api.py:70:28: error[unresolved-attribute] Object of type `Resource` has no attribute `tasks` homeassistant/components/google_tasks/api.py:86:28: error[unresolved-attribute] Object of type `Resource` has no attribute `tasks` @@ -1103,14 +1081,6 @@ homeassistant/components/harmony/data.py:113:68: error[invalid-argument-type] Ar homeassistant/components/harmony/data.py:113:68: error[invalid-argument-type] Argument is incorrect: Expected `Future[Unknown] | Event | ((object, Any | None, /) -> Any) | None`, found `Unknown | (bound method Self@connect._config_updated(_: dict[Unknown, Unknown] | None = None) -> None) | (bound method Self@connect._connected(_: str | None = None) -> None) | ... omitted 3 union elements` homeassistant/components/harmony/data.py:113:68: error[invalid-argument-type] Argument is incorrect: Expected `Future[Unknown] | Event | ((object, Any | None, /) -> Any) | None`, found `Unknown | (bound method Self@connect._config_updated(_: dict[Unknown, Unknown] | None = None) -> None) | (bound method Self@connect._connected(_: str | None = None) -> None) | ... omitted 3 union elements` homeassistant/components/harmony/data.py:234:21: error[invalid-argument-type] Argument is incorrect: Expected `int`, found `str` -homeassistant/components/harmony/subscriber.py:13:32: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? -homeassistant/components/harmony/subscriber.py:13:36: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/components/harmony/subscriber.py:14:33: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[tuple[Unknown, ...]]`? -homeassistant/components/harmony/subscriber.py:14:42: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/components/hassio/addon_manager.py:38:36: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/hassio/addon_manager.py:38:78: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/hassio/addon_manager.py:44:45: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/hassio/addon_manager.py:45:46: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 homeassistant/components/hassio/repairs.py:226:18: warning[possibly-missing-attribute] Attribute `key` may be missing on object of type `(SupervisorIssues & ~AlwaysTruthy & ~AlwaysFalsy) | (Issue & ~AlwaysFalsy)` homeassistant/components/hassio/repairs.py:228:18: warning[possibly-missing-attribute] Attribute `key` may be missing on object of type `(SupervisorIssues & ~AlwaysTruthy & ~AlwaysFalsy) | (Issue & ~AlwaysFalsy)` homeassistant/components/hassio/repairs.py:230:18: warning[possibly-missing-attribute] Attribute `key` may be missing on object of type `(SupervisorIssues & ~AlwaysTruthy & ~AlwaysFalsy) | (Issue & ~AlwaysFalsy)` @@ -1118,10 +1088,6 @@ homeassistant/components/haveibeenpwned/sensor.py:94:17: error[invalid-argument- homeassistant/components/hddtemp/sensor.py:68:23: error[no-matching-overload] No overload of function `iter` matches arguments homeassistant/components/hdmi_cec/__init__.py:258:49: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `list[int]`, found `Unknown | Literal[""]` homeassistant/components/heatmiser/climate.py:8:6: error[unresolved-import] Cannot resolve imported module `heatmiserv3` -homeassistant/components/heos/media_player.py:144:30: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/heos/media_player.py:144:56: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/heos/media_player.py:147:39: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/heos/media_player.py:147:67: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 homeassistant/components/here_travel_time/coordinator.py:226:21: error[invalid-argument-type] Argument is incorrect: Expected `int | float`, found `str` homeassistant/components/here_travel_time/coordinator.py:226:48: error[invalid-argument-type] Argument is incorrect: Expected `int | float`, found `str` homeassistant/components/here_travel_time/coordinator.py:229:21: error[invalid-argument-type] Argument is incorrect: Expected `int | float`, found `str` @@ -1385,16 +1351,6 @@ homeassistant/components/horizon/media_player.py:10:6: error[unresolved-import] homeassistant/components/hp_ilo/sensor.py:8:8: error[unresolved-import] Cannot resolve imported module `hpilo` homeassistant/components/html5/notify.py:481:13: warning[possibly-missing-attribute] Attribute `get` may be missing on object of type `Unknown | str | dict[Unknown, Unknown]` homeassistant/components/html5/notify.py:484:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `str` -homeassistant/components/http/decorators.py:33:41: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:34:40: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:44:47: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:45:41: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:53:47: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:59:45: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:60:44: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:62:42: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:67:50: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/http/decorators.py:68:45: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 homeassistant/components/huawei_lte/sensor.py:903:69: error[invalid-argument-type] Argument is incorrect: Expected `str`, found `Unknown | None` homeassistant/components/hue/__init__.py:40:37: warning[possibly-missing-attribute] Attribute `bridge_id` may be missing on object of type `Unknown | Config | None | ConfigController` homeassistant/components/hue/__init__.py:76:54: warning[possibly-missing-attribute] Attribute `mac_address` may be missing on object of type `Unknown | Config | None | ConfigController` @@ -1734,7 +1690,7 @@ homeassistant/components/imap/coordinator.py:353:31: warning[possibly-missing-at homeassistant/components/imap/coordinator.py:531:46: warning[possibly-missing-attribute] Attribute `idle_start` may be missing on object of type `Unknown | IMAP4_SSL | None` homeassistant/components/imap/coordinator.py:532:23: warning[possibly-missing-attribute] Attribute `wait_server_push` may be missing on object of type `Unknown | IMAP4_SSL | None` homeassistant/components/imap/coordinator.py:533:17: warning[possibly-missing-attribute] Attribute `idle_done` may be missing on object of type `Unknown | IMAP4_SSL | None` -homeassistant/components/input_datetime/__init__.py:295:34: warning[possibly-missing-attribute] Attribute `replace` may be missing on object of type `datetime | None | Unknown` +homeassistant/components/input_datetime/__init__.py:295:34: warning[possibly-missing-attribute] Attribute `replace` may be missing on object of type `datetime | None` homeassistant/components/input_datetime/__init__.py:404:20: warning[possibly-missing-attribute] Attribute `date` may be missing on object of type `Unknown | None | datetime` homeassistant/components/input_datetime/__init__.py:407:20: warning[possibly-missing-attribute] Attribute `time` may be missing on object of type `Unknown | None | datetime` homeassistant/components/input_number/__init__.py:316:40: error[unsupported-operator] Operator `+` is unsupported between objects of type `int | float | None` and `int` @@ -1944,10 +1900,6 @@ homeassistant/components/isy994/switch.py:173:9: error[invalid-method-override] homeassistant/components/itach/remote.py:9:8: error[unresolved-import] Cannot resolve imported module `pyitachip2ir` homeassistant/components/itunes/media_player.py:279:17: warning[possibly-missing-attribute] Attribute `update_state` may be missing on object of type `Unknown | None` homeassistant/components/itunes/media_player.py:298:16: error[unsupported-operator] Operator `/` is unsupported between objects of type `Unknown | None` and `float` -homeassistant/components/izone/climate.py:122:40: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/izone/climate.py:122:70: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/izone/climate.py:123:44: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/izone/climate.py:123:76: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 homeassistant/components/izone/climate.py:367:16: error[invalid-return-type] Return type does not match returned value: expected `int | float`, found `Unknown | int | float | None` homeassistant/components/izone/climate.py:469:25: error[invalid-argument-type] Invalid argument to key "identifiers" with declared type `set[tuple[str, str]]` on TypedDict `DeviceInfo`: value of type `set[Unknown | tuple[str, Unknown & ~AlwaysFalsy, int]]` homeassistant/components/izone/climate.py:539:16: error[invalid-return-type] Return type does not match returned value: expected `int | float`, found `Unknown | int | float | None` @@ -2133,6 +2085,7 @@ homeassistant/components/lifx/coordinator.py:202:27: error[non-subscriptable] Ca homeassistant/components/lifx/coordinator.py:203:23: error[non-subscriptable] Cannot subscript object of type `None` with no `__getitem__` method homeassistant/components/lifx/coordinator.py:209:48: error[invalid-argument-type] Argument to function `__new__` is incorrect: Expected `Iterable[Unknown]`, found `Unknown | None | list[Unknown | None]` homeassistant/components/lifx/coordinator.py:210:17: error[invalid-assignment] Cannot assign to a subscript on an object of type `int` +homeassistant/components/lifx/coordinator.py:210:17: error[invalid-assignment] Cannot assign to a subscript on an object of type `None` homeassistant/components/lifx/coordinator.py:294:27: error[invalid-argument-type] Argument is incorrect: Expected `Message`, found `Light` homeassistant/components/lifx/coordinator.py:294:33: error[invalid-argument-type] Argument is incorrect: Expected `dict[str, Any] | None`, found `Message` homeassistant/components/lifx/coordinator.py:385:47: error[unresolved-attribute] Object of type `Message` has no attribute `signal` @@ -2207,9 +2160,6 @@ homeassistant/components/livisi/climate.py:93:13: error[invalid-argument-type] A homeassistant/components/livisi/coordinator.py:98:36: error[invalid-assignment] Object of type `Unknown | dict[str, Any] | None` is not assignable to `dict[str, Any]` homeassistant/components/livisi/coordinator.py:107:42: error[invalid-assignment] Object of type `Unknown | dict[str, Any]` is not assignable to `list[dict[str, Any]]` homeassistant/components/locative/device_tracker.py:58:9: error[call-non-callable] Object of type `None` is not callable -homeassistant/components/logbook/helpers.py:220:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/logbook/helpers.py:221:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _forward_state_events_filtered(event: Event[EventStateChangedData]) -> None` -homeassistant/components/logentries/__init__.py:54:21: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` homeassistant/components/london_underground/config_flow.py:36:9: error[invalid-method-override] Invalid override of method `async_get_options_flow`: Definition is incompatible with `ConfigFlow.async_get_options_flow` homeassistant/components/lookin/__init__.py:81:78: error[invalid-argument-type] Argument to function `start_lookin_udp` is incorrect: Expected `str`, found `None` homeassistant/components/lookin/__init__.py:82:20: error[invalid-return-type] Return type does not match returned value: expected `LookinUDPSubscriptions`, found `LookinUDPSubscriptions | None` @@ -2510,8 +2460,6 @@ homeassistant/components/mpd/media_player.py:515:19: warning[possibly-missing-at homeassistant/components/mpd/media_player.py:520:19: warning[possibly-missing-attribute] Attribute `play` may be missing on object of type `Unknown | MPDClient` homeassistant/components/mpd/media_player.py:526:19: warning[possibly-missing-attribute] Attribute `clear` may be missing on object of type `Unknown | MPDClient` homeassistant/components/mpd/media_player.py:531:19: warning[possibly-missing-attribute] Attribute `seekcur` may be missing on object of type `Unknown | MPDClient` -homeassistant/components/mqtt/client.py:307:18: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[ReceiveMessage]`? -homeassistant/components/mqtt/client.py:307:36: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/components/mqtt/client.py:879:30: error[unresolved-attribute] Object of type `object` has no attribute `__name__` homeassistant/components/mqtt/client.py:881:30: error[unresolved-attribute] Object of type `((ReceiveMessage, /) -> Coroutine[Any, Any, None] | None) & ~Top[partial[Unknown]]` has no attribute `__name__` homeassistant/components/mqtt/config_flow.py:3762:65: error[no-matching-overload] No overload of bound method `__init__` matches arguments @@ -2536,9 +2484,6 @@ homeassistant/components/mqtt/subscription.py:169:28: error[invalid-assignment] homeassistant/components/mqtt/valve.py:335:54: error[invalid-argument-type] Argument to bound method `_process_position_valve_update` is incorrect: Expected `str`, found `Unknown | str | bytes | ... omitted 6 union elements` homeassistant/components/mqtt/valve.py:335:72: error[invalid-argument-type] Argument to bound method `_process_position_valve_update` is incorrect: Expected `str`, found `Unknown | str | bytes | ... omitted 6 union elements` homeassistant/components/mqtt/valve.py:337:52: error[invalid-argument-type] Argument to bound method `_process_binary_valve_update` is incorrect: Expected `str`, found `Unknown | str | bytes | ... omitted 6 union elements` -homeassistant/components/mqtt_statestream/__init__.py:104:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/mqtt_statestream/__init__.py:104:34: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _state_publisher(evt: Event[EventStateChangedData]) -> CoroutineType[Any, Any, None]` -homeassistant/components/mqtt_statestream/__init__.py:104:52: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _event_filter(event_data: EventStateChangedData) -> bool` homeassistant/components/msteams/notify.py:7:8: error[unresolved-import] Cannot resolve imported module `pymsteams` homeassistant/components/music_assistant/media_player.py:615:39: warning[possibly-missing-attribute] Attribute `uri` may be missing on object of type `QueueItem | None` homeassistant/components/music_assistant/media_player.py:616:37: warning[possibly-missing-attribute] Attribute `duration` may be missing on object of type `QueueItem | None` @@ -2666,6 +2611,8 @@ homeassistant/components/ondilo_ico/coordinator.py:181:55: error[invalid-argumen homeassistant/components/onedrive/backup.py:92:17: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@handle_backup_errors]` has no attribute `__name__` homeassistant/components/onedrive/backup.py:100:17: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@handle_backup_errors]` has no attribute `__name__` homeassistant/components/onewire/onewirehub.py:47:42: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 2 +homeassistant/components/onkyo/receiver.py:85:36: error[invalid-argument-type] Argument is incorrect: Expected `InfoT@connect`, found `ReceiverInfo` +homeassistant/components/onkyo/receiver.py:93:44: warning[possibly-missing-attribute] Attribute `read` may be missing on object of type `Receiver[ReceiverInfo] | None` homeassistant/components/onvif/camera.py:182:17: error[invalid-argument-type] Argument to function `async_aiohttp_proxy_stream` is incorrect: Expected `StreamReader`, found `StreamReader` homeassistant/components/onvif/device.py:189:20: error[call-non-callable] Object of type `None` is not callable homeassistant/components/onvif/device.py:480:15: error[call-non-callable] Object of type `None` is not callable @@ -2769,11 +2716,7 @@ homeassistant/components/openai_conversation/entity.py:603:39: error[invalid-ass homeassistant/components/openai_conversation/entity.py:603:39: error[invalid-assignment] Invalid assignment to key "content" with declared type `Iterable[Content]` on TypedDict `ResponseReasoningItemParam`: value of type `list[Unknown | dict[Unknown | str, Unknown | str]]` homeassistant/components/openai_conversation/entity.py:603:39: error[invalid-assignment] Invalid assignment to key "content" with declared type `str | list[ResponseInputTextParam | ResponseInputImageParam | ResponseInputFileParam]` on TypedDict `EasyInputMessageParam`: value of type `list[Unknown | dict[Unknown | str, Unknown | str]]` homeassistant/components/openevse/sensor.py:7:8: error[unresolved-import] Cannot resolve imported module `openevsewifi` -homeassistant/components/openhome/media_player.py:71:38: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/openhome/media_player.py:71:82: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/openhome/media_player.py:76:47: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/openhome/media_player.py:77:48: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/openhome/media_player.py:88:55: error[unresolved-attribute] Object of type `(...) -> Awaitable[Unknown]` has no attribute `__name__` +homeassistant/components/openhome/media_player.py:88:55: error[unresolved-attribute] Object of type `(...) -> Awaitable[_R@catch_request_errors]` has no attribute `__name__` homeassistant/components/opensensemap/air_quality.py:8:6: error[unresolved-import] Cannot resolve imported module `opensensemap_api` homeassistant/components/opensensemap/air_quality.py:9:6: error[unresolved-import] Cannot resolve imported module `opensensemap_api.exceptions` homeassistant/components/openweathermap/coordinator.py:190:25: error[invalid-argument-type] Invalid argument to key "temperature" with declared type `None` on TypedDict `Forecast`: value of type `Decimal` @@ -2830,9 +2773,6 @@ homeassistant/components/peco/__init__.py:73:9: error[invalid-argument-type] Arg homeassistant/components/peco/__init__.py:103:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `(() -> Awaitable[dict[str, Any]]) | None`, found `def async_update_meter_data() -> CoroutineType[Any, Any, bool]` homeassistant/components/pencom/switch.py:8:6: error[unresolved-import] Cannot resolve imported module `pencompy.pencompy` homeassistant/components/persistent_notification/__init__.py:55:5: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 2 -homeassistant/components/person/__init__.py:238:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/person/__init__.py:239:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@async_load._entity_registry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> CoroutineType[Any, Any, None]` -homeassistant/components/person/__init__.py:240:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `bound method Self@async_load._entity_registry_filter(event_data: _EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update) -> bool` homeassistant/components/pglab/__init__.py:48:38: error[invalid-argument-type] Argument is incorrect: Expected `str`, found `str | bytes | bytearray` homeassistant/components/pglab/__init__.py:69:36: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `(str, str, int | None, bool | None, /) -> Coroutine[Any, Any, dict[Unknown, Unknown]]`, found `def mqtt_publish(topic: str, payload: str, qos: int, retain: bool) -> CoroutineType[Any, Any, None]` homeassistant/components/pglab/__init__.py:69:66: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `(dict[str, Any], /) -> Coroutine[Any, Any, dict[Unknown, Unknown]]`, found `def mqtt_unsubscribe(sub_state: dict[str, Any]) -> CoroutineType[Any, Any, None]` @@ -2984,10 +2924,6 @@ homeassistant/components/powerwall/__init__.py:236:43: error[invalid-assignment] homeassistant/components/progettihwsw/binary_sensor.py:69:16: error[invalid-argument-type] Method `__getitem__` of type `bound method dict[str, Any].__getitem__(key: str, /) -> Any` cannot be called with key of type `Unknown | int` on object of type `dict[str, Any]` homeassistant/components/progettihwsw/switch.py:85:16: error[invalid-argument-type] Method `__getitem__` of type `bound method dict[str, Any].__getitem__(key: str, /) -> Any` cannot be called with key of type `Unknown | int` on object of type `dict[str, Any]` homeassistant/components/proliphix/climate.py:7:8: error[unresolved-import] Cannot resolve imported module `proliphix` -homeassistant/components/prometheus/__init__.py:164:21: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/prometheus/__init__.py:164:42: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method PrometheusMetrics.handle_state_changed_event(event: Event[EventStateChangedData]) -> None` -homeassistant/components/prometheus/__init__.py:166:9: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/prometheus/__init__.py:167:9: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method PrometheusMetrics.handle_entity_registry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` homeassistant/components/prometheus/__init__.py:303:34: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" homeassistant/components/proximity/coordinator.py:125:63: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" homeassistant/components/proximity/coordinator.py:126:42: error[invalid-key] Unknown key "old_entity_id" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "old_entity_id" @@ -3027,10 +2963,33 @@ homeassistant/components/raspyrfm/switch.py:12:6: error[unresolved-import] Canno homeassistant/components/raspyrfm/switch.py:15:6: error[unresolved-import] Cannot resolve imported module `raspyrfm_client.device_implementations.manufacturer_constants` homeassistant/components/recollect_waste/__init__.py:60:9: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `(() -> Awaitable[dict[str, Any]]) | None`, found `def async_get_pickup_events() -> CoroutineType[Any, Any, list[PickupEvent]]` homeassistant/components/recorder/core.py:284:13: error[call-non-callable] Object of type `object` is not callable +homeassistant/components/recorder/db_schema.py:646:13: error[unknown-argument] Argument `metadata_id` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:647:13: error[unknown-argument] Argument `created` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:648:13: error[unknown-argument] Argument `created_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:649:13: error[unknown-argument] Argument `start` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:650:13: error[unknown-argument] Argument `start_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:651:13: error[unknown-argument] Argument `mean` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:652:13: error[unknown-argument] Argument `mean_weight` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:653:13: error[unknown-argument] Argument `min` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:654:13: error[unknown-argument] Argument `max` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:655:13: error[unknown-argument] Argument `last_reset` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:656:13: error[unknown-argument] Argument `last_reset_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:657:13: error[unknown-argument] Argument `state` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:658:13: error[unknown-argument] Argument `sum` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:670:13: error[unknown-argument] Argument `metadata_id` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:671:13: error[unknown-argument] Argument `created` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:672:13: error[unknown-argument] Argument `created_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:673:13: error[unknown-argument] Argument `start` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:674:13: error[unknown-argument] Argument `start_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:675:13: error[unknown-argument] Argument `mean` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:676:13: error[unknown-argument] Argument `mean_weight` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:677:13: error[unknown-argument] Argument `min` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:678:13: error[unknown-argument] Argument `max` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:679:13: error[unknown-argument] Argument `last_reset` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:680:13: error[unknown-argument] Argument `last_reset_ts` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:681:13: error[unknown-argument] Argument `state` does not match any known parameter of bound method `__init__` +homeassistant/components/recorder/db_schema.py:682:13: error[unknown-argument] Argument `sum` does not match any known parameter of bound method `__init__` homeassistant/components/recorder/entity_registry.py:29:36: error[invalid-key] Unknown key "old_entity_id" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "old_entity_id" -homeassistant/components/recorder/entity_registry.py:52:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/recorder/entity_registry.py:53:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _async_entity_id_changed(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` -homeassistant/components/recorder/entity_registry.py:54:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def entity_registry_changed_filter(event_data: _EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update) -> bool` homeassistant/components/recorder/executor.py:55:19: error[invalid-argument-type] Argument to bound method `put` is incorrect: Expected `_WorkItem[Any]`, found `None` homeassistant/components/recorder/history/__init__.py:911:53: error[unresolved-reference] Name `prev_state` used when not defined homeassistant/components/recorder/history/__init__.py:927:49: error[unresolved-reference] Name `prev_state` used when not defined @@ -3043,26 +3002,6 @@ homeassistant/components/recorder/statistics.py:2440:12: error[invalid-return-ty homeassistant/components/recorder/statistics.py:2458:12: error[invalid-return-type] Return type does not match returned value: expected `list[StatisticsRow]`, found `list[dict[Unknown | str, Unknown | None | int | float] | Unknown]` homeassistant/components/recorder/util.py:386:10: error[unresolved-import] Cannot resolve imported module `MySQLdb.constants` homeassistant/components/recorder/util.py:387:10: error[unresolved-import] Cannot resolve imported module `MySQLdb.converters` -homeassistant/components/recorder/util.py:587:30: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:587:52: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:593:38: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:593:62: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:601:37: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:601:66: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:607:45: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:607:76: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:614:30: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:615:26: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:643:30: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:643:50: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:653:28: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:654:24: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:664:37: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:664:64: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:674:35: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:675:31: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/recorder/util.py:684:30: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/recorder/util.py:688:26: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 homeassistant/components/recswitch/switch.py:8:6: error[unresolved-import] Cannot resolve imported module `pyrecswitch` homeassistant/components/reddit/sensor.py:88:12: warning[possibly-missing-attribute] Submodule `exceptions` may not be available as an attribute on module `praw` homeassistant/components/reddit/sensor.py:156:16: warning[possibly-missing-attribute] Submodule `exceptions` may not be available as an attribute on module `praw` @@ -3089,13 +3028,12 @@ homeassistant/components/repetier/sensor.py:130:16: error[no-matching-overload] homeassistant/components/repetier/sensor.py:151:16: error[no-matching-overload] No overload of function `round` matches arguments homeassistant/components/rest/data.py:56:13: error[invalid-assignment] Object of type `DigestAuthMiddleware | BasicAuth | tuple[str, str] | None` is not assignable to attribute `_auth` of type `BasicAuth | DigestAuthMiddleware | None` homeassistant/components/rflink/__init__.py:278:43: error[invalid-argument-type] Argument to bound method `set_rflink_protocol` is incorrect: Expected `ProtocolBase | None`, found `Protocol` +homeassistant/components/rflink/entity.py:219:22: error[unresolved-attribute] Object of type `ProtocolBase | None` has no attribute `send_command_ack` homeassistant/components/rflink/entity.py:286:19: error[unresolved-attribute] Object of type `ProtocolBase | None` has no attribute `send_command_ack` homeassistant/components/rflink/entity.py:292:13: error[unresolved-attribute] Object of type `ProtocolBase | None` has no attribute `send_command` homeassistant/components/rfxtrx/__init__.py:192:38: error[unresolved-attribute] Object of type `RFXtrxEvent & ~ConnectionLost` has no attribute `data` homeassistant/components/rfxtrx/__init__.py:234:41: error[unresolved-attribute] Object of type `RFXtrxEvent` has no attribute `data` homeassistant/components/rfxtrx/__init__.py:239:39: error[unresolved-attribute] Object of type `RFXtrxEvent` has no attribute `data` -homeassistant/components/rfxtrx/__init__.py:276:31: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/components/rfxtrx/__init__.py:276:65: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _updated_device(event: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> None` homeassistant/components/rfxtrx/cover.py:52:17: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `RFXtrxEvent`, found `RFXtrxEvent | None` homeassistant/components/rfxtrx/cover.py:70:9: error[invalid-parameter-default] Default value of type `None` is not assignable to annotated parameter type `RFXtrxEvent` homeassistant/components/rfxtrx/cover.py:104:36: warning[possibly-missing-attribute] Attribute `send_up05sec` may be missing on object of type `RollerTrolDevice | RfyDevice | LightingDevice` @@ -3136,10 +3074,6 @@ homeassistant/components/roborock/vacuum.py:201:16: error[invalid-return-type] R homeassistant/components/rocketchat/notify.py:8:6: error[unresolved-import] Cannot resolve imported module `rocketchat_API.APIExceptions.RocketExceptions` homeassistant/components/rocketchat/notify.py:12:6: error[unresolved-import] Cannot resolve imported module `rocketchat_API.rocketchat` homeassistant/components/roku/browse_media.py:252:9: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `bool`, found `Literal[False, ""] | Unknown` -homeassistant/components/roku/helpers.py:31:40: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/roku/helpers.py:31:76: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/roku/helpers.py:35:39: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 -homeassistant/components/roku/helpers.py:36:40: error[invalid-type-arguments] Too many type arguments: expected 1, got 2 homeassistant/components/roomba/vacuum.py:200:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int]`, found `tuple[Unknown | int | float, Unknown]` homeassistant/components/roon/media_browser.py:94:24: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `str`, found `Unknown | str | bool | None` homeassistant/components/roon/media_browser.py:94:24: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `str`, found `Unknown | str | bool | None` @@ -3350,16 +3284,8 @@ homeassistant/components/sonos/__init__.py:117:5: error[invalid-assignment] Obje homeassistant/components/sonos/__init__.py:118:5: error[unresolved-attribute] Unresolved attribute `EVENT_CACHE_TIMEOUT` on type ``. homeassistant/components/sonos/__init__.py:374:21: error[invalid-assignment] Invalid subscript assignment with key of type `Unknown` and value of type `SonosAlarms | SonosFavorites` on object of type `dict[str, SonosAlarms]` homeassistant/components/sonos/__init__.py:374:21: error[invalid-assignment] Invalid subscript assignment with key of type `Unknown` and value of type `SonosAlarms | SonosFavorites` on object of type `dict[str, SonosFavorites]` -homeassistant/components/sonos/helpers.py:46:34: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:46:58: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:52:34: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:52:64: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:57:34: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:57:64: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:60:44: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:60:76: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/components/sonos/helpers.py:70:28: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__qualname__` -homeassistant/components/sonos/helpers.py:87:17: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__qualname__` +homeassistant/components/sonos/helpers.py:70:28: error[unresolved-attribute] Object of type `(...) -> _R@soco_error` has no attribute `__qualname__` +homeassistant/components/sonos/helpers.py:87:17: error[unresolved-attribute] Object of type `(...) -> _R@soco_error` has no attribute `__qualname__` homeassistant/components/sonos/media_browser.py:259:21: error[call-non-callable] Object of type `None` is not callable homeassistant/components/sonos/media_browser.py:285:31: error[invalid-argument-type] Argument to function `can_expand` is incorrect: Expected `DidlObject`, found `str` homeassistant/components/sonos/media_browser.py:304:21: error[call-non-callable] Object of type `None` is not callable @@ -3386,7 +3312,6 @@ homeassistant/components/soundtouch/media_player.py:210:16: warning[possibly-mis homeassistant/components/soundtouch/media_player.py:215:16: warning[possibly-missing-attribute] Attribute `track` may be missing on object of type `Unknown | None` homeassistant/components/soundtouch/media_player.py:220:16: warning[possibly-missing-attribute] Attribute `album` may be missing on object of type `Unknown | None` homeassistant/components/splunk/__init__.py:9:6: error[unresolved-import] Cannot resolve imported module `hass_splunk` -homeassistant/components/splunk/__init__.py:127:27: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` homeassistant/components/spotify/browse_media.py:331:21: error[invalid-assignment] Object of type `list[dict[Unknown | str, Unknown | str | None] | Unknown]` is not assignable to `list[ItemPayload]` homeassistant/components/squeezebox/__init__.py:207:42: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `str`, found `Unknown | str | None` homeassistant/components/squeezebox/browse_media.py:162:43: error[invalid-argument-type] Argument to bound method `async_query` is incorrect: Expected `str`, found `Unknown | str | int` @@ -3400,14 +3325,11 @@ homeassistant/components/squeezebox/media_player.py:581:50: error[invalid-argume homeassistant/components/squeezebox/media_player.py:889:17: error[invalid-argument-type] Argument to function `safe_library_call` is incorrect: Expected `(...) -> Awaitable[Any]`, found `Unknown | (bound method Player.generate_image_url_from_track_id(track_id: int) -> str)` homeassistant/components/squeezebox/switch.py:150:16: warning[redundant-cast] Value is already of type `bool` homeassistant/components/ssdp/common.py:18:42: warning[possibly-missing-attribute] Attribute `scope_id` may be missing on object of type `IPv4Address | IPv6Address` -homeassistant/components/ssdp/scanner.py:64:5: error[invalid-type-form] List literals are not allowed in this context in a type expression -homeassistant/components/ssdp/scanner.py:64:37: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/components/ssdp/scanner.py:263:24: warning[possibly-missing-attribute] Attribute `scope_id` may be missing on object of type `IPv4Address | IPv6Address` homeassistant/components/ssdp/scanner.py:268:25: warning[possibly-missing-attribute] Attribute `scope_id` may be missing on object of type `IPv4Address | IPv6Address` homeassistant/components/ssdp/server.py:174:28: warning[possibly-missing-attribute] Attribute `scope_id` may be missing on object of type `IPv4Address | IPv6Address` homeassistant/components/ssdp/server.py:179:29: warning[possibly-missing-attribute] Attribute `scope_id` may be missing on object of type `IPv4Address | IPv6Address` homeassistant/components/starlingbank/sensor.py:9:6: error[unresolved-import] Cannot resolve imported module `starlingbank` -homeassistant/components/statsd/__init__.py:91:21: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` homeassistant/components/steam_online/config_flow.py:30:5: warning[possibly-missing-attribute] Submodule `api` may not be available as an attribute on module `steam` homeassistant/components/steam_online/config_flow.py:31:17: warning[possibly-missing-attribute] Submodule `api` may not be available as an attribute on module `steam` homeassistant/components/steam_online/config_flow.py:61:21: warning[possibly-missing-attribute] Submodule `api` may not be available as an attribute on module `steam` @@ -3465,6 +3387,7 @@ homeassistant/components/switchbot_cloud/__init__.py:135:37: error[invalid-argum homeassistant/components/switchbot_cloud/climate.py:144:20: error[no-matching-overload] No overload of bound method `get` matches arguments homeassistant/components/switchbot_cloud/climate.py:157:25: error[no-matching-overload] No overload of bound method `get` matches arguments homeassistant/components/switchbot_cloud/entity.py:51:13: error[invalid-argument-type] Argument to bound method `send_command` is incorrect: Expected `str`, found `str | None | Unknown` +homeassistant/components/switchbot_cloud/entity.py:52:13: error[invalid-argument-type] Argument to bound method `send_command` is incorrect: Argument type `Commands` does not satisfy upper bound `CommonCommands` of type variable `T` homeassistant/components/switchbot_cloud/entity.py:54:13: error[invalid-argument-type] Argument to bound method `send_command` is incorrect: Expected `dict[Unknown, Unknown] | str`, found `dict[Unknown, Unknown] | str | int` homeassistant/components/switchbot_cloud/sensor.py:344:38: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Device`, found `Device | Remote` homeassistant/components/switcher_kis/sensor.py:138:16: error[unresolved-attribute] Object of type `SensorEntityDescription` has no attribute `value_fn` @@ -3491,9 +3414,6 @@ homeassistant/components/tank_utility/sensor.py:9:6: error[unresolved-import] Ca homeassistant/components/tapsaff/binary_sensor.py:8:6: error[unresolved-import] Cannot resolve imported module `tapsaff` homeassistant/components/tasmota/camera.py:103:24: error[unresolved-attribute] Object of type `object` has no attribute `Request` homeassistant/components/tasmota/camera.py:104:10: error[unresolved-attribute] Object of type `object` has no attribute `StreamResponse` -homeassistant/components/tasmota/device_automation.py:61:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/components/tasmota/device_automation.py:62:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def async_device_removed(event: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> CoroutineType[Any, Any, None]` -homeassistant/components/tasmota/device_automation.py:63:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _async_device_removed_filter(event_data: _EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update) -> bool` homeassistant/components/tautulli/entity.py:35:25: error[invalid-argument-type] Invalid argument to key "identifiers" with declared type `set[tuple[str, str]]` on TypedDict `DeviceInfo`: value of type `set[Unknown | tuple[str, int | None | str]]` homeassistant/components/tautulli/sensor.py:42:17: error[not-iterable] Object of type `PyTautulliApiHomeStats` is not iterable homeassistant/components/tautulli/sensor.py:252:13: error[invalid-argument-type] Argument is incorrect: Expected `PyTautulliApiHomeStats`, found `Unknown | list[PyTautulliApiHomeStats] | None` @@ -3925,8 +3845,6 @@ homeassistant/components/vizio/media_player.py:454:25: error[invalid-argument-ty homeassistant/components/vlc/media_player.py:8:8: error[unresolved-import] Cannot resolve imported module `vlc` homeassistant/components/voicerss/tts.py:196:46: error[invalid-argument-type] Argument to function `async_get_clientsession` is incorrect: Expected `HomeAssistant`, found `HomeAssistant | None | Unknown` homeassistant/components/voip/assist_satellite.py:168:9: error[invalid-assignment] Object of type `Self@async_added_to_hass` is not assignable to attribute `protocol` on type `Unknown | VoIPDevice` -homeassistant/components/voip/devices.py:122:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/components/voip/devices.py:123:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def async_device_removed(ev: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> None` homeassistant/components/voip/voip.py:58:16: error[invalid-return-type] Return type does not match returned value: expected `VoipDatagramProtocol`, found `PreRecordMessageProtocol` homeassistant/components/voip/voip.py:68:5: error[unresolved-attribute] Object of type `VoipDatagramProtocol` has no attribute `_rtp_input` homeassistant/components/voip/voip.py:69:5: error[unresolved-attribute] Object of type `VoipDatagramProtocol` has no attribute `_rtp_output` @@ -3980,7 +3898,6 @@ homeassistant/components/webostv/config_flow.py:137:9: error[invalid-method-over homeassistant/components/webostv/media_player.py:128:51: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@cmd]` has no attribute `__name__` homeassistant/components/webostv/media_player.py:134:29: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@cmd]` has no attribute `__name__` homeassistant/components/webostv/media_player.py:145:29: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@cmd]` has no attribute `__name__` -homeassistant/components/websocket_api/commands.py:454:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` homeassistant/components/websocket_api/connection.py:282:27: warning[possibly-missing-attribute] Submodule `humanize` may not be available as an attribute on module `voluptuous` homeassistant/components/websocket_api/decorators.py:37:40: error[unresolved-attribute] Object of type `AsyncWebSocketCommandHandler` has no attribute `__name__` homeassistant/components/websocket_api/decorators.py:142:19: error[non-subscriptable] Cannot subscript object of type `All` with no `__getitem__` method @@ -4022,8 +3939,6 @@ homeassistant/components/websocket_api/http.py:553:21: warning[possibly-missing- homeassistant/components/websocket_api/http.py:558:21: warning[possibly-missing-attribute] Attribute `data` may be missing on object of type `Unknown | HomeAssistant | None` homeassistant/components/websocket_api/http.py:561:17: error[no-matching-overload] No overload of function `async_dispatcher_send` matches arguments homeassistant/components/wemo/__init__.py:92:27: warning[possibly-missing-attribute] Submodule `ssdp` may not be available as an attribute on module `pywemo` -homeassistant/components/wemo/__init__.py:263:37: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/components/wemo/__init__.py:263:49: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/components/wemo/light.py:196:32: error[invalid-argument-type] Argument to bound method `turn_on` is incorrect: Expected `bool`, found `Unknown | int` homeassistant/components/whirlpool/binary_sensor.py:76:16: error[unresolved-attribute] Object of type `BinarySensorEntityDescription` has no attribute `value_fn` homeassistant/components/whirlpool/climate.py:88:16: error[invalid-return-type] Return type does not match returned value: expected `int | float`, found `int | float | None` @@ -4141,12 +4056,12 @@ homeassistant/components/xs1/sensor.py:7:6: error[unresolved-import] Cannot reso homeassistant/components/xs1/switch.py:7:6: error[unresolved-import] Cannot resolve imported module `xs1_api_client.api_constants` homeassistant/components/xs1/switch.py:8:6: error[unresolved-import] Cannot resolve imported module `xs1_api_client.device.actuator` homeassistant/components/yale/__init__.py:65:36: error[invalid-argument-type] Argument to bound method `async_setup` is incorrect: Expected `Config`, found `dict[Unknown | str, Unknown | Brand]` -homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'username' in TypedDict `Config` constructor -homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'password' in TypedDict `Config` constructor -homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'login_method' in TypedDict `Config` constructor homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'access_token_cache_file' in TypedDict `Config` constructor homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'install_id' in TypedDict `Config` constructor +homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'login_method' in TypedDict `Config` constructor +homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'password' in TypedDict `Config` constructor homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'timeout' in TypedDict `Config` constructor +homeassistant/components/yale/__init__.py:65:36: error[missing-typed-dict-key] Missing required key 'username' in TypedDict `Config` constructor homeassistant/components/yale/binary_sensor.py:75:9: error[invalid-argument-type] Argument is incorrect: Expected `(YaleData, DoorbellDetail | LockDetail, /) -> Activity | None`, found `def retrieve_online_state(data: YaleData, detail: DoorbellDetail | LockDetail) -> bool` homeassistant/components/yale/binary_sensor.py:103:12: warning[possibly-missing-attribute] Attribute `doorsense` may be missing on object of type `DoorbellDetail | LockDetail` homeassistant/components/yale/binary_sensor.py:106:12: warning[possibly-missing-attribute] Attribute `doorbell` may be missing on object of type `DoorbellDetail | LockDetail` @@ -4203,9 +4118,12 @@ homeassistant/components/yamaha_musiccast/media_player.py:393:13: error[invalid- homeassistant/components/yamaha_musiccast/number.py:65:35: error[invalid-argument-type] Argument to bound method `set` is incorrect: Expected `int`, found `int | float` homeassistant/components/yandextts/tts.py:123:46: error[invalid-argument-type] Argument to function `async_get_clientsession` is incorrect: Expected `HomeAssistant`, found `HomeAssistant | None | Unknown` homeassistant/components/yeelight/config_flow.py:146:9: error[invalid-method-override] Invalid override of method `is_matching`: Definition is incompatible with `ConfigFlow.is_matching` +homeassistant/components/yeelight/device.py:200:9: error[invalid-assignment] Object of type `(CaseInsensitiveDict & ~AlwaysFalsy) | dict[Unknown, Unknown]` is not assignable to attribute `capabilities` of type `dict[str, Any]` homeassistant/components/yeelight/light.py:256:47: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__` homeassistant/components/yeelight/light.py:264:43: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__` homeassistant/components/yeelight/light.py:270:43: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__` +homeassistant/components/yeelight/scanner.py:55:13: error[invalid-assignment] Object of type `Self@async_get` is not assignable to attribute `_scanner` of type ` | None` +homeassistant/components/yeelight/scanner.py:56:16: error[invalid-return-type] Return type does not match returned value: expected `Self@async_get`, found ` | None` homeassistant/components/yeelightsunflower/light.py:9:8: error[unresolved-import] Cannot resolve imported module `yeelightsunflower` homeassistant/components/yi/camera.py:7:6: error[unresolved-import] Cannot resolve imported module `aioftp` homeassistant/components/yi/camera.py:144:34: error[invalid-argument-type] Argument to bound method `open_camera` is incorrect: Expected `str`, found `Unknown | None` @@ -4213,8 +4131,6 @@ homeassistant/components/yi/camera.py:151:17: error[invalid-argument-type] Argum homeassistant/components/yolink/switch.py:174:41: error[invalid-assignment] Object of type `None` is not assignable to `ClientRequest` homeassistant/components/zabbix/__init__.py:15:6: error[unresolved-import] Cannot resolve imported module `zabbix_utils` homeassistant/components/zabbix/__init__.py:16:6: error[unresolved-import] Cannot resolve imported module `zabbix_utils.exceptions` -homeassistant/components/zabbix/__init__.py:214:25: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/components/zabbix/__init__.py:214:46: error[invalid-argument-type] Argument to bound method `listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@setup._event_listener(event: Event[EventStateChangedData]) -> None` homeassistant/components/zabbix/sensor.py:10:6: error[unresolved-import] Cannot resolve imported module `zabbix_utils` homeassistant/components/zamg/coordinator.py:51:9: error[invalid-assignment] Object of type `Unknown | dict[Unknown, Unknown] | None` is not assignable to attribute `data` of type `dict[Unknown, Unknown]` homeassistant/components/zamg/coordinator.py:54:16: error[invalid-return-type] Return type does not match returned value: expected `ZamgData`, found `Unknown | dict[Unknown, Unknown] | None` @@ -4230,6 +4146,7 @@ homeassistant/components/zha/alarm_control_panel.py:94:15: error[unresolved-attr homeassistant/components/zha/alarm_control_panel.py:100:15: error[unresolved-attribute] Object of type `PlatformEntity | GroupEntity` has no attribute `async_alarm_arm_away` homeassistant/components/zha/alarm_control_panel.py:106:15: error[unresolved-attribute] Object of type `PlatformEntity | GroupEntity` has no attribute `async_alarm_arm_night` homeassistant/components/zha/alarm_control_panel.py:112:15: error[unresolved-attribute] Object of type `PlatformEntity | GroupEntity` has no attribute `async_alarm_trigger` +homeassistant/components/zha/api.py:61:24: error[no-matching-overload] No overload of function `max` matches arguments homeassistant/components/zha/api.py:108:13: error[invalid-argument-type] Argument to bound method `energy_scan` is incorrect: Expected `Channels`, found `Unknown | Literal[134215680]` homeassistant/components/zha/binary_sensor.py:59:16: error[unresolved-attribute] Object of type `PlatformEntity | GroupEntity` has no attribute `is_on` homeassistant/components/zha/button.py:60:15: error[unresolved-attribute] Object of type `PlatformEntity | GroupEntity` has no attribute `async_press` @@ -4296,8 +4213,6 @@ homeassistant/components/zha/helpers.py:374:31: warning[possibly-missing-attribu homeassistant/components/zha/helpers.py:378:33: warning[possibly-missing-attribute] Attribute `name` may be missing on object of type `Unknown | PermitJoins` homeassistant/components/zha/helpers.py:388:35: warning[possibly-missing-attribute] Attribute `name` may be missing on object of type `Unknown | RouteStatus` homeassistant/components/zha/helpers.py:533:44: warning[possibly-missing-attribute] Submodule `handlers` may not be available as an attribute on module `logging` -homeassistant/components/zha/helpers.py:542:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/components/zha/helpers.py:543:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@__init__._handle_entity_registry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> CoroutineType[Any, Any, None]` homeassistant/components/zha/helpers.py:603:27: error[invalid-argument-type] Method `__getitem__` of type `bound method dict[tuple[Platform, str], PlatformEntity].__getitem__(key: tuple[Platform, str], /) -> PlatformEntity` cannot be called with key of type `tuple[str, str]` on object of type `dict[tuple[Platform, str], PlatformEntity]` homeassistant/components/zha/helpers.py:615:65: error[invalid-argument-type] Argument to bound method `_async_get_or_create_group_proxy` is incorrect: Expected `GroupInfo`, found `Unknown | Group` homeassistant/components/zha/helpers.py:701:67: error[invalid-argument-type] Argument to bound method `_async_get_or_create_device_proxy` is incorrect: Expected `Device`, found `Unknown | Device | None` @@ -4408,85 +4323,42 @@ homeassistant/config_entries.py:207:17: error[invalid-type-arguments] Too many t homeassistant/config_entries.py:1273:17: error[invalid-argument-type] Argument to bound method `async_init` is incorrect: Expected `ConfigFlowContext | None`, found `ConfigFlowContext | dict[str, object]` homeassistant/config_entries.py:1833:9: error[invalid-method-override] Invalid override of method `__setitem__`: Definition is incompatible with `UserDict.__setitem__` homeassistant/config_entries.py:1904:9: error[invalid-method-override] Invalid override of method `__delitem__`: Definition is incompatible with `UserDict.__delitem__` -homeassistant/config_entries.py:3853:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/config_entries.py:3854:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@async_setup._handle_entry_updated(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` -homeassistant/config_entries.py:3855:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _handle_entry_updated_filter(event_data: _EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update) -> bool` homeassistant/config_entries.py:3930:33: error[invalid-argument-type] Method `__getitem__` of type `(Overload[(key: Literal["action"], /) -> Literal["create", "remove"], (key: Literal["entity_id"], /) -> str]) | (Overload[(key: Literal["action"], /) -> Literal["update"], (key: Literal["entity_id"], /) -> str, (key: Literal["changes"], /) -> dict[str, Any], (key: Literal["old_entity_id"], /) -> str])` cannot be called with key of type `Literal["changes"]` on object of type `EventEntityRegistryUpdatedData` homeassistant/config_entries.py:3931:12: error[invalid-argument-type] Method `__getitem__` of type `(Overload[(key: Literal["action"], /) -> Literal["create", "remove"], (key: Literal["entity_id"], /) -> str]) | (Overload[(key: Literal["action"], /) -> Literal["update"], (key: Literal["entity_id"], /) -> str, (key: Literal["changes"], /) -> dict[str, Any], (key: Literal["old_entity_id"], /) -> str])` cannot be called with key of type `Literal["changes"]` on object of type `EventEntityRegistryUpdatedData` homeassistant/const.py:979:43: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 -homeassistant/core.py:359:23: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:648:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:658:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:667:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:698:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:707:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:715:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:735:45: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:743:45: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:748:45: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:881:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:890:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:898:31: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:917:45: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:1026:37: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:1032:37: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:1037:37: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/core.py:1277:32: error[invalid-type-form] Variable of type `under_cached_property[Unknown]` is not allowed in a type expression homeassistant/core.py:1378:32: error[invalid-type-form] Variable of type `under_cached_property[Unknown]` is not allowed in a type expression -homeassistant/core.py:1398:13: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_DataT@_FilterableJobType]]`? -homeassistant/core.py:1398:30: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/core.py:1406:27: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_DataT@_OneTimeListener]]`? -homeassistant/core.py:1406:44: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/core.py:1504:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_DataT@async_fire] | str` homeassistant/core.py:1527:48: error[invalid-argument-type] Argument to function `_event_repr` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_DataT@async_fire_internal] | str` homeassistant/core.py:1621:50: error[invalid-argument-type] Argument to bound method `_async_listen_filterable_job` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_DataT@async_listen] | str` -homeassistant/core.py:1621:62: error[invalid-argument-type] Argument to bound method `_async_listen_filterable_job` is incorrect: Expected `tuple[HassJob[Unknown], ((Mapping[str, Any], /) -> bool) | None]`, found `tuple[HassJob[Unknown], ((_DataT@async_listen, /) -> bool) | None]` +homeassistant/core.py:1621:62: error[invalid-argument-type] Argument to bound method `_async_listen_filterable_job` is incorrect: Expected `tuple[HassJob[(Event[Mapping[str, Any]], /), Coroutine[Any, Any, None] | None], ((Mapping[str, Any], /) -> bool) | None]`, found `tuple[HassJob[(Event[_DataT@async_listen], /), Unknown], ((_DataT@async_listen, /) -> bool) | None]` +homeassistant/core.py:1684:33: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `(Event[_DataT@async_listen_once], /) -> Coroutine[Any, Any, None] | None` homeassistant/core.py:1687:13: error[invalid-argument-type] Argument to bound method `_async_listen_filterable_job` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_DataT@async_listen_once] | str` homeassistant/core.py:1925:32: error[invalid-type-form] Variable of type `under_cached_property[Unknown]` is not allowed in a type expression homeassistant/core.py:2048:9: error[invalid-method-override] Invalid override of method `__setitem__`: Definition is incompatible with `UserDict.__setitem__` -homeassistant/core.py:2356:17: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[dict[Unknown | str, Unknown | str | datetime | State | None]] | str`, found `EventType[EventStateReportedData]` +homeassistant/core.py:2356:17: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[EventStateReportedData | dict[Unknown | str, Unknown | str | datetime | State | None]] | str`, found `EventType[EventStateReportedData]` homeassistant/data_entry_flow.py:365:27: warning[redundant-cast] Value is already of type `Schema` -homeassistant/data_entry_flow.py:1016:45: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/data_entry_flow.py:1016:79: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/data_entry_flow.py:1031:44: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/data_entry_flow.py:1032:39: error[invalid-type-arguments] Too many type arguments: expected 2, got 3 -homeassistant/data_entry_flow.py:1037:23: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Unknown]` has no attribute `__name__` +homeassistant/data_entry_flow.py:1037:23: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, ResultT@progress_step]` has no attribute `__name__` homeassistant/data_entry_flow.py:1063:21: error[invalid-argument-type] Argument to bound method `async_show_progress` is incorrect: Expected `Mapping[str, str] | None`, found `None | @Todo | (dict[str, str] & ~(() -> object)) | (((Any, /) -> dict[str, str]) & ~(() -> object))` homeassistant/helpers/area_registry.py:90:32: error[invalid-type-form] Variable of type `cached_property[Unknown]` is not allowed in a type expression homeassistant/helpers/area_registry.py:481:16: error[invalid-return-type] Return type does not match returned value: expected `AreasRegistryStoreData`, found `dict[Unknown | str, Unknown | list[dict[Unknown | str, Unknown | list[str] | str | None] | Unknown]]` homeassistant/helpers/area_registry.py:482:22: error[invalid-argument-type] Invalid argument to key "areas" with declared type `list[_AreaStoreData]` on TypedDict `AreasRegistryStoreData`: value of type `list[dict[Unknown | str, Unknown | list[str] | str | None] | Unknown]` homeassistant/helpers/area_registry.py:521:35: error[invalid-key] Unknown key "floor_id" for TypedDict `_EventFloorRegistryUpdatedData_Reorder`: Unknown key "floor_id" -homeassistant/helpers/area_registry.py:526:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` -homeassistant/helpers/area_registry.py:527:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _removed_from_registry_filter(event_data: _EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder | EventLabelRegistryUpdatedData) -> bool` -homeassistant/helpers/area_registry.py:528:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _handle_floor_registry_update(event: Event[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]) -> None` -homeassistant/helpers/area_registry.py:539:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventLabelRegistryUpdatedData]` -homeassistant/helpers/area_registry.py:540:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _removed_from_registry_filter(event_data: _EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder | EventLabelRegistryUpdatedData) -> bool` -homeassistant/helpers/area_registry.py:541:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _handle_label_registry_update(event: Event[EventLabelRegistryUpdatedData]) -> None` homeassistant/helpers/category_registry.py:230:16: error[invalid-return-type] Return type does not match returned value: expected `CategoryRegistryStoreData`, found `dict[Unknown | str, Unknown | dict[str | Unknown, list[dict[Unknown | str, Unknown | str | None] | Unknown] | Unknown]]` homeassistant/helpers/category_registry.py:231:27: error[invalid-argument-type] Invalid argument to key "categories" with declared type `dict[str, list[_CategoryStoreData]]` on TypedDict `CategoryRegistryStoreData`: value of type `dict[str | Unknown, list[dict[Unknown | str, Unknown | str | None] | Unknown] | Unknown]` homeassistant/helpers/condition.py:413:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, ConditionProtocol | None]`, found `tuple[str, ModuleType]` homeassistant/helpers/condition.py:480:49: error[call-non-callable] Object of type `None` is not callable homeassistant/helpers/condition.py:481:39: error[call-non-callable] Object of type `None` is not callable homeassistant/helpers/config_validation.py:21:5: error[unresolved-import] Module `socket` has no member `_GLOBAL_DEFAULT_TIMEOUT` -homeassistant/helpers/debounce.py:43:28: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? -homeassistant/helpers/debounce.py:43:32: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/deprecation.py:44:25: error[unresolved-attribute] Object of type `(_ObjectT@deprecated_substitute, /) -> Any` has no attribute `__name__` -homeassistant/helpers/deprecation.py:158:24: error[unresolved-attribute] Object of type `(...) -> _T@deprecated_hass_argument` has no attribute `__name__` -homeassistant/helpers/deprecation.py:160:34: error[unresolved-attribute] Object of type `(...) -> _T@deprecated_hass_argument` has no attribute `__name__` +homeassistant/helpers/deprecation.py:158:24: error[unresolved-attribute] Object of type `(**_P@deprecated_hass_argument) -> _T@deprecated_hass_argument` has no attribute `__name__` +homeassistant/helpers/deprecation.py:160:34: error[unresolved-attribute] Object of type `(**_P@deprecated_hass_argument) -> _T@deprecated_hass_argument` has no attribute `__name__` homeassistant/helpers/device_registry.py:1308:20: error[invalid-assignment] Object of type `dict[Unknown | str, Unknown | str]` is not assignable to `EventDeviceRegistryUpdatedData` homeassistant/helpers/device_registry.py:1310:20: error[invalid-assignment] Object of type `dict[Unknown | str, Unknown | str | dict[str, Any]]` is not assignable to `EventDeviceRegistryUpdatedData` -homeassistant/helpers/device_registry.py:1457:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventDeviceRegistryUpdatedData_Remove] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/helpers/device_registry.py:1838:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventLabelRegistryUpdatedData]` -homeassistant/helpers/device_registry.py:1839:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _label_removed_from_registry_filter(event_data: EventLabelRegistryUpdatedData) -> bool` -homeassistant/helpers/device_registry.py:1840:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _handle_label_registry_update(event: Event[EventLabelRegistryUpdatedData]) -> None` homeassistant/helpers/device_registry.py:1867:36: error[invalid-argument-type] Method `__getitem__` of type `(Overload[(key: Literal["action"], /) -> Literal["create", "remove"], (key: Literal["entity_id"], /) -> str]) | (Overload[(key: Literal["action"], /) -> Literal["update"], (key: Literal["entity_id"], /) -> str, (key: Literal["changes"], /) -> dict[str, Any], (key: Literal["old_entity_id"], /) -> str])` cannot be called with key of type `Literal["changes"]` on object of type `EventEntityRegistryUpdatedData` -homeassistant/helpers/device_registry.py:1876:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/helpers/device_registry.py:1877:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _async_entity_registry_changed(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` -homeassistant/helpers/device_registry.py:1878:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def entity_registry_changed_filter(event_data: _EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update) -> bool` homeassistant/helpers/discovery.py:22:46: error[invalid-type-arguments] Too many type arguments to class `SignalTypeFormat`: expected 0, got 1 homeassistant/helpers/discovery_flow.py:59:19: error[invalid-assignment] Object of type `dict[str, object]` is not assignable to `ConfigFlowContext` homeassistant/helpers/dispatcher.py:30:16: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 -homeassistant/helpers/dispatcher.py:33:22: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/dispatcher.py:41:45: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:55:24: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:72:38: error[invalid-type-arguments] Too many type arguments: expected 0, got 1 @@ -4498,7 +4370,6 @@ homeassistant/helpers/dispatcher.py:131:45: error[invalid-type-arguments] Too ma homeassistant/helpers/dispatcher.py:142:45: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:149:24: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:163:24: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 -homeassistant/helpers/dispatcher.py:164:19: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/dispatcher.py:186:45: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:199:45: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/helpers/dispatcher.py:221:45: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 @@ -4513,109 +4384,28 @@ homeassistant/helpers/entity.py:1578:73: error[invalid-key] Unknown key "changes homeassistant/helpers/entity_component.py:378:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `EntityPlatformModule | None`, found `ModuleType | None` homeassistant/helpers/entity_registry.py:218:5: error[call-non-callable] Object of type `_MISSING_TYPE` is not callable homeassistant/helpers/entity_registry.py:443:5: error[call-non-callable] Object of type `_MISSING_TYPE` is not callable -homeassistant/helpers/entity_registry.py:830:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/helpers/entity_registry.py:831:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `bound method Self@__init__.async_device_modified(event: Event[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]) -> None` homeassistant/helpers/entity_registry.py:1061:13: error[invalid-argument-type] Argument is incorrect: Expected `str`, found `None | str` homeassistant/helpers/entity_registry.py:1064:13: error[invalid-argument-type] Argument is incorrect: Expected `ReadOnlyEntityOptionsType`, found `ReadOnlyDict[str, ReadOnlyDict[str, Any]] | @Todo | None` -homeassistant/helpers/entity_registry.py:1080:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventEntityRegistryUpdatedData_CreateRemove] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/helpers/entity_registry.py:1127:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventEntityRegistryUpdatedData_CreateRemove] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` homeassistant/helpers/entity_registry.py:1150:46: error[invalid-key] Unknown key "device" for TypedDict `_EventDeviceRegistryUpdatedData_Create` - did you mean "device_id"? homeassistant/helpers/entity_registry.py:1150:46: error[invalid-key] Unknown key "device" for TypedDict `_EventDeviceRegistryUpdatedData_Update` - did you mean "device_id"? homeassistant/helpers/entity_registry.py:1180:45: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Create`: Unknown key "changes" homeassistant/helpers/entity_registry.py:1180:45: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Remove`: Unknown key "changes" homeassistant/helpers/entity_registry.py:1194:56: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Create`: Unknown key "changes" homeassistant/helpers/entity_registry.py:1194:56: error[invalid-key] Unknown key "changes" for TypedDict `_EventDeviceRegistryUpdatedData_Remove`: Unknown key "changes" -homeassistant/helpers/entity_registry.py:1379:43: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventEntityRegistryUpdatedData_Update] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/helpers/entity_registry.py:1863:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventLabelRegistryUpdatedData]` -homeassistant/helpers/entity_registry.py:1864:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _removed_from_registry_filter(event_data: EventLabelRegistryUpdatedData | EventCategoryRegistryUpdatedData) -> bool` -homeassistant/helpers/entity_registry.py:1865:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _handle_label_registry_update(event: Event[EventLabelRegistryUpdatedData]) -> None` -homeassistant/helpers/entity_registry.py:1876:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventCategoryRegistryUpdatedData]` -homeassistant/helpers/entity_registry.py:1877:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def _removed_from_registry_filter(event_data: EventLabelRegistryUpdatedData | EventCategoryRegistryUpdatedData) -> bool` -homeassistant/helpers/entity_registry.py:1878:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def _handle_category_registry_update(event: Event[EventCategoryRegistryUpdatedData]) -> None` homeassistant/helpers/entity_registry.py:1917:40: error[invalid-key] Unknown key "old_entity_id" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "old_entity_id" -homeassistant/helpers/entity_registry.py:1934:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/helpers/entity_registry.py:1935:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def cleanup_restored_states(event: Event[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]) -> None` -homeassistant/helpers/event.py:105:36: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_TypedDictT@_KeyedEventTracker]]`? -homeassistant/helpers/event.py:105:58: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:113:36: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_TypedDictT@_KeyedEventTracker]]`? -homeassistant/helpers/event.py:113:58: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:125:46: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_TypedDictT@_KeyedEventData]]`? -homeassistant/helpers/event.py:125:68: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:299:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/helpers/event.py:300:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def state_change_dispatcher(event: Event[EventStateChangedData]) -> None` -homeassistant/helpers/event.py:301:9: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `((Mapping[str, Any], /) -> bool) | None`, found `def state_change_filter(event_data: EventStateChangedData) -> bool` -homeassistant/helpers/event.py:342:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_StateEventDataT@_async_dispatch_entity_id_event_soon]]`? -homeassistant/helpers/event.py:342:66: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:352:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_StateEventDataT@_async_dispatch_entity_id_event]]`? -homeassistant/helpers/event.py:352:66: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:372:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_StateEventDataT@_async_state_filter]]`? -homeassistant/helpers/event.py:372:66: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:437:18: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_TypedDictT@_remove_listener]]`? -homeassistant/helpers/event.py:437:40: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:438:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[_TypedDictT@_remove_listener]]`? -homeassistant/helpers/event.py:438:61: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/event.py:474:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_TypedDictT@_async_track_event] | str` -homeassistant/helpers/event.py:501:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventEntityRegistryUpdatedData]]`? -homeassistant/helpers/event.py:501:80: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:525:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventEntityRegistryUpdatedData]]`? -homeassistant/helpers/event.py:525:80: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:568:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventDeviceRegistryUpdatedData]]`? -homeassistant/helpers/event.py:568:80: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:578:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventDeviceRegistryUpdatedData]]`? -homeassistant/helpers/event.py:578:80: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:622:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventStateChangedData]]`? -homeassistant/helpers/event.py:622:71: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:639:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventStateChangedData]]`? -homeassistant/helpers/event.py:639:71: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:689:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[Event[EventStateChangedData]]`? -homeassistant/helpers/event.py:689:71: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:861:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/helpers/event.py:861:34: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `Unknown | ((Event[EventStateChangedData], /) -> Any)` -homeassistant/helpers/event.py:1447:13: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventStateChangedData]` -homeassistant/helpers/event.py:1447:34: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `(Event[Mapping[str, Any]], /) -> Coroutine[Any, Any, None] | None`, found `def state_for_cancel_listener(event: Event[EventStateChangedData]) -> None` -homeassistant/helpers/event.py:1466:21: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1466:33: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1500:18: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1500:30: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1546:21: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1546:33: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1571:39: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1571:51: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1581:21: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1581:33: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1602:21: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1602:33: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1632:25: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1632:37: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1633:23: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1633:35: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1708:18: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? -homeassistant/helpers/event.py:1708:22: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1805:18: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1805:30: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/event.py:1807:48: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[datetime]`? -homeassistant/helpers/event.py:1807:60: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/floor_registry.py:224:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` -homeassistant/helpers/floor_registry.py:237:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` -homeassistant/helpers/floor_registry.py:279:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` -homeassistant/helpers/floor_registry.py:306:13: error[invalid-argument-type] Argument to bound method `async_fire_internal` is incorrect: Expected `EventType[_EventFloorRegistryUpdatedData_Reorder] | str`, found `EventType[_EventFloorRegistryUpdatedData_Create_Remove_Update | _EventFloorRegistryUpdatedData_Reorder]` homeassistant/helpers/floor_registry.py:333:16: error[invalid-return-type] Return type does not match returned value: expected `FloorRegistryStoreData`, found `dict[Unknown | str, Unknown | list[dict[Unknown | str, Unknown | list[str] | str | None | int] | Unknown]]` homeassistant/helpers/floor_registry.py:334:23: error[invalid-argument-type] Invalid argument to key "floors" with declared type `list[_FloorStoreData]` on TypedDict `FloorRegistryStoreData`: value of type `list[dict[Unknown | str, Unknown | list[str] | str | None | int] | Unknown]` homeassistant/helpers/helper_integration.py:73:32: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" homeassistant/helpers/helper_integration.py:81:60: error[invalid-key] Unknown key "changes" for TypedDict `_EventEntityRegistryUpdatedData_CreateRemove`: Unknown key "changes" -homeassistant/helpers/integration_platform.py:37:26: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[HomeAssistant, str, Any]`? -homeassistant/helpers/integration_platform.py:37:53: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/label_registry.py:250:16: error[invalid-return-type] Return type does not match returned value: expected `LabelRegistryStoreData`, found `dict[Unknown | str, Unknown | list[dict[Unknown | str, Unknown | str | None] | Unknown]]` homeassistant/helpers/label_registry.py:251:23: error[invalid-argument-type] Invalid argument to key "labels" with declared type `list[_LabelStoreData]` on TypedDict `LabelRegistryStoreData`: value of type `list[dict[Unknown | str, Unknown | str | None] | Unknown]` homeassistant/helpers/registry.py:38:9: error[invalid-method-override] Invalid override of method `__setitem__`: Definition is incompatible with `UserDict.__setitem__` +homeassistant/helpers/restore_state.py:94:75: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `datetime`, found `(Unknown & ~str) | datetime | None` homeassistant/helpers/schema_config_entry_flow.py:258:40: error[invalid-assignment] Object of type `(((dict[str, Any], /) -> Coroutine[Any, Any, str | None]) & ~(() -> object)) | (str & ~(() -> object)) | None` is not assignable to `str | None` homeassistant/helpers/script.py:153:36: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 3 homeassistant/helpers/script.py:154:46: error[invalid-type-arguments] Too many type arguments to class `SignalTypeFormat`: expected 0, got 1 homeassistant/helpers/script_variables.py:196:9: error[invalid-method-override] Invalid override of method `__setitem__`: Definition is incompatible with `UserDict.__setitem__` -homeassistant/helpers/service.py:923:9: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[ServiceCall]`? -homeassistant/helpers/service.py:924:9: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/service.py:1137:38: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 -homeassistant/helpers/service.py:1177:38: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/singleton.py:68:32: error[invalid-await] `_Coro[_T@singleton] | _U@singleton` is not awaitable homeassistant/helpers/singleton.py:83:12: error[invalid-return-type] Return type does not match returned value: expected `(_FuncType[_S@singleton], /) -> _FuncType[_S@singleton]`, found `Overload[(func: _FuncType[_Coro[_T@singleton]]) -> _FuncType[_Coro[_T@singleton]], (func: _FuncType[_U@singleton]) -> _FuncType[_U@singleton]]` homeassistant/helpers/singleton.py:121:5: error[type-assertion-failure] Type `str` does not match asserted type `Unknown` @@ -4689,9 +4479,6 @@ homeassistant/helpers/storage.py:436:30: error[non-subscriptable] Cannot subscri homeassistant/helpers/storage.py:436:30: error[non-subscriptable] Cannot subscript object of type `None` with no `__getitem__` method homeassistant/helpers/storage.py:437:35: error[invalid-argument-type] Argument to bound method `async_save` is incorrect: Argument type `Unknown | dict[str, Any] | list[Any] | ... omitted 4 union elements` does not satisfy upper bound `Mapping[str, Any] | Sequence[Any]` of type variable `_T` homeassistant/helpers/storage.py:437:35: error[invalid-argument-type] Argument to bound method `async_save` is incorrect: Expected `_T@Store`, found `Unknown | dict[str, Any] | list[Any] | ... omitted 4 union elements` -homeassistant/helpers/target.py:328:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventEntityRegistryUpdatedData_CreateRemove | _EventEntityRegistryUpdatedData_Update]` -homeassistant/helpers/target.py:331:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[_EventDeviceRegistryUpdatedData_Create | _EventDeviceRegistryUpdatedData_Remove | _EventDeviceRegistryUpdatedData_Update]` -homeassistant/helpers/target.py:334:17: error[invalid-argument-type] Argument to bound method `async_listen` is incorrect: Expected `EventType[Mapping[str, Any]] | str`, found `EventType[EventAreaRegistryUpdatedData]` homeassistant/helpers/template/__init__.py:599:13: warning[possibly-missing-attribute] Attribute `loop` may be missing on object of type `Unknown | HomeAssistant | None` homeassistant/helpers/template/__init__.py:1560:14: warning[possibly-missing-attribute] Submodule `filters` may not be available as an attribute on module `jinja2` homeassistant/helpers/template/__init__.py:1568:14: warning[possibly-missing-attribute] Submodule `filters` may not be available as an attribute on module `jinja2` @@ -4699,8 +4486,6 @@ homeassistant/helpers/template/__init__.py:1861:19: warning[possibly-missing-att homeassistant/helpers/template/__init__.py:2061:23: warning[possibly-missing-attribute] Submodule `nodes` may not be available as an attribute on module `jinja2` homeassistant/helpers/template/__init__.py:2071:23: warning[possibly-missing-attribute] Submodule `nodes` may not be available as an attribute on module `jinja2` homeassistant/helpers/template/__init__.py:2080:23: warning[possibly-missing-attribute] Submodule `nodes` may not be available as an attribute on module `jinja2` -homeassistant/helpers/trigger.py:621:21: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[dict[str, Any], Context | None]`? -homeassistant/helpers/trigger.py:621:55: error[invalid-type-arguments] Too many type arguments to class `HassJob`: expected 1, got 2 homeassistant/helpers/trigger.py:749:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, TriggerProtocol]`, found `tuple[Unknown | str, ModuleType]` homeassistant/helpers/update_coordinator.py:218:20: error[not-iterable] Object of type `GeneratorType[~None, None, None]` is not iterable homeassistant/loader.py:298:16: error[unresolved-import] Cannot resolve imported module `custom_components` @@ -4766,4 +4551,4 @@ homeassistant/util/signal_type.pyi:61:37: error[invalid-type-arguments] Too many homeassistant/util/signal_type.pyi:63:49: error[invalid-type-arguments] Too many type arguments to class `SignalTypeFormat`: expected 0, got 1 homeassistant/util/signal_type.pyi:64:38: error[invalid-type-arguments] Too many type arguments to class `SignalType`: expected 0, got 1 homeassistant/util/variance.py:41:43: error[unsupported-operator] Operator `-` is unsupported between objects of type `_R@ignore_variance` and `_R@ignore_variance` -Found 4768 diagnostics +Found 4553 diagnostics diff --git a/scripts/ty_benchmark/snapshots/jinja_Pyrefly.txt b/scripts/ty_benchmark/snapshots/jinja_Pyrefly.txt index a63410cd01..b5bcc8c6b3 100644 --- a/scripts/ty_benchmark/snapshots/jinja_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/jinja_Pyrefly.txt @@ -44,7 +44,6 @@ ERROR src/jinja2/filters.py:169:48-61: `dict_items[tuple[str, Any], Unknown]` is ERROR src/jinja2/filters.py:308:22-56: Argument `str` is not assignable to parameter `object` with type `LiteralString` in function `list.append` [bad-argument-type] ERROR src/jinja2/filters.py:730:34-38: `unit` may be uninitialized [unbound-name] ERROR src/jinja2/filters.py:1352:9-25: `+=` is not supported between `V` and `V` [unsupported-operation] -ERROR src/jinja2/filters.py:1354:12-14: Returned type `V | Unknown` is not assignable to declared return type `V` [bad-return] ERROR src/jinja2/idtracking.py:90:9-16: Object of class `object` has no attribute `refs` [missing-attribute] ERROR src/jinja2/idtracking.py:91:9-17: Object of class `object` has no attribute `loads` [missing-attribute] ERROR src/jinja2/idtracking.py:92:9-18: Object of class `object` has no attribute `stores` [missing-attribute] @@ -53,7 +52,6 @@ ERROR src/jinja2/lexer.py:816:31-51: Type of yielded value `tuple[Literal[1], st ERROR src/jinja2/loaders.py:143:32-38: `bucket` may be uninitialized [unbound-name] ERROR src/jinja2/loaders.py:144:13-19: `bucket` may be uninitialized [unbound-name] ERROR src/jinja2/loaders.py:145:28-34: `bucket` may be uninitialized [unbound-name] -ERROR src/jinja2/loaders.py:331:29-43: `str` is not assignable to attribute `_archive` with type `None` [bad-assignment] ERROR src/jinja2/meta.py:79:30-40: Argument `tuple[type[Extends], type[FromImport], type[Import], type[Include]]` is not assignable to parameter `node_type` with type `tuple[type[Extends], ...] | type[Extends]` in function `jinja2.nodes.Node.find_all` [bad-argument-type] ERROR src/jinja2/parser.py:160:29-31: Argument `object` is not assignable to parameter `self` with type `Node` in function `jinja2.nodes.Node.__init__` [bad-argument-type] ERROR src/jinja2/parser.py:161:16-18: Returned type `object` is not assignable to declared return type `InternalName` [bad-return] @@ -68,4 +66,4 @@ ERROR src/jinja2/sandbox.py:244:33-43: Cannot set item in `dict[str, ((n: int = ERROR src/jinja2/utils.py:271:16-39: `>` is not supported between `int` and `None` [unsupported-operation] ERROR src/jinja2/utils.py:431:2-29: Class `MutableMapping` has no class attribute `register` [missing-attribute] INFO Checking project configured at `/pyrefly.toml` - INFO 69 errors (77 suppressed) + INFO 67 errors (78 suppressed) diff --git a/scripts/ty_benchmark/snapshots/pandas_Pyrefly.txt b/scripts/ty_benchmark/snapshots/pandas_Pyrefly.txt index f624dc89c2..d0be3aa197 100644 --- a/scripts/ty_benchmark/snapshots/pandas_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/pandas_Pyrefly.txt @@ -50,7 +50,6 @@ ERROR pandas/core/_numba/kernels/mean_.py:135:21-47: `num_consecutive_same_value ERROR pandas/core/_numba/kernels/mean_.py:136:21-31: `prev_value` is uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/mean_.py:141:16-42: `num_consecutive_same_value` may be uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/mean_.py:142:26-36: `prev_value` may be uninitialized [unbound-name] -ERROR pandas/core/_numba/kernels/min_max_.py:109:17-110:37: `int` is not assignable to `int` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR pandas/core/_numba/kernels/sum_.py:135:21-47: `num_consecutive_same_value` is uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/sum_.py:136:21-31: `prev_value` is uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/sum_.py:142:16-42: `num_consecutive_same_value` may be uninitialized [unbound-name] @@ -58,7 +57,6 @@ ERROR pandas/core/_numba/kernels/sum_.py:143:26-36: `prev_value` may be uninitia ERROR pandas/core/_numba/kernels/var_.py:144:21-47: `num_consecutive_same_value` is uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/var_.py:145:21-31: `prev_value` is uninitialized [unbound-name] ERROR pandas/core/_numba/kernels/var_.py:149:29-55: `num_consecutive_same_value` may be uninitialized [unbound-name] -ERROR pandas/core/algorithms.py:214:16-22: Returned type `ExtensionArray & ArrayLikeT` is not assignable to declared return type `ArrayLikeT` [bad-return] ERROR pandas/core/algorithms.py:257:12-18: Returned type `ExtensionArray | Index | NumpyExtensionArray | Series | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to declared return type `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` [bad-return] ERROR pandas/core/algorithms.py:469:16-29: Object of class `ndarray` has no attribute `unique` [missing-attribute] ERROR pandas/core/algorithms.py:476:45-51: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `values` with type `ndarray[tuple[Any, ...], dtype[Any]]` in function `_get_hashtable_algo` [bad-argument-type] @@ -89,7 +87,6 @@ ERROR pandas/core/apply.py:379:57-60: Argument `(BaseWindow & NDFrame) | (DataFr ERROR pandas/core/apply.py:812:5-8: Class member `NDFrameApply.obj` overrides parent class `Apply` in an inconsistent manner [bad-override] ERROR pandas/core/apply.py:868:5-8: Class member `FrameApply.obj` overrides parent class `NDFrameApply` in an inconsistent manner [bad-override] ERROR pandas/core/apply.py:1125:17-27: Type `Materialization` is not iterable [not-iterable] -ERROR pandas/core/apply.py:1152:42-45: Argument `object` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] ERROR pandas/core/apply.py:1477:5-8: Class member `SeriesApply.obj` overrides parent class `NDFrameApply` in an inconsistent manner [bad-override] ERROR pandas/core/apply.py:1589:5-8: Class member `GroupByApply.obj` overrides parent class `Apply` in an inconsistent manner [bad-override] ERROR pandas/core/apply.py:1684:5-8: Class member `ResamplerWindowApply.obj` overrides parent class `GroupByApply` in an inconsistent manner [bad-override] @@ -387,6 +384,10 @@ Object of class `ndarray` has no attribute `_codes` [missing-attribute] ERROR pandas/core/arrays/categorical.py:538:9-29: Class member `Categorical._internal_fill_value` overrides parent class `NDArrayBackedExtensionArray` in an inconsistent manner [bad-override] ERROR pandas/core/arrays/categorical.py:700:18-46: Object of class `ndarray` has no attribute `is_monotonic_increasing` [missing-attribute] ERROR pandas/core/arrays/categorical.py:703:26-42: Object of class `ndarray` has no attribute `sort_values` [missing-attribute] +ERROR pandas/core/arrays/categorical.py:1638:5-11: Class member `Categorical.__eq__` overrides parent class `PandasObject` in an inconsistent manner [bad-override] +ERROR pandas/core/arrays/categorical.py:1638:5-11: Class member `Categorical.__eq__` overrides parent class `ObjectStringArrayMixin` in an inconsistent manner [bad-override] +ERROR pandas/core/arrays/categorical.py:1639:5-11: Class member `Categorical.__ne__` overrides parent class `PandasObject` in an inconsistent manner [bad-override] +ERROR pandas/core/arrays/categorical.py:1639:5-11: Class member `Categorical.__ne__` overrides parent class `ObjectStringArrayMixin` in an inconsistent manner [bad-override] ERROR pandas/core/arrays/categorical.py:1655:9-25: Class member `Categorical._validate_scalar` overrides parent class `NDArrayBackedExtensionArray` in an inconsistent manner [bad-param-name-override] ERROR pandas/core/arrays/categorical.py:2229:9-18: Class member `Categorical._box_func` overrides parent class `NDArrayBackedExtensionArray` in an inconsistent manner [bad-param-name-override] ERROR pandas/core/arrays/categorical.py:2252:9-21: Class member `Categorical.__contains__` overrides parent class `NDArrayBackedExtensionArray` in an inconsistent manner [bad-param-name-override] @@ -406,8 +407,6 @@ ERROR pandas/core/arrays/datetimelike.py:716:25-51: Object of class `DatetimeLik Object of class `ExtensionArray` has no attribute `_internal_get_values` Object of class `ndarray` has no attribute `_internal_get_values` [missing-attribute] ERROR pandas/core/arrays/datetimelike.py:1998:9-13: Class member `TimelikeOps.freq` overrides parent class `DatetimeLikeArrayMixin` in an inconsistent manner [bad-override] -ERROR pandas/core/arrays/datetimelike.py:2038:22-27: `Day | Tick | Unknown | None` is not assignable to attribute `_freq` with type `None` [bad-assignment] -ERROR pandas/core/arrays/datetimelike.py:2337:21-25: `BaseOffset | Day | Tick | None` is not assignable to attribute `_freq` with type `None` [bad-assignment] ERROR pandas/core/arrays/datetimes.py:295:5-11: Class member `DatetimeArray._dtype` overrides parent class `TimelikeOps` in an inconsistent manner [bad-override] ERROR pandas/core/arrays/datetimes.py:295:5-11: Class member `DatetimeArray._dtype` overrides parent class `DatelikeOps` in an inconsistent manner [bad-override] ERROR pandas/core/arrays/datetimes.py:410:9-24: Class member `DatetimeArray._generate_range` overrides parent class `TimelikeOps` in an inconsistent manner [bad-override] @@ -434,9 +433,6 @@ ERROR pandas/core/arrays/datetimes.py:524:32-35: Argument `NaTType | Timestamp | ERROR pandas/core/arrays/datetimes.py:543:33-58: No matching overload found for function `numpy.datetime64.__new__` called with arguments: (type[datetime64[date | int | None]], signedinteger[_64Bit], Literal['ms', 'ns', 's', 'us']) [no-matching-overload] ERROR pandas/core/arrays/datetimes.py:2891:21-36: Object of class `NoneType` has no attribute `normalize` [missing-attribute] ERROR pandas/core/arrays/datetimes.py:2894:19-32: Object of class `NoneType` has no attribute `normalize` [missing-attribute] -ERROR pandas/core/arrays/datetimes.py:2896:12-22: Returned type `tuple[_TimestampNoneT1 | Unknown, _TimestampNoneT2 | Unknown]` is not assignable to declared return type `tuple[_TimestampNoneT1, _TimestampNoneT2]` [bad-return] -ERROR pandas/core/arrays/datetimes.py:2928:29-44: Unpacked keyword argument `bool | Unknown | None` is not assignable to parameter `ambiguous` with type `Literal['NaT', 'raise'] | bool` in function `pandas._libs.tslibs.timestamps.Timestamp.tz_localize` [bad-argument-type] -ERROR pandas/core/arrays/datetimes.py:2928:29-44: Unpacked keyword argument `bool | Unknown | None` is not assignable to parameter `nonexistent` with type `Literal['NaT', 'raise', 'shift_backward', 'shift_forward'] | timedelta` in function `pandas._libs.tslibs.timestamps.Timestamp.tz_localize` [bad-argument-type] ERROR pandas/core/arrays/datetimes.py:2970:17-30: Object of class `NoneType` has no attribute `as_unit` [missing-attribute] ERROR pandas/core/arrays/datetimes.py:2978:15-26: Object of class `NoneType` has no attribute `as_unit` [missing-attribute] ERROR pandas/core/arrays/interval.py:293:17-21: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `intervals` with type `ndarray[tuple[Any, ...], dtype[Any]]` in function `pandas._libs.interval.intervals_to_interval_bounds` [bad-argument-type] @@ -571,9 +567,6 @@ ERROR pandas/core/arrays/timedeltas.py:1148:20-30: Object of class `ExtensionArr Object of class `ndarray` has no attribute `_data` [missing-attribute] ERROR pandas/core/arrays/timedeltas.py:1152:42-46: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]] | Unknown` is not assignable to parameter `values` with type `ndarray[tuple[Any, ...], dtype[Any]]` in function `pandas._libs.tslibs.conversion.cast_from_unit_vectorized` [bad-argument-type] ERROR pandas/core/arrays/timedeltas.py:1161:40-44: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `values` with type `ndarray[tuple[Any, ...], dtype[Any]]` in function `pandas._libs.tslibs.np_datetime.astype_overflowsafe` [bad-argument-type] -ERROR pandas/core/base.py:198:20-45: `NDFrameT` is not subscriptable [unsupported-operation] -ERROR pandas/core/base.py:212:20-50: `NDFrameT` is not subscriptable [unsupported-operation] -ERROR pandas/core/base.py:236:20-33: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/core/common.py:525:20-42: Expected *-unpacked P.args and **-unpacked P.kwargs [invalid-param-spec] ERROR pandas/core/common.py:586:32-41: `old_value` may be uninitialized [unbound-name] ERROR pandas/core/computation/align.py:176:28-35: `list[Unknown]` is not assignable to upper bound `(...) -> Any` of type variable `F` [bad-specialization] @@ -586,7 +579,6 @@ ERROR pandas/core/computation/eval.py:175:35-38: `msg` may be uninitialized [unb ERROR pandas/core/computation/expr.py:172:9-173:41: Argument `Generator[object, None, None]` is not assignable to parameter `iterable` with type `Iterable[_Token]` in function `tokenize.untokenize` [bad-argument-type] ERROR pandas/core/computation/expr.py:241:22-250:18: `-` is not supported between `UnionType` and `frozenset[str]` [unsupported-operation] ERROR pandas/core/computation/expr.py:241:22-250:18: `-` is not supported between `type` and `frozenset[str]` [unsupported-operation] -ERROR pandas/core/computation/expr.py:635:25-60: `str | Any | Unknown` is not assignable to attribute `assigner` with type `None` [bad-assignment] ERROR pandas/core/computation/ops.py:79:20-38: Expected second argument to `super` to be a class object or instance, got `type[Constant] | type[Self@Term]` [invalid-argument] ERROR pandas/core/computation/ops.py:477:32-38: Argument `Any | None` is not assignable to parameter `cls` with type `type` in function `issubclass` [bad-argument-type] ERROR pandas/core/computation/ops.py:478:36-42: Argument `Any | None` is not assignable to parameter `cls` with type `type` in function `issubclass` [bad-argument-type] @@ -700,24 +692,18 @@ ERROR pandas/core/generic.py:9489:22-9493:10: No matching overload found for fun ERROR pandas/core/generic.py:9956:64-72: `res_cols` may be uninitialized [unbound-name] ERROR pandas/core/groupby/generic.py:1133:17-22: Argument `list[ndarray[tuple[int], dtype[Unknown]] | ndarray[tuple[Any, ...], dtype[Any]] | ndarray[tuple[Any, ...], dtype[Unknown]]]` is not assignable to parameter `right_keys` with type `list[ArrayLike]` in function `pandas.core.reshape.merge.get_join_indexers` [bad-argument-type] ERROR pandas/core/groupby/generic.py:2258:19-23: `path` may be uninitialized [unbound-name] -ERROR pandas/core/groupby/groupby.py:712:24-49: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/core/groupby/groupby.py:770:24-53: No matching overload found for function `pandas.core.common.pipe` called with arguments: (Self@BaseGroupBy, ((Self@BaseGroupBy, ParamSpec(P)) -> T) | tuple[(...) -> T, str], *tuple[Any, ...], **dict[str, Any]) [no-matching-overload] ERROR pandas/core/groupby/groupby.py:1603:28-48: Returned type `object` is not assignable to declared return type `NDFrameT` [bad-return] WARN pandas/core/groupby/groupby.py:1837:28-63: Redundant cast: `Literal['idxmax', 'idxmin']` is the same type as `Literal['idxmax', 'idxmin']` [redundant-cast] -ERROR pandas/core/groupby/groupby.py:1845:49-55: Argument `NDFrameT | Unknown` is not assignable to parameter `result` with type `NDFrameT` in function `GroupBy._wrap_transform_fast_result` [bad-argument-type] -ERROR pandas/core/groupby/groupby.py:1870:16-22: Returned type `NDFrameT | Unknown` is not assignable to declared return type `NDFrameT` [bad-return] ERROR pandas/core/groupby/groupby.py:5212:18-24: `concat` may be uninitialized [unbound-name] ERROR pandas/core/groupby/groupby.py:5618:54-65: `weights_arr` may be uninitialized [unbound-name] ERROR pandas/core/groupby/groupby.py:5719:16-22: Returned type `Series | NDFrameT` is not assignable to declared return type `NDFrameT` [bad-return] -ERROR pandas/core/groupby/grouper.py:369:28-36: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/core/groupby/grouper.py:656:47-54: `na_code` may be uninitialized [unbound-name] ERROR pandas/core/groupby/grouper.py:657:34-41: `na_mask` may be uninitialized [unbound-name] ERROR pandas/core/groupby/grouper.py:657:43-50: `na_code` may be uninitialized [unbound-name] ERROR pandas/core/groupby/grouper.py:678:16-30: Returned type `tuple[ndarray[tuple[Any, ...], dtype[signedinteger[_NBitIntP]]] | ndarray[tuple[Any, ...], dtype[Any]], ExtensionArray | Index | ndarray[tuple[Any, ...], dtype[Any]]]` is not assignable to declared return type `tuple[ndarray[tuple[Any, ...], dtype[signedinteger[Any]]], ArrayLike]` [bad-return] -ERROR pandas/core/groupby/grouper.py:871:30-43: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/core/groupby/grouper.py:881:28-36: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR pandas/core/groupby/grouper.py:886:57-60: Argument `Index | Unknown | None` is not assignable to parameter `key` with type `Hashable` in function `pandas.core.generic.NDFrame._check_label_or_level_ambiguity` [bad-argument-type] -ERROR pandas/core/groupby/grouper.py:887:49-57: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/core/groupby/grouper.py:892:32-36: Argument `Index | Unknown | None` is not assignable to parameter `element` with type `Hashable` in function `set.add` [bad-argument-type] ERROR pandas/core/groupby/grouper.py:893:42-45: Argument `Index | Unknown | None` is not assignable to parameter `key` with type `Hashable` in function `pandas.core.generic.NDFrame._is_level_reference` [bad-argument-type] ERROR pandas/core/groupby/numba_.py:116:18-42: Type `prange` is not iterable [not-iterable] @@ -1088,27 +1074,6 @@ ERROR pandas/core/indexes/multi.py:3539:17-3568:43: `ndarray[tuple[int], dtype[A ERROR pandas/core/indexes/multi.py:4048:22-66: Illegal `super(type[MultiIndex], Index)` call: `Index` is not an instance or subclass of `type[MultiIndex]` [invalid-super-call] ERROR pandas/core/indexes/multi.py:4090:20-38: Returned type `Index` is not assignable to declared return type `MultiIndex` [bad-return] ERROR pandas/core/indexes/multi.py:4158:9-29: Class member `MultiIndex._validate_fill_value` overrides parent class `Index` in an inconsistent manner [bad-param-name-override] -ERROR pandas/core/indexes/multi.py:4291:5-12: Class member `MultiIndex.__add__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4292:5-13: Class member `MultiIndex.__radd__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4293:5-13: Class member `MultiIndex.__iadd__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4294:5-12: Class member `MultiIndex.__sub__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4295:5-13: Class member `MultiIndex.__rsub__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4297:5-12: Class member `MultiIndex.__pow__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4298:5-13: Class member `MultiIndex.__rpow__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4299:5-12: Class member `MultiIndex.__mul__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4300:5-13: Class member `MultiIndex.__rmul__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4301:5-17: Class member `MultiIndex.__floordiv__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4302:5-18: Class member `MultiIndex.__rfloordiv__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4303:5-16: Class member `MultiIndex.__truediv__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4304:5-17: Class member `MultiIndex.__rtruediv__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4305:5-12: Class member `MultiIndex.__mod__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4306:5-13: Class member `MultiIndex.__rmod__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4307:5-15: Class member `MultiIndex.__divmod__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4308:5-16: Class member `MultiIndex.__rdivmod__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4310:5-12: Class member `MultiIndex.__neg__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4311:5-12: Class member `MultiIndex.__pos__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4312:5-12: Class member `MultiIndex.__abs__` overrides parent class `Index` in an inconsistent manner [bad-override] -ERROR pandas/core/indexes/multi.py:4313:5-15: Class member `MultiIndex.__invert__` overrides parent class `Index` in an inconsistent manner [bad-override] ERROR pandas/core/indexes/period.py:165:5-10: Class member `PeriodIndex._data` overrides parent class `DatetimeIndexOpsMixin` in an inconsistent manner [bad-override] ERROR pandas/core/indexes/period.py:243:34-38: Argument `Unknown | Self@PeriodIndex | None` is not assignable to parameter `data` with type `ExtensionArray | Index | Sequence[Period | str | None] | Series | ndarray[tuple[Any, ...], dtype[Any]]` in function `pandas.core.arrays.period.period_array` [bad-argument-type] ERROR pandas/core/indexes/period.py:518:16-22: Returned type `NaTType | Period` is not assignable to declared return type `Period` [bad-return] @@ -1121,6 +1086,7 @@ ERROR pandas/core/indexes/range.py:249:9-31: Object of class `object` has no att ERROR pandas/core/indexes/range.py:250:9-27: Object of class `object` has no attribute `_references` [missing-attribute] ERROR pandas/core/indexes/range.py:251:16-22: Returned type `object` is not assignable to declared return type `Self@RangeIndex` [bad-return] ERROR pandas/core/indexes/range.py:779:9-20: Class member `RangeIndex.sort_values` overrides parent class `Index` in an inconsistent manner [bad-override] + WARN pandas/core/indexes/range.py:937:25-30: Identity comparison `False is False` is always True [unnecessary-comparison] ERROR pandas/core/indexes/range.py:1129:24-28: `lidx` may be uninitialized [unbound-name] ERROR pandas/core/indexes/range.py:1129:62-66: `lidx` may be uninitialized [unbound-name] ERROR pandas/core/indexes/range.py:1130:24-28: `ridx` may be uninitialized [unbound-name] @@ -1138,6 +1104,9 @@ ERROR pandas/core/indexing.py:2019:60-72: Cannot index into `slice[Any, Any, Any ERROR pandas/core/indexing.py:2033:45-55: Argument `Hashable | slice[Any, Any, Any] | Unknown` is not assignable to parameter `loc` with type `int` in function `_iLocIndexer._setitem_single_column` [bad-argument-type] ERROR pandas/core/indexing.py:2277:43-53: Argument `Any | None` is not assignable to parameter `dtype` with type `dtype[Any]` in function `pandas.core.dtypes.cast.maybe_promote` [bad-argument-type] ERROR pandas/core/interchange/column.py:174:17-31: Object of class `str` has no attribute `itemsize` [missing-attribute] +ERROR pandas/core/internals/__init__.py:9:5-12: Name `Block` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR pandas/core/internals/__init__.py:11:5-22: Name `DatetimeTZBlock` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR pandas/core/internals/__init__.py:12:5-21: Name `ExtensionBlock` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR pandas/core/internals/api.py:82:5-11: Class member `_DatetimeTZBlock.values` overrides parent class `DatetimeLikeBlock` in an inconsistent manner [bad-override] ERROR pandas/core/internals/api.py:113:57-61: Argument `Unknown | None` is not assignable to parameter `ndim` with type `int` in function `pandas.core.internals.blocks.extract_pandas_array` [bad-argument-type] ERROR pandas/core/internals/api.py:133:13-19: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `values` with type `ndarray[tuple[Any, ...], dtype[datetime64[date | int | None]]]` in function `pandas.core.arrays.datetimes.DatetimeArray._simple_new` [bad-argument-type] @@ -1226,6 +1195,7 @@ ERROR pandas/core/reshape/merge.py:2927:32-39: Argument `ExtensionArray | ndarra ERROR pandas/core/reshape/merge.py:2928:32-39: Argument `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `values` with type `ndarray[tuple[Any, ...], dtype[Any]]` in function `pandas._libs.hashtable.Factorizer.factorize` [bad-argument-type] ERROR pandas/core/reshape/pivot.py:403:30-42: `values_multi` may be uninitialized [unbound-name] ERROR pandas/core/reshape/pivot.py:592:25-34: Argument `list[Hashable | Unknown]` is not assignable to parameter `tuples` with type `Iterable[tuple[Hashable, ...]]` in function `pandas.core.indexes.multi.MultiIndex.from_tuples` [bad-argument-type] + WARN pandas/core/reshape/pivot.py:1164:21-25: Identity comparison `True is True` is always True [unnecessary-comparison] ERROR pandas/core/reshape/reshape.py:513:13-520:65: `DataFrame | Series` is not assignable to `DataFrame` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR pandas/core/reshape/reshape.py:742:9-745:66: `DataFrame | Series` is not assignable to `DataFrame` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR pandas/core/reshape/reshape.py:756:9-763:62: `DataFrame | Series` is not assignable to `DataFrame` (caused by inconsistent types when breaking cycles) [bad-assignment] @@ -1267,6 +1237,7 @@ ERROR pandas/core/strings/accessor.py:331:21-44: No attribute `list_flatten` in ERROR pandas/core/strings/accessor.py:923:21-48: Object of class `str` has no attribute `categories` [missing-attribute] ERROR pandas/core/strings/accessor.py:1046:21-48: Object of class `str` has no attribute `categories` [missing-attribute] ERROR pandas/core/strings/accessor.py:1066:21-48: Object of class `str` has no attribute `categories` [missing-attribute] + WARN pandas/core/strings/accessor.py:1647:30-34: Identity comparison `False is None` is always False [unnecessary-comparison] ERROR pandas/core/strings/accessor.py:3894:12-18: `result` may be uninitialized [unbound-name] ERROR pandas/core/strings/object_array.py:229:20-45: Object of class `type` has no attribute `_from_sequence` [missing-attribute] WARN pandas/core/tools/datetimes.py:533:27-65: Redundant cast: `int` is the same type as `int` [redundant-cast] @@ -1282,6 +1253,7 @@ ERROR pandas/core/tools/numeric.py:278:38-59: Object of class `ExtensionDtype` h ERROR pandas/core/tools/numeric.py:294:24-56: No matching overload found for function `numpy._core.multiarray._ConstructorEmpty.__call__` called with arguments: (tuple[Any, ...], dtype=ExtensionDtype | dtype[signedinteger[_64Bit]] | dtype[Any] | Unknown) [no-matching-overload] ERROR pandas/core/util/numba_.py:79:8-23: Module `numba.extending` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR pandas/core/util/numba_.py:89:22-37: Module `numba.extending` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] + WARN pandas/core/window/common.py:54:30-34: Identity comparison `True is True` is always True [unnecessary-comparison] ERROR pandas/core/window/ewm.py:913:47-55: Argument `Unknown | None` is not assignable to parameter `_grouper` with type `BaseGrouper` in function `pandas.core.window.rolling.BaseWindowGroupby.__init__` [bad-argument-type] ERROR pandas/core/window/expanding.py:419:28-51: No matching overload found for function `pandas.core.window.rolling.RollingAndExpandingMixin.pipe` called with arguments: (((Self@Expanding, ParamSpec(P)) -> T) | tuple[(...) -> T, str], *tuple[Any, ...], **dict[str, Any]) [no-matching-overload] ERROR pandas/core/window/numba_.py:67:18-43: Type `prange` is not iterable [not-iterable] @@ -1345,7 +1317,6 @@ ERROR pandas/io/common.py:1161:12-42: Returned type `tuple[_IOWrapper, Literal[T ERROR pandas/io/excel/_base.py:493:24-34: Argument `int | list[IntStrT] | str | None` is not assignable to parameter `sheet_name` with type `int | list[int] | list[str] | str | None` in function `ExcelFile.parse` [bad-argument-type] ERROR pandas/io/excel/_base.py:496:23-32: Argument `Sequence[int] | int | str | None` is not assignable to parameter `index_col` with type `Sequence[int] | int | None` in function `ExcelFile.parse` [bad-argument-type] ERROR pandas/io/excel/_base.py:520:12-16: Returned type `DataFrame | dict[int, DataFrame] | dict[str, DataFrame]` is not assignable to declared return type `DataFrame | dict[IntStrT, DataFrame]` [bad-return] -ERROR pandas/io/excel/_base.py:547:25-44: `IO[Unknown] & _WorkbookT` is not assignable to attribute `book` with type `_WorkbookT` [bad-assignment] ERROR pandas/io/excel/_base.py:737:22-34: `list[int | list[str]]` is not assignable to variable `sheets` with type `list[int] | list[str]` [bad-assignment] ERROR pandas/io/excel/_base.py:877:28-39: `control_row` may be uninitialized [unbound-name] ERROR pandas/io/excel/_base.py:1174:16-35: Returned type `object` is not assignable to declared return type `Self@ExcelWriter` [bad-return] @@ -1363,6 +1334,7 @@ ERROR pandas/io/excel/_xlrd.py:79:9-23: Class member `XlrdReader.get_sheet_data` ERROR pandas/io/formats/excel.py:252:21-24: Argument `dict[str, dict[str, bool | float | str | None] | dict[str, bool | str | None] | dict[str, str | None] | dict[str, dict[str, str | None]] | Unknown]` is not assignable to parameter `d` with type `dict[str, str | None]` in function `remove_none` [bad-argument-type] ERROR pandas/io/formats/excel.py:253:16-19: Returned type `dict[str, dict[str, bool | float | str | None] | dict[str, bool | str | None] | dict[str, str | None] | dict[str, dict[str, str | None]] | Unknown]` is not assignable to declared return type `dict[str, dict[str, str]]` [bad-return] WARN pandas/io/formats/format.py:237:28-43: Redundant cast: `int` is the same type as `int` [redundant-cast] + WARN pandas/io/formats/format.py:283:58-62: Identity comparison `True is not None` is always True [unnecessary-comparison] ERROR pandas/io/formats/format.py:1052:1-16: Argument `(buf: PathLike[str] | WriteBuffer[str] | str | None, encoding: str | None = None) -> Generator[StringIO, None, None] | Generator[WriteBuffer[str], None, None]` is not assignable to parameter `func` with type `(buf: PathLike[str] | WriteBuffer[str] | str | None, encoding: str | None = None) -> Iterator[StringIO]` in function `contextlib.contextmanager` [bad-argument-type] ERROR pandas/io/formats/format.py:1081:19-20: Type of yielded value `TextIOWrapper[_WrappedBuffer]` is not assignable to declared return type `StringIO` [invalid-yield] ERROR pandas/io/formats/format.py:1159:9-15: Argument `DatetimeArray | ExtensionArray | TimedeltaArray | ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to parameter `values` with type `DatetimeArray` in function `_Datetime64Formatter.__init__` [bad-argument-type] @@ -1390,16 +1362,8 @@ ERROR pandas/io/formats/printing.py:452:53-61: Argument `str | tuple[str, ...] | ERROR pandas/io/formats/string.py:143:31-34: `idx` may be uninitialized [unbound-name] ERROR pandas/io/formats/string.py:150:28-63: Argument `str` is not assignable to parameter `object` with type `LiteralString` in function `list.append` [bad-argument-type] ERROR pandas/io/formats/style.py:2010:33-39: `result` may be uninitialized [unbound-name] +ERROR pandas/io/formats/style.py:2704:24-55: Unpacked `dict[str, str]` is not assignable to `dict[str, str]` [bad-unpacking] ERROR pandas/io/formats/style.py:3879:24-53: No matching overload found for function `pandas.core.common.pipe` called with arguments: (Self@Styler, ((Self@Styler, ParamSpec(P)) -> T) | tuple[(...) -> T, str], *tuple[Any, ...], **dict[str, Any]) [no-matching-overload] -ERROR pandas/io/formats/style.py:4236:9-17: `object` is not assignable to `float` [bad-assignment] -ERROR pandas/io/formats/style.py:4269:24-32: `-` is not supported between `Literal[0]` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4269:24-32: `-` is not supported between `float` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4269:34-43: `-` is not supported between `Literal[0]` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4269:34-43: `-` is not supported between `float` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4279:25-33: `-` is not supported between `Literal[0]` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4279:25-33: `-` is not supported between `float` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4280:25-34: `-` is not supported between `Literal[0]` and `object` [unsupported-operation] -ERROR pandas/io/formats/style.py:4280:25-34: `-` is not supported between `float` and `object` [unsupported-operation] ERROR pandas/io/formats/style_render.py:959:28-42: `row_body_cells` may be uninitialized [unbound-name] ERROR pandas/io/formats/style_render.py:1849:32-42: `last_label` is uninitialized [unbound-name] ERROR pandas/io/formats/style_render.py:1855:33-43: `last_label` is uninitialized [unbound-name] @@ -1410,18 +1374,10 @@ ERROR pandas/io/html.py:639:9-18: Class member `_BeautifulSoupHtml5LibFrameParse ERROR pandas/io/html.py:731:9-18: Class member `_LxmlFrameParser._parse_td` overrides parent class `_HtmlFrameParser` in an inconsistent manner [bad-param-name-override] ERROR pandas/io/html.py:736:9-22: Class member `_LxmlFrameParser._parse_tables` overrides parent class `_HtmlFrameParser` in an inconsistent manner [bad-param-name-override] ERROR pandas/io/json/_json.py:955:16-19: `obj` may be uninitialized [unbound-name] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `dtype` with type `ExtensionDtype | Mapping[Hashable, Dtype] | dtype[Any] | str | type[bool | complex | object | str] | None` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `convert_axes` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `convert_dates` with type `bool | list[str]` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `keep_default_dates` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `precise_float` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1025:38-46: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `dtype_backend` with type `Literal['numpy_nullable', 'pyarrow'] | _NoDefault` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `dtype` with type `ExtensionDtype | Mapping[Hashable, Dtype] | dtype[Any] | str | type[bool | complex | object | str] | None` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `convert_axes` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `convert_dates` with type `bool | list[str]` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `keep_default_dates` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `precise_float` with type `bool` in function `Parser.__init__` [bad-argument-type] -ERROR pandas/io/json/_json.py:1029:39-47: Unpacked keyword argument `_NoDefault | bool | str | Unknown | None` is not assignable to parameter `dtype_backend` with type `Literal['numpy_nullable', 'pyarrow'] | _NoDefault` in function `Parser.__init__` [bad-argument-type] +ERROR pandas/io/json/_json.py:1025:38-46: Argument `bool | None` is not assignable to parameter `convert_axes` with type `bool` in function `Parser.__init__` [bad-argument-type] +ERROR pandas/io/json/_json.py:1025:38-46: Argument `_NoDefault | str` is not assignable to parameter `dtype_backend` with type `Literal['numpy_nullable', 'pyarrow'] | _NoDefault` in function `Parser.__init__` [bad-argument-type] +ERROR pandas/io/json/_json.py:1029:39-47: Argument `bool | None` is not assignable to parameter `convert_axes` with type `bool` in function `Parser.__init__` [bad-argument-type] +ERROR pandas/io/json/_json.py:1029:39-47: Argument `_NoDefault | str` is not assignable to parameter `dtype_backend` with type `Literal['numpy_nullable', 'pyarrow'] | _NoDefault` in function `Parser.__init__` [bad-argument-type] ERROR pandas/io/json/_normalize.py:148:12-18: Returned type `list[dict[str, Any] | list[dict[str, Any]]]` is not assignable to declared return type `dict[str, Any] | list[dict[str, Any]]` [bad-return] ERROR pandas/io/json/_normalize.py:578:32-41: Argument `int` is not assignable to parameter `object` with type `_NestedSequence[_SupportsArray[dtype[numpy.bool[builtins.bool] | integer[Any]]]] | _SupportsArray[dtype[numpy.bool[builtins.bool] | integer[Any]]]` in function `list.append` [bad-argument-type] ERROR pandas/io/json/_table_schema.py:311:36-53: Object of class `Index` has no attribute `levels` [missing-attribute] @@ -1454,13 +1410,18 @@ ERROR pandas/io/pytables.py:140:39-44: Could not import `Block` from `pandas.cor ERROR pandas/io/pytables.py:483:8-47: `<=` is not supported between `None` and `None` [unsupported-operation] ERROR pandas/io/pytables.py:487:11-31: `>` is not supported between `None` and `Literal[1]` [unsupported-operation] ERROR pandas/io/pytables.py:639:30-38: `None` is not subscriptable [unsupported-operation] -ERROR pandas/io/pytables.py:702:20-704:14: Returned type `list[None]` is not assignable to declared return type `list[str]` [bad-return] +ERROR pandas/io/pytables.py:702:20-704:14: Returned type `list[Unknown | None]` is not assignable to declared return type `list[str]` [bad-return] ERROR pandas/io/pytables.py:1281:13-14: `s` may be uninitialized [unbound-name] ERROR pandas/io/pytables.py:1285:16-17: `s` may be uninitialized [unbound-name] ERROR pandas/io/pytables.py:1287:16-17: `s` may be uninitialized [unbound-name] ERROR pandas/io/pytables.py:1659:20-40: Object of class `NoneType` has no attribute `rstrip` [missing-attribute] ERROR pandas/io/pytables.py:1941:64-72: Argument `Unknown | None` is not assignable to parameter `encoding` with type `str` in function `HDFStore._create_storer` [bad-argument-type] ERROR pandas/io/pytables.py:2017:16-21: `group` may be uninitialized [unbound-name] +ERROR pandas/io/pytables.py:2091:15-34: `<` is not supported between `Literal[0]` and `None` [unsupported-operation] +ERROR pandas/io/pytables.py:2091:15-34: `<` is not supported between `None` and `None` [unsupported-operation] +ERROR pandas/io/pytables.py:2092:24-48: `+` is not supported between `Literal[0]` and `None` [unsupported-operation] +ERROR pandas/io/pytables.py:2092:24-48: `+` is not supported between `None` and `int` [unsupported-operation] +ERROR pandas/io/pytables.py:2092:24-48: `+` is not supported between `None` and `None` [unsupported-operation] ERROR pandas/io/pytables.py:2196:16-33: Object of class `NoneType` has no attribute `itemsize` [missing-attribute] ERROR pandas/io/pytables.py:2254:41-49: Argument `Unknown | None` is not assignable to parameter `val_kind` with type `str` in function `_maybe_convert` [bad-argument-type] ERROR pandas/io/pytables.py:2277:44-52: Unpacked keyword argument `Unknown | None` is not assignable to parameter `freq` with type `BaseOffset | _NoDefault | str` in function `pandas.core.indexes.datetimes.DatetimeIndex.__new__` [bad-argument-type] @@ -1513,19 +1474,17 @@ ERROR pandas/io/pytables.py:3678:21-29: No matching overload found for function ERROR pandas/io/pytables.py:4135:13-26: Cannot index into `list[Index]` [bad-index] ERROR pandas/io/pytables.py:4136:40-43: Argument `int | Unknown | None` is not assignable to parameter `axis` with type `Literal['columns', 'index', 'rows'] | int` in function `pandas.core.generic.NDFrame._get_axis_name` [bad-argument-type] ERROR pandas/io/pytables.py:4383:23-37: `process_filter` may be uninitialized [unbound-name] -ERROR pandas/io/pytables.py:4402:28-63: Cannot set item in `dict[str, int | str]` [unsupported-operation] +ERROR pandas/io/pytables.py:4402:28-63: `dict[str, Unknown | None]` is not assignable to TypedDict key `description` with type `int | str` [bad-typed-dict-key] ERROR pandas/io/pytables.py:4598:24-40: Object of class `bool` has no attribute `all` [missing-attribute] ERROR pandas/io/pytables.py:4945:5-11: Class member `GenericTable.levels` overrides parent class `AppendableFrameTable` in an inconsistent manner [bad-override] ERROR pandas/io/pytables.py:5205:19-35: Object of class `ndarray` has no attribute `to_numpy` [missing-attribute] -ERROR pandas/io/pytables.py:5503:44-49: `ndarray[tuple[Any, ...], dtype[Any]]` is not assignable to attribute `coordinates` with type `None` [bad-assignment] ERROR pandas/io/pytables.py:5506:39-46: No matching overload found for function `Selection.generate` called with arguments: (ndarray[tuple[Any, ...], dtype[Any]] | Unknown | None) [no-matching-overload] ERROR pandas/io/sas/sas_xport.py:491:32-33: `v` may be uninitialized [unbound-name] ERROR pandas/io/sql.py:1036:20-35: Object of class `NoneType` has no attribute `copy` [missing-attribute] ERROR pandas/io/sql.py:1045:38-50: Object of class `NoneType` has no attribute `columns` [missing-attribute] ERROR pandas/io/sql.py:1051:38-48: Object of class `NoneType` has no attribute `items` [missing-attribute] ERROR pandas/io/sql.py:1100:21-31: Argument `Unknown | None` is not assignable to parameter `obj` with type `Sized` in function `len` [bad-argument-type] -ERROR pandas/io/sql.py:1113:13-1128:55: `int | object | None` is not assignable to `None` (caused by inconsistent types when breaking cycles) [bad-assignment] -ERROR pandas/io/sql.py:1129:16-30: Returned type `int | object | None` is not assignable to declared return type `int | None` [bad-return] +ERROR pandas/io/sql.py:1113:13-1128:55: `int | Unknown | None` is not assignable to `None` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR pandas/io/sql.py:1217:23-39: Object of class `NoneType` has no attribute `index` [missing-attribute] ERROR pandas/io/sql.py:1231:36-54: Object of class `NoneType` has no attribute `columns` [missing-attribute] ERROR pandas/io/sql.py:1232:21-37: Object of class `NoneType` has no attribute `index` [missing-attribute] @@ -1610,11 +1569,9 @@ ERROR pandas/plotting/_matplotlib/converter.py:1102:5-9: Class member `TimeSerie ERROR pandas/plotting/_matplotlib/core.py:443:16-19: Returned type `list[tuple[Unknown]]` is not assignable to declared return type `bool | list[tuple[int, ...]]` [bad-return] ERROR pandas/plotting/_matplotlib/core.py:698:33-41: Argument `type[bool]` is not assignable to parameter `object` with type `type[number] | str` in function `list.append` [bad-argument-type] ERROR pandas/plotting/_matplotlib/core.py:709:33-65: Argument `list[str]` is not assignable to parameter `iterable` with type `Iterable[type[number]]` in function `list.extend` [bad-argument-type] + WARN pandas/plotting/_matplotlib/core.py:727:28-32: Identity comparison `True is True` is always True [unnecessary-comparison] ERROR pandas/plotting/_matplotlib/core.py:1063:35-39: Function declared to return `bool`, but one or more paths are missing an explicit `return` [bad-return] -ERROR pandas/plotting/_matplotlib/core.py:1163:23-32: `NDFrameT` is not subscriptable [unsupported-operation] -ERROR pandas/plotting/_matplotlib/core.py:1164:20-48: `NDFrameT` is not subscriptable [unsupported-operation] ERROR pandas/plotting/_matplotlib/core.py:1202:26-1205:14: No matching overload found for function `numpy.lib._shape_base_impl.tile` called with arguments: (list[Number | number[Any, complex | float | int]], tuple[int, int]) [no-matching-overload] -ERROR pandas/plotting/_matplotlib/core.py:1211:16-25: Returned type `tuple[Unknown, NDFrameT | Unknown]` is not assignable to declared return type `tuple[Any, NDFrameT]` [bad-return] ERROR pandas/plotting/_matplotlib/core.py:1240:32-40: Module `matplotlib.axes` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR pandas/plotting/_matplotlib/core.py:1383:21-32: Module `matplotlib.patches` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR pandas/plotting/_matplotlib/core.py:1575:40-42: Argument `Iterable[tuple[Hashable, Series]] | Iterator[tuple[Hashable, ndarray[tuple[Any, ...], dtype[Any]]]]` is not assignable to parameter `iterable` with type `Iterable[tuple[Hashable, Series]]` in function `enumerate.__new__` [bad-argument-type] @@ -1626,7 +1583,6 @@ ERROR pandas/plotting/_matplotlib/misc.py:192:18-29: Module `matplotlib.patches` ERROR pandas/plotting/_matplotlib/misc.py:195:22-33: Module `matplotlib.patches` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR pandas/plotting/_matplotlib/misc.py:416:27-42: Unpacked keyword argument `int | str` is not assignable to parameter `ymin` with type `float` in function `matplotlib.axes._axes.Axes.axvline` [bad-argument-type] ERROR pandas/plotting/_matplotlib/misc.py:416:27-42: Unpacked keyword argument `int | str` is not assignable to parameter `ymax` with type `float` in function `matplotlib.axes._axes.Axes.axvline` [bad-argument-type] -ERROR pandas/plotting/_matplotlib/timeseries.py:294:12-16: Returned type `NDFrameT | Unknown` is not assignable to declared return type `NDFrameT` [bad-return] ERROR pandas/plotting/_matplotlib/tools.py:82:12-21: Module `matplotlib.table` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR pandas/plotting/_matplotlib/tools.py:85:19-28: Argument `Index | Unknown` is not assignable to parameter `rowLabels` with type `Sequence[str] | None` in function `matplotlib.table.table` [bad-argument-type] ERROR pandas/plotting/_matplotlib/tools.py:86:19-28: Argument `Index | Unknown` is not assignable to parameter `colLabels` with type `Sequence[str] | None` in function `matplotlib.table.table` [bad-argument-type] @@ -1656,4 +1612,4 @@ ERROR typings/numba.pyi:20:7-23: Module `numba.core.types` exists, but was not i ERROR typings/numba.pyi:21:12-28: Module `numba.core.types` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR typings/numba.pyi:24:21-35: No attribute `compiler` in module `numba` [missing-attribute] INFO Checking project configured at `/pyrefly.toml` - INFO 1,592 errors (595 suppressed) + INFO 1,542 errors (592 suppressed) diff --git a/scripts/ty_benchmark/snapshots/pandas_ty.txt b/scripts/ty_benchmark/snapshots/pandas_ty.txt index 4f2361619e..1209e08752 100644 --- a/scripts/ty_benchmark/snapshots/pandas_ty.txt +++ b/scripts/ty_benchmark/snapshots/pandas_ty.txt @@ -12,6 +12,8 @@ pandas/_version.py:48:5: error[unresolved-attribute] Unresolved attribute `versi pandas/_version.py:49:5: error[unresolved-attribute] Unresolved attribute `verbose` on type `VersioneerConfig`. pandas/_version.py:101:16: error[unresolved-attribute] Object of type `BaseException | None` has no attribute `errno` pandas/_version.py:111:14: error[unresolved-attribute] Object of type `str` has no attribute `decode` +pandas/conftest.py:2123:10: error[missing-argument] No argument provided for required parameter `cls` +pandas/conftest.py:2123:10: error[missing-argument] No argument provided for required parameter `cls` pandas/core/_numba/executor.py:48:22: error[not-iterable] Object of type `prange` is not iterable pandas/core/_numba/executor.py:52:22: error[not-iterable] Object of type `prange` is not iterable pandas/core/_numba/executor.py:78:22: error[not-iterable] Object of type `prange` is not iterable @@ -123,7 +125,7 @@ pandas/core/arrays/_arrow_string_mixins.py:360:22: error[unresolved-attribute] M pandas/core/arrays/_arrow_string_mixins.py:361:21: error[unresolved-attribute] Module `pyarrow.compute` has no member `not_equal` pandas/core/arrays/_arrow_string_mixins.py:362:29: error[unresolved-attribute] Module `pyarrow.compute` has no member `add` pandas/core/arrays/_arrow_string_mixins.py:363:22: error[unresolved-attribute] Module `pyarrow.compute` has no member `if_else` -pandas/core/arrays/_mixins.py:135:20: error[invalid-return-type] Return type does not match returned value: expected `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]`, found `ndarray[tuple[Any, ...], type]` +pandas/core/arrays/_mixins.py:242:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_concat_same_type`, found `NDArrayBackedExtensionArray` pandas/core/arrays/_mixins.py:283:9: error[invalid-method-override] Invalid override of method `__getitem__`: Definition is incompatible with `ExtensionArray.__getitem__` pandas/core/arrays/arrow/accessors.py:115:25: error[unresolved-attribute] Module `pyarrow.compute` has no member `list_value_length` pandas/core/arrays/arrow/accessors.py:163:23: error[unresolved-attribute] Module `pyarrow.compute` has no member `list_element` @@ -309,7 +311,9 @@ pandas/core/arrays/arrow/array.py:3199:22: error[unresolved-attribute] Module `p pandas/core/arrays/arrow/extension_types.py:171:5: error[unresolved-attribute] Unresolved attribute `_hotfix_installed` on type ``. pandas/core/arrays/boolean.py:259:24: warning[possibly-missing-attribute] Attribute `shape` may be missing on object of type `Unknown | None | ndarray[tuple[Any, ...], dtype[bool[bool]]] | ndarray[tuple[Any, ...], dtype[Any]]` pandas/core/arrays/boolean.py:262:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[ndarray[tuple[Any, ...], dtype[Any]], ndarray[tuple[Any, ...], dtype[Any]]]`, found `tuple[@Todo | ndarray[tuple[int], dtype[Any]], Unknown | None | ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]] | ndarray[tuple[Any, ...], dtype[Any]]]` +pandas/core/arrays/boolean.py:333:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_simple_new`, found `BooleanArray` pandas/core/arrays/boolean.py:385:9: error[invalid-method-override] Invalid override of method `_coerce_to_array`: Definition is incompatible with `BaseMaskedArray._coerce_to_array` +pandas/core/arrays/categorical.py:385:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_simple_new`, found `Categorical` pandas/core/arrays/categorical.py:494:25: warning[possibly-missing-attribute] Attribute `_codes` may be missing on object of type `Unknown | RangeIndex | ndarray[tuple[Any, ...], dtype[Any]] | ExtensionArray` pandas/core/arrays/categorical.py:700:18: warning[possibly-missing-attribute] Attribute `is_monotonic_increasing` may be missing on object of type `Index | Unknown | ndarray[tuple[Any, ...], dtype[bool[bool]]]` pandas/core/arrays/categorical.py:703:26: warning[possibly-missing-attribute] Attribute `sort_values` may be missing on object of type `Index | Unknown | ndarray[tuple[Any, ...], dtype[bool[bool]]]` @@ -323,15 +327,14 @@ pandas/core/arrays/categorical.py:2989:9: error[invalid-method-override] Invalid pandas/core/arrays/categorical.py:2992:9: error[invalid-method-override] Invalid override of method `_delegate_property_set`: Definition is incompatible with `PandasDelegate._delegate_property_set` pandas/core/arrays/datetimelike.py:387:9: error[invalid-method-override] Invalid override of method `__getitem__`: Definition is incompatible with `ExtensionArray.__getitem__` pandas/core/arrays/datetimelike.py:565:18: error[invalid-argument-type] Argument to function `len` is incorrect: Expected `Sized`, found `(Unknown & ~str) | Period | Timestamp | Timedelta | NaTType` -pandas/core/arrays/datetimelike.py:1144:42: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[datetime64[date | int | None]]]`, found `ndarray[tuple[Any, ...], str]` -pandas/core/arrays/datetimelike.py:1206:43: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[timedelta64[timedelta | int | None]]]`, found `ndarray[tuple[Any, ...], str]` -pandas/core/arrays/datetimelike.py:1315:20: error[invalid-return-type] Return type does not match returned value: expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `ndarray[tuple[int, ...], dtype[Any] | str]` +pandas/core/arrays/datetimelike.py:714:16: warning[possibly-missing-attribute] Attribute `categories` may be missing on object of type `Unknown | Self@_validate_listlike` +pandas/core/arrays/datetimelike.py:716:25: warning[possibly-missing-attribute] Attribute `_internal_get_values` may be missing on object of type `Unknown | Self@_validate_listlike` pandas/core/arrays/datetimelike.py:1582:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_quantile`, found `DatetimeLikeArrayMixin` -pandas/core/arrays/datetimelike.py:1771:47: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[timedelta64[timedelta | int | None]]]`, found `ndarray[tuple[Any, ...], str]` pandas/core/arrays/datetimelike.py:2375:9: error[invalid-method-override] Invalid override of method `_concat_same_type`: Definition is incompatible with `NDArrayBacked._concat_same_type` pandas/core/arrays/datetimelike.py:2399:16: error[invalid-return-type] Return type does not match returned value: expected `Self@copy`, found `TimelikeOps` pandas/core/arrays/datetimelike.py:2458:16: error[invalid-return-type] Return type does not match returned value: expected `Self@take`, found `TimelikeOps` pandas/core/arrays/datetimelike.py:2476:36: error[invalid-argument-type] Argument to function `py_get_unit_from_dtype` is incorrect: Expected `dtype[Any]`, found `ExtensionDtype` +pandas/core/arrays/datetimes.py:332:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_simple_new`, found `DatetimeArray` pandas/core/arrays/datetimes.py:410:9: error[invalid-method-override] Invalid override of method `_generate_range`: Definition is incompatible with `TimelikeOps._generate_range` pandas/core/arrays/datetimes.py:483:62: warning[possibly-missing-attribute] Attribute `tz` may be missing on object of type `Timestamp | None` pandas/core/arrays/datetimes.py:501:51: error[invalid-argument-type] Argument to bound method `tz_localize` is incorrect: Expected `bool | Literal["NaT", "raise"]`, found `Literal["NaT", "infer", "raise"] | ndarray[tuple[Any, ...], dtype[bool[bool]]]` @@ -344,8 +347,6 @@ pandas/core/arrays/datetimes.py:524:32: error[invalid-argument-type] Argument to pandas/core/arrays/datetimes.py:561:45: error[invalid-argument-type] Argument to bound method `_from_value_and_reso` is incorrect: Expected `int`, found `datetime64[date | int | None]` pandas/core/arrays/datetimes.py:590:21: error[invalid-type-form] Variable of type `property` is not allowed in a type expression pandas/core/arrays/datetimes.py:639:25: error[invalid-type-form] Variable of type `property` is not allowed in a type expression -pandas/core/arrays/datetimes.py:1114:65: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], str], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], str], (key: str, /) -> ndarray[tuple[Any, ...], dtype[Any]], (key: list[str], /) -> ndarray[tuple[Any, ...], dtype[void]]]` cannot be called with key of type `Literal[0]` on object of type `ndarray[tuple[Any, ...], str]` -pandas/core/arrays/datetimes.py:1121:33: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[datetime64[date | int | None]]]`, found `ndarray[tuple[Any, ...], str]` pandas/core/arrays/datetimes.py:2891:21: error[invalid-assignment] Object of type `Timestamp` is not assignable to `_TimestampNoneT1@_maybe_normalize_endpoints` pandas/core/arrays/datetimes.py:2894:19: error[invalid-assignment] Object of type `Timestamp` is not assignable to `_TimestampNoneT2@_maybe_normalize_endpoints` pandas/core/arrays/datetimes.py:2928:29: error[invalid-argument-type] Argument to bound method `tz_localize` is incorrect: Expected `bool | Literal["NaT", "raise"]`, found `Unknown | bool | None` @@ -358,9 +359,10 @@ pandas/core/arrays/interval.py:399:63: warning[possibly-missing-attribute] Attri pandas/core/arrays/interval.py:401:35: warning[possibly-missing-attribute] Attribute `_ensure_matching_resos` may be missing on object of type `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]] | Unknown` pandas/core/arrays/interval.py:831:9: error[invalid-method-override] Invalid override of method `__getitem__`: Definition is incompatible with `ExtensionArray.__getitem__` pandas/core/arrays/interval.py:1127:9: error[invalid-method-override] Invalid override of method `_concat_same_type`: Definition is incompatible with `ExtensionArray._concat_same_type` +pandas/core/arrays/interval.py:1147:73: error[invalid-argument-type] Argument to bound method `_ensure_simple_new_inputs` is incorrect: Expected `Literal["both", "left", "neither", "right"] | None`, found `str | Unknown` pandas/core/arrays/interval.py:1801:50: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Argument type `Period | Timestamp | Timedelta | NaTType | Any` does not satisfy constraints (`int`, `int | float`, `Timestamp`, `Timedelta`) of type variable `_OrderableT` pandas/core/arrays/interval.py:1801:50: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `int`, found `Period | Timestamp | Timedelta | NaTType | Any` -pandas/core/arrays/masked.py:185:30: error[invalid-assignment] Object of type `ndarray[tuple[int, ...], dtype[Any] | type]` is not assignable to `ndarray[tuple[Any, ...], dtype[Any]]` +pandas/core/arrays/masked.py:156:54: error[invalid-argument-type] Argument to bound method `_coerce_to_array` is incorrect: Expected `dtype[Any] | ExtensionDtype`, found `Unknown | None` pandas/core/arrays/masked.py:385:9: error[invalid-method-override] Invalid override of method `__contains__`: Definition is incompatible with `ExtensionArray.__contains__` pandas/core/arrays/masked.py:1036:9: error[invalid-method-override] Invalid override of method `_concat_same_type`: Definition is incompatible with `ExtensionArray._concat_same_type` pandas/core/arrays/masked.py:1054:9: error[invalid-method-override] Invalid override of method `take`: Definition is incompatible with `ExtensionArray.take` @@ -406,6 +408,7 @@ pandas/core/arrays/string_arrow.py:494:23: error[unresolved-attribute] Module `p pandas/core/arrays/string_arrow.py:494:41: error[unresolved-attribute] Module `pyarrow.compute` has no member `not_equal` pandas/core/arrays/string_arrow.py:496:23: error[unresolved-attribute] Module `pyarrow.compute` has no member `not_equal` pandas/core/arrays/timedeltas.py:188:47: error[invalid-argument-type] Argument to bound method `_from_value_and_reso` is incorrect: Expected `signedinteger[_64Bit]`, found `timedelta64[timedelta | int | None]` +pandas/core/arrays/timedeltas.py:240:16: error[invalid-return-type] Return type does not match returned value: expected `Self@_simple_new`, found `TimedeltaArray` pandas/core/arrays/timedeltas.py:243:9: error[invalid-method-override] Invalid override of method `_from_sequence`: Definition is incompatible with `ExtensionArray._from_sequence` pandas/core/arrays/timedeltas.py:250:46: error[invalid-argument-type] Argument to function `astype_overflowsafe` is incorrect: Expected `dtype[Any]`, found `(Unknown & ~AlwaysTruthy & ~None) | dtype[Any] | ExtensionDtype` pandas/core/arrays/timedeltas.py:276:46: error[invalid-argument-type] Argument to function `astype_overflowsafe` is incorrect: Expected `dtype[Any]`, found `(Unknown & ~AlwaysTruthy & ~None) | dtype[Any] | ExtensionDtype` @@ -462,7 +465,6 @@ pandas/core/dtypes/dtypes.py:1363:39: error[invalid-type-form] Invalid subscript pandas/core/dtypes/dtypes.py:1398:23: error[invalid-type-form] Invalid subscript of object of type `property` in type expression pandas/core/dtypes/dtypes.py:1548:23: error[invalid-type-form] Invalid subscript of object of type `property` in type expression pandas/core/dtypes/inference.py:301:17: error[invalid-argument-type] Argument to function `len` is incorrect: Expected `Sized`, found `` -pandas/core/dtypes/missing.py:392:12: error[unsupported-operator] Unary operator `~` is unsupported for type `~bool` pandas/core/frame.py:894:56: error[invalid-argument-type] Argument to function `construct_1d_arraylike_from_scalar` is incorrect: Expected `str | bytes | date | ... omitted 10 union elements`, found `(@Todo & ~BlockManager & ~None & ~Top[dict[Unknown, Unknown]] & ~ndarray[tuple[object, ...], dtype[object]] & ~Series & ~Index & ~ExtensionArray) | (list[Unknown] & ~BlockManager & ~ndarray[tuple[object, ...], dtype[object]] & ~Series & ~Index & ~ExtensionArray)` pandas/core/frame.py:900:21: error[invalid-argument-type] Argument to function `construct_2d_arraylike_from_scalar` is incorrect: Expected `str | bytes | date | ... omitted 10 union elements`, found `(@Todo & ~BlockManager & ~None & ~Top[dict[Unknown, Unknown]] & ~ndarray[tuple[object, ...], dtype[object]] & ~Series & ~Index & ~ExtensionArray) | (list[Unknown] & ~BlockManager & ~ndarray[tuple[object, ...], dtype[object]] & ~Series & ~Index & ~ExtensionArray)` pandas/core/frame.py:2358:37: error[no-matching-overload] No overload of function `maybe_convert_objects` matches arguments @@ -552,6 +554,7 @@ pandas/core/indexes/datetimelike.py:156:10: error[invalid-argument-type] Argumen pandas/core/indexes/datetimelike.py:200:42: warning[possibly-missing-attribute] Attribute `asi8` may be missing on object of type `(Any & Index) | CategoricalIndex | Self@equals` pandas/core/indexes/datetimelike.py:527:10: error[invalid-argument-type] Argument to function `doc` is incorrect: Expected `None | str | ((...) -> Unknown)`, found `property` pandas/core/indexes/datetimelike.py:756:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[Self@_wrap_join_result, ndarray[tuple[Any, ...], dtype[signedinteger[_64Bit]]] | None, ndarray[tuple[Any, ...], dtype[signedinteger[_64Bit]]] | None]`, found `tuple[DatetimeTimedeltaMixin | Unknown, ndarray[tuple[Any, ...], dtype[signedinteger[_64Bit]]] | None, ndarray[tuple[Any, ...], dtype[signedinteger[_64Bit]]] | None]` +pandas/core/indexes/datetimelike.py:807:45: error[unsupported-operator] Operator `-` is unsupported between objects of type `Timestamp | NaTType | Timedelta` and `BaseOffset` pandas/core/indexes/datetimelike.py:815:45: error[invalid-argument-type] Argument to bound method `is_on_offset` is incorrect: Expected `datetime`, found `Timestamp | NaTType | Timedelta` pandas/core/indexes/datetimelike.py:823:16: error[invalid-return-type] Return type does not match returned value: expected `Self@delete`, found `DatetimeTimedeltaMixin` pandas/core/indexes/datetimelike.py:855:13: error[invalid-assignment] Object of type `BaseOffset | None` is not assignable to attribute `_freq` on type `DatetimeArray | TimedeltaArray` @@ -603,7 +606,6 @@ pandas/core/internals/construction.py:992:27: error[no-matching-overload] No ove pandas/core/internals/construction.py:1021:46: error[invalid-argument-type] Argument to function `maybe_cast_to_datetime` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[Any]] | list[Unknown]`, found `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]]` pandas/core/internals/managers.py:1656:9: error[invalid-method-override] Invalid override of method `_equal_values`: Definition is incompatible with `BaseBlockManager._equal_values` pandas/core/internals/managers.py:2231:9: error[invalid-method-override] Invalid override of method `_equal_values`: Definition is incompatible with `BaseBlockManager._equal_values` -pandas/core/internals/managers.py:2501:42: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[datetime64[date | int | None]]]`, found `ndarray[tuple[int, ...], str]` pandas/core/missing.py:153:12: error[invalid-return-type] Return type does not match returned value: expected `ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]`, found `Unknown | (ExtensionArray & ndarray[tuple[object, ...], dtype[object]]) | ndarray[tuple[Any, ...], dtype[Any]]` pandas/core/missing.py:608:19: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Literal["linear", "nearest", "nearest-up", "slinear", "zero", ... omitted 4 literals] | int`, found `Unknown | None | (str & ~Literal["polynomial"])` pandas/core/missing.py:613:28: error[unsupported-operator] Operator `<=` is not supported between objects of type `Unknown | None` and `Literal[0]` @@ -625,6 +627,7 @@ pandas/core/ops/mask_ops.py:132:12: error[invalid-return-type] Return type does pandas/core/ops/mask_ops.py:172:18: error[unsupported-operator] Operator `&` is unsupported between objects of type `(NAType & ndarray[tuple[object, ...], dtype[object]]) | ndarray[tuple[Any, ...], dtype[Any]]` and `bool | NAType | ndarray[tuple[Any, ...], dtype[Any]]` pandas/core/ops/mask_ops.py:190:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]], ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]]`, found `tuple[(NAType & ndarray[tuple[object, ...], dtype[object]]) | ndarray[tuple[Any, ...], dtype[Any]] | Unknown, Any | ndarray[tuple[Any, ...], dtype[Any]]]` pandas/core/ops/mask_ops.py:194:32: error[no-matching-overload] No overload matches arguments +pandas/core/resample.py:265:9: error[invalid-method-override] Invalid override of method `pipe`: Definition is incompatible with `BaseGroupBy.pipe` pandas/core/resample.py:442:45: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `((...) -> Unknown) | str | list[((...) -> Unknown) | str] | MutableMapping[Hashable, ((...) -> Unknown) | str | list[((...) -> Unknown) | str]]`, found `Unknown | None` pandas/core/resample.py:2110:9: error[invalid-method-override] Invalid override of method `_upsample`: Definition is incompatible with `Resampler._upsample` pandas/core/resample.py:2242:9: error[invalid-method-override] Invalid override of method `_upsample`: Definition is incompatible with `Resampler._upsample` @@ -712,15 +715,14 @@ pandas/core/strings/object_array.py:115:26: error[no-matching-overload] No overl pandas/core/tools/datetimes.py:387:27: warning[possibly-missing-attribute] Attribute `_dt_tz_convert` may be missing on object of type `(Unknown & ~Top[list[Unknown]] & ~tuple[object, ...] & ~NumpyExtensionArray & ~Index) | (ndarray[tuple[Any, ...], dtype[Any]] & ~Index)` pandas/core/tools/datetimes.py:389:27: warning[possibly-missing-attribute] Attribute `_dt_tz_localize` may be missing on object of type `(Unknown & ~Top[list[Unknown]] & ~tuple[object, ...] & ~NumpyExtensionArray & ~Index) | (ndarray[tuple[Any, ...], dtype[Any]] & ~Index)` pandas/core/tools/datetimes.py:393:35: error[invalid-argument-type] Argument to function `is_supported_dtype` is incorrect: Expected `dtype[Any]`, found `(Any & ~DatetimeTZDtype) | None` -pandas/core/tools/datetimes.py:452:41: error[invalid-argument-type] Argument to bound method `_simple_new` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[datetime64[date | int | None]]]`, found `ndarray[tuple[Any, ...], str]` pandas/core/tools/datetimes.py:1062:22: error[invalid-assignment] Object of type `bool` is not assignable to `Timestamp | NaTType | Series | Index` pandas/core/tools/numeric.py:225:16: warning[possibly-missing-attribute] Attribute `isna` may be missing on object of type `(Unknown & ~BaseMaskedArray) | ndarray[tuple[Any, ...], dtype[Any]]` pandas/core/tools/numeric.py:226:18: warning[possibly-missing-attribute] Attribute `dropna` may be missing on object of type `(Unknown & ~BaseMaskedArray) | ndarray[tuple[Any, ...], dtype[Any]]` -pandas/core/util/hashing.py:314:16: error[no-matching-overload] No overload of bound method `astype` matches arguments pandas/core/util/numba_.py:79:8: warning[possibly-missing-attribute] Submodule `extending` may not be available as an attribute on module `numba` pandas/core/util/numba_.py:82:22: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__name__` pandas/core/util/numba_.py:89:22: warning[possibly-missing-attribute] Submodule `extending` may not be available as an attribute on module `numba` pandas/core/window/ewm.py:913:38: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `BaseGrouper`, found `Unknown | None` +pandas/core/window/expanding.py:336:9: error[invalid-method-override] Invalid override of method `pipe`: Definition is incompatible with `RollingAndExpandingMixin.pipe` pandas/core/window/numba_.py:67:18: error[not-iterable] Object of type `prange` is not iterable pandas/core/window/numba_.py:131:18: error[not-iterable] Object of type `prange` is not iterable pandas/core/window/numba_.py:229:18: error[not-iterable] Object of type `prange` is not iterable @@ -733,6 +735,7 @@ pandas/core/window/rolling.py:1139:43: error[unsupported-operator] Operator `<` pandas/core/window/rolling.py:1288:45: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `((...) -> Unknown) | str | list[((...) -> Unknown) | str] | MutableMapping[Hashable, ((...) -> Unknown) | str | list[((...) -> Unknown) | str]]`, found `Unknown | None` pandas/core/window/rolling.py:1291:22: error[call-non-callable] Object of type `None` is not callable pandas/core/window/rolling.py:2018:45: error[unsupported-operator] Operator `<` is not supported between objects of type `(Unknown & ~BaseIndexer) | None` and `Literal[0]` +pandas/core/window/rolling.py:2263:9: error[invalid-method-override] Invalid override of method `pipe`: Definition is incompatible with `RollingAndExpandingMixin.pipe` pandas/core/window/rolling.py:3494:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `int | BaseIndexer`, found `(Unknown & BaseIndexer) | int | (Unknown & ~BaseIndexer) | None` pandas/io/clipboard/__init__.py:121:18: error[unresolved-reference] Name `Foundation` used when not defined pandas/io/clipboard/__init__.py:122:45: error[unresolved-reference] Name `Foundation` used when not defined @@ -795,6 +798,7 @@ pandas/io/excel/_base.py:846:20: error[unsupported-operator] Operator `>` is not pandas/io/excel/_base.py:852:17: error[invalid-assignment] Invalid subscript assignment with key of type `object` and value of type `list[Hashable]` on object of type `list[Unknown]` pandas/io/excel/_base.py:852:57: error[invalid-argument-type] Method `__getitem__` of type `Overload[(i: SupportsIndex, /) -> Unknown, (s: slice[Any, Any, Any], /) -> list[Unknown]]` cannot be called with key of type `object` on object of type `list[Unknown]` pandas/io/excel/_base.py:855:54: error[invalid-argument-type] Method `__getitem__` of type `Overload[(i: SupportsIndex, /) -> Unknown, (s: slice[Any, Any, Any], /) -> list[Unknown]]` cannot be called with key of type `object` on object of type `list[Unknown]` +pandas/io/excel/_base.py:1174:16: error[invalid-return-type] Return type does not match returned value: expected `Self@__new__`, found `@Todo | ExcelWriter[Unknown]` pandas/io/excel/_base.py:1366:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int | float | str | date, str | None]`, found `tuple[Unknown | int | float | Decimal | str, None | Unknown | str]` pandas/io/excel/_calamine.py:100:9: error[invalid-method-override] Invalid override of method `get_sheet_data`: Definition is incompatible with `BaseExcelReader.get_sheet_data` pandas/io/excel/_odfreader.py:102:9: error[invalid-method-override] Invalid override of method `get_sheet_data`: Definition is incompatible with `BaseExcelReader.get_sheet_data` @@ -898,7 +902,7 @@ pandas/io/pytables.py:2645:72: error[invalid-argument-type] Argument to bound me pandas/io/pytables.py:2700:12: warning[possibly-missing-attribute] Attribute `startswith` may be missing on object of type `(Unknown & ~None) | ExtensionDtype | str | ... omitted 3 union elements` pandas/io/pytables.py:2702:48: error[invalid-argument-type] Argument to function `_set_tz` is incorrect: Expected `str`, found `(Unknown & ~None) | ExtensionDtype | str | ... omitted 3 union elements` pandas/io/pytables.py:2742:29: error[no-matching-overload] No overload of bound method `astype` matches arguments -pandas/io/pytables.py:2749:17: error[invalid-argument-type] Argument to function `_unconvert_string_array` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `DatetimeArray | ndarray[tuple[Any, ...], dtype[Any]] | Unknown | ndarray[tuple[Any, ...], Unknown]` +pandas/io/pytables.py:2749:17: error[invalid-argument-type] Argument to function `_unconvert_string_array` is incorrect: Expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `DatetimeArray | ndarray[tuple[Any, ...], dtype[Any]] | Categorical | @Todo | ndarray[tuple[Any, ...], Unknown]` pandas/io/pytables.py:2841:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int]`, found `tuple[int, ...]` pandas/io/pytables.py:3118:35: error[invalid-argument-type] Argument to bound method `write_array` is incorrect: Expected `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]] | Index | Series`, found `Unknown | None` pandas/io/pytables.py:3146:41: error[invalid-argument-type] Argument to bound method `write_array` is incorrect: Expected `ExtensionArray | ndarray[tuple[Any, ...], dtype[Any]] | Index | Series`, found `Unknown | None` @@ -958,34 +962,6 @@ pandas/plotting/_matplotlib/converter.py:182:21: warning[possibly-missing-attrib pandas/plotting/_matplotlib/converter.py:227:9: error[invalid-method-override] Invalid override of method `convert`: Definition is incompatible with `DateConverter.convert` pandas/plotting/_matplotlib/converter.py:236:16: error[no-matching-overload] No overload of function `to_offset` matches arguments pandas/plotting/_matplotlib/converter.py:291:9: error[invalid-method-override] Invalid override of method `convert`: Definition is incompatible with `DateConverter.convert` -pandas/plotting/_matplotlib/converter.py:784:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["val"]` and value of type `ndarray[tuple[int], dtype[signedinteger[Any]]]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:785:14: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["val"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:786:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["fmt"]` and value of type `Literal[""]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:788:16: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["maj"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:789:16: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["fmt"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:793:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["min"]` and value of type `Literal[True]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:810:9: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["fmt"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:811:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["min"]` and value of type `Literal[True]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:818:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["min"]` and value of type `Literal[True]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:827:9: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["min"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:837:9: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["min"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:841:12: error[invalid-return-type] Return type does not match returned value: expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:854:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["val"]` and value of type `ndarray[tuple[int], dtype[signedinteger[Any]]]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:855:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["fmt"]` and value of type `Literal[""]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:856:14: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["val"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:857:16: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["maj"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:858:16: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["fmt"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:863:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["min"]` and value of type `Literal[True]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:876:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["min"]` and value of type `Literal[True]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:886:9: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["min"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:889:12: error[invalid-return-type] Return type does not match returned value: expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:901:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["val"]` and value of type `ndarray[tuple[int], dtype[signedinteger[Any]]]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:902:5: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["fmt"]` and value of type `Literal[""]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:903:14: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["val"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:908:5: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["maj"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:909:5: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["min"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:910:5: error[invalid-argument-type] Method `__getitem__` of type `Overload[(key: ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]] | tuple[ndarray[tuple[Any, ...], dtype[integer[Any] | bool[bool]]], ...], /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: SupportsIndex | tuple[SupportsIndex, ...], /) -> Any, (key: SupportsIndex | slice[Any, Any, Any] | EllipsisType | ... omitted 5 union elements, /) -> ndarray[tuple[Any, ...], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]], (key: str, /) -> ndarray[tuple[int], dtype[Any]], (key: list[str], /) -> ndarray[tuple[int], dtype[void]]]` cannot be called with key of type `Literal["fmt"]` on object of type `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` -pandas/plotting/_matplotlib/converter.py:912:12: error[invalid-return-type] Return type does not match returned value: expected `ndarray[tuple[Any, ...], dtype[Any]]`, found `ndarray[tuple[int], list[Unknown | tuple[str, ] | tuple[str, ] | tuple[str, str]]]` pandas/plotting/_matplotlib/converter.py:932:30: warning[possibly-missing-attribute] Submodule `ticker` may not be available as an attribute on module `matplotlib` pandas/plotting/_matplotlib/converter.py:1013:16: warning[possibly-missing-attribute] Submodule `transforms` may not be available as an attribute on module `matplotlib` pandas/plotting/_matplotlib/converter.py:1021:32: warning[possibly-missing-attribute] Submodule `ticker` may not be available as an attribute on module `matplotlib` @@ -1028,4 +1004,4 @@ pandas/util/_exceptions.py:45:15: error[no-matching-overload] No overload of fun pandas/util/_print_versions.py:29:14: error[unresolved-import] Cannot resolve imported module `pandas._version_meson` pandas/util/_validators.py:388:33: error[invalid-argument-type] Argument to function `validate_bool_kwarg` is incorrect: Argument type `object` does not satisfy constraints (`bool`, `int`, `None`) of type variable `BoolishNoneT` typings/numba.pyi:24:21: error[unresolved-attribute] Module `numba` has no member `compiler` -Found 1030 diagnostics +Found 1006 diagnostics diff --git a/scripts/ty_benchmark/snapshots/prefect_Pyrefly.txt b/scripts/ty_benchmark/snapshots/prefect_Pyrefly.txt index 2ce82c21ed..04db558ce1 100644 --- a/scripts/ty_benchmark/snapshots/prefect_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/prefect_Pyrefly.txt @@ -1,5 +1,7 @@ ERROR src/prefect/concurrency/_leases.py:116:10-28: Cannot use `AsyncCancelScope` as a context manager [bad-context-manager] ERROR src/prefect/concurrency/_leases.py:116:10-28: Cannot use `AsyncCancelScope` as a context manager [bad-context-manager] +ERROR src/prefect/concurrency/v1/sync.py:58:74-81: Unexpected keyword argument `_sync` in function `prefect.concurrency.v1._asyncio.acquire_concurrency_slots` [unexpected-keyword] +ERROR src/prefect/concurrency/v1/sync.py:70:67-74: Unexpected keyword argument `_sync` in function `prefect.concurrency.v1._asyncio.release_concurrency_slots` [unexpected-keyword] ERROR src/prefect/events/actions.py:27:5-9: Class member `DoNothing.type` overrides parent class `Action` in an inconsistent manner [bad-override] ERROR src/prefect/events/actions.py:63:5-9: Class member `RunDeployment.type` overrides parent class `DeploymentAction` in an inconsistent manner [bad-override] ERROR src/prefect/events/actions.py:91:5-9: Class member `PauseDeployment.type` overrides parent class `DeploymentAction` in an inconsistent manner [bad-override] @@ -110,6 +112,7 @@ ERROR src/prefect/server/models/deployments.py:1146:34-45: Argument `datetime` i ERROR src/prefect/server/models/deployments.py:1192:24-51: Cannot use `PrefectServerEventsClient` as a context manager [bad-context-manager] ERROR src/prefect/server/models/deployments.py:1199:38-48: Argument `datetime` is not assignable to parameter `occurred` with type `DateTime` in function `prefect.server.models.events.deployment_status_event` [bad-argument-type] ERROR src/prefect/server/models/events.py:23:30-75: Could not import `PREFECT_API_EVENTS_RELATED_RESOURCE_CACHE_TTL` from `prefect.settings` [missing-module-attribute] +ERROR src/prefect/server/models/events.py:82:12-30: Argument `UUID | None` is not assignable to parameter `id` with type `UUID | str` in function `prefect.server.events.schemas.events.Event.__init__` [bad-argument-type] ERROR src/prefect/server/models/flow_run_input.py:91:12-27: Object of class `Result` has no attribute `rowcount` [missing-attribute] ERROR src/prefect/server/models/flow_run_states.py:79:12-27: Object of class `Result` has no attribute `rowcount` [missing-attribute] ERROR src/prefect/server/models/flow_runs.py:47:5-45: Could not import `PREFECT_API_MAX_FLOW_RUN_GRAPH_ARTIFACTS` from `prefect.settings` [missing-module-attribute] @@ -154,9 +157,9 @@ ERROR src/prefect/server/models/workers.py:328:26-42: Argument `datetime | None` ERROR src/prefect/server/models/workers.py:329:25-40: Argument `datetime | None` is not assignable to parameter `scheduled_after` with type `DateTime | None` in function `prefect.server.database.query_components.BaseQueryComponents.get_scheduled_flow_runs_from_work_pool` [bad-argument-type] ERROR src/prefect/server/models/workers.py:626:15-30: Object of class `Result` has no attribute `rowcount` [missing-attribute] ERROR src/prefect/server/models/workers.py:672:12-18: Module `sqlalchemy.exc` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR src/prefect/server/models/workers.py:755:55-81: Cannot set item in `dict[str, WorkerStatus | datetime]` [unsupported-operation] +ERROR src/prefect/server/models/workers.py:755:55-81: `int` is not assignable to TypedDict key `heartbeat_interval_seconds` with type `WorkerStatus | datetime` [bad-typed-dict-key] ERROR src/prefect/server/models/workers.py:770:12-27: Object of class `Result` has no attribute `rowcount` [missing-attribute] ERROR src/prefect/server/models/workers.py:799:12-27: Object of class `Result` has no attribute `rowcount` [missing-attribute] ERROR src/prefect/server/models/workers.py:811:16-43: Cannot use `PrefectServerEventsClient` as a context manager [bad-context-manager] INFO Checking project configured at `/pyrefly.toml` - INFO 159 errors (12 suppressed) + INFO 162 errors (12 suppressed) diff --git a/scripts/ty_benchmark/snapshots/prefect_ty.txt b/scripts/ty_benchmark/snapshots/prefect_ty.txt index f61cddca96..cc2cdaf356 100644 --- a/scripts/ty_benchmark/snapshots/prefect_ty.txt +++ b/scripts/ty_benchmark/snapshots/prefect_ty.txt @@ -29,6 +29,7 @@ src/prefect/events/utilities.py:96:27: error[invalid-argument-type] Argument is src/prefect/events/worker.py:74:9: error[invalid-method-override] Invalid override of method `_prepare_item`: Definition is incompatible with `QueueService._prepare_item` src/prefect/events/worker.py:78:15: error[invalid-method-override] Invalid override of method `_handle`: Definition is incompatible with `QueueService._handle` src/prefect/events/worker.py:100:9: error[invalid-method-override] Invalid override of method `instance`: Definition is incompatible with `_QueueServiceBase.instance` +src/prefect/events/worker.py:130:16: error[invalid-return-type] Return type does not match returned value: expected `Self@instance`, found `EventsWorker` src/prefect/input/actions.py:46:49: warning[deprecated] The function `json` is deprecated: The `json` method is deprecated; use `model_dump_json` instead. src/prefect/server/models/artifacts.py:449:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/artifacts.py:449:39: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` @@ -77,6 +78,8 @@ src/prefect/server/models/flow_runs.py:251:26: error[invalid-type-form] Variable src/prefect/server/models/flow_runs.py:252:26: error[invalid-type-form] Variable of type `type[TaskRun]` is not allowed in a type expression src/prefect/server/models/flow_runs.py:322:41: error[invalid-argument-type] Argument to function `load_only` is incorrect: Expected `Literal["*"] | QueryableAttribute[Any]`, found `str` src/prefect/server/models/flow_runs.py:504:12: error[unresolved-attribute] Object of type `Result[Any]` has no attribute `rowcount` +src/prefect/server/models/flow_runs.py:582:15: error[missing-argument] No argument provided for required parameter `db` +src/prefect/server/models/flow_runs.py:582:15: error[missing-argument] No argument provided for required parameter `db` src/prefect/server/models/flow_runs.py:685:19: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/flows.py:83:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/flows.py:290:12: error[unresolved-attribute] Object of type `Result[Any]` has no attribute `rowcount` @@ -85,6 +88,8 @@ src/prefect/server/models/saved_searches.py:146:12: error[unresolved-attribute] src/prefect/server/models/task_run_states.py:74:12: error[unresolved-attribute] Object of type `Result[Any]` has no attribute `rowcount` src/prefect/server/models/task_runs.py:176:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/task_runs.py:462:12: error[unresolved-attribute] Object of type `Result[Any]` has no attribute `rowcount` +src/prefect/server/models/task_runs.py:535:15: error[missing-argument] No argument provided for required parameter `db` +src/prefect/server/models/task_runs.py:535:15: error[missing-argument] No argument provided for required parameter `db` src/prefect/server/models/task_workers.py:71:13: error[invalid-argument-type] Argument is incorrect: Expected `DateTime`, found `datetime` src/prefect/server/models/variables.py:123:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/variables.py:140:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` @@ -133,4 +138,4 @@ src/prefect/server/models/workers.py:672:12: warning[possibly-missing-attribute] src/prefect/server/models/workers.py:755:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["heartbeat_interval_seconds"]` and value of type `int` on object of type `dict[str, datetime | WorkerStatus]` src/prefect/server/models/workers.py:770:12: error[unresolved-attribute] Object of type `Result[Unknown]` has no attribute `rowcount` src/prefect/server/models/workers.py:799:12: error[unresolved-attribute] Object of type `Result[Any]` has no attribute `rowcount` -Found 135 diagnostics +Found 140 diagnostics diff --git a/scripts/ty_benchmark/snapshots/pytorch_Pyrefly.txt b/scripts/ty_benchmark/snapshots/pytorch_Pyrefly.txt index 68aa42e827..1372f42310 100644 --- a/scripts/ty_benchmark/snapshots/pytorch_Pyrefly.txt +++ b/scripts/ty_benchmark/snapshots/pytorch_Pyrefly.txt @@ -1,3 +1,16 @@ +ERROR torch/__init__.py:67:5-17: Name `BoolTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:69:5-17: Name `ByteTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:71:5-17: Name `CharTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:73:5-19: Name `DoubleTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:75:5-18: Name `FloatTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:78:5-16: Name `IntTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:80:5-17: Name `LongTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:82:5-18: Name `ShortTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:91:5-12: Name `chunk` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:110:5-13: Name `matmul` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:112:5-11: Name `rand` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:113:5-12: Name `randn` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/__init__.py:124:5-12: Name `stack` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/__init__.py:291:5-51: Could not find import of `torch.version` [missing-import] ERROR torch/__init__.py:1018:12-24: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/__init__.py:1025:26-40: Could not import `_initExtension` from `torch._C` [missing-module-attribute] @@ -112,6 +125,7 @@ ERROR torch/_VF.py:25:19-46: No attribute `_VariableFunctions` in module `torch. ERROR torch/__config__.py:9:12-33: No attribute `_show_config` in module `torch._C` [missing-attribute] ERROR torch/__config__.py:17:12-31: No attribute `_cxx_flags` in module `torch._C` [missing-attribute] ERROR torch/__config__.py:22:12-35: No attribute `_parallel_info` in module `torch._C` [missing-attribute] +ERROR torch/_awaits/__init__.py:7:12-19: Name `Await` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/_awaits/__init__.py:14:14-29: No attribute `_Await` in module `torch._C` [missing-attribute] ERROR torch/_classes.py:12:9-20: Class member `_ClassNamespace.__getattr__` overrides parent class `ModuleType` in an inconsistent manner [bad-param-name-override] ERROR torch/_classes.py:13:17-58: No attribute `_get_custom_class_python_wrapper` in module `torch._C` [missing-attribute] @@ -565,7 +579,6 @@ ERROR torch/_dynamo/aot_compile.py:227:13-29: Module `torch._functorch` exists, ERROR torch/_dynamo/aot_compile.py:227:13-36: Module `torch._functorch.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/aot_compile_types.py:49:14-30: Module `torch._functorch` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/aot_compile_types.py:49:14-37: Module `torch._functorch.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_dynamo/backends/common.py:73:20-22: Returned type `GraphModule` is not assignable to declared return type `(...) -> Any` [bad-return] ERROR torch/_dynamo/backends/common.py:166:58-70: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_dynamo/backends/common.py:170:12-24: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_dynamo/backends/common.py:173:57-68: No attribute `dtype` in module `torch` [missing-attribute] @@ -646,10 +659,6 @@ ERROR torch/_dynamo/convert_frame.py:345:21-65: No attribute `_unset_default_mob ERROR torch/_dynamo/convert_frame.py:347:26-55: No attribute `DisableTorchFunction` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/convert_frame.py:349:17-52: No attribute `_set_fp32_precision_setter` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/convert_frame.py:667:9-671:43: `FrameType | None` is not assignable to `FrameType` (caused by inconsistent types when breaking cycles) [bad-assignment] -ERROR torch/_dynamo/convert_frame.py:1034:23-69: `((...) -> Any) | GraphModule` is not assignable to variable `compiled_fn` with type `((...) -> Any) | None` [bad-assignment] -ERROR torch/_dynamo/convert_frame.py:1035:57-68: Argument `((...) -> Any) | None` is not assignable to parameter `compiled_fn` with type `(...) -> Any` in function `GraphRuntimeEnv.forward_callable` [bad-argument-type] -ERROR torch/_dynamo/convert_frame.py:1206:25-43: Argument `(gm: GraphModule, example_inputs: list[Tensor]) -> GraphModule` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `compile_frame` [bad-argument-type] -ERROR torch/_dynamo/convert_frame.py:1870:13-20: Argument `WrapBackendDebug` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `convert_frame` [bad-argument-type] ERROR torch/_dynamo/create_parameter_op.py:43:35-46: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_dynamo/create_parameter_op.py:43:56-68: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_dynamo/create_parameter_op.py:47:9-20: No attribute `empty` in module `torch` [missing-attribute] @@ -712,12 +721,7 @@ ERROR torch/_dynamo/device_interface.py:572:24-36: No attribute `device` in modu ERROR torch/_dynamo/device_interface.py:574:27-39: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_dynamo/device_interface.py:579:49-61: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_dynamo/device_interface.py:580:27-39: No attribute `device` in module `torch` [missing-attribute] -ERROR torch/_dynamo/eval_frame.py:210:49-81: Argument `WrapBackendDebug` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `_create_wrapped_callback` [bad-argument-type] -ERROR torch/_dynamo/eval_frame.py:316:49-61: Argument `WrapBackendDebug` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `_create_wrapped_callback` [bad-argument-type] ERROR torch/_dynamo/eval_frame.py:357:12-28: Module `torch._C._dynamo` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_dynamo/eval_frame.py:401:39-44: Runtime checkable protocol `Sized` has an unsafe overlap with type `Module` [invalid-argument] -ERROR torch/_dynamo/eval_frame.py:410:44-67: Argument `BoundMethod[Module, (...) -> Any]` is not assignable to parameter `fn` with type `(...) -> Any` in function `DisableContext.__call__` [bad-argument-type] -ERROR torch/_dynamo/eval_frame.py:421:71-85: Argument `Module` is not assignable to parameter `fn` with type `(ParamSpec(@_)) -> @_` in function `torch._dynamo.external_utils.wrap_inline` [bad-argument-type] ERROR torch/_dynamo/eval_frame.py:527:9-20: Class member `OptimizedModule.__setattr__` overrides parent class `Module` in an inconsistent manner [bad-param-name-override] ERROR torch/_dynamo/eval_frame.py:868:26-46: No attribute `_is_tracing` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/eval_frame.py:876:39-52: Module `torch._guards` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -725,18 +729,13 @@ ERROR torch/_dynamo/eval_frame.py:914:21-40: Module `torch._C._functorch` exists ERROR torch/_dynamo/eval_frame.py:940:21-40: Module `torch._C._functorch` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/eval_frame.py:1057:23-54: Module `torch._dynamo.compiled_autograd` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/eval_frame.py:1429:5-33: No attribute `_log_api_usage_once` in module `torch._C` [missing-attribute] -ERROR torch/_dynamo/eval_frame.py:1464:13-20: Argument `WrapBackendDebug` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `torch._dynamo.convert_frame.convert_frame` [bad-argument-type] ERROR torch/_dynamo/eval_frame.py:1739:9-30: No attribute `ScriptObject` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/eval_frame.py:1954:9-37: No attribute `_log_api_usage_once` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/eval_frame.py:2228:22-40: Module `torch.fx.traceback` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_dynamo/eval_frame.py:2345:13-20: Argument `WrapBackendDebug` is not assignable to parameter `compiler_fn` with type `(GraphModule, list[Tensor]) -> CompiledFn` in function `torch._dynamo.convert_frame.convert_frame_assert` [bad-argument-type] ERROR torch/_dynamo/exc.py:388:35-43: Cannot index into `dict[type[AttributeError] | type[GeneratorExit] | type[IndexError] | type[KeyError] | type[LookupError] | type[NotImplementedError] | type[RuntimeError] | type[StopIteration] | type[TypeError], type[ObservedAttributeError] | type[ObservedGeneratorExit] | type[ObservedIndexError] | type[ObservedKeyError] | type[ObservedLookupError] | type[ObservedNotImplementedError] | type[ObservedRuntimeError] | type[ObservedTypeError] | type[ObservedUserStopIteration]]` [bad-index] ERROR torch/_dynamo/functional_export.py:348:9-17: Class member `DynamoGraphTransformer.run_node` overrides parent class `Transformer` in an inconsistent manner [bad-param-name-override] ERROR torch/_dynamo/functional_export.py:374:70-377:18: Cannot index into `Module` [bad-index] ERROR torch/_dynamo/functional_export.py:381:55-384:18: Cannot index into `Module` [bad-index] -ERROR torch/_dynamo/functional_export.py:521:34-48: `tuple[Unknown, ...]` is not assignable to attribute `gm_inputs` with type `None` [bad-assignment] -ERROR torch/_dynamo/functional_export.py:535:9-20: Argument `pytreeify.InShuffle` is not assignable to parameter `f` with type `(...) -> Unknown` in function `torch.fx.experimental.proxy_tensor.make_fx` [bad-argument-type] -ERROR torch/_dynamo/functional_export.py:580:13-24: Argument `pytreeify.OutShuffle` is not assignable to parameter `f` with type `(...) -> Unknown` in function `torch.fx.experimental.proxy_tensor.make_fx` [bad-argument-type] ERROR torch/_dynamo/functional_export.py:800:43-63: Module `torch._dynamo.source` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/graph_region_tracker.py:55:5-16: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_dynamo/graph_region_tracker.py:155:9-30: No attribute `is_grad_enabled` in module `torch` [missing-attribute] @@ -880,13 +879,10 @@ ERROR torch/_dynamo/repro/after_aot.py:42:5-63: Could not find import of `triton ERROR torch/_dynamo/repro/after_aot.py:43:5-47: Could not find import of `triton.runtime.jit` [missing-import] ERROR torch/_dynamo/repro/after_aot.py:507:25-46: Module `torch.fx.experimental` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/repro/after_aot.py:507:25-62: Module `torch.fx.experimental._backward_state` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_dynamo/repro/after_aot.py:789:19-22: Argument `Module` is not assignable to parameter `f` with type `(...) -> Unknown` in function `torch.fx.experimental.proxy_tensor.make_fx` [bad-argument-type] ERROR torch/_dynamo/repro/after_aot.py:792:5-27: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/repro/after_aot.py:883:14-40: Module `torch.utils._content_store` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/repro/after_aot.py:886:14-40: Module `torch.utils._content_store` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/repro/after_dynamo.py:231:42-67: No attribute `is_autocast_enabled` in module `torch` [missing-attribute] -ERROR torch/_dynamo/repro/after_dynamo.py:474:63-66: Argument `Module` is not assignable to parameter `fn` with type `(...) -> Any` in function `torch._dynamo.eval_frame._NullDecorator.__call__` [bad-argument-type] -ERROR torch/_dynamo/repro/after_dynamo.py:481:55-58: Argument `Module` is not assignable to parameter `fn` with type `(...) -> Any` in function `torch._dynamo.eval_frame._NullDecorator.__call__` [bad-argument-type] ERROR torch/_dynamo/repro/aoti.py:305:5-27: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/side_effects.py:724:26-50: Module `torch._dynamo.variables.torch_function` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/side_effects.py:958:22-46: Module `torch._dynamo.variables.torch_function` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -1128,7 +1124,7 @@ ERROR torch/_dynamo/variables/builder.py:2791:14-51: No attribute `DisableTorchF ERROR torch/_dynamo/variables/builder.py:2864:17-40: Module `torch._dynamo.variables` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/variables/builder.py:2865:17-40: Module `torch._dynamo.variables` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/variables/builder.py:2910:22-59: No attribute `DisableTorchFunctionSubclass` in module `torch._C` [missing-attribute] -ERROR torch/_dynamo/variables/builder.py:2924:68-76: Unpacked keyword argument `bool` is not assignable to parameter `source` with type `Source | None` in function `wrap_to_fake_tensor_and_record` [bad-argument-type] +ERROR torch/_dynamo/variables/builder.py:2924:52-77: Missing argument `source` in function `wrap_to_fake_tensor_and_record` [missing-argument] ERROR torch/_dynamo/variables/builder.py:3001:52-70: No attribute `Generator` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/variables/builder.py:3006:30-56: No attribute `_DisableFuncTorch` in module `torch._C` [missing-attribute] ERROR torch/_dynamo/variables/builder.py:3010:32-42: No attribute `Size` in module `torch` [missing-attribute] @@ -1277,6 +1273,7 @@ ERROR torch/_dynamo/variables/ctx_manager.py:951:17-35: Module `torch._C._autogr ERROR torch/_dynamo/variables/ctx_manager.py:955:13-31: Module `torch._C._autograd` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/variables/ctx_manager.py:959:34-52: Module `torch._C._autograd` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/variables/ctx_manager.py:961:13-31: Module `torch._C._autograd` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] + WARN torch/_dynamo/variables/ctx_manager.py:996:41-64: Identity comparison between an instance of `autocast` and class `autocast` is always False [unnecessary-comparison] ERROR torch/_dynamo/variables/ctx_manager.py:1091:9-20: Class member `ProfilerContextVariable.reconstruct` overrides parent class `ContextWrappingVariable` in an inconsistent manner [bad-param-name-override] ERROR torch/_dynamo/variables/ctx_manager.py:1367:29-47: Module `torch.fx.traceback` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_dynamo/variables/ctx_manager.py:1368:29-47: Module `torch.fx.traceback` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -1449,6 +1446,7 @@ ERROR torch/_dynamo/variables/misc.py:594:60-71: Argument `Source | None` is not ERROR torch/_dynamo/variables/misc.py:597:9-22: Class member `ComptimeVariable.call_function` overrides parent class `VariableTracker` in an inconsistent manner [bad-override] ERROR torch/_dynamo/variables/misc.py:629:23-40: Object of class `VariableTracker` has no attribute `items` [missing-attribute] ERROR torch/_dynamo/variables/misc.py:673:5-38: Object of class `FunctionType` has no attribute `_origin` [missing-attribute] + WARN torch/_dynamo/variables/misc.py:704:52-57: Identity comparison `True is False` is always False [unnecessary-comparison] ERROR torch/_dynamo/variables/misc.py:791:37-52: Object of class `Signature` has no attribute `_parameters` [missing-attribute] ERROR torch/_dynamo/variables/misc.py:819:32-43: Argument `Source | None` is not assignable to parameter `base` with type `Source` in function `torch._dynamo.source.AttrSource.__init__` [bad-argument-type] ERROR torch/_dynamo/variables/misc.py:864:25-865:44: Class `VariableTracker` has no class attribute `create_with_source` @@ -1477,7 +1475,6 @@ ERROR torch/_dynamo/variables/misc.py:2071:9-14: Class member `WeakRefVariable.b ERROR torch/_dynamo/variables/misc.py:2087:9-22: Class member `WeakRefVariable.call_function` overrides parent class `VariableTracker` in an inconsistent manner [bad-override] ERROR torch/_dynamo/variables/nn_module.py:210:57-68: Argument `Source | None` is not assignable to parameter `base` with type `Source` in function `torch._dynamo.source.GetItemSource.__init__` [bad-argument-type] ERROR torch/_dynamo/variables/nn_module.py:237:39-50: Argument `Source | None` is not assignable to parameter `base` with type `Source` in function `torch._dynamo.source.AttrSource.__init__` [bad-argument-type] -ERROR torch/_dynamo/variables/nn_module.py:319:63-72: Unpacked keyword argument `AttrSource` is not assignable to parameter `source_fn` with type `((...) -> Any) | None` in function `torch._dynamo.variables.functions.UserMethodVariable.__init__` [bad-argument-type] ERROR torch/_dynamo/variables/nn_module.py:383:45-51: `subobj` may be uninitialized [unbound-name] ERROR torch/_dynamo/variables/nn_module.py:383:68-74: Argument `AttrSource | Source | None` is not assignable to parameter `base` with type `Source` in function `torch._dynamo.source.NNModuleSource.__init__` [bad-argument-type] ERROR torch/_dynamo/variables/nn_module.py:395:23-29: `subobj` may be uninitialized [unbound-name] @@ -2229,8 +2226,6 @@ ERROR torch/_export/wrappers.py:306:13-53: No attribute `_dispatch_tls_local_exc ERROR torch/_export/wrappers.py:307:15-38: No attribute `DispatchKeySet` in module `torch._C` [missing-attribute] ERROR torch/_export/wrappers.py:307:39-59: No attribute `DispatchKey` in module `torch._C` [missing-attribute] ERROR torch/_export/wrappers.py:310:14-45: No attribute `_ForceDispatchKeyGuard` in module `torch._C` [missing-attribute] -ERROR torch/_functorch/_activation_checkpointing/graph_info_provider.py:256:9-68: Could not find import of `matplotlib` [missing-import] -ERROR torch/_functorch/_activation_checkpointing/knapsack.py:34:9-66: Could not find import of `scipy.optimize` [missing-import] ERROR torch/_functorch/_activation_checkpointing/knapsack.py:71:24-36: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/_functorch/_activation_checkpointing/knapsack.py:72:47-57: No attribute `long` in module `torch` [missing-attribute] ERROR torch/_functorch/_activation_checkpointing/knapsack.py:74:16-28: No attribute `tensor` in module `torch` [missing-attribute] @@ -2306,7 +2301,6 @@ ERROR torch/_functorch/_aot_autograd/graph_capture_wrappers.py:1075:37-57: No at ERROR torch/_functorch/_aot_autograd/graph_capture_wrappers.py:1092:38-66: Module `torch.utils._python_dispatch` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_functorch/_aot_autograd/graph_capture_wrappers.py:1093:17-47: No attribute `_TorchDispatchModeKey` in module `torch._C` [missing-attribute] ERROR torch/_functorch/_aot_autograd/graph_capture_wrappers.py:1140:36-48: No attribute `tensor` in module `torch` [missing-attribute] -ERROR torch/_functorch/_aot_autograd/graph_compile.py:276:19-24: Argument `GraphModule` is not assignable to parameter `compiled_fn` with type `(...) -> Unknown` in function `torch._functorch._aot_autograd.runtime_wrappers.post_compile` [bad-argument-type] ERROR torch/_functorch/_aot_autograd/graph_compile.py:368:32-48: Module `torch._functorch` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_functorch/_aot_autograd/graph_compile.py:368:32-55: Module `torch._functorch.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_functorch/_aot_autograd/graph_compile.py:510:19-52: No attribute `_is_any_autocast_enabled` in module `torch._C` [missing-attribute] @@ -2334,7 +2328,6 @@ ERROR torch/_functorch/_aot_autograd/graph_compile.py:1669:16-32: Module `torch. ERROR torch/_functorch/_aot_autograd/graph_compile.py:1669:16-39: Module `torch._functorch.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_functorch/_aot_autograd/graph_compile.py:1819:61-86: No attribute `_DisableAutocast` in module `torch._C` [missing-attribute] ERROR torch/_functorch/_aot_autograd/graph_compile.py:1943:16-47: Module `torch._dynamo.compiled_autograd` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_functorch/_aot_autograd/graph_compile.py:1952:17-26: Argument `GraphModule` is not assignable to parameter `bw_module` with type `(...) -> Unknown` in function `torch._functorch._aot_autograd.runtime_wrappers.AutogradLazyBackwardCompileInfo.__init__` [bad-argument-type] ERROR torch/_functorch/_aot_autograd/graph_compile.py:2069:19-52: No attribute `_is_any_autocast_enabled` in module `torch._C` [missing-attribute] ERROR torch/_functorch/_aot_autograd/graph_compile.py:2248:13-38: No attribute `_DisableAutocast` in module `torch._C` [missing-attribute] ERROR torch/_functorch/_aot_autograd/graph_compile.py:2249:16-49: No attribute `_is_any_autocast_enabled` in module `torch._C` [missing-attribute] @@ -2462,18 +2455,10 @@ ERROR torch/_functorch/compilers.py:48:29-60: No attribute `_jit_set_autocast_mo ERROR torch/_functorch/compilers.py:52:9-40: No attribute `_jit_set_autocast_mode` in module `torch._C` [missing-attribute] ERROR torch/_functorch/compilers.py:82:34-46: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_functorch/compilers.py:93:9-43: No attribute `_jit_pass_remove_mutation` in module `torch._C` [missing-attribute] -ERROR torch/_functorch/compilers.py:99:12-13: Returned type `ScriptModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] -ERROR torch/_functorch/compilers.py:122:12-16: Returned type `GraphModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] ERROR torch/_functorch/compilers.py:126:9-12: Class member `DebugInterpreter.run` overrides parent class `Interpreter` in an inconsistent manner [bad-override] ERROR torch/_functorch/compilers.py:127:44-55: Argument `Module` is not assignable to parameter `gm` with type `GraphModule` in function `torch.fx.experimental.symbolic_shapes.bind_symbols` [bad-argument-type] ERROR torch/_functorch/compilers.py:228:45-67: Argument `set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]]` is not assignable to parameter `aten_ops` with type `Sequence[OpOverloadPacket[Ellipsis, Any] | OperatorBase]` in function `torch._decomp.get_decompositions` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `fw_compiler` with type `(...) -> Unknown` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `bw_compiler` with type `((...) -> Unknown) | None` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `partition_fn` with type `(...) -> Unknown` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `decompositions` with type `dict[Unknown, Unknown] | None` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `num_params_buffers` with type `int` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `keep_inference_input_mutations` with type `bool` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] -ERROR torch/_functorch/compilers.py:273:33-41: Unpacked keyword argument `((joint_module: GraphModule, _joint_inputs: Unknown, compiler: str | Unknown = 'inductor', *, num_fwd_outputs: Unknown, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]] | Unknown` is not assignable to parameter `inference_compiler` with type `((...) -> Unknown) | None` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] +ERROR torch/_functorch/compilers.py:273:33-41: Argument `dict[OperatorBase, (...) -> Unknown] | set[OpOverload[Ellipsis, Any] | OpOverloadPacket[Ellipsis, Any]]` is not assignable to parameter `decompositions` with type `dict[Unknown, Unknown] | None` in function `torch._functorch.aot_autograd.aot_function` [bad-argument-type] ERROR torch/_functorch/compilers.py:298:5-29: Could not find import of `foo` [missing-import] ERROR torch/_functorch/compilers.py:319:30-41: No attribute `rand` in module `random` [missing-attribute] ERROR torch/_functorch/compilers.py:323:21-30: No attribute `int` in module `torch` [missing-attribute] @@ -2565,7 +2550,6 @@ ERROR torch/_functorch/partitioners.py:1456:26-38: Module `torch._prims` exists, ERROR torch/_functorch/partitioners.py:1477:21-33: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_functorch/partitioners.py:1484:18-40: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_functorch/partitioners.py:2072:12-17: Could not find import of `pydot` [missing-import] -ERROR torch/_functorch/partitioners.py:2558:16-40: Could not find import of `matplotlib.pyplot` [missing-import] ERROR torch/_functorch/partitioners.py:2662:34-46: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/_functorch/partitioners.py:2670:35-47: No attribute `argmin` in module `torch` [missing-attribute] ERROR torch/_functorch/predispatch.py:17:5-48: Could not import `_remove_batch_dim` from `torch._C._functorch` [missing-module-attribute] @@ -2600,7 +2584,6 @@ ERROR torch/_higher_order_ops/associative_scan.py:384:13-22: No attribute `cat` ERROR torch/_higher_order_ops/associative_scan.py:673:35-75: No attribute `_dispatch_tls_local_include_set` in module `torch._C` [missing-attribute] ERROR torch/_higher_order_ops/associative_scan.py:674:35-75: No attribute `_dispatch_tls_local_exclude_set` in module `torch._C` [missing-attribute] ERROR torch/_higher_order_ops/associative_scan.py:676:14-49: No attribute `_AutoDispatchBelowAutograd` in module `torch._C` [missing-attribute] -ERROR torch/_higher_order_ops/associative_scan.py:736:46-62: Argument `GraphModule` is not assignable to parameter `func` with type `(...) -> Unknown` in function `torch._functorch.apis.vmap` [bad-argument-type] ERROR torch/_higher_order_ops/associative_scan.py:742:32-47: No attribute `ones_like` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/associative_scan.py:756:29-39: No attribute `tril` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/associative_scan.py:757:21-31: No attribute `ones` in module `torch` [missing-attribute] @@ -2688,7 +2671,6 @@ ERROR torch/_higher_order_ops/flex_attention.py:454:48-57: No attribute `int` in ERROR torch/_higher_order_ops/flex_attention.py:516:73-86: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:517:74-87: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:561:28-47: No attribute `empty_strided` in module `torch` [missing-attribute] -ERROR torch/_higher_order_ops/flex_attention.py:625:16-38: Returned type `tuple[(...) -> Unknown, GraphModule]` is not assignable to declared return type `tuple[(...) -> Unknown, (...) -> Unknown]` [bad-return] ERROR torch/_higher_order_ops/flex_attention.py:658:14-49: No attribute `_AutoDispatchBelowAutograd` in module `torch._C` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:789:12-33: No attribute `is_grad_enabled` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:797:43-52: No attribute `int` in module `torch` [missing-attribute] @@ -2717,8 +2699,6 @@ ERROR torch/_higher_order_ops/flex_attention.py:1040:52-61: No attribute `int` i ERROR torch/_higher_order_ops/flex_attention.py:1118:10-31: Module `torch.fx.experimental` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_higher_order_ops/flex_attention.py:1118:10-44: Module `torch.fx.experimental.proxy_tensor` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_higher_order_ops/flex_attention.py:1142:10-45: Module `torch._subclasses.functional_tensor` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_higher_order_ops/flex_attention.py:1209:49-57: Argument `((...) -> Unknown) | GraphModule` is not assignable to parameter `inner_f` with type `(...) -> Unknown` in function `torch._subclasses.functional_tensor.BaseFunctionalizeAPI.functionalize` [bad-argument-type] -ERROR torch/_higher_order_ops/flex_attention.py:1210:52-63: Argument `GraphModule` is not assignable to parameter `inner_f` with type `(...) -> Unknown` in function `torch._subclasses.functional_tensor.BaseFunctionalizeAPI.functionalize` [bad-argument-type] ERROR torch/_higher_order_ops/flex_attention.py:1277:18-34: No attribute `empty_like` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:1281:13-29: No attribute `empty_like` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/flex_attention.py:1281:52-75: No attribute `contiguous_format` in module `torch` [missing-attribute] @@ -2767,7 +2747,6 @@ ERROR torch/_higher_order_ops/out_dtype.py:121:20-31: No attribute `dtype` in mo ERROR torch/_higher_order_ops/out_dtype.py:140:19-30: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/out_dtype.py:150:19-30: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/partitioner.py:318:27-43: No attribute `zeros_like` in module `torch` [missing-attribute] -ERROR torch/_higher_order_ops/partitioner.py:328:38-46: Argument `GraphModule` is not assignable to parameter `func` with type `(...) -> Unknown` in function `torch._functorch.eager_transforms.functionalize` [bad-argument-type] ERROR torch/_higher_order_ops/print.py:25:16-32: Method `__call__` inherited from class `HigherOrderOperator` has no implementation and cannot be accessed via `super()` [missing-attribute] ERROR torch/_higher_order_ops/print.py:28:64-84: No attribute `FunctionSchema` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/print.py:61:16-36: No attribute `DispatchKey` in module `torch._C` [missing-attribute] @@ -2959,8 +2938,6 @@ ERROR torch/_higher_order_ops/while_loop.py:783:20-31: No attribute `zeros` in m ERROR torch/_higher_order_ops/while_loop.py:783:42-53: No attribute `int64` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/while_loop.py:786:13-29: No attribute `zeros_like` in module `torch` [missing-attribute] ERROR torch/_higher_order_ops/while_loop.py:796:13-22: No attribute `cat` in module `torch` [missing-attribute] -ERROR torch/_higher_order_ops/while_loop.py:884:17-24: Argument `GraphModule` is not assignable to parameter `cond_fn` with type `(...) -> Unknown` in function `WhileLoopOp.__call__` [bad-argument-type] -ERROR torch/_higher_order_ops/while_loop.py:885:17-24: Argument `GraphModule` is not assignable to parameter `body_fn` with type `(...) -> Unknown` in function `WhileLoopOp.__call__` [bad-argument-type] ERROR torch/_higher_order_ops/wrap.py:9:22-33: Could not import `DispatchKey` from `torch._C` [missing-module-attribute] ERROR torch/_higher_order_ops/wrap.py:58:16-32: Method `__call__` inherited from class `HigherOrderOperator` has no implementation and cannot be accessed via `super()` [missing-attribute] ERROR torch/_higher_order_ops/wrap.py:88:20-41: No attribute `is_grad_enabled` in module `torch` [missing-attribute] @@ -4144,7 +4121,6 @@ ERROR torch/_inductor/codegen/halide.py:566:9-14: Class member `HalideOverrides. ERROR torch/_inductor/codegen/halide.py:594:25-36: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_inductor/codegen/halide.py:720:35-46: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_inductor/codegen/halide.py:811:42-43: Argument `Literal[1]` is not assignable to parameter `divisor` with type `Expr` in function `torch._inductor.codegen.simd.IterationRangesRoot.lookup` [bad-argument-type] -ERROR torch/_inductor/codegen/halide.py:832:17-860:51: `int` is not assignable to `int` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR torch/_inductor/codegen/halide.py:983:32-70: `list[tuple[list[Basic | Unknown], Expr | Unknown] | tuple[list[Symbol], Expr]]` is not assignable to variable `split_failed` with type `list[tuple[list[Symbol], Expr]]` [bad-assignment] ERROR torch/_inductor/codegen/halide.py:1133:22-35: No attribute `float16` in module `torch` [missing-attribute] ERROR torch/_inductor/codegen/halide.py:1133:37-51: No attribute `bfloat16` in module `torch` [missing-attribute] @@ -4363,6 +4339,7 @@ ERROR torch/_inductor/codegen/simd_kernel_features.py:357:46-52: Argument `list[ ERROR torch/_inductor/codegen/subgraph.py:97:44-56: Object of class `Expr` has no attribute `name` [missing-attribute] ERROR torch/_inductor/codegen/subgraph.py:98:56-68: Object of class `Expr` has no attribute `name` [missing-attribute] ERROR torch/_inductor/codegen/subgraph.py:373:31-42: No attribute `empty` in module `torch` [missing-attribute] +ERROR torch/_inductor/codegen/triton_combo_kernel.py:614:34-56: `list[Any]` is not assignable to TypedDict key `configs` with type `DeviceProperties | dict[str, str] | dict[@_, @_]` [bad-typed-dict-key] ERROR torch/_inductor/codegen/triton_split_scan.py:92:16-37: Could not find import of `triton.language` [missing-import] ERROR torch/_inductor/codegen/triton_split_scan.py:130:55-61: Argument `int` is not assignable to parameter `index` with type `Expr` in function `torch._inductor.codegen.simd.SIMDKernel.index_to_str` [bad-argument-type] ERROR torch/_inductor/codegen/triton_utils.py:39:25-44: No attribute `float8_e4m3fn` in module `torch` [missing-attribute] @@ -4458,7 +4435,6 @@ ERROR torch/_inductor/compile_fx.py:2150:30-42: No attribute `device` in module ERROR torch/_inductor/compile_fx.py:2296:19-32: Module `torch._guards` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/compile_fx.py:2421:5-26: Module `torch._inductor.debug` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/compile_fx.py:2426:17-38: Module `torch._inductor.debug` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_inductor/compile_fx.py:2470:16-22: Returned type `GraphModule` is not assignable to declared return type `((list[object]) -> Sequence[Tensor]) | Weights | list[str] | str` [bad-return] ERROR torch/_inductor/compile_fx.py:2633:9-27: Module `torch.fx.traceback` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/compile_fx.py:2636:9-30: Module `torch._inductor.debug` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/compile_fx.py:2681:36-57: No attribute `is_grad_enabled` in module `torch` [missing-attribute] @@ -4535,7 +4511,17 @@ ERROR torch/_inductor/cpu_vec_isa.py:345:61-74: No attribute `float16` in module ERROR torch/_inductor/cpu_vec_isa.py:358:25-36: No attribute `float` in module `torch` [missing-attribute] ERROR torch/_inductor/cpu_vec_isa.py:358:41-55: No attribute `bfloat16` in module `torch` [missing-attribute] ERROR torch/_inductor/cpu_vec_isa.py:358:61-74: No attribute `float16` in module `torch` [missing-attribute] -ERROR torch/_inductor/cpu_vec_isa.py:435:41-51: Cannot index into `dict[str, str]` [bad-index] +ERROR torch/_inductor/cpu_vec_isa.py:410:11-13: Missing argument `__hash__` in function `VecAMX.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:411:14-16: Missing argument `__hash__` in function `VecAVX512.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:412:12-14: Missing argument `__hash__` in function `VecAVX2.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:413:12-14: Missing argument `__hash__` in function `VecNEON.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:414:14-16: Missing argument `__hash__` in function `VecSVE256.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:435:41-51: Invalid key for TypedDict ``, got `None` [bad-typed-dict-key] +ERROR torch/_inductor/cpu_vec_isa.py:472:55-57: Missing argument `__hash__` in function `VecZVECTOR.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:475:31-33: Missing argument `__hash__` in function `VecVSX.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:478:38-40: Missing argument `__hash__` in function `VecSVE256.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:480:36-38: Missing argument `__hash__` in function `VecNEON.__init__` [missing-argument] +ERROR torch/_inductor/cpu_vec_isa.py:498:23-25: Missing argument `__hash__` in function `VecAVX2.__init__` [missing-argument] ERROR torch/_inductor/cudagraph_trees.py:104:9-61: Could not import `_cuda_CUDAAllocator_AllocatorState` from `torch._C` [missing-module-attribute] ERROR torch/_inductor/cudagraph_trees.py:105:9-36: Could not import `_set_cached_tensors_enabled` from `torch._C` [missing-module-attribute] ERROR torch/_inductor/cudagraph_trees.py:142:5-41: No attribute `_cuda_clearCublasWorkspaces` in module `torch._C` [missing-attribute] @@ -5031,7 +5017,6 @@ ERROR torch/_inductor/fx_passes/joint_graph.py:945:16-26: No attribute `amax` in ERROR torch/_inductor/fx_passes/memory_estimator.py:20:13-25: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_inductor/fx_passes/memory_estimator.py:147:41-63: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/fx_passes/memory_estimator.py:150:27-39: No attribute `device` in module `torch` [missing-attribute] -ERROR torch/_inductor/fx_passes/memory_estimator.py:205:9-209:76: `int` is not assignable to `int` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR torch/_inductor/fx_passes/memory_estimator.py:329:34-46: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_inductor/fx_passes/memory_estimator.py:388:34-56: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/fx_passes/micro_pipeline_tp.py:459:16-27: No attribute `dtype` in module `torch` [missing-attribute] @@ -6525,6 +6510,7 @@ ERROR torch/_inductor/mkldnn_lowerings.py:199:8-28: No attribute `_has_mkldnn` i ERROR torch/_inductor/mkldnn_lowerings.py:344:29-45: Argument `list[Expr | int]` is not assignable to parameter `sizes` with type `Sequence[Expr]` in function `torch._inductor.lowering.view` [bad-argument-type] ERROR torch/_inductor/mkldnn_lowerings.py:406:29-45: Argument `list[Expr | int]` is not assignable to parameter `sizes` with type `Sequence[Expr]` in function `torch._inductor.lowering.view` [bad-argument-type] ERROR torch/_inductor/mkldnn_lowerings.py:409:29-45: Argument `list[Expr | int]` is not assignable to parameter `sizes` with type `Sequence[Expr]` in function `torch._inductor.lowering.view` [bad-argument-type] +ERROR torch/_inductor/mkldnn_lowerings.py:430:47-87: `list[int]` is not assignable to TypedDict key `input_indices` with type `((buf: Unknown) -> Unknown) | bool` [bad-typed-dict-key] ERROR torch/_inductor/mkldnn_lowerings.py:557:17-29: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/_inductor/mkldnn_lowerings.py:557:45-58: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/_inductor/mkldnn_lowerings.py:561:17-29: No attribute `tensor` in module `torch` [missing-attribute] @@ -6663,11 +6649,9 @@ ERROR torch/_inductor/output_code.py:611:21-42: Module `torch._inductor.debug` e ERROR torch/_inductor/output_code.py:614:13-34: Module `torch._inductor.debug` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/output_code.py:805:13-40: Module `torch._inductor.cpp_builder` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/output_code.py:806:16-43: Module `torch._inductor.cpp_builder` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_inductor/output_code.py:827:37-53: `GraphModule` is not assignable to attribute `current_callable` with type `((...) -> Any) | None` [bad-assignment] ERROR torch/_inductor/package/package.py:129:22-36: Module `torch._C._aoti` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/package/package.py:135:14-28: Module `torch._C._aoti` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/pattern_matcher.py:298:17-36: Module `torch.utils._pytree` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] -ERROR torch/_inductor/pattern_matcher.py:309:40-61: Argument `GraphModule` is not assignable to parameter `fn` with type `ReplaceFn | SearchFn` in function `TraceFn.__call__` [bad-argument-type] ERROR torch/_inductor/pattern_matcher.py:1155:17-25: Class member `Replacer.run_node` overrides parent class `Interpreter` in an inconsistent manner [bad-param-name-override] ERROR torch/_inductor/pattern_matcher.py:1482:31-50: No attribute `empty_strided` in module `torch` [missing-attribute] ERROR torch/_inductor/pattern_matcher.py:1581:12-43: No attribute `is_inference_mode_enabled` in module `torch` [missing-attribute] @@ -6697,6 +6681,8 @@ ERROR torch/_inductor/runtime/autotune_cache.py:71:28-47: Module `torch.utils._t ERROR torch/_inductor/runtime/autotune_cache.py:374:13-77: Could not find import of `torch._inductor.fb.remote_cache` [missing-import] ERROR torch/_inductor/runtime/autotune_cache.py:514:12-37: Module `torch._inductor.codecache` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/runtime/autotune_cache.py:528:9-73: Could not find import of `torch._inductor.fb.remote_cache` [missing-import] +ERROR torch/_inductor/runtime/autotune_cache.py:577:45-58: Unexpected keyword argument `num_warps` in function `object.__init__` [unexpected-keyword] +ERROR torch/_inductor/runtime/autotune_cache.py:577:45-58: Unexpected keyword argument `num_stages` in function `object.__init__` [unexpected-keyword] ERROR torch/_inductor/runtime/benchmarking.py:65:8-30: Module `torch._inductor.config` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/runtime/benchmarking.py:106:64-76: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_inductor/runtime/benchmarking.py:107:35-47: No attribute `device` in module `torch` [missing-attribute] @@ -7119,6 +7105,8 @@ ERROR torch/_inductor/utils.py:3047:17-28: No attribute `dtype` in module `torch ERROR torch/_inductor/utils.py:3048:16-27: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_inductor/utils.py:3078:60-70: No attribute `bool` in module `torch` [missing-attribute] ERROR torch/_inductor/utils.py:3078:72-83: No attribute `int64` in module `torch` [missing-attribute] + WARN torch/_inductor/utils.py:3094:20-35: Identity comparison between an instance of `BaseSchedulerNode` and class `EnableReduction` is always False [unnecessary-comparison] + WARN torch/_inductor/utils.py:3096:22-38: Identity comparison between an instance of `BaseSchedulerNode` and class `DisableReduction` is always False [unnecessary-comparison] ERROR torch/_inductor/utils.py:3142:23-36: Module `torch._guards` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/utils.py:3159:10-23: Module `unittest.mock` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_inductor/utils.py:3224:13-33: No attribute `_foreach_copy_` in module `torch` [missing-attribute] @@ -7173,7 +7161,6 @@ ERROR torch/_jit_internal.py:1335:9-37: No attribute `_jit_set_emit_hooks` in mo ERROR torch/_jit_internal.py:1341:22-50: No attribute `_jit_get_emit_hooks` in module `torch._C` [missing-attribute] ERROR torch/_jit_internal.py:1342:9-37: No attribute `_jit_set_emit_hooks` in module `torch._C` [missing-attribute] ERROR torch/_jit_internal.py:1345:9-37: No attribute `_jit_set_emit_hooks` in module `torch._C` [missing-attribute] -ERROR torch/_lazy/closure.py:66:40-68:14: `Thread` is not assignable to attribute `_closure_event_loop` with type `None` [bad-assignment] ERROR torch/_lazy/extract_compiled_graph.py:106:28-40: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_lazy/extract_compiled_graph.py:107:20-32: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_lazy/extract_compiled_graph.py:112:29-41: No attribute `device` in module `torch` [missing-attribute] @@ -10144,6 +10131,7 @@ ERROR torch/_ops.py:1353:9-20: Class member `_OpNamespace.__getattr__` overrides ERROR torch/_ops.py:1391:26-53: No attribute `_jit_get_operation` in module `torch._C` [missing-attribute] ERROR torch/_ops.py:1395:9-28: Module `torch.jit._builtins` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/_prims/__init__.py:12:22-41: Could not import `_get_default_device` from `torch._C` [missing-module-attribute] +ERROR torch/_prims/__init__.py:147:5-12: Name `slice` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/_prims/__init__.py:228:21-32: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/_prims/__init__.py:229:28-40: No attribute `device` in module `torch` [missing-attribute] ERROR torch/_prims/__init__.py:237:27-39: No attribute `device` in module `torch` [missing-attribute] @@ -12599,6 +12587,7 @@ ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:162:28-53: No attribute `quan ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:163:62-73: No attribute `qint8` in module `torch` [missing-attribute] ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:165:28-53: No attribute `quantize_per_tensor` in module `torch` [missing-attribute] ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:166:62-73: No attribute `qint8` in module `torch` [missing-attribute] + WARN torch/ao/nn/quantized/dynamic/modules/rnn.py:170:40-44: Identity comparison `2 is None` is always False [unnecessary-comparison] ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:328:34-45: No attribute `qint8` in module `torch` [missing-attribute] ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:372:35-46: No attribute `qint8` in module `torch` [missing-attribute] ERROR torch/ao/nn/quantized/dynamic/modules/rnn.py:372:48-61: No attribute `float16` in module `torch` [missing-attribute] @@ -13147,6 +13136,9 @@ ERROR torch/ao/pruning/sparsifier/weight_norm_sparsifier.py:197:25-35: No attrib ERROR torch/ao/pruning/sparsifier/weight_norm_sparsifier.py:231:25-40: No attribute `ones_like` in module `torch` [missing-attribute] ERROR torch/ao/pruning/sparsifier/weight_norm_sparsifier.py:233:25-41: No attribute `zeros_like` in module `torch` [missing-attribute] ERROR torch/ao/pruning/sparsifier/weight_norm_sparsifier.py:249:31-47: No attribute `logical_or` in module `torch` [missing-attribute] +ERROR torch/ao/quantization/__init__.py:65:5-19: Name `MatchAllNode` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/ao/quantization/__init__.py:72:5-14: Name `Pattern` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/ao/quantization/__init__.py:131:5-24: Name `get_combined_dict` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/ao/quantization/__init__.py:217:16-27: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/ao/quantization/__init__.py:224:18-31: No attribute `qscheme` in module `torch` [missing-attribute] ERROR torch/ao/quantization/_correct_bias.py:147:30-40: No attribute `mean` in module `torch` [missing-attribute] @@ -13436,7 +13428,6 @@ ERROR torch/ao/quantization/experimental/observer.py:133:9-16: Class member `APo ERROR torch/ao/quantization/experimental/observer.py:137:28-41: No attribute `aminmax` in module `torch` [missing-attribute] ERROR torch/ao/quantization/experimental/observer.py:139:23-32: No attribute `min` in module `torch` [missing-attribute] ERROR torch/ao/quantization/experimental/observer.py:141:23-32: No attribute `max` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/experimental/observer.py:154:16-40: Could not find import of `matplotlib.pyplot` [missing-import] ERROR torch/ao/quantization/experimental/qconfig.py:12:38-64: No attribute `per_tensor_symmetric` in module `torch` [missing-attribute] ERROR torch/ao/quantization/experimental/qconfig.py:12:72-84: No attribute `quint8` in module `torch` [missing-attribute] ERROR torch/ao/quantization/experimental/qconfig.py:19:38-64: No attribute `per_tensor_symmetric` in module `torch` [missing-attribute] @@ -13804,7 +13795,6 @@ ERROR torch/ao/quantization/fx/_model_report/model_report_observer.py:276:24-36: ERROR torch/ao/quantization/fx/_model_report/model_report_observer.py:277:41-53: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/ao/quantization/fx/_model_report/model_report_observer.py:278:43-55: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/ao/quantization/fx/_model_report/model_report_observer.py:279:34-46: No attribute `tensor` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/fx/_model_report/model_report_visualizer.py:19:12-36: Could not find import of `matplotlib.pyplot` [missing-import] ERROR torch/ao/quantization/fx/convert.py:77:5-17: No attribute `quint8` in module `torch` [missing-attribute] ERROR torch/ao/quantization/fx/convert.py:78:5-16: No attribute `qint8` in module `torch` [missing-attribute] ERROR torch/ao/quantization/fx/convert.py:79:5-17: No attribute `qint32` in module `torch` [missing-attribute] @@ -14043,7 +14033,6 @@ ERROR torch/ao/quantization/observer.py:1119:47-59: No attribute `tensor` in mod ERROR torch/ao/quantization/observer.py:1126:32-44: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1143:17-26: No attribute `sum` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1144:16-28: No attribute `cumsum` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/observer.py:1161:13-1162:26: `int` is not assignable to `int` (caused by inconsistent types when breaking cycles) [bad-assignment] ERROR torch/ao/quantization/observer.py:1207:13-27: No attribute `linspace` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1215:36-50: No attribute `linspace` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1220:13-28: No attribute `bucketize` in module `torch` [missing-attribute] @@ -14078,6 +14067,9 @@ ERROR torch/ao/quantization/observer.py:1615:26-38: No attribute `quint8` in mod ERROR torch/ao/quantization/observer.py:1839:23-34: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1844:22-33: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:1845:27-38: No attribute `dtype` in module `torch` [missing-attribute] +ERROR torch/ao/quantization/observer.py:1909:25-52: Object of class `NoneType` has no attribute `name` [missing-attribute] +ERROR torch/ao/quantization/observer.py:1945:21-48: Object of class `NoneType` has no attribute `name` [missing-attribute] +ERROR torch/ao/quantization/observer.py:1959:21-48: Object of class `NoneType` has no attribute `name` [missing-attribute] ERROR torch/ao/quantization/observer.py:2070:11-22: No attribute `qint8` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:2070:32-58: No attribute `per_tensor_symmetric` in module `torch` [missing-attribute] ERROR torch/ao/quantization/observer.py:2077:11-22: No attribute `qint8` in module `torch` [missing-attribute] @@ -14096,17 +14088,11 @@ ERROR torch/ao/quantization/observer.py:2141:44-56: No attribute `quint8` in mod ERROR torch/ao/quantization/pt2e/_numeric_debugger.py:112:26-39: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/_numeric_debugger.py:112:47-60: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/export_utils.py:66:27-38: No attribute `randn` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/export_utils.py:69:17-46: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/export_utils.py:73:17-45: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/export_utils.py:78:17-45: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/export_utils.py:82:17-46: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] ERROR torch/ao/quantization/pt2e/export_utils.py:140:9-20: No attribute `randn` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/export_utils.py:141:9-20: No attribute `randn` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/export_utils.py:142:9-20: No attribute `randn` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/export_utils.py:143:9-20: No attribute `randn` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/export_utils.py:144:9-20: No attribute `randn` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/export_utils.py:150:9-33: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/export_utils.py:155:9-32: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `torch.ao.quantization.pt2e.utils._get_aten_graph_module_for_pattern` [bad-argument-type] ERROR torch/ao/quantization/pt2e/graph_utils.py:32:6-15: No attribute `add` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/graph_utils.py:33:6-15: No attribute `mul` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/lowering.py:31:20-33: Module `torch._export` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -14123,17 +14109,12 @@ ERROR torch/ao/quantization/pt2e/qat_utils.py:54:60-71: No attribute `float` in ERROR torch/ao/quantization/pt2e/qat_utils.py:55:41-53: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/qat_utils.py:55:65-74: No attribute `int` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/qat_utils.py:57:31-42: No attribute `randn` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/qat_utils.py:81:12-44: Returned type `_WrapperModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] ERROR torch/ao/quantization/pt2e/qat_utils.py:102:23-33: No attribute `sqrt` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/qat_utils.py:110:21-37: No attribute `zeros_like` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/qat_utils.py:125:12-48: Returned type `_WrapperModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] ERROR torch/ao/quantization/pt2e/qat_utils.py:144:23-33: No attribute `sqrt` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/qat_utils.py:165:12-61: Returned type `_WrapperModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] ERROR torch/ao/quantization/pt2e/qat_utils.py:184:13-23: No attribute `int8` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/qat_utils.py:222:23-33: No attribute `sqrt` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/qat_utils.py:236:25-41: No attribute `zeros_like` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/qat_utils.py:261:12-58: Returned type `_WrapperModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] -ERROR torch/ao/quantization/pt2e/qat_utils.py:315:12-65: Returned type `_WrapperModule` is not assignable to declared return type `(...) -> Unknown` [bad-return] ERROR torch/ao/quantization/pt2e/qat_utils.py:596:21-45: Cannot set item in `dict[Mapping[str, Unknown], Unknown]` [unsupported-operation] ERROR torch/ao/quantization/pt2e/qat_utils.py:596:21-45: Cannot set item in `dict[Mapping[str, Unknown], Unknown]` [unsupported-operation] ERROR torch/ao/quantization/pt2e/qat_utils.py:596:21-45: Cannot set item in `dict[Mapping[str, Unknown], Unknown]` [unsupported-operation] @@ -14397,30 +14378,10 @@ ERROR torch/ao/quantization/pt2e/representation/rewrite.py:723:9-20: No attribut ERROR torch/ao/quantization/pt2e/representation/rewrite.py:723:30-41: No attribute `float` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:724:9-20: No attribute `zeros` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:724:30-39: No attribute `int` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:733:13-58: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:734:13-64: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:737:53-64: No attribute `finfo` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:737:65-78: No attribute `float32` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:741:53-64: No attribute `finfo` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/representation/rewrite.py:741:65-78: No attribute `float32` in module `torch` [missing-attribute] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:746:13-50: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:747:13-56: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:753:13-50: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:754:13-56: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:760:13-52: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:761:13-58: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:765:13-47: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:766:13-53: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:770:13-54: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:771:13-60: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:777:13-54: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:778:13-64: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:782:13-56: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:783:13-66: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:787:13-55: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:788:13-65: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:794:13-57: Argument `_WrapperModule` is not assignable to parameter `pattern` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] -ERROR torch/ao/quantization/pt2e/representation/rewrite.py:795:13-67: Argument `_WrapperModule` is not assignable to parameter `replacement` with type `(...) -> Unknown` in function `_RewriteInfo.__init__` [bad-argument-type] ERROR torch/ao/quantization/pt2e/utils.py:364:10-23: Module `torch._export` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/ao/quantization/pt2e/utils.py:475:46-57: No attribute `dtype` in module `torch` [missing-attribute] ERROR torch/ao/quantization/pt2e/utils.py:517:50-61: No attribute `dtype` in module `torch` [missing-attribute] @@ -15095,6 +15056,16 @@ ERROR torch/cuda/__init__.py:1669:16-30: No attribute `bfloat16` in module `torc ERROR torch/cuda/__init__.py:1680:16-29: No attribute `cdouble` in module `torch` [missing-attribute] ERROR torch/cuda/__init__.py:1691:16-28: No attribute `cfloat` in module `torch` [missing-attribute] ERROR torch/cuda/__init__.py:1738:18-32: Module `importlib.util` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] +ERROR torch/cuda/__init__.py:1834:5-21: Name `BFloat16Tensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1836:5-17: Name `BoolTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1838:5-17: Name `ByteTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1840:5-17: Name `CharTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1844:5-19: Name `DoubleTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1846:5-18: Name `FloatTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1848:5-17: Name `HalfTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1850:5-16: Name `IntTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1852:5-17: Name `LongTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/cuda/__init__.py:1854:5-18: Name `ShortTensor` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/cuda/_device_limits.py:2:22-27: Could not import `dtype` from `torch._C` [missing-module-attribute] ERROR torch/cuda/_device_limits.py:15:39-51: No attribute `device` in module `torch` [missing-attribute] ERROR torch/cuda/_device_limits.py:47:25-38: No attribute `float16` in module `torch` [missing-attribute] @@ -16343,8 +16314,6 @@ ERROR torch/distributed/pipelining/_IR.py:503:17-29: No attribute `device` in mo ERROR torch/distributed/pipelining/_IR.py:1122:17-29: No attribute `device` in module `torch` [missing-attribute] ERROR torch/distributed/pipelining/_backward.py:196:13-28: No attribute `ones_like` in module `torch` [missing-attribute] ERROR torch/distributed/pipelining/_backward.py:418:16-25: No attribute `add` in module `torch` [missing-attribute] -ERROR torch/distributed/pipelining/_schedule_visualizer.py:350:12-36: Could not find import of `matplotlib.pyplot` [missing-import] -ERROR torch/distributed/pipelining/_schedule_visualizer.py:351:5-45: Could not find import of `matplotlib.patches` [missing-import] ERROR torch/distributed/pipelining/microbatch.py:52:28-40: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/distributed/pipelining/microbatch.py:143:28-46: No attribute `tensor_split` in module `torch` [missing-attribute] ERROR torch/distributed/pipelining/microbatch.py:146:25-43: No attribute `tensor_split` in module `torch` [missing-attribute] @@ -16567,7 +16536,6 @@ ERROR torch/distributed/tensor/_utils.py:440:25-35: No attribute `Size` in modul ERROR torch/distributed/tensor/_utils.py:449:12-22: No attribute `Size` in module `torch` [missing-attribute] ERROR torch/distributed/tensor/debug/__init__.py:29:12-65: No attribute `_get_DTensor_sharding_propagator_cache_stats` in module `torch._C` [missing-attribute] ERROR torch/distributed/tensor/debug/__init__.py:47:5-54: No attribute `_clear_DTensor_sharding_propagator_cache` in module `torch._C` [missing-attribute] -ERROR torch/distributed/tensor/debug/_visualize_sharding.py:74:12-22: Could not find import of `matplotlib` [missing-import] ERROR torch/distributed/tensor/examples/comm_mode_features_example.py:72:13-25: No attribute `arange` in module `torch` [missing-attribute] ERROR torch/distributed/tensor/examples/comm_mode_features_example.py:76:15-25: No attribute `rand` in module `torch` [missing-attribute] ERROR torch/distributed/tensor/examples/comm_mode_features_example.py:90:13-25: No attribute `arange` in module `torch` [missing-attribute] @@ -17280,7 +17248,6 @@ ERROR torch/export/_trace.py:843:20-33: Module `torch._export` exists, but was n ERROR torch/export/_trace.py:1502:22-55: No attribute `_jit_texpr_fuser_enabled` in module `torch._C` [missing-attribute] ERROR torch/export/_trace.py:1503:5-42: No attribute `_jit_set_texpr_fuser_enabled` in module `torch._C` [missing-attribute] ERROR torch/export/_trace.py:1507:9-46: No attribute `_jit_set_texpr_fuser_enabled` in module `torch._C` [missing-attribute] -ERROR torch/export/_trace.py:1525:9-12: Argument `Module` is not assignable to parameter `f` with type `(...) -> Unknown` in function `_export_to_torch_ir` [bad-argument-type] ERROR torch/export/_trace.py:1728:24-64: No attribute `_is_torch_function_mode_enabled` in module `torch._C` [missing-attribute] ERROR torch/export/_trace.py:1806:29-50: No attribute `is_grad_enabled` in module `torch` [missing-attribute] ERROR torch/export/_trace.py:1810:21-47: No attribute `_set_grad_enabled` in module `torch._C` [missing-attribute] @@ -17549,7 +17516,6 @@ ERROR torch/fx/experimental/symbolic_shapes.py:2354:9-25: `Expr` is not assignab ERROR torch/fx/experimental/symbolic_shapes.py:2355:9-25: `Expr` is not assignable to `list[Expr]` [bad-assignment] ERROR torch/fx/experimental/symbolic_shapes.py:2652:9-21: Class member `SymExprPrinter._print_Float` overrides parent class `PythonPrinter` in an inconsistent manner [bad-override] ERROR torch/fx/experimental/symbolic_shapes.py:2940:64-2945:10: `set[type[Application] | type[FloorDiv] | type[Mod] | type[PythonMod]]` is not assignable to attribute `_supported_sympy_functions` with type `set[Function]` [bad-assignment] -ERROR torch/fx/experimental/symbolic_shapes.py:3029:16-20: Returned type `_SympyT | Unknown` is not assignable to declared return type `_SympyT` [bad-return] ERROR torch/fx/experimental/symbolic_shapes.py:3032:18-36: Module `torch.utils._sympy` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/fx/experimental/symbolic_shapes.py:3032:18-46: Module `torch.utils._sympy.functions` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/fx/experimental/symbolic_shapes.py:3077:55-56: Cannot index into `defaultdict[Symbol, set[Expr]]` [bad-index] @@ -17835,6 +17801,7 @@ ERROR torch/jit/_script.py:682:17-36: No attribute `BufferDict` in module `torch ERROR torch/jit/_script.py:699:35-62: No attribute `ConcreteModuleType` in module `torch._C` [missing-attribute] ERROR torch/jit/_script.py:705:37-56: No attribute `ModuleDict` in module `torch._C` [missing-attribute] ERROR torch/jit/_script.py:717:38-59: No attribute `ScriptMethod` in module `torch._C` [missing-attribute] + WARN torch/jit/_script.py:821:30-57: Identity comparison between an instance of `str` and class `RecursiveScriptModule` is always False [unnecessary-comparison] ERROR torch/jit/_script.py:889:20-40: Module `torch.jit._recursive` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/jit/_script.py:892:20-40: Module `torch.jit._recursive` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] ERROR torch/jit/_script.py:1188:16-36: Module `torch.jit._recursive` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] @@ -18545,6 +18512,14 @@ ERROR torch/nn/modules/batchnorm.py:74:27-37: No attribute `long` in module `tor ERROR torch/nn/modules/batchnorm.py:129:60-72: No attribute `device` in module `torch` [missing-attribute] ERROR torch/nn/modules/batchnorm.py:130:26-38: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/nn/modules/batchnorm.py:130:48-58: No attribute `long` in module `torch` [missing-attribute] +ERROR torch/nn/modules/batchnorm.py:240:50-66: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:240:50-66: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:242:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:242:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:245:53-69: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedBuffer.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:245:53-69: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedBuffer.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:247:52-68: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedBuffer.__init__` [unexpected-keyword] +ERROR torch/nn/modules/batchnorm.py:247:52-68: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedBuffer.__init__` [unexpected-keyword] ERROR torch/nn/modules/batchnorm.py:248:40-52: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/nn/modules/batchnorm.py:250:23-33: No attribute `long` in module `torch` [missing-attribute] ERROR torch/nn/modules/batchnorm.py:802:17-55: No attribute `_get_privateuse1_backend_name` in module `torch._C` [missing-attribute] @@ -18554,13 +18529,41 @@ ERROR torch/nn/modules/container.py:1008:46-84: No attribute `_get_privateuse1_b ERROR torch/nn/modules/conv.py:163:17-28: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/nn/modules/conv.py:170:17-28: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/nn/modules/conv.py:176:35-46: No attribute `empty` in module `torch` [missing-attribute] +ERROR torch/nn/modules/conv.py:1536:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1536:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1540:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1540:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1608:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1608:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1612:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1612:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1681:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1681:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1685:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1685:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1753:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1753:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1757:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1757:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1825:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1825:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1829:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1829:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1897:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1897:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1901:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/conv.py:1901:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] ERROR torch/nn/modules/linear.py:109:13-24: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/nn/modules/linear.py:112:35-46: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/nn/modules/linear.py:221:13-24: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/nn/modules/linear.py:225:35-46: No attribute `empty` in module `torch` [missing-attribute] -ERROR torch/nn/modules/loss.py:1883:13-87: `((Tensor, Tensor) -> Tensor) | PairwiseDistance` is not assignable to attribute `distance_function` with type `((Tensor, Tensor) -> Tensor) | None` [bad-assignment] +ERROR torch/nn/modules/linear.py:302:46-62: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/linear.py:302:46-62: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/linear.py:306:48-64: Unexpected keyword argument `device` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] +ERROR torch/nn/modules/linear.py:306:48-64: Unexpected keyword argument `dtype` in function `torch.nn.parameter.UninitializedParameter.__init__` [unexpected-keyword] ERROR torch/nn/modules/module.py:14:19-25: Could not import `device` from `torch` [missing-module-attribute] ERROR torch/nn/modules/module.py:14:27-32: Could not import `dtype` from `torch` [missing-module-attribute] +ERROR torch/nn/modules/module.py:97:32-45: `Module | None` is not assignable to TypedDict key `module` with type `((...) -> Unknown) | bool` [bad-typed-dict-key] ERROR torch/nn/modules/module.py:484:9-37: No attribute `_log_api_usage_once` in module `torch._C` [missing-attribute] ERROR torch/nn/modules/module.py:938:16-55: No attribute `_has_compatible_shallow_copy_type` in module `torch` [missing-attribute] ERROR torch/nn/modules/module.py:1236:23-39: No attribute `empty_like` in module `torch` [missing-attribute] @@ -20538,7 +20541,6 @@ ERROR torch/profiler/_memory_profiler.py:380:62-75: No attribute `strided` in mo ERROR torch/profiler/_memory_profiler.py:678:39-51: No attribute `device` in module `torch` [missing-attribute] ERROR torch/profiler/_memory_profiler.py:1006:18-30: No attribute `device` in module `torch` [missing-attribute] ERROR torch/profiler/_memory_profiler.py:1074:18-30: No attribute `device` in module `torch` [missing-attribute] -ERROR torch/profiler/_memory_profiler.py:1158:16-40: Could not find import of `matplotlib.pyplot` [missing-import] ERROR torch/profiler/_memory_profiler.py:1167:18-30: No attribute `device` in module `torch` [missing-attribute] ERROR torch/profiler/_pattern_matcher.py:337:23-34: No attribute `randn` in module `torch` [missing-attribute] ERROR torch/profiler/_pattern_matcher.py:337:66-79: No attribute `float32` in module `torch` [missing-attribute] @@ -20565,6 +20567,11 @@ ERROR torch/profiler/_utils.py:332:69-78: No attribute `std` in module `torch` [ ERROR torch/profiler/profiler.py:17:22-51: Could not import `_get_privateuse1_backend_name` from `torch._C` [missing-module-attribute] ERROR torch/profiler/profiler.py:48:9-16: Class member `_NumpyEncoder.default` overrides parent class `JSONEncoder` in an inconsistent manner [bad-param-name-override] ERROR torch/profiler/profiler.py:394:28-43: Module `torch.cuda.nccl` exists, but was not imported explicitly. You are relying on other modules to load it. [implicit-import] +ERROR torch/profiler/profiler.py:396:41-79: `str` is not assignable to TypedDict key `nccl_version` with type `Backend | int | list[dict[str, Any]]` [bad-typed-dict-key] +ERROR torch/quantization/__init__.py:37:5-36: Name `_prepare_ondevice_dynamic_jit` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/quantization/__init__.py:38:5-36: Name `_convert_ondevice_dynamic_jit` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/quantization/__init__.py:39:5-37: Name `_quantize_ondevice_dynamic_jit` is listed in `__all__` but is not defined in the module [missing-module-attribute] +ERROR torch/quantization/__init__.py:60:5-21: Name `WeightObserver` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/quantization/_quantized_conversions.py:11:28-38: No attribute `int8` in module `torch` [missing-attribute] ERROR torch/quantization/_quantized_conversions.py:20:28-38: No attribute `int8` in module `torch` [missing-attribute] ERROR torch/quantization/_quantized_conversions.py:21:12-23: No attribute `stack` in module `torch` [missing-attribute] @@ -20751,6 +20758,7 @@ ERROR torch/signal/windows/windows.py:870:12-23: No attribute `dtype` in module ERROR torch/signal/windows/windows.py:871:13-25: No attribute `layout` in module `torch` [missing-attribute] ERROR torch/signal/windows/windows.py:871:28-41: No attribute `strided` in module `torch` [missing-attribute] ERROR torch/signal/windows/windows.py:872:13-25: No attribute `device` in module `torch` [missing-attribute] +ERROR torch/sparse/__init__.py:35:5-12: Name `solve` is listed in `__all__` but is not defined in the module [missing-module-attribute] ERROR torch/sparse/__init__.py:260:20-37: No attribute `_sparse_sum` in module `torch` [missing-attribute] ERROR torch/sparse/__init__.py:262:20-37: No attribute `_sparse_sum` in module `torch` [missing-attribute] ERROR torch/sparse/__init__.py:265:20-37: No attribute `_sparse_sum` in module `torch` [missing-attribute] @@ -21469,7 +21477,6 @@ ERROR torch/utils/_sympy/reference.py:348:39-50: No attribute `dtype` in module ERROR torch/utils/_sympy/reference.py:372:21-32: No attribute `int64` in module `torch` [missing-attribute] ERROR torch/utils/_sympy/reference.py:374:23-35: No attribute `double` in module `torch` [missing-attribute] ERROR torch/utils/_sympy/reference.py:376:23-33: No attribute `bool` in module `torch` [missing-attribute] -ERROR torch/utils/_sympy/singleton_int.py:12:5-17: Class member `SingletonInt._op_priority` overrides parent class `AtomicExpr` in an inconsistent manner [bad-override] ERROR torch/utils/_sympy/solve.py:147:13-38: Object of class `Basic` has no attribute `is_positive` [missing-attribute] ERROR torch/utils/_sympy/value_ranges.py:276:31-278:14: No matching overload found for function `ValueRanges.__init__` called with arguments: (Max, Min) [no-matching-overload] ERROR torch/utils/_sympy/value_ranges.py:307:31-309:14: No matching overload found for function `ValueRanges.__init__` called with arguments: (Min, Max) [no-matching-overload] @@ -21571,10 +21578,6 @@ ERROR torch/utils/benchmark/utils/common.py:292:25-46: No attribute `get_num_thr ERROR torch/utils/benchmark/utils/common.py:294:9-30: No attribute `set_num_threads` in module `torch` [missing-attribute] ERROR torch/utils/benchmark/utils/common.py:297:9-30: No attribute `set_num_threads` in module `torch` [missing-attribute] ERROR torch/utils/benchmark/utils/compare.py:8:19-36: Could not import `tensor` from `torch` [missing-module-attribute] -ERROR torch/utils/benchmark/utils/compile.py:92:42-98: No matching overload found for function `torch.compile` called with arguments: (((...) -> Unknown) | Module, backend=CompileCounterWithBackend, mode=str | None) [no-matching-overload] -ERROR torch/utils/benchmark/utils/compile.py:95:86-93: Argument `((...) -> Unknown) | Module | None` is not assignable to parameter `loss_fn` with type `((...) -> Unknown) | None` in function `bench_loop` [bad-argument-type] -ERROR torch/utils/benchmark/utils/compile.py:97:90-97: Argument `((...) -> Unknown) | Module | None` is not assignable to parameter `loss_fn` with type `((...) -> Unknown) | None` in function `bench_loop` [bad-argument-type] -ERROR torch/utils/benchmark/utils/compile.py:112:86-93: Argument `((...) -> Unknown) | Module | None` is not assignable to parameter `loss_fn` with type `((...) -> Unknown) | None` in function `bench_loop` [bad-argument-type] ERROR torch/utils/benchmark/utils/fuzzer.py:170:17-27: No attribute `bool` in module `torch` [missing-attribute] ERROR torch/utils/benchmark/utils/fuzzer.py:173:20-31: No attribute `finfo` in module `torch` [missing-attribute] ERROR torch/utils/benchmark/utils/fuzzer.py:174:16-27: No attribute `iinfo` in module `torch` [missing-attribute] @@ -21666,6 +21669,8 @@ ERROR torch/utils/data/dataloader.py:650:26-41: No attribute `Generator` in modu ERROR torch/utils/data/dataloader.py:706:13-24: No attribute `empty` in module `torch` [missing-attribute] ERROR torch/utils/data/dataloader.py:706:35-46: No attribute `int64` in module `torch` [missing-attribute] ERROR torch/utils/data/dataloader.py:723:26-41: No attribute `Generator` in module `torch` [missing-attribute] + WARN torch/utils/data/dataloader.py:1626:45-49: Identity comparison `False is True` is always False [unnecessary-comparison] + WARN torch/utils/data/dataloader.py:1627:45-49: Identity comparison `False is None` is always False [unnecessary-comparison] ERROR torch/utils/data/datapipes/datapipe.py:426:9-20: Class member `_MapDataPipeSerializationWrapper.__getitem__` overrides parent class `MapDataPipe` in an inconsistent manner [bad-param-name-override] WARN torch/utils/data/datapipes/gen_pyi.py:64:30-47: `materialize_lines` is deprecated [deprecated] ERROR torch/utils/data/datapipes/iter/callable.py:79:9-37: No attribute `_log_api_usage_once` in module `torch._C` [missing-attribute] @@ -21677,7 +21682,6 @@ ERROR torch/utils/data/datapipes/utils/decoder.py:189:20-29: Could not find impo ERROR torch/utils/data/datapipes/utils/decoder.py:224:28-40: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/utils/data/datapipes/utils/decoder.py:227:28-40: No attribute `tensor` in module `torch` [missing-attribute] ERROR torch/utils/data/datapipes/utils/decoder.py:253:16-30: Could not find import of `torchvision.io` [missing-import] -ERROR torch/utils/data/datapipes/utils/decoder.py:297:20-35: Could not find import of `scipy.io` [missing-import] ERROR torch/utils/data/dataset.py:17:19-36: Could not import `default_generator` from `torch` [missing-module-attribute] ERROR torch/utils/data/dataset.py:17:38-47: Could not import `Generator` from `torch` [missing-module-attribute] ERROR torch/utils/data/dataset.py:17:49-57: Could not import `randperm` from `torch` [missing-module-attribute] @@ -21786,9 +21790,6 @@ ERROR torch/utils/tensorboard/_pytorch_graph.py:8:1-79: Could not find import of ERROR torch/utils/tensorboard/_pytorch_graph.py:9:1-61: Could not find import of `tensorboard.compat.proto.versions_pb2` [missing-import] ERROR torch/utils/tensorboard/_pytorch_graph.py:330:13-38: No attribute `_jit_pass_inline` in module `torch._C` [missing-attribute] ERROR torch/utils/tensorboard/_pytorch_graph.py:375:21-34: No attribute `Node` in module `torch._C` [missing-attribute] -ERROR torch/utils/tensorboard/_utils.py:19:12-36: Could not find import of `matplotlib.pyplot` [missing-import] -ERROR torch/utils/tensorboard/_utils.py:20:12-62: Could not find import of `matplotlib.backends.backend_agg` [missing-import] -ERROR torch/utils/tensorboard/writer.py:11:5-41: Could not find import of `matplotlib.figure` [missing-import] ERROR torch/utils/tensorboard/writer.py:12:1-34: Could not find import of `tensorboard.compat` [missing-import] ERROR torch/utils/tensorboard/writer.py:13:1-47: Could not find import of `tensorboard.compat.proto` [missing-import] ERROR torch/utils/tensorboard/writer.py:14:1-65: Could not find import of `tensorboard.compat.proto.event_pb2` [missing-import] @@ -21869,4 +21870,4 @@ ERROR torch/xpu/streams.py:103:13-35: No attribute `_XpuEventBase` in module `to ERROR torch/xpu/streams.py:167:32-47: Object of class `Event` has no attribute `sycl_event` [missing-attribute] ERROR torch/xpu/streams.py:170:12-27: Object of class `Event` has no attribute `sycl_event` [missing-attribute] INFO Checking project configured at `/pyrefly.toml` - INFO 21,740 errors (6,368 suppressed) + INFO 21,733 errors (6,202 suppressed) diff --git a/scripts/ty_benchmark/snapshots/pytorch_Pyright.txt b/scripts/ty_benchmark/snapshots/pytorch_Pyright.txt index ebe376a4c4..2ab99028dd 100644 --- a/scripts/ty_benchmark/snapshots/pytorch_Pyright.txt +++ b/scripts/ty_benchmark/snapshots/pytorch_Pyright.txt @@ -7664,7 +7664,6 @@ /torch/_inductor/config.py:643:36 - error: "config" is not a known attribute of module "torch._inductor" (reportAttributeAccessIssue) /torch/_inductor/config.py:653:47 - error: "hip" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/_inductor/config.py:964:21 - error: "_utils_internal" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/_inductor/config.py:993:20 - error: "sched_getaffinity" is not a known attribute of module "os" (reportAttributeAccessIssue) /torch/_inductor/config.py:1040:14 - error: Import "libfb.py" could not be resolved (reportMissingImports) /torch/_inductor/config.py:1565:48 - error: "hip" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/_inductor/config.py:2240:10 - warning: Import "torch.utils._config_typing" could not be resolved from source (reportMissingModuleSource) @@ -11703,7 +11702,6 @@   Type "Sequence[Symbol] | None" is not assignable to type "Iterable[Expr | int]"     "None" is incompatible with protocol "Iterable[Expr | int]"       "__iter__" is not present (reportArgumentType) - /torch/_inductor/select_algorithm.py:2534:16 - error: "sched_getaffinity" is not a known attribute of module "os" (reportAttributeAccessIssue) /torch/_inductor/select_algorithm.py:2745:29 - error: "autotune_process" is not a known attribute of module "torch._inductor" (reportAttributeAccessIssue) /torch/_inductor/select_algorithm.py:2761:26 - error: Cannot access attribute "hint_override" for class "ChoiceCaller"   Attribute "hint_override" is unknown (reportAttributeAccessIssue) @@ -25931,13 +25929,7 @@ /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:14:22 - warning: Import "torch._C._onnx" could not be resolved from source (reportMissingModuleSource) /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:100:50 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:104:15 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "float" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "float" -     "tuple[Unknown, ...]" is not assignable to "float" (reportAssignmentType) /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:106:23 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:108:15 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "float" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "float" -     "tuple[Unknown, ...]" is not assignable to "float" (reportAssignmentType) /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:110:23 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:189:23 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset11.py:193:23 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) @@ -26038,9 +26030,6 @@ /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:90:48 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:91:21 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:91:37 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:97:9 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "float" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "float" -     "tuple[Unknown, ...]" is not assignable to "float" (reportAssignmentType) /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:97:40 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:98:40 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset12.py:98:66 - error: "bool" is not a known attribute of module "torch" (reportAttributeAccessIssue) @@ -26241,8 +26230,6 @@ /torch/onnx/_internal/torchscript_exporter/symbolic_opset17.py:241:68 - error: "int64" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset17.py:246:27 - error: "sqrt" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset17.py:246:38 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset17.py:246:65 - error: Cannot access attribute "type" for class "tuple[Unknown, ...]" -   Attribute "type" is unknown (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset18.py /torch/onnx/_internal/torchscript_exporter/symbolic_opset18.py:68:15 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset18.py:69:21 - error: "Value" is not a known attribute of module "torch" (reportAttributeAccessIssue) @@ -26495,8 +26482,8 @@ /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4247:25 - error: Object of type "None" is not subscriptable (reportOptionalSubscript) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4248:25 - error: Object of type "None" is not subscriptable (reportOptionalSubscript) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4463:48 - error: "LongTensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4564:5 - error: Expression with type "tuple[Unknown | tuple[Unknown, ...], Unknown | tuple[Unknown, ...]] | tuple[Unknown | tuple[Unknown, ...], Unknown | tuple[Unknown, ...], Unknown | tuple[Unknown, ...]] | None" cannot be assigned to target tuple -   Type "tuple[Unknown | tuple[Unknown, ...], Unknown | tuple[Unknown, ...]]" is incompatible with target tuple + /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4564:5 - error: Expression with type "tuple[Unknown, Unknown] | tuple[Unknown, Unknown, Unknown] | None" cannot be assigned to target tuple +   Type "tuple[Unknown, Unknown]" is incompatible with target tuple     Tuple size mismatch; expected 3 but received 2 (reportAssignmentType) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:4564:25 - error: "None" is not iterable   "__iter__" method not defined (reportGeneralTypeIssues) @@ -26602,21 +26589,6 @@ /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5921:48 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5926:48 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5929:64 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5932:23 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "Tensor | None" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "Tensor | None" -     Type "tuple[Unknown, ...]" is not assignable to type "Tensor | None" -       "tuple[Unknown, ...]" is not assignable to "Tensor" -       "tuple[Unknown, ...]" is not assignable to "None" (reportAssignmentType) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5934:23 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "Tensor | None" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "Tensor | None" -     Type "tuple[Unknown, ...]" is not assignable to type "Tensor | None" -       "tuple[Unknown, ...]" is not assignable to "Tensor" -       "tuple[Unknown, ...]" is not assignable to "None" (reportAssignmentType) - /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5937:19 - error: Type "Unknown | tuple[Unknown, ...]" is not assignable to declared type "Tensor | None" -   Type "Unknown | tuple[Unknown, ...]" is not assignable to type "Tensor | None" -     Type "tuple[Unknown, ...]" is not assignable to type "Tensor | None" -       "tuple[Unknown, ...]" is not assignable to "Tensor" -       "tuple[Unknown, ...]" is not assignable to "None" (reportAssignmentType) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5937:59 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5967:48 - error: "tensor" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/onnx/_internal/torchscript_exporter/symbolic_opset9.py:5967:70 - error: "int64" is not a known attribute of module "torch" (reportAttributeAccessIssue) @@ -28493,7 +28465,6 @@ /torch/utils/data/dataloader.py /torch/utils/data/dataloader.py:268:18 - error: "_log_api_usage_once" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/utils/data/dataloader.py:455:69 - error: "context" is not a known attribute of module "multiprocessing" (reportAttributeAccessIssue) - /torch/utils/data/dataloader.py:612:49 - error: "sched_getaffinity" is not a known attribute of module "os" (reportAttributeAccessIssue) /torch/utils/data/dataloader.py:650:32 - error: "Generator" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/utils/data/dataloader.py:706:19 - error: "empty" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/utils/data/dataloader.py:706:41 - error: "int64" is not a known attribute of module "torch" (reportAttributeAccessIssue) @@ -28816,4 +28787,4 @@ /torch/xpu/streams.py /torch/xpu/streams.py:14:23 - error: "_XpuStreamBase" is not a known attribute of module "torch" (reportAttributeAccessIssue) /torch/xpu/streams.py:103:22 - error: "_XpuEventBase" is not a known attribute of module "torch" (reportAttributeAccessIssue) -19691 errors, 402 warnings, 0 informations +19681 errors, 402 warnings, 0 informations diff --git a/scripts/ty_benchmark/snapshots/pytorch_ty.txt b/scripts/ty_benchmark/snapshots/pytorch_ty.txt index ec1f705e83..e4742326a4 100644 --- a/scripts/ty_benchmark/snapshots/pytorch_ty.txt +++ b/scripts/ty_benchmark/snapshots/pytorch_ty.txt @@ -154,6 +154,7 @@ torch/_decomp/decompositions.py:162:16: error[unresolved-attribute] Module `torc torch/_decomp/decompositions.py:168:16: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:170:50: error[unresolved-attribute] Module `torch` has no member `exp` torch/_decomp/decompositions.py:177:12: error[unresolved-attribute] Module `torch` has no member `full_like` +torch/_decomp/decompositions.py:186:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_decomp/decompositions.py:193:12: error[unresolved-attribute] Module `torch` has no member `clamp` torch/_decomp/decompositions.py:193:24: error[unresolved-attribute] Module `torch` has no member `clamp` torch/_decomp/decompositions.py:200:12: error[unresolved-attribute] Module `torch` has no member `where` @@ -174,6 +175,10 @@ torch/_decomp/decompositions.py:301:24: error[unresolved-attribute] Module `torc torch/_decomp/decompositions.py:307:12: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:316:18: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:317:19: error[unresolved-attribute] Module `torch` has no member `where` +torch/_decomp/decompositions.py:338:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:338:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:338:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:338:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/_decomp/decompositions.py:347:17: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:348:12: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:349:9: error[unresolved-attribute] Module `torch` has no member `exp` @@ -211,6 +216,7 @@ torch/_decomp/decompositions.py:650:46: error[unresolved-attribute] Module `torc torch/_decomp/decompositions.py:666:12: error[unresolved-attribute] Module `torch` has no member `log1p` torch/_decomp/decompositions.py:666:24: error[unresolved-attribute] Module `torch` has no member `exp` torch/_decomp/decompositions.py:679:42: error[unresolved-attribute] Module `torch` has no member `sigmoid` +torch/_decomp/decompositions.py:688:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_decomp/decompositions.py:695:14: error[unresolved-attribute] Module `torch` has no member `ones_like` torch/_decomp/decompositions.py:695:53: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/_decomp/decompositions.py:697:14: error[unresolved-attribute] Module `torch` has no member `ones_like` @@ -224,6 +230,8 @@ torch/_decomp/decompositions.py:821:60: error[unresolved-attribute] Module `torc torch/_decomp/decompositions.py:823:16: error[unresolved-attribute] Module `torch` has no member `logical_and` torch/_decomp/decompositions.py:826:16: error[unresolved-attribute] Module `torch` has no member `logical_and` torch/_decomp/decompositions.py:829:16: error[unresolved-attribute] Module `torch` has no member `logical_and` +torch/_decomp/decompositions.py:834:75: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_decomp/decompositions.py:834:79: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_decomp/decompositions.py:841:12: error[unresolved-attribute] Module `torch` has no member `select_scatter` torch/_decomp/decompositions.py:850:12: error[unresolved-attribute] Module `torch` has no member `diagonal_scatter` torch/_decomp/decompositions.py:854:59: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -235,14 +243,20 @@ torch/_decomp/decompositions.py:885:52: error[unresolved-attribute] Module `torc torch/_decomp/decompositions.py:897:25: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:897:45: error[unresolved-attribute] Module `torch` has no member `int64` torch/_decomp/decompositions.py:976:33: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[int, int, int, int]` +torch/_decomp/decompositions.py:1083:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[None, None, Tensor, Unknown]` +torch/_decomp/decompositions.py:1083:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/_decomp/decompositions.py:1084:28: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[int, int, int, int]` torch/_decomp/decompositions.py:1112:16: error[unresolved-attribute] Module `torch` has no member `squeeze_copy` torch/_decomp/decompositions.py:1114:11: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:1114:67: error[unresolved-attribute] Module `torch` has no member `int32` +torch/_decomp/decompositions.py:1122:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/_decomp/decompositions.py:1133:16: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:1134:13: error[unresolved-attribute] Module `torch` has no member `logical_and` torch/_decomp/decompositions.py:1139:16: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:1140:13: error[unresolved-attribute] Module `torch` has no member `logical_and` +torch/_decomp/decompositions.py:1151:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:1151:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `(int & ~Literal[0]) | float` +torch/_decomp/decompositions.py:1151:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/_decomp/decompositions.py:1161:21: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_decomp/decompositions.py:1161:46: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_decomp/decompositions.py:1161:76: error[unresolved-attribute] Module `torch` has no member `bool` @@ -260,13 +274,29 @@ torch/_decomp/decompositions.py:1217:25: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:1217:35: error[unresolved-attribute] Module `torch` has no member `sum` torch/_decomp/decompositions.py:1217:45: error[unresolved-attribute] Module `torch` has no member `exp` torch/_decomp/decompositions.py:1261:16: error[unresolved-attribute] Module `torch` has no member `ones_like` +torch/_decomp/decompositions.py:1262:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | Tensor]` +torch/_decomp/decompositions.py:1262:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:1271:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | Tensor]` +torch/_decomp/decompositions.py:1271:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:1298:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:1298:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_decomp/decompositions.py:1299:41: error[unresolved-attribute] Module `torch` has no member `Size` torch/_decomp/decompositions.py:1368:16: error[unresolved-attribute] Module `torch` has no member `cat` torch/_decomp/decompositions.py:1370:9: error[unresolved-attribute] Module `torch` has no member `cat` +torch/_decomp/decompositions.py:1384:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:1384:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_decomp/decompositions.py:1384:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_decomp/decompositions.py:1386:39: error[unresolved-attribute] Module `torch` has no member `contiguous_format` +torch/_decomp/decompositions.py:1396:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:1396:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_decomp/decompositions.py:1396:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_decomp/decompositions.py:1403:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:1403:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_decomp/decompositions.py:1403:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_decomp/decompositions.py:1433:48: error[unresolved-attribute] Module `torch` has no member `int64` torch/_decomp/decompositions.py:1446:26: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` torch/_decomp/decompositions.py:1476:19: error[unresolved-attribute] Module `torch` has no member `mm` +torch/_decomp/decompositions.py:1503:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal["tanh"]` torch/_decomp/decompositions.py:1516:19: error[unresolved-attribute] Module `torch` has no member `mv` torch/_decomp/decompositions.py:1563:10: error[unresolved-attribute] Module `torch` has no member `mul` torch/_decomp/decompositions.py:1572:22: error[unresolved-attribute] Module `torch` has no member `mul` @@ -291,6 +321,7 @@ torch/_decomp/decompositions.py:1780:23: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:1780:35: error[unresolved-attribute] Module `torch` has no member `float64` torch/_decomp/decompositions.py:1784:19: error[unresolved-attribute] Module `torch` has no member `rsqrt` torch/_decomp/decompositions.py:1788:13: error[unresolved-attribute] Module `torch` has no member `pow` +torch/_decomp/decompositions.py:1788:82: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int | float` torch/_decomp/decompositions.py:1801:9: error[unresolved-attribute] Module `torch` has no member `channels_last` torch/_decomp/decompositions.py:1802:9: error[unresolved-attribute] Module `torch` has no member `channels_last_3d` torch/_decomp/decompositions.py:1829:42: error[unresolved-attribute] Module `torch` has no member `contiguous_format` @@ -304,6 +335,38 @@ torch/_decomp/decompositions.py:1915:21: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:1916:21: error[unresolved-attribute] Module `torch` has no member `squeeze` torch/_decomp/decompositions.py:1926:28: error[unresolved-attribute] Module `torch` has no member `squeeze` torch/_decomp/decompositions.py:1938:23: error[unresolved-attribute] Module `torch` has no member `sqrt` +torch/_decomp/decompositions.py:2014:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2014:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2014:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2014:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_decomp/decompositions.py:2014:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2014:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2029:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2029:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2029:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2029:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2029:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2029:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:2029:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2029:81: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2033:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2033:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2033:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2033:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2033:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2033:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2033:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2045:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:2045:84: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_decomp/decompositions.py:2046:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_decomp/decompositions.py:2060:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2061:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2062:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2063:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2064:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2065:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_decomp/decompositions.py:2066:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2067:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_decomp/decompositions.py:2152:12: error[unresolved-attribute] Module `torch` has no member `empty` torch/_decomp/decompositions.py:2153:29: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_decomp/decompositions.py:2243:13: error[unresolved-attribute] Module `torch` has no member `rand_like` @@ -314,9 +377,37 @@ torch/_decomp/decompositions.py:2258:29: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:2260:36: error[unresolved-attribute] Module `torch` has no member `strided` torch/_decomp/decompositions.py:2273:20: error[unresolved-attribute] Module `torch` has no member `scalar_tensor` torch/_decomp/decompositions.py:2287:16: error[unresolved-attribute] Module `torch` has no member `clone` +torch/_decomp/decompositions.py:2316:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2317:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2318:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2319:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2320:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2321:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_decomp/decompositions.py:2322:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2323:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_decomp/decompositions.py:2327:54: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_decomp/decompositions.py:2332:37: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_decomp/decompositions.py:2424:18: error[unresolved-attribute] Module `torch` has no member `rsqrt` +torch/_decomp/decompositions.py:2527:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2528:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2529:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2530:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2531:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2532:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2533:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2534:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:2535:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2536:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | bool]` +torch/_decomp/decompositions.py:2554:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2555:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2556:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:2557:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2558:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2559:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2560:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:2561:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:2562:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:2563:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | bool]` torch/_decomp/decompositions.py:2595:16: error[unresolved-attribute] Module `torch` has no member `div` torch/_decomp/decompositions.py:2598:16: error[unresolved-attribute] Module `torch` has no member `div` torch/_decomp/decompositions.py:2601:18: error[unresolved-attribute] Module `torch` has no member `arange` @@ -327,8 +418,22 @@ torch/_decomp/decompositions.py:2619:22: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:2622:19: error[unresolved-attribute] Module `torch` has no member `minimum` torch/_decomp/decompositions.py:2638:16: error[unresolved-attribute] Module `torch` has no member `mean` torch/_decomp/decompositions.py:2650:20: error[unresolved-attribute] Module `torch` has no member `masked_fill` +torch/_decomp/decompositions.py:2692:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:2692:63: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_decomp/decompositions.py:2704:26: error[unresolved-attribute] Module `torch` has no member `int64` torch/_decomp/decompositions.py:2753:26: error[unresolved-attribute] Module `torch` has no member `int64` +torch/_decomp/decompositions.py:2858:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/_decomp/decompositions.py:2858:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[None | Tensor, ...]` +torch/_decomp/decompositions.py:2858:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/_decomp/decompositions.py:2858:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_decomp/decompositions.py:2883:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/_decomp/decompositions.py:2886:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_decomp/decompositions.py:2886:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_decomp/decompositions.py:2888:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_decomp/decompositions.py:2888:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_decomp/decompositions.py:2917:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/_decomp/decompositions.py:2917:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[None | Unknown | Tensor, ...]` +torch/_decomp/decompositions.py:2917:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_decomp/decompositions.py:2929:11: error[unresolved-attribute] Module `torch` has no member `minimum` torch/_decomp/decompositions.py:2930:9: error[unresolved-attribute] Module `torch` has no member `exp` torch/_decomp/decompositions.py:2930:20: error[unresolved-attribute] Module `torch` has no member `abs` @@ -337,6 +442,7 @@ torch/_decomp/decompositions.py:2944:25: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:3062:26: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:3062:52: error[unresolved-attribute] Module `torch` has no member `float32` torch/_decomp/decompositions.py:3063:64: error[unresolved-attribute] Module `torch` has no member `int64` +torch/_decomp/decompositions.py:3168:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_decomp/decompositions.py:3177:29: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/_decomp/decompositions.py:3222:12: error[unresolved-attribute] Module `torch` has no member `concat` torch/_decomp/decompositions.py:3271:11: error[unresolved-attribute] Module `torch` has no member `cat` @@ -344,6 +450,13 @@ torch/_decomp/decompositions.py:3272:18: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:3308:11: error[unresolved-attribute] Module `torch` has no member `cat` torch/_decomp/decompositions.py:3320:14: error[unresolved-attribute] Module `torch` has no member `zeros` torch/_decomp/decompositions.py:3321:14: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/_decomp/decompositions.py:3349:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/_decomp/decompositions.py:3350:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_decomp/decompositions.py:3351:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_decomp/decompositions.py:3353:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_decomp/decompositions.py:3355:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_decomp/decompositions.py:3356:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_decomp/decompositions.py:3357:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_decomp/decompositions.py:3398:21: error[unresolved-attribute] Module `torch` has no member `dropout` torch/_decomp/decompositions.py:3430:51: error[unresolved-attribute] Module `torch` has no member `tanh` torch/_decomp/decompositions.py:3432:17: error[unresolved-attribute] Module `torch` has no member `stack` @@ -377,14 +490,18 @@ torch/_decomp/decompositions.py:3942:18: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:3944:18: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:3972:13: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:3976:22: error[unresolved-attribute] Module `torch` has no member `int64` +torch/_decomp/decompositions.py:3991:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:3991:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | None]` torch/_decomp/decompositions.py:3999:18: error[unresolved-attribute] Module `torch` has no member `mul` torch/_decomp/decompositions.py:4011:25: error[unresolved-attribute] Module `torch` has no member `contiguous_format` +torch/_decomp/decompositions.py:4042:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` torch/_decomp/decompositions.py:4050:33: error[unresolved-attribute] Module `torch` has no member `long` torch/_decomp/decompositions.py:4050:45: error[unresolved-attribute] Module `torch` has no member `int` torch/_decomp/decompositions.py:4055:23: error[unresolved-attribute] Module `torch` has no member `bool` torch/_decomp/decompositions.py:4078:33: error[unresolved-attribute] Module `torch` has no member `long` torch/_decomp/decompositions.py:4078:45: error[unresolved-attribute] Module `torch` has no member `int` torch/_decomp/decompositions.py:4083:23: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_decomp/decompositions.py:4096:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/_decomp/decompositions.py:4124:19: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:4128:15: error[unresolved-attribute] Module `torch` has no member `gather` torch/_decomp/decompositions.py:4130:14: error[unresolved-attribute] Module `torch` has no member `where` @@ -433,6 +550,8 @@ torch/_decomp/decompositions.py:4575:16: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:4575:30: error[unresolved-attribute] Module `torch` has no member `mm` torch/_decomp/decompositions.py:4575:39: error[unresolved-attribute] Module `torch` has no member `unsqueeze` torch/_decomp/decompositions.py:4577:16: error[unresolved-attribute] Module `torch` has no member `mm` +torch/_decomp/decompositions.py:4611:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:4614:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/_decomp/decompositions.py:4709:9: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:4710:9: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:4723:14: error[unresolved-attribute] Module `torch` has no member `int64` @@ -444,25 +563,46 @@ torch/_decomp/decompositions.py:4742:47: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:4742:71: error[unresolved-attribute] Module `torch` has no member `int16` torch/_decomp/decompositions.py:4747:17: error[unresolved-attribute] Module `torch` has no member `clamp` torch/_decomp/decompositions.py:4748:17: error[unresolved-attribute] Module `torch` has no member `clamp` +torch/_decomp/decompositions.py:4749:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:4749:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | None]` torch/_decomp/decompositions.py:4754:27: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_decomp/decompositions.py:4760:23: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_decomp/decompositions.py:4807:19: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:4824:19: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:4825:16: error[unresolved-attribute] Module `torch` has no member `clamp` +torch/_decomp/decompositions.py:4854:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_decomp/decompositions.py:4878:24: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:4885:16: error[unresolved-attribute] Module `torch` has no member `logical_and` +torch/_decomp/decompositions.py:4909:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:4909:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_decomp/decompositions.py:4923:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` torch/_decomp/decompositions.py:4957:12: error[unresolved-attribute] Module `torch` has no member `amin` torch/_decomp/decompositions.py:4959:12: error[unresolved-attribute] Module `torch` has no member `amax` torch/_decomp/decompositions.py:4966:21: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:4966:33: error[unresolved-attribute] Module `torch` has no member `isnan` +torch/_decomp/decompositions.py:4966:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:4966:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/_decomp/decompositions.py:4966:76: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/_decomp/decompositions.py:4974:21: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_decomp/decompositions.py:4975:13: error[unresolved-attribute] Module `torch` has no member `layout` torch/_decomp/decompositions.py:4975:28: error[unresolved-attribute] Module `torch` has no member `strided` torch/_decomp/decompositions.py:4976:22: error[unresolved-attribute] Module `torch` has no member `device` +torch/_decomp/decompositions.py:4980:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_decomp/decompositions.py:4980:12: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | complex` +torch/_decomp/decompositions.py:4980:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_decomp/decompositions.py:4980:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:4980:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:4980:63: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/_decomp/decompositions.py:4989:21: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_decomp/decompositions.py:4990:13: error[unresolved-attribute] Module `torch` has no member `layout` torch/_decomp/decompositions.py:4990:28: error[unresolved-attribute] Module `torch` has no member `strided` torch/_decomp/decompositions.py:4991:22: error[unresolved-attribute] Module `torch` has no member `device` +torch/_decomp/decompositions.py:4995:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | complex` +torch/_decomp/decompositions.py:4995:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | complex` +torch/_decomp/decompositions.py:4995:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_decomp/decompositions.py:4995:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:4995:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:4995:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/_decomp/decompositions.py:5037:9: error[unresolved-attribute] Module `torch` has no member `gather` torch/_decomp/decompositions.py:5043:11: error[unresolved-attribute] Module `torch` has no member `arange` torch/_decomp/decompositions.py:5044:9: error[unresolved-attribute] Module `torch` has no member `where` @@ -475,10 +615,29 @@ torch/_decomp/decompositions.py:5084:13: error[unresolved-attribute] Module `tor torch/_decomp/decompositions.py:5085:17: error[unresolved-attribute] Module `torch` has no member `any` torch/_decomp/decompositions.py:5091:9: error[unresolved-attribute] Module `torch` has no member `where` torch/_decomp/decompositions.py:5128:9: error[unresolved-attribute] Module `torch` has no member `is_floating_point` +torch/_decomp/decompositions.py:5144:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5145:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5146:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5147:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_decomp/decompositions.py:5148:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_decomp/decompositions.py:5149:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_decomp/decompositions.py:5150:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_decomp/decompositions.py:5151:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | None` torch/_decomp/decompositions.py:5179:35: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/_decomp/decompositions.py:5201:14: error[unresolved-attribute] Module `torch` has no member `bmm` torch/_decomp/decompositions.py:5215:12: error[unresolved-attribute] Module `torch` has no member `div` torch/_decomp/decompositions.py:5227:21: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_decomp/decompositions.py:5231:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5231:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:5231:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:5233:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5233:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_decomp/decompositions.py:5233:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_decomp/decompositions.py:5233:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5243:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5243:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_decomp/decompositions.py:5245:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_decomp/decompositions.py:5245:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` torch/_decomp/decompositions.py:5253:18: error[unresolved-attribute] Module `torch` has no member `float` torch/_decomp/decompositions.py:5253:44: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_decomp/decompositions.py:5263:20: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -535,7 +694,10 @@ torch/_decomp/decompositions_for_jvp.py:286:23: error[unresolved-attribute] Modu torch/_decomp/decompositions_for_jvp.py:291:21: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_decomp/decompositions_for_rng.py:33:36: error[unresolved-attribute] Module `torch` has no member `strided` torch/_decomp/decompositions_for_rng.py:37:22: error[unresolved-attribute] Module `torch` has no member `float32` +torch/_decomp/decompositions_for_rng.py:39:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_decomp/decompositions_for_rng.py:39:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/_decomp/decompositions_for_rng.py:52:19: error[unresolved-attribute] Module `torch` has no member `preserve_format` +torch/_decomp/decompositions_for_rng.py:60:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` torch/_decomp/decompositions_for_rng.py:78:21: error[unresolved-attribute] Module `torch` has no member `tensor` torch/_decomp/decompositions_for_rng.py:79:28: error[unresolved-attribute] Module `torch` has no member `tensor` torch/_decomp/decompositions_for_rng.py:102:16: error[unresolved-attribute] Module `torch` has no member `stack` @@ -566,8 +728,16 @@ torch/_dynamo/__init__.py:153:9: warning[possibly-missing-attribute] Submodule ` torch/_dynamo/__init__.py:160:9: warning[possibly-missing-attribute] Submodule `_autograd` may not be available as an attribute on module `torch._C` torch/_dynamo/_trace_wrapped_higher_order_op.py:35:22: error[unresolved-import] Module `torch._C` has no member `DispatchKey` torch/_dynamo/_trace_wrapped_higher_order_op.py:59:12: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/_dynamo/_trace_wrapped_higher_order_op.py:60:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_dynamo/_trace_wrapped_higher_order_op.py:60:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_dynamo/_trace_wrapped_higher_order_op.py:60:58: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/_dynamo/_trace_wrapped_higher_order_op.py:88:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_dynamo/_trace_wrapped_higher_order_op.py:100:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_dynamo/_trace_wrapped_higher_order_op.py:100:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` torch/_dynamo/_trace_wrapped_higher_order_op.py:121:6: warning[possibly-missing-attribute] Submodule `_export` may not be available as an attribute on module `torch` torch/_dynamo/_trace_wrapped_higher_order_op.py:139:22: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` +torch/_dynamo/_trace_wrapped_higher_order_op.py:147:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/_dynamo/_trace_wrapped_higher_order_op.py:147:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/_dynamo/_trace_wrapped_higher_order_op.py:171:12: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_dynamo/_trace_wrapped_higher_order_op.py:215:40: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/_dynamo/_trace_wrapped_higher_order_op.py:247:17: error[invalid-assignment] Object of type `list[Any]` is not assignable to `tuple[Any, ...]` @@ -648,10 +818,12 @@ torch/_dynamo/convert_frame.py:311:22: error[unresolved-attribute] Module `torch torch/_dynamo/convert_frame.py:313:37: error[unresolved-attribute] Module `torch._C` has no member `_get_fp32_precision_getter` torch/_dynamo/convert_frame.py:317:13: error[invalid-assignment] Implicit shadowing of function `_forward_from_src` torch/_dynamo/convert_frame.py:449:47: error[invalid-argument-type] Argument to function `write_record_to_file` is incorrect: Expected `ExecutionRecord`, found `object` -torch/_dynamo/convert_frame.py:473:21: error[unresolved-attribute] Object of type `(...) -> _T@cprofile_wrapper` has no attribute `__name__` -torch/_dynamo/convert_frame.py:489:13: error[unresolved-attribute] Object of type `(...) -> _T@cprofile_wrapper` has no attribute `__name__` +torch/_dynamo/convert_frame.py:473:21: error[unresolved-attribute] Object of type `(**_P@cprofile_wrapper) -> _T@cprofile_wrapper` has no attribute `__name__` +torch/_dynamo/convert_frame.py:489:13: error[unresolved-attribute] Object of type `(**_P@cprofile_wrapper) -> _T@cprofile_wrapper` has no attribute `__name__` torch/_dynamo/convert_frame.py:628:13: error[no-matching-overload] No overload of function `dirname` matches arguments torch/_dynamo/convert_frame.py:1247:6: error[invalid-return-type] Function can implicitly return `None`, which is not assignable to return type `DynamoOutput` +torch/_dynamo/convert_frame.py:1374:33: error[missing-argument] No argument provided for required parameter `cls` +torch/_dynamo/convert_frame.py:1374:33: error[missing-argument] No argument provided for required parameter `cls` torch/_dynamo/convert_frame.py:1938:51: error[invalid-argument-type] Argument to function `format_list` is incorrect: Expected `Iterable[FrameSummary | tuple[str, int, str, str | None]]`, found `object` torch/_dynamo/convert_frame.py:2132:25: error[call-non-callable] Object of type `object` is not callable torch/_dynamo/create_parameter_op.py:43:35: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -1004,6 +1176,89 @@ torch/_dynamo/utils.py:865:25: error[unresolved-attribute] Module `torch` has no torch/_dynamo/utils.py:865:38: error[unresolved-attribute] Module `torch` has no member `short` torch/_dynamo/utils.py:866:5: error[unresolved-attribute] Module `torch` has no member `BoolTensor` torch/_dynamo/utils.py:866:24: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `list[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `list[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `dict[str, bool] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `int | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `set[str] | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `bool | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` +torch/_dynamo/utils.py:1490:20: error[invalid-argument-type] Argument is incorrect: Expected `str | None`, found `Unknown | int | float | None` torch/_dynamo/utils.py:1665:18: error[unresolved-import] Cannot resolve imported module `torch._inductor.fb.remote_cache` torch/_dynamo/utils.py:1680:22: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` torch/_dynamo/utils.py:1901:36: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` @@ -1063,10 +1318,10 @@ torch/_dynamo/utils.py:3325:27: warning[possibly-missing-attribute] Submodule `o torch/_dynamo/utils.py:3542:32: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_pystub` torch/_dynamo/utils.py:3880:44: error[unresolved-attribute] Object of type `(...) -> Any` has no attribute `__code__` torch/_dynamo/utils.py:3980:16: error[unresolved-attribute] Module `torch` has no member `as_tensor` -torch/_dynamo/utils.py:3992:38: error[unresolved-attribute] Object of type `(...) -> R@numpy_to_tensor_wrapper` has no attribute `__name__` -torch/_dynamo/utils.py:3995:47: warning[possibly-missing-attribute] Attribute `__name__` may be missing on object of type `Unknown | ((...) -> R@numpy_to_tensor_wrapper)` +torch/_dynamo/utils.py:3992:38: error[unresolved-attribute] Object of type `(**_P@numpy_to_tensor_wrapper) -> R@numpy_to_tensor_wrapper` has no attribute `__name__` +torch/_dynamo/utils.py:3995:47: warning[possibly-missing-attribute] Attribute `__name__` may be missing on object of type `Unknown | ((**_P@numpy_to_tensor_wrapper) -> R@numpy_to_tensor_wrapper)` torch/_dynamo/utils.py:4035:36: error[unresolved-attribute] Object of type `(...) -> Any` has no attribute `__name__` -torch/_dynamo/utils.py:4044:16: error[invalid-assignment] Object of type `GeneratorType[ndarray | (@Todo & ~Tensor), None, None]` is not assignable to `tuple[@Todo, ...]` +torch/_dynamo/utils.py:4044:16: error[invalid-assignment] Object of type `GeneratorType[ndarray | ~Tensor, None, None]` is not assignable to `_P@numpy_operator_wrapper.args` torch/_dynamo/utils.py:4054:11: warning[possibly-missing-attribute] Submodule `_prims_common` may not be available as an attribute on module `torch` torch/_dynamo/utils.py:4055:13: warning[possibly-missing-attribute] Submodule `_prims_common` may not be available as an attribute on module `torch` torch/_dynamo/utils.py:4072:9: error[unresolved-attribute] Module `torch` has no member `empty_strided` @@ -1303,6 +1558,7 @@ torch/_dynamo/variables/higher_order_ops.py:669:9: error[unresolved-attribute] O torch/_dynamo/variables/higher_order_ops.py:1029:50: error[unresolved-attribute] Object of type `tuple[Node]` has no attribute `values` torch/_dynamo/variables/higher_order_ops.py:1065:32: error[unresolved-attribute] Object of type `tuple[Node]` has no attribute `values` torch/_dynamo/variables/higher_order_ops.py:1210:23: warning[possibly-missing-attribute] Submodule `output_graph` may not be available as an attribute on module `torch._dynamo` +torch/_dynamo/variables/higher_order_ops.py:1314:49: error[invalid-argument-type] Argument is incorrect: Expected `SubgraphTracer`, found `Unknown | None` torch/_dynamo/variables/higher_order_ops.py:1361:21: warning[possibly-missing-attribute] Attribute `append` may be missing on object of type `list[Unknown] | tuple[Unknown, ...]` torch/_dynamo/variables/higher_order_ops.py:1410:44: error[invalid-argument-type] Argument to function `validate_subgraph_output_types` is incorrect: Expected `VariableTracker`, found `tuple[Unknown, ...]` torch/_dynamo/variables/higher_order_ops.py:1603:29: error[invalid-argument-type] Argument is incorrect: Expected `TreeSpec`, found `None | Unknown` @@ -1351,6 +1607,7 @@ torch/_dynamo/variables/higher_order_ops.py:3679:14: warning[possibly-missing-at torch/_dynamo/variables/higher_order_ops.py:3708:9: error[invalid-method-override] Invalid override of method `call_function`: Definition is incompatible with `VariableTracker.call_function` torch/_dynamo/variables/higher_order_ops.py:3754:22: warning[possibly-missing-attribute] Submodule `output_graph` may not be available as an attribute on module `torch._dynamo` torch/_dynamo/variables/higher_order_ops.py:3814:22: warning[possibly-missing-attribute] Submodule `output_graph` may not be available as an attribute on module `torch._dynamo` +torch/_dynamo/variables/higher_order_ops.py:3854:33: error[invalid-argument-type] Argument is incorrect: Expected `((...) -> Any) | str | None`, found `UserFunctionVariable` torch/_dynamo/variables/higher_order_ops.py:3869:20: warning[possibly-missing-attribute] Submodule `exc` may not be available as an attribute on module `torch._dynamo` torch/_dynamo/variables/higher_order_ops.py:3871:24: warning[possibly-missing-attribute] Submodule `exc` may not be available as an attribute on module `torch._dynamo` torch/_dynamo/variables/higher_order_ops.py:3875:34: warning[possibly-missing-attribute] Submodule `output_graph` may not be available as an attribute on module `torch._dynamo` @@ -1476,6 +1733,7 @@ torch/_dynamo/variables/nn_module.py:1058:20: error[unresolved-attribute] Object torch/_dynamo/variables/nn_module.py:1059:24: error[unresolved-attribute] Object of type `object` has no attribute `_call_impl` torch/_dynamo/variables/nn_module.py:1060:17: error[unresolved-attribute] Object of type `object` has no attribute `__call__` torch/_dynamo/variables/nn_module.py:1061:17: error[unresolved-attribute] Object of type `object` has no attribute `_call_impl` +torch/_dynamo/variables/nn_module.py:1089:70: error[invalid-argument-type] Argument is incorrect: Expected `Module`, found `object` torch/_dynamo/variables/optimizer.py:125:27: error[call-non-callable] Object of type `object` is not callable torch/_dynamo/variables/optimizer.py:156:26: error[unresolved-attribute] Object of type `object` has no attribute `param_groups` torch/_dynamo/variables/optimizer.py:169:18: error[unresolved-attribute] Object of type `object` has no attribute `param_groups` @@ -1766,6 +2024,7 @@ torch/_export/converter.py:103:9: error[unresolved-attribute] Module `torch._C` torch/_export/converter.py:105:17: error[unresolved-attribute] Module `torch._C` has no member `_propagate_and_assign_input_shapes` torch/_export/converter.py:111:5: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_onnx_lint` torch/_export/converter.py:120:5: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_onnx_function_substitution` +torch/_export/converter.py:157:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal["trunc"]` torch/_export/converter.py:197:5: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_export/converter.py:198:5: error[unresolved-attribute] Module `torch` has no member `int8` torch/_export/converter.py:199:5: error[unresolved-attribute] Module `torch` has no member `int16` @@ -1994,6 +2253,15 @@ torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:165:28: err torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:231:26: error[unresolved-attribute] Module `torch` has no member `qint8` torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:231:39: error[unresolved-attribute] Module `torch` has no member `quint8` torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:240:23: error[unresolved-attribute] Module `torch` has no member `per_channel_affine` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:280:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:280:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:283:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:284:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:285:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:286:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:287:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:288:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:290:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:499:52: error[invalid-argument-type] Argument to function `insert_fused_activation_node` is incorrect: Expected `str`, found `object` torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:512:9: error[unresolved-attribute] Module `torch` has no member `per_tensor_affine` torch/_export/passes/replace_quantized_ops_with_standard_ops_pass.py:523:9: error[unresolved-attribute] Module `torch` has no member `per_tensor_affine` @@ -2286,12 +2554,13 @@ torch/_functorch/_aot_autograd/utils.py:523:26: warning[possibly-missing-attribu torch/_functorch/_aot_autograd/utils.py:525:21: warning[possibly-missing-attribute] Submodule `proxy_tensor` may not be available as an attribute on module `torch.fx.experimental` torch/_functorch/_aot_autograd/utils.py:545:17: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_functorch/_aot_autograd/utils.py:563:12: warning[possibly-missing-attribute] Submodule `_autograd` may not be available as an attribute on module `torch._C` +torch/_functorch/_aot_autograd/utils.py:601:12: error[invalid-return-type] Return type does not match returned value: expected `((**_P2@simple_wraps) -> _R2@simple_wraps, /) -> (**_P2@simple_wraps) -> _R2@simple_wraps`, found `_Wrapper[_P@simple_wraps, Unknown]` torch/_functorch/aot_autograd.py:564:16: warning[possibly-missing-attribute] Submodule `_functorch` may not be available as an attribute on module `torch` torch/_functorch/aot_autograd.py:598:25: error[invalid-argument-type] Method `__getitem__` of type `Overload[(i: SupportsIndex, /) -> InputAliasInfo, (s: slice[Any, Any, Any], /) -> list[InputAliasInfo]]` cannot be called with key of type `int | None` on object of type `list[InputAliasInfo]` torch/_functorch/aot_autograd.py:785:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` torch/_functorch/aot_autograd.py:786:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` torch/_functorch/aot_autograd.py:788:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` -torch/_functorch/aot_autograd.py:789:9: error[invalid-argument-type] Argument is incorrect: Expected `dict[OpOverload[Unknown, Any], (...) -> Unknown]`, found `dict[Unknown, Unknown] | None` +torch/_functorch/aot_autograd.py:789:9: error[invalid-argument-type] Argument is incorrect: Expected `dict[OpOverload[EllipsisType, Any], (...) -> Unknown]`, found `dict[Unknown, Unknown] | None` torch/_functorch/aot_autograd.py:871:58: error[invalid-argument-type] Argument to function `assert_no_fake_params_or_buffers` is incorrect: Expected `GraphModule`, found `Module` torch/_functorch/aot_autograd.py:881:33: error[parameter-already-assigned] Multiple values provided for parameter `num_params_buffers` of function `aot_function` torch/_functorch/aot_autograd.py:970:27: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` @@ -2317,7 +2586,7 @@ torch/_functorch/aot_autograd.py:1550:9: error[invalid-argument-type] Argument t torch/_functorch/aot_autograd.py:1710:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` torch/_functorch/aot_autograd.py:1711:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` torch/_functorch/aot_autograd.py:1713:9: error[invalid-argument-type] Argument is incorrect: Expected `(...) -> Unknown`, found `None` -torch/_functorch/aot_autograd.py:1714:9: error[invalid-argument-type] Argument is incorrect: Expected `dict[OpOverload[Unknown, Any], (...) -> Unknown]`, found `dict[Unknown, Unknown] | None` +torch/_functorch/aot_autograd.py:1714:9: error[invalid-argument-type] Argument is incorrect: Expected `dict[OpOverload[EllipsisType, Any], (...) -> Unknown]`, found `dict[Unknown, Unknown] | None` torch/_functorch/aot_autograd.py:1749:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[GraphModule, ViewAndMutationMeta, TreeSpec, TreeSpec]`, found `tuple[(...) -> Unknown, ViewAndMutationMeta, TreeSpec, TreeSpec | None]` torch/_functorch/apis.py:213:19: error[invalid-assignment] Implicit shadowing of function `wrapped` torch/_functorch/apis.py:409:19: error[invalid-assignment] Implicit shadowing of function `wrapper` @@ -2338,14 +2607,14 @@ torch/_functorch/compilers.py:52:9: error[unresolved-attribute] Module `torch._C torch/_functorch/compilers.py:82:34: error[unresolved-attribute] Module `torch` has no member `device` torch/_functorch/compilers.py:93:9: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_remove_mutation` torch/_functorch/compilers.py:127:44: error[invalid-argument-type] Argument to function `bind_symbols` is incorrect: Expected `GraphModule`, found `Unknown | Module` -torch/_functorch/compilers.py:228:45: error[invalid-argument-type] Argument to function `get_decompositions` is incorrect: Expected `Sequence[OperatorBase | OpOverloadPacket[Unknown, Any]]`, found `set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `(...) -> Unknown`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `((...) -> Unknown) | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `(...) -> Unknown`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `dict[Unknown, Unknown] | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `int`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `bool`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` -torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `((...) -> Unknown) | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:228:45: error[invalid-argument-type] Argument to function `get_decompositions` is incorrect: Expected `Sequence[OperatorBase | OpOverloadPacket[EllipsisType, Any]]`, found `set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `(...) -> Unknown`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `((...) -> Unknown) | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `(...) -> Unknown`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `dict[Unknown, Unknown] | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `int`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `bool`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:273:33: error[invalid-argument-type] Argument to function `aot_function` is incorrect: Expected `((...) -> Unknown) | None`, found `Unknown | ((joint_module: GraphModule, _joint_inputs, compiler=Literal["inductor"], *, num_fwd_outputs, static_lifetime_input_indices: list[int] | None = None) -> tuple[GraphModule, GraphModule]) | set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` torch/_functorch/compilers.py:298:10: error[unresolved-import] Cannot resolve imported module `foo` torch/_functorch/compilers.py:319:30: error[unresolved-attribute] Module `random` has no member `rand` torch/_functorch/compilers.py:323:21: error[unresolved-attribute] Module `torch` has no member `int` @@ -2359,7 +2628,7 @@ torch/_functorch/compilers.py:334:29: error[unresolved-attribute] Module `torch` torch/_functorch/compilers.py:419:16: error[missing-argument] No argument provided for required parameter `num_fwd_outputs` of function `default_partition` torch/_functorch/compilers.py:424:9: error[invalid-argument-type] Argument to function `aot_module_simplified` is incorrect: Expected `AOTDispatchCompiler`, found `def graph_saver_forward(gm, fw_args) -> Unknown` torch/_functorch/compilers.py:425:9: error[invalid-argument-type] Argument to function `aot_module_simplified` is incorrect: Expected `AOTDispatchCompiler | None`, found `def graph_saver_backward(gm, bw_args) -> Unknown` -torch/_functorch/compilers.py:427:9: error[invalid-argument-type] Argument to function `aot_module_simplified` is incorrect: Expected `dict[Unknown, Unknown] | None`, found `set[Unknown | OpOverloadPacket[Unknown, Any] | OpOverload[Unknown, Any]] | dict[OperatorBase, (...) -> Unknown]` +torch/_functorch/compilers.py:427:9: error[invalid-argument-type] Argument to function `aot_module_simplified` is incorrect: Expected `dict[Unknown, Unknown] | None`, found `set[Unknown | OpOverloadPacket[EllipsisType, Any] | OpOverload[EllipsisType, Any]] | dict[OperatorBase, (...) -> Unknown]` torch/_functorch/eager_transforms.py:17:5: error[unresolved-import] Module `torch._C._functorch` has no member `_assert_wrapped_functional` torch/_functorch/eager_transforms.py:18:5: error[unresolved-import] Module `torch._C._functorch` has no member `_func_decrement_nesting` torch/_functorch/eager_transforms.py:19:5: error[unresolved-import] Module `torch._C._functorch` has no member `_func_increment_nesting` @@ -2403,13 +2672,19 @@ torch/_functorch/make_functional.py:612:25: error[unresolved-attribute] Module ` torch/_functorch/partitioners.py:156:17: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_functorch/partitioners.py:313:13: error[unresolved-attribute] Object of type `object` has no attribute `is_mutable` torch/_functorch/partitioners.py:327:13: error[unresolved-attribute] Object of type `object` has no attribute `is_mutable` +torch/_functorch/partitioners.py:388:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_functorch/partitioners.py:388:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/_functorch/partitioners.py:394:30: error[unresolved-attribute] Module `torch` has no member `float64` torch/_functorch/partitioners.py:397:36: error[unresolved-attribute] Module `torch` has no member `float64` +torch/_functorch/partitioners.py:408:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_functorch/partitioners.py:430:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_functorch/partitioners.py:436:29: error[unresolved-attribute] Module `torch` has no member `float32` torch/_functorch/partitioners.py:440:35: error[unresolved-attribute] Module `torch` has no member `float32` torch/_functorch/partitioners.py:450:17: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_functorch/partitioners.py:458:25: error[unresolved-attribute] Module `torch` has no member `float32` torch/_functorch/partitioners.py:461:31: error[unresolved-attribute] Module `torch` has no member `float32` +torch/_functorch/partitioners.py:483:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_functorch/partitioners.py:494:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_functorch/partitioners.py:533:34: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_functorch/partitioners.py:534:22: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` torch/_functorch/partitioners.py:547:22: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` @@ -2483,10 +2758,38 @@ torch/_higher_order_ops/aoti_call_delegate.py:63:29: error[unresolved-attribute] torch/_higher_order_ops/associative_scan.py:10:22: error[unresolved-import] Module `torch._C` has no member `DispatchKey` torch/_higher_order_ops/associative_scan.py:58:15: error[unresolved-attribute] Module `torch` has no member `stack` torch/_higher_order_ops/associative_scan.py:59:19: error[unresolved-attribute] Module `torch` has no member `flatten` +torch/_higher_order_ops/associative_scan.py:63:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:63:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_higher_order_ops/associative_scan.py:240:18: error[unresolved-attribute] Module `torch` has no member `movedim` torch/_higher_order_ops/associative_scan.py:243:22: error[unresolved-attribute] Module `torch` has no member `flip` torch/_higher_order_ops/associative_scan.py:295:40: error[unresolved-attribute] Module `torch` has no member `movedim` +torch/_higher_order_ops/associative_scan.py:360:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:360:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_higher_order_ops/associative_scan.py:360:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-1]` +torch/_higher_order_ops/associative_scan.py:360:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_higher_order_ops/associative_scan.py:361:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:361:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_higher_order_ops/associative_scan.py:361:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_higher_order_ops/associative_scan.py:361:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_higher_order_ops/associative_scan.py:370:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:370:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_higher_order_ops/associative_scan.py:370:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-1]` +torch/_higher_order_ops/associative_scan.py:371:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:371:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_higher_order_ops/associative_scan.py:371:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_higher_order_ops/associative_scan.py:371:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_higher_order_ops/associative_scan.py:377:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:377:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` +torch/_higher_order_ops/associative_scan.py:377:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_higher_order_ops/associative_scan.py:377:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` torch/_higher_order_ops/associative_scan.py:384:13: error[unresolved-attribute] Module `torch` has no member `cat` +torch/_higher_order_ops/associative_scan.py:384:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:384:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_higher_order_ops/associative_scan.py:384:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_higher_order_ops/associative_scan.py:389:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/_higher_order_ops/associative_scan.py:389:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_higher_order_ops/associative_scan.py:389:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_higher_order_ops/associative_scan.py:458:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_higher_order_ops/associative_scan.py:673:35: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_tls_local_include_set` torch/_higher_order_ops/associative_scan.py:674:35: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_tls_local_exclude_set` torch/_higher_order_ops/associative_scan.py:676:14: error[unresolved-attribute] Module `torch._C` has no member `_AutoDispatchBelowAutograd` @@ -2503,6 +2806,11 @@ torch/_higher_order_ops/auto_functionalize.py:12:22: error[unresolved-import] Mo torch/_higher_order_ops/auto_functionalize.py:32:32: error[unresolved-attribute] Module `torch` has no member `FunctionSchema` torch/_higher_order_ops/auto_functionalize.py:54:8: error[unresolved-attribute] Module `torch` has no member `is_inference_mode_enabled` torch/_higher_order_ops/auto_functionalize.py:84:16: error[unresolved-attribute] Module `torch` has no member `as_strided` +torch/_higher_order_ops/auto_functionalize.py:106:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_higher_order_ops/auto_functionalize.py:106:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | SymInt` +torch/_higher_order_ops/auto_functionalize.py:106:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | SymInt` +torch/_higher_order_ops/auto_functionalize.py:106:64: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | SymInt` +torch/_higher_order_ops/auto_functionalize.py:116:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_higher_order_ops/auto_functionalize.py:173:29: error[unresolved-attribute] Module `torch` has no member `Type` torch/_higher_order_ops/auto_functionalize.py:251:29: error[unresolved-attribute] Module `torch` has no member `Type` torch/_higher_order_ops/auto_functionalize.py:428:14: warning[possibly-missing-attribute] Attribute `_schema` may be missing on object of type `OperatorBase | HopInstance` @@ -2515,7 +2823,7 @@ torch/_higher_order_ops/auto_functionalize.py:461:28: error[unresolved-attribute torch/_higher_order_ops/auto_functionalize.py:480:63: error[unresolved-attribute] Module `torch` has no member `Type` torch/_higher_order_ops/auto_functionalize.py:485:12: warning[possibly-missing-attribute] Submodule `functional_tensor` may not be available as an attribute on module `torch._subclasses` torch/_higher_order_ops/auto_functionalize.py:599:12: warning[possibly-missing-attribute] Submodule `functional_tensor` may not be available as an attribute on module `torch._subclasses` -torch/_higher_order_ops/auto_functionalize.py:614:10: error[invalid-assignment] Object of type `Unknown | HigherOrderOperator | (OpOverload[Unknown, Any] & ~HopInstance)` is not assignable to `OpOverload[Unknown, Any] | HopInstance` +torch/_higher_order_ops/auto_functionalize.py:614:10: error[invalid-assignment] Object of type `Unknown | HigherOrderOperator | (OpOverload[EllipsisType, Any] & ~HopInstance)` is not assignable to `OpOverload[EllipsisType, Any] | HopInstance` torch/_higher_order_ops/auto_functionalize.py:854:17: error[unresolved-attribute] Module `torch._C` has no member `FunctionSchema` torch/_higher_order_ops/base_hop.py:7:22: error[unresolved-import] Module `torch._C` has no member `DispatchKey` torch/_higher_order_ops/base_hop.py:226:14: error[unresolved-attribute] Module `torch._C` has no member `_AutoDispatchBelowAutograd` @@ -2536,6 +2844,8 @@ torch/_higher_order_ops/effects.py:35:16: error[invalid-return-type] Return type torch/_higher_order_ops/effects.py:50:13: warning[possibly-missing-attribute] Submodule `simple_registry` may not be available as an attribute on module `torch._library` torch/_higher_order_ops/effects.py:57:13: warning[possibly-missing-attribute] Submodule `simple_registry` may not be available as an attribute on module `torch._library` torch/_higher_order_ops/effects.py:130:12: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/_higher_order_ops/effects.py:140:14: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Any, ...]` +torch/_higher_order_ops/effects.py:140:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `dict[str, Any]` torch/_higher_order_ops/effects.py:201:61: error[unresolved-attribute] Module `torch` has no member `FunctionSchema` torch/_higher_order_ops/effects.py:243:29: error[unresolved-attribute] Module `torch._C` has no member `_get_dispatch_mode` torch/_higher_order_ops/effects.py:244:13: error[unresolved-attribute] Module `torch._C` has no member `_TorchDispatchModeKey` @@ -2911,6 +3221,7 @@ torch/_inductor/autotune_process.py:362:13: error[unresolved-attribute] Module ` torch/_inductor/autotune_process.py:363:12: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/autotune_process.py:364:12: warning[possibly-missing-attribute] Submodule `_prims_common` may not be available as an attribute on module `torch` torch/_inductor/autotune_process.py:365:14: warning[possibly-missing-attribute] Submodule `_prims_common` may not be available as an attribute on module `torch` +torch/_inductor/autotune_process.py:374:51: error[invalid-argument-type] Argument to bound method `from_irnodes` is incorrect: Expected `Layout | Buffer | Sequence[Layout | Buffer]`, found `object` torch/_inductor/autotune_process.py:654:13: warning[possibly-missing-attribute] Submodule `runtime` may not be available as an attribute on module `torch._inductor` torch/_inductor/autotune_process.py:751:30: error[unresolved-attribute] Module `torch` has no member `zeros` torch/_inductor/autotune_process.py:753:23: error[unresolved-attribute] Module `torch` has no member `float64` @@ -3019,7 +3330,6 @@ torch/_inductor/codegen/common.py:1642:19: error[unresolved-attribute] Module `t torch/_inductor/codegen/common.py:1656:17: error[invalid-assignment] Object of type `Integer` is not assignable to `int` torch/_inductor/codegen/common.py:1658:20: error[invalid-argument-type] Method `__getitem__` of type `bound method dict[Expr, str].__getitem__(key: Expr, /) -> str` cannot be called with key of type `int` on object of type `dict[Expr, str]` torch/_inductor/codegen/common.py:1663:9: error[invalid-assignment] Invalid subscript assignment with key of type `int` and value of type `str` on object of type `dict[Expr, str]` -torch/_inductor/codegen/common.py:1671:35: error[invalid-argument-type] Argument to function `_lookup` is incorrect: Expected `dict[Symbol, str | RemovedArg] | dict[Symbol, str]`, found `dict[Expr, str]` torch/_inductor/codegen/common.py:1674:16: error[invalid-return-type] Return type does not match returned value: expected `Iterator[str]`, found `chain[str | Expr]` torch/_inductor/codegen/common.py:1690:45: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/codegen/common.py:1697:48: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -3082,6 +3392,7 @@ torch/_inductor/codegen/cpp.py:213:40: error[unresolved-attribute] Module `torch torch/_inductor/codegen/cpp.py:226:28: error[unresolved-attribute] Module `torch` has no member `bool` torch/_inductor/codegen/cpp.py:255:37: error[unresolved-attribute] Module `torch` has no member `bool` torch/_inductor/codegen/cpp.py:331:12: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_inductor/codegen/cpp.py:514:17: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `list[FusedSchedulerNode | SchedulerNode]`, found `list[Unknown] | list[Unknown | BaseSchedulerNode]` torch/_inductor/codegen/cpp.py:704:9: error[invalid-method-override] Invalid override of method `add`: Definition is incompatible with `OpsHandler.add` torch/_inductor/codegen/cpp.py:708:9: error[invalid-method-override] Invalid override of method `sub`: Definition is incompatible with `OpsHandler.sub` torch/_inductor/codegen/cpp.py:712:9: error[invalid-method-override] Invalid override of method `mul`: Definition is incompatible with `OpsHandler.mul` @@ -3598,6 +3909,8 @@ torch/_inductor/codegen/cpp_wrapper_cpu.py:362:18: error[unresolved-attribute] O torch/_inductor/codegen/cpp_wrapper_cpu.py:372:32: error[invalid-argument-type] Argument to function `codegen_symbol` is incorrect: Expected `Expr`, found `int | Expr` torch/_inductor/codegen/cpp_wrapper_cpu.py:697:25: error[call-non-callable] Object of type `object` is not callable torch/_inductor/codegen/cpp_wrapper_cpu.py:725:25: error[call-non-callable] Object of type `object` is not callable +torch/_inductor/codegen/cpp_wrapper_cpu.py:835:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/codegen/cpp_wrapper_cpu.py:881:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/codegen/cpp_wrapper_cpu.py:1073:22: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/codegen/cpp_wrapper_cpu.py:1078:21: error[unresolved-attribute] Module `torch` has no member `float16` torch/_inductor/codegen/cpp_wrapper_cpu.py:1078:47: error[unresolved-attribute] Module `torch` has no member `bfloat16` @@ -4263,9 +4576,6 @@ torch/_inductor/codegen/halide.py:1200:20: error[unresolved-attribute] Module `t torch/_inductor/codegen/halide.py:1299:9: error[invalid-method-override] Invalid override of method `scan`: Definition is incompatible with `Kernel.scan` torch/_inductor/codegen/halide.py:1301:23: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/codegen/halide.py:1693:43: error[unresolved-attribute] Module `torch` has no member `device` -torch/_inductor/codegen/memory_planning.py:228:35: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? -torch/_inductor/codegen/memory_planning.py:229:33: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? -torch/_inductor/codegen/memory_planning.py:230:37: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[()]`? torch/_inductor/codegen/memory_planning.py:387:13: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/codegen/memory_planning.py:467:27: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_inductor/codegen/memory_planning.py:489:27: error[unresolved-attribute] Module `torch` has no member `device` @@ -4473,6 +4783,10 @@ torch/_inductor/codegen/simd.py:1817:31: error[unresolved-attribute] Module `tor torch/_inductor/codegen/simd.py:2673:27: error[invalid-argument-type] Argument to function `sympy_product` is incorrect: Expected `Iterable[Expr]`, found `list[int | Unknown]` torch/_inductor/codegen/simd.py:2678:27: error[invalid-argument-type] Argument to function `sympy_product` is incorrect: Expected `Iterable[Expr]`, found `list[int | Unknown]` torch/_inductor/codegen/simd.py:2703:28: error[invalid-return-type] Return type does not match returned value: expected `tuple[list[int], list[int]]`, found `tuple[list[int | (Expr & ~AlwaysFalsy)], list[int]]` +torch/_inductor/codegen/simd.py:2809:35: error[invalid-argument-type] Argument to bound method `create_tiling` is incorrect: Expected `Sequence[Expr]`, found `list[int]` +torch/_inductor/codegen/simd.py:2809:45: error[invalid-argument-type] Argument to bound method `create_tiling` is incorrect: Expected `Sequence[Expr]`, found `list[int]` +torch/_inductor/codegen/simd.py:2812:46: error[invalid-argument-type] Argument to bound method `create_tiling` is incorrect: Expected `Sequence[Expr]`, found `list[int]` +torch/_inductor/codegen/simd.py:2812:56: error[invalid-argument-type] Argument to bound method `create_tiling` is incorrect: Expected `Sequence[Expr]`, found `list[int]` torch/_inductor/codegen/simd.py:3017:70: error[invalid-argument-type] Argument to bound method `statically_known_multiple_of` is incorrect: Expected `Expr`, found `Expr | Literal[1]` torch/_inductor/codegen/simd.py:3027:24: error[invalid-return-type] Return type does not match returned value: expected `dict[str, Expr] | None`, found `dict[Unknown | str, Unknown | Expr | int]` torch/_inductor/codegen/simd.py:3092:20: warning[possibly-missing-attribute] Attribute `replace` may be missing on object of type `Any | str | None` @@ -4832,6 +5146,7 @@ torch/_inductor/compile_worker/__main__.py:30:12: error[unresolved-import] Canno torch/_inductor/compile_worker/subproc_pool.py:446:9: warning[possibly-missing-attribute] Submodule `util` may not be available as an attribute on module `multiprocessing` torch/_inductor/compile_worker/subproc_pool.py:483:9: error[call-non-callable] Object of type `object` is not callable torch/_inductor/compile_worker/tracked_process_pool.py:81:24: warning[possibly-missing-attribute] Submodule `futures` may not be available as an attribute on module `concurrent` +torch/_inductor/compile_worker/tracked_process_pool.py:84:9: error[invalid-method-override] Invalid override of method `submit`: Definition is incompatible with `Executor.submit` torch/_inductor/compile_worker/utils.py:42:5: error[unresolved-attribute] Module `torch._C` has no member `_initCrashHandler` torch/_inductor/config.py:291:16: warning[possibly-missing-attribute] Submodule `scheduler` may not be available as an attribute on module `torch._inductor` torch/_inductor/config.py:292:15: warning[possibly-missing-attribute] Submodule `scheduler` may not be available as an attribute on module `torch._inductor` @@ -4922,6 +5237,19 @@ torch/_inductor/debug.py:1232:20: warning[possibly-missing-attribute] Submodule torch/_inductor/decomposition.py:195:16: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/decomposition.py:211:39: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_inductor/decomposition.py:230:12: error[unresolved-attribute] Module `torch` has no member `empty` +torch/_inductor/decomposition.py:249:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:249:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_inductor/decomposition.py:251:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:252:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:253:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:254:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_inductor/decomposition.py:255:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:256:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:257:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:258:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/decomposition.py:259:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_inductor/decomposition.py:260:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_inductor/decomposition.py:261:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | bool]` torch/_inductor/decomposition.py:277:25: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/decomposition.py:292:20: error[unresolved-attribute] Module `torch` has no member `sum` torch/_inductor/decomposition.py:304:25: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -4930,6 +5258,8 @@ torch/_inductor/decomposition.py:333:25: error[unresolved-attribute] Module `tor torch/_inductor/decomposition.py:351:33: error[unresolved-attribute] Module `torch` has no member `numel` torch/_inductor/decomposition.py:351:53: error[unresolved-attribute] Module `torch` has no member `numel` torch/_inductor/decomposition.py:359:20: error[unresolved-attribute] Module `torch` has no member `sum` +torch/_inductor/decomposition.py:415:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_inductor/decomposition.py:415:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_inductor/decomposition.py:434:16: error[unresolved-attribute] Module `torch` has no member `where` torch/_inductor/decomposition.py:435:13: error[unresolved-attribute] Module `torch` has no member `isnan` torch/_inductor/decomposition.py:435:48: error[unresolved-attribute] Module `torch` has no member `atan2` @@ -4950,6 +5280,8 @@ torch/_inductor/decomposition.py:548:16: error[unresolved-attribute] Module `tor torch/_inductor/decomposition.py:558:22: error[unresolved-attribute] Module `torch` has no member `bool` torch/_inductor/decomposition.py:559:16: error[unresolved-attribute] Module `torch` has no member `all` torch/_inductor/decomposition.py:570:12: error[unresolved-attribute] Module `torch` has no member `narrow` +torch/_inductor/decomposition.py:578:22: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:578:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int | SymInt]` torch/_inductor/decomposition.py:584:12: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/decomposition.py:607:21: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/decomposition.py:608:22: error[unresolved-attribute] Module `torch` has no member `layout` @@ -4967,13 +5299,56 @@ torch/_inductor/decomposition.py:653:42: error[unresolved-attribute] Module `tor torch/_inductor/decomposition.py:659:25: error[unresolved-attribute] Module `torch` has no member `preserve_format` torch/_inductor/decomposition.py:681:23: error[unresolved-attribute] Module `torch` has no member `rand` torch/_inductor/decomposition.py:686:23: error[unresolved-attribute] Module `torch` has no member `randn` +torch/_inductor/decomposition.py:707:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_inductor/decomposition.py:707:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_inductor/decomposition.py:707:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int | SymInt]` +torch/_inductor/decomposition.py:716:79: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:718:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:718:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/decomposition.py:736:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:736:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:736:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:736:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:739:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:740:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:741:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:743:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:744:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:745:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_inductor/decomposition.py:752:37: error[unresolved-attribute] Module `torch` has no member `int32` torch/_inductor/decomposition.py:754:64: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/decomposition.py:756:64: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/decomposition.py:760:32: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/decomposition.py:778:21: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/decomposition.py:780:43: error[unresolved-attribute] Module `torch` has no member `contiguous_format` +torch/_inductor/decomposition.py:802:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:802:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:802:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:802:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:814:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:814:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:814:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:814:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:825:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:827:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:827:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:827:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:839:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:841:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:841:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/_inductor/decomposition.py:841:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int | float]` torch/_inductor/decomposition.py:846:41: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` +torch/_inductor/decomposition.py:859:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:860:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:861:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/decomposition.py:862:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/decomposition.py:863:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/decomposition.py:864:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/decomposition.py:865:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:866:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:907:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | Tensor]` +torch/_inductor/decomposition.py:910:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_inductor/decomposition.py:910:82: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_inductor/decomposition.py:911:16: error[unresolved-attribute] Module `torch` has no member `where` torch/_inductor/decomposition.py:921:12: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/decomposition.py:923:24: error[unresolved-attribute] Module `torch` has no member `aminmax` @@ -4984,6 +5359,10 @@ torch/_inductor/decomposition.py:927:18: error[unresolved-attribute] Module `tor torch/_inductor/decomposition.py:928:21: error[unresolved-attribute] Module `torch` has no member `float64` torch/_inductor/decomposition.py:928:51: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/decomposition.py:939:17: error[unresolved-attribute] Module `torch` has no member `index_put` +torch/_inductor/decomposition.py:952:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:952:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:952:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:952:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/_inductor/decomposition.py:962:18: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/decomposition.py:965:20: error[unresolved-attribute] Module `torch` has no member `sum` torch/_inductor/decomposition.py:992:16: error[unresolved-attribute] Module `torch` has no member `ones_like` @@ -4997,11 +5376,34 @@ torch/_inductor/decomposition.py:1056:14: error[invalid-assignment] Object of ty torch/_inductor/decomposition.py:1061:9: warning[possibly-missing-attribute] Submodule `lowering` may not be available as an attribute on module `torch._inductor` torch/_inductor/decomposition.py:1064:26: error[unresolved-attribute] Module `torch` has no member `iinfo` torch/_inductor/decomposition.py:1064:38: error[unresolved-attribute] Module `torch` has no member `int8` +torch/_inductor/decomposition.py:1069:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:1070:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_inductor/decomposition.py:1071:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int] | None` +torch/_inductor/decomposition.py:1072:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:1073:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:1074:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/decomposition.py:1078:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/_inductor/decomposition.py:1080:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int] | None` +torch/_inductor/decomposition.py:1081:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` +torch/_inductor/decomposition.py:1082:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | list[int]` torch/_inductor/decomposition.py:1124:63: error[unresolved-attribute] Module `torch` has no member `int64` +torch/_inductor/decomposition.py:1128:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:1128:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_inductor/decomposition.py:1144:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/decomposition.py:1145:9: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/_inductor/decomposition.py:1146:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/decomposition.py:1147:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/decomposition.py:1148:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str | None` +torch/_inductor/decomposition.py:1149:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/_inductor/decomposition.py:1160:25: error[unresolved-attribute] Module `torch` has no member `Generator` +torch/_inductor/decomposition.py:1164:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:1164:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:1164:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/decomposition.py:1164:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/_inductor/decomposition.py:1165:18: error[unresolved-attribute] Module `torch` has no member `where` torch/_inductor/decomposition.py:1166:21: error[unresolved-attribute] Module `torch` has no member `where` +torch/_inductor/decomposition.py:1170:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/decomposition.py:1170:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_inductor/decomposition.py:1186:29: error[unresolved-attribute] Module `torch` has no member `int32` torch/_inductor/decomposition.py:1186:42: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/decomposition.py:1189:11: error[unresolved-attribute] Module `torch` has no member `arange` @@ -5011,6 +5413,11 @@ torch/_inductor/decomposition.py:1193:12: error[unresolved-attribute] Module `to torch/_inductor/decomposition.py:1215:14: error[invalid-assignment] Object of type `int` is not assignable to `tuple[int]` torch/_inductor/decomposition.py:1217:15: error[invalid-assignment] Object of type `int` is not assignable to `tuple[int]` torch/_inductor/decomposition.py:1219:16: error[invalid-assignment] Object of type `int` is not assignable to `tuple[int]` +torch/_inductor/decomposition.py:1230:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/decomposition.py:1231:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[tuple[int], Literal[1]]` +torch/_inductor/decomposition.py:1232:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[tuple[int], Literal[0]]` +torch/_inductor/decomposition.py:1233:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[tuple[int], Literal[1]]` +torch/_inductor/decomposition.py:1234:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_inductor/dependencies.py:215:35: error[invalid-argument-type] Argument is incorrect: Expected `tuple[Symbol, ...]`, found `tuple[Expr, ...]` torch/_inductor/dependencies.py:227:69: error[invalid-argument-type] Argument is incorrect: Expected `dict[Expr, Expr]`, found `dict[Symbol, Expr]` torch/_inductor/dependencies.py:563:41: error[invalid-argument-type] Argument is incorrect: Expected `Expr`, found `Expr | tuple[Expr, ...] | @Todo` @@ -5211,43 +5618,80 @@ torch/_inductor/fx_passes/freezing_patterns.py:283:9: error[invalid-argument-typ torch/_inductor/fx_passes/freezing_patterns.py:285:9: error[invalid-argument-type] Argument to function `register_replacement` is incorrect: Expected `_PassDictsType | Sequence[_PassDictsType]`, found `Unknown | PatternMatcherPass` torch/_inductor/fx_passes/freezing_patterns.py:302:5: error[invalid-argument-type] Argument to function `register_graph_pattern` is incorrect: Expected `_PassDictsType`, found `Unknown | PatternMatcherPass` torch/_inductor/fx_passes/fuse_attention.py:26:9: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:39:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:40:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:41:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:48:9: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:61:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:62:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:63:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:70:9: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:83:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:85:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:92:9: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:103:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:105:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:111:19: error[unresolved-attribute] Module `torch` has no member `softmax` +torch/_inductor/fx_passes/fuse_attention.py:125:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:126:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:131:19: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:134:19: error[unresolved-attribute] Module `torch` has no member `dropout` +torch/_inductor/fx_passes/fuse_attention.py:146:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:158:18: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/fx_passes/fuse_attention.py:159:19: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:160:19: error[unresolved-attribute] Module `torch` has no member `dropout` torch/_inductor/fx_passes/fuse_attention.py:161:34: error[unresolved-attribute] Module `torch` has no member `float16` +torch/_inductor/fx_passes/fuse_attention.py:179:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:181:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:191:18: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/fx_passes/fuse_attention.py:192:19: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:193:34: error[unresolved-attribute] Module `torch` has no member `float16` +torch/_inductor/fx_passes/fuse_attention.py:206:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:207:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:208:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:218:18: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/fx_passes/fuse_attention.py:219:19: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:220:19: error[unresolved-attribute] Module `torch` has no member `dropout` torch/_inductor/fx_passes/fuse_attention.py:221:34: error[unresolved-attribute] Module `torch` has no member `float16` +torch/_inductor/fx_passes/fuse_attention.py:234:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:236:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:247:18: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/fx_passes/fuse_attention.py:248:19: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:249:34: error[unresolved-attribute] Module `torch` has no member `float16` +torch/_inductor/fx_passes/fuse_attention.py:262:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:263:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:264:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:273:12: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:282:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:283:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:284:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:294:9: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:305:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:307:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:313:19: error[unresolved-attribute] Module `torch` has no member `bmm` torch/_inductor/fx_passes/fuse_attention.py:315:12: error[unresolved-attribute] Module `torch` has no member `bmm` +torch/_inductor/fx_passes/fuse_attention.py:325:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` torch/_inductor/fx_passes/fuse_attention.py:336:10: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:349:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:350:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:366:18: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:368:12: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:385:38: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_inductor/fx_passes/fuse_attention.py:386:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/_inductor/fx_passes/fuse_attention.py:387:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:399:14: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:417:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:431:18: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:435:13: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:455:38: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_inductor/fx_passes/fuse_attention.py:457:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/fuse_attention.py:468:20: error[unresolved-attribute] Module `torch` has no member `matmul` torch/_inductor/fx_passes/fuse_attention.py:469:17: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:476:25: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:477:13: error[unresolved-attribute] Module `torch` has no member `finfo` torch/_inductor/fx_passes/fuse_attention.py:479:20: error[unresolved-attribute] Module `torch` has no member `where` +torch/_inductor/fx_passes/fuse_attention.py:502:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:503:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_inductor/fx_passes/fuse_attention.py:512:20: error[unresolved-attribute] Module `torch` has no member `matmul` torch/_inductor/fx_passes/fuse_attention.py:513:17: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:520:25: error[unresolved-attribute] Module `torch` has no member `full` @@ -5255,16 +5699,29 @@ torch/_inductor/fx_passes/fuse_attention.py:521:13: error[unresolved-attribute] torch/_inductor/fx_passes/fuse_attention.py:523:20: error[unresolved-attribute] Module `torch` has no member `where` torch/_inductor/fx_passes/fuse_attention.py:531:18: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:532:17: error[unresolved-attribute] Module `torch` has no member `where` +torch/_inductor/fx_passes/fuse_attention.py:539:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:540:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_inductor/fx_passes/fuse_attention.py:553:18: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/fuse_attention.py:557:13: error[unresolved-attribute] Module `torch` has no member `softmax` torch/_inductor/fx_passes/fuse_attention.py:577:38: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_inductor/fx_passes/fuse_attention.py:579:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:580:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_inductor/fx_passes/fuse_attention.py:589:13: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:611:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:612:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` torch/_inductor/fx_passes/fuse_attention.py:621:13: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:644:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:645:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` torch/_inductor/fx_passes/fuse_attention.py:659:13: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/fx_passes/fuse_attention.py:681:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/_inductor/fx_passes/fuse_attention.py:682:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:683:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` torch/_inductor/fx_passes/fuse_attention.py:703:20: error[unresolved-attribute] Module `torch` has no member `bmm` torch/_inductor/fx_passes/fuse_attention.py:707:23: error[unresolved-attribute] Module `torch` has no member `half` torch/_inductor/fx_passes/fuse_attention.py:708:40: error[unresolved-attribute] Module `torch` has no member `half` torch/_inductor/fx_passes/fuse_attention.py:709:19: error[unresolved-attribute] Module `torch` has no member `bmm` +torch/_inductor/fx_passes/fuse_attention.py:721:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/_inductor/fx_passes/fuse_attention.py:722:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` torch/_inductor/fx_passes/fuse_attention.py:749:39: error[unresolved-attribute] Module `torch` has no member `bool` torch/_inductor/fx_passes/fuse_attention.py:750:39: error[unresolved-attribute] Module `torch` has no member `float` torch/_inductor/fx_passes/fuse_attention.py:820:9: error[unresolved-attribute] Module `torch` has no member `empty` @@ -5297,6 +5754,8 @@ torch/_inductor/fx_passes/group_batch_fusion.py:90:20: error[unresolved-attribut torch/_inductor/fx_passes/group_batch_fusion.py:91:29: error[unresolved-attribute] Module `torch` has no member `mul` torch/_inductor/fx_passes/group_batch_fusion.py:241:37: error[unresolved-attribute] Module `torch` has no member `stack` torch/_inductor/fx_passes/group_batch_fusion.py:244:38: error[unresolved-attribute] Module `torch` has no member `stack` +torch/_inductor/fx_passes/group_batch_fusion.py:258:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_inductor/fx_passes/group_batch_fusion.py:258:76: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_inductor/fx_passes/group_batch_fusion.py:457:33: error[unresolved-attribute] Module `torch` has no member `stack` torch/_inductor/fx_passes/group_batch_fusion.py:460:33: error[unresolved-attribute] Module `torch` has no member `stack` torch/_inductor/fx_passes/group_batch_fusion.py:529:17: error[unresolved-attribute] Module `torch` has no member `cat` @@ -5354,6 +5813,8 @@ torch/_inductor/fx_passes/joint_graph.py:170:10: warning[possibly-missing-attrib torch/_inductor/fx_passes/joint_graph.py:172:41: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/fx_passes/joint_graph.py:278:17: error[unresolved-attribute] Module `torch` has no member `full` torch/_inductor/fx_passes/joint_graph.py:290:9: error[invalid-method-override] Invalid override of method `insertable_tensor_check`: Definition is incompatible with `ConstantFolder.insertable_tensor_check` +torch/_inductor/fx_passes/joint_graph.py:340:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | list[Unknown | int]` +torch/_inductor/fx_passes/joint_graph.py:340:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Sequence[Divergent] | Mapping[str, Divergent] | slice[Any, Any, Any] | ... omitted 13 union elements` torch/_inductor/fx_passes/joint_graph.py:363:13: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_inductor/fx_passes/joint_graph.py:382:10: warning[possibly-missing-attribute] Submodule `_python_dispatch` may not be available as an attribute on module `torch.utils` torch/_inductor/fx_passes/joint_graph.py:422:60: error[unresolved-attribute] Module `torch` has no member `contiguous_format` @@ -5387,11 +5848,16 @@ torch/_inductor/fx_passes/micro_pipeline_tp.py:878:16: warning[possibly-missing- torch/_inductor/fx_passes/misc_patterns.py:34:17: error[unresolved-attribute] Module `torch` has no member `randperm` torch/_inductor/fx_passes/misc_patterns.py:35:16: error[unresolved-attribute] Module `torch` has no member `index_add` torch/_inductor/fx_passes/misc_patterns.py:38:17: error[unresolved-attribute] Module `torch` has no member `randperm` +torch/_inductor/fx_passes/misc_patterns.py:41:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown]` +torch/_inductor/fx_passes/misc_patterns.py:41:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown]` +torch/_inductor/fx_passes/misc_patterns.py:41:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/_inductor/fx_passes/misc_patterns.py:51:10: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/fx_passes/misc_patterns.py:51:44: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/fx_passes/misc_patterns.py:53:9: error[invalid-argument-type] Argument to function `register_replacement` is incorrect: Expected `TraceFn`, found `def fwd_only(fn: (...) -> Any, args: Sequence[Any], *, run_functional_passes: bool = Literal[True], get_decomp_fn: ((...) -> Any) | None = None) -> GraphModule` torch/_inductor/fx_passes/misc_patterns.py:59:17: error[unresolved-attribute] Module `torch` has no member `randperm` +torch/_inductor/fx_passes/misc_patterns.py:60:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown]` torch/_inductor/fx_passes/misc_patterns.py:63:17: error[unresolved-attribute] Module `torch` has no member `randperm` +torch/_inductor/fx_passes/misc_patterns.py:64:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown]` torch/_inductor/fx_passes/misc_patterns.py:71:10: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/fx_passes/misc_patterns.py:73:9: error[invalid-argument-type] Argument to function `register_replacement` is incorrect: Expected `TraceFn`, found `def fwd_only(fn: (...) -> Any, args: Sequence[Any], *, run_functional_passes: bool = Literal[True], get_decomp_fn: ((...) -> Any) | None = None) -> GraphModule` torch/_inductor/fx_passes/misc_patterns.py:110:30: warning[possibly-missing-attribute] Submodule `operator_schemas` may not be available as an attribute on module `torch.fx` @@ -5464,6 +5930,16 @@ torch/_inductor/fx_passes/pad_mm.py:72:19: error[unresolved-attribute] Module `t torch/_inductor/fx_passes/pad_mm.py:72:45: error[unresolved-attribute] Module `torch` has no member `float` torch/_inductor/fx_passes/pad_mm.py:114:9: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` torch/_inductor/fx_passes/pad_mm.py:137:12: error[unresolved-attribute] Module `torch` has no member `cat` +torch/_inductor/fx_passes/pad_mm.py:143:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:143:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:143:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:143:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/fx_passes/pad_mm.py:143:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/fx_passes/pad_mm.py:186:22: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/fx_passes/pad_mm.py:186:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:186:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:186:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_inductor/fx_passes/pad_mm.py:186:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_inductor/fx_passes/pad_mm.py:217:56: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/fx_passes/pad_mm.py:225:18: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_inductor/fx_passes/pad_mm.py:251:24: warning[possibly-missing-attribute] Submodule `codecache` may not be available as an attribute on module `torch._inductor` @@ -5483,6 +5959,18 @@ torch/_inductor/fx_passes/pad_mm.py:455:12: warning[possibly-missing-attribute] torch/_inductor/fx_passes/pad_mm.py:458:12: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` torch/_inductor/fx_passes/pad_mm.py:467:35: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` torch/_inductor/fx_passes/pad_mm.py:724:8: warning[possibly-missing-attribute] Submodule `config` may not be available as an attribute on module `torch._inductor` +torch/_inductor/fx_passes/pad_mm.py:739:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:739:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:757:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:757:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_inductor/fx_passes/pad_mm.py:770:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:770:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_inductor/fx_passes/pad_mm.py:792:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:792:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:814:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:814:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:847:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/fx_passes/pad_mm.py:847:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/fx_passes/pad_mm.py:883:31: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/fx_passes/pad_mm.py:884:31: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/fx_passes/pad_mm.py:886:31: error[unresolved-attribute] Module `torch` has no member `empty` @@ -5497,10 +5985,18 @@ torch/_inductor/fx_passes/post_grad.py:398:24: error[unresolved-attribute] Modul torch/_inductor/fx_passes/post_grad.py:398:46: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/fx_passes/post_grad.py:398:66: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/fx_passes/post_grad.py:407:17: error[unresolved-attribute] Module `torch` has no member `empty_strided` +torch/_inductor/fx_passes/post_grad.py:441:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[""]` +torch/_inductor/fx_passes/post_grad.py:442:77: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[""]` +torch/_inductor/fx_passes/post_grad.py:443:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_inductor/fx_passes/post_grad.py:447:70: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_inductor/fx_passes/post_grad.py:597:24: error[unresolved-attribute] Module `torch` has no member `zeros` torch/_inductor/fx_passes/post_grad.py:597:46: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/fx_passes/post_grad.py:597:66: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/fx_passes/post_grad.py:613:17: error[unresolved-attribute] Module `torch` has no member `empty_strided` +torch/_inductor/fx_passes/post_grad.py:644:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[""]` +torch/_inductor/fx_passes/post_grad.py:645:78: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[""]` +torch/_inductor/fx_passes/post_grad.py:646:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_inductor/fx_passes/post_grad.py:652:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_inductor/fx_passes/post_grad.py:691:8: error[unresolved-attribute] Module `torch._C` has no member `_has_mkldnn` torch/_inductor/fx_passes/post_grad.py:693:36: warning[possibly-missing-import] Member `_mkldnn_fusion_init` of module `torch._inductor.fx_passes.mkldnn_fusion` may be missing torch/_inductor/fx_passes/post_grad.py:705:10: error[unresolved-attribute] Module `torch` has no member `empty` @@ -5659,8 +6155,10 @@ torch/_inductor/fx_passes/quantization.py:3746:17: error[unresolved-attribute] M torch/_inductor/fx_passes/quantization.py:3748:17: error[unresolved-attribute] Module `torch` has no member `tensor` torch/_inductor/fx_passes/quantization.py:3762:21: error[unresolved-attribute] Module `torch` has no member `int32` torch/_inductor/fx_passes/quantization.py:3764:31: error[unresolved-attribute] Module `torch` has no member `cat` +torch/_inductor/fx_passes/quantization.py:3766:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` torch/_inductor/fx_passes/quantization.py:3768:27: error[unresolved-attribute] Module `torch` has no member `cat` torch/_inductor/fx_passes/quantization.py:3848:55: error[unresolved-attribute] Module `torch` has no member `contiguous_format` +torch/_inductor/fx_passes/reinplace.py:96:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/fx_passes/reinplace.py:722:18: error[unresolved-import] Cannot resolve imported module `triton.runtime.autotuner` torch/_inductor/fx_passes/reinplace.py:723:18: error[unresolved-import] Cannot resolve imported module `triton.runtime.jit` torch/_inductor/fx_passes/reinplace.py:785:26: warning[possibly-missing-attribute] Submodule `fx_utils` may not be available as an attribute on module `torch._inductor` @@ -5989,7 +6487,7 @@ torch/_inductor/graph.py:145:10: error[unresolved-import] Cannot resolve importe torch/_inductor/graph.py:152:76: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/graph.py:159:16: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/graph.py:179:20: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject` -torch/_inductor/graph.py:279:13: error[invalid-return-type] Return type does not match returned value: expected `OpOverloadPacket[Unknown, Any] | None`, found `object` +torch/_inductor/graph.py:279:13: error[invalid-return-type] Return type does not match returned value: expected `OpOverloadPacket[EllipsisType, Any] | None`, found `object` torch/_inductor/graph.py:290:13: warning[possibly-missing-attribute] Submodule `triton_kernel_wrap` may not be available as an attribute on module `torch._higher_order_ops` torch/_inductor/graph.py:298:16: error[unresolved-attribute] Module `torch._C` has no member `Tag` torch/_inductor/graph.py:418:24: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject` @@ -6073,6 +6571,7 @@ torch/_inductor/inductor_prims.py:72:27: error[unresolved-attribute] Module `tor torch/_inductor/inductor_prims.py:74:11: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_inductor/inductor_prims.py:90:41: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/inductor_prims.py:96:35: error[unresolved-attribute] Module `torch` has no member `randint` +torch/_inductor/inductor_prims.py:107:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` torch/_inductor/inductor_prims.py:115:11: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_inductor/inductor_prims.py:178:14: error[unresolved-attribute] Module `torch` has no member `arange` torch/_inductor/inductor_prims.py:179:44: error[unresolved-attribute] Module `torch` has no member `int64` @@ -6146,6 +6645,9 @@ torch/_inductor/ir.py:1502:17: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:1503:20: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:1504:20: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:1523:33: error[unresolved-attribute] Module `torch` has no member `bool` +torch/_inductor/ir.py:1613:39: error[invalid-argument-type] Argument to function `_maybe_increase_split` is incorrect: Expected `int`, found `int | Expr` +torch/_inductor/ir.py:1635:17: error[invalid-argument-type] Argument to bound method `create_multilayer_existing_ranges` is incorrect: Expected `list[Integer]`, found `list[Expr]` +torch/_inductor/ir.py:1636:17: error[invalid-argument-type] Argument to bound method `create_multilayer_existing_ranges` is incorrect: Expected `list[Integer]`, found `list[Expr]` torch/_inductor/ir.py:1689:17: error[invalid-assignment] Object of type `int | Expr` is not assignable to attribute `_split_size` on type `ComputedBuffer & ~AlwaysFalsy` torch/_inductor/ir.py:1711:37: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:1719:24: error[unresolved-attribute] Module `torch` has no member `iinfo` @@ -6163,6 +6665,8 @@ torch/_inductor/ir.py:1895:18: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:1937:17: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/ir.py:1938:20: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:1939:20: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_inductor/ir.py:1973:13: error[invalid-argument-type] Argument to bound method `create_multilayer_helper` is incorrect: Expected `list[Expr]`, found `list[Expr | int]` +torch/_inductor/ir.py:1974:13: error[invalid-argument-type] Argument to bound method `create_multilayer_helper` is incorrect: Expected `list[Integer]`, found `list[Integer | FloorDiv]` torch/_inductor/ir.py:1983:17: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/ir.py:1984:20: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:1985:20: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -6208,10 +6712,20 @@ torch/_inductor/ir.py:2860:24: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:2866:38: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/ir.py:2916:42: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/ir.py:2945:17: error[invalid-argument-type] Argument to bound method `is_size_one_or_false` is incorrect: Expected `Expr`, found `Expr | Unknown | None` +torch/_inductor/ir.py:2978:17: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr]`, found `list[int | Expr]` +torch/_inductor/ir.py:2985:35: error[invalid-argument-type] Argument is incorrect: Expected `Sequence[Expr]`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:3032:36: error[invalid-argument-type] Argument is incorrect: Expected `list[Expr]`, found `list[int]` torch/_inductor/ir.py:3039:46: error[invalid-argument-type] Argument to bound method `_map_neg_dims` is incorrect: Expected `Sequence[int]`, found `list[Expr]` torch/_inductor/ir.py:3043:17: error[invalid-argument-type] Method `__getitem__` of type `Overload[(index: int) -> Expr, (index: slice[Any, Any, Any]) -> Sequence[Expr]]` cannot be called with key of type `Expr` on object of type `Sequence[Expr]` torch/_inductor/ir.py:3123:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[list[int], (Sequence[Expr], /) -> tuple[Expr]]`, found `tuple[list[Expr | Unknown], def reindex(index: Sequence[Expr]) -> tuple[Expr]]` +torch/_inductor/ir.py:3198:53: error[invalid-argument-type] Argument is incorrect: Expected `(Sequence[Expr], /) -> Sequence[Expr]`, found `def fake_reindex(index: Any) -> tuple[int, ...]` +torch/_inductor/ir.py:3214:51: error[invalid-argument-type] Argument to function `contiguous_strides` is incorrect: Expected `Sequence[int]`, found `list[Expr]` +torch/_inductor/ir.py:3248:52: error[invalid-argument-type] Argument to function `_dynamic_reshape_indexer` is incorrect: Expected `Sequence[Expr]`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:3248:62: error[invalid-argument-type] Argument to function `_dynamic_reshape_indexer` is incorrect: Expected `Sequence[Expr]`, found `Sequence[int | Expr]` torch/_inductor/ir.py:3251:35: error[invalid-argument-type] Argument to function `sympy_product` is incorrect: Expected `Iterable[Expr]`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:3252:53: error[invalid-argument-type] Argument to function `_dynamic_reshape_indexer` is incorrect: Expected `Sequence[Expr]`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:3253:59: error[invalid-argument-type] Argument to function `_dynamic_reshape_indexer` is incorrect: Expected `Sequence[Expr]`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:3255:16: error[invalid-return-type] Return type does not match returned value: expected `(Sequence[_T@dynamic_reshape_indexer], /) -> Sequence[_V@dynamic_reshape_indexer]`, found `((Sequence[Expr], /) -> Sequence[Expr]) | ((Sequence[Unknown], /) -> Sequence[Unknown])` torch/_inductor/ir.py:3322:53: error[invalid-argument-type] Argument to bound method `check_equals` is incorrect: Expected `Expr`, found `Literal[1]` torch/_inductor/ir.py:3327:53: error[invalid-argument-type] Argument to bound method `check_equals` is incorrect: Expected `Expr`, found `Literal[1]` torch/_inductor/ir.py:3373:38: error[unresolved-attribute] Module `torch` has no member `device` @@ -6221,6 +6735,9 @@ torch/_inductor/ir.py:3443:43: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:3463:24: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:3499:79: error[invalid-argument-type] Argument to bound method `evaluate_max` is incorrect: Expected `Expr`, found `int` torch/_inductor/ir.py:3504:46: error[invalid-argument-type] Argument to bound method `evaluate_min` is incorrect: Expected `Expr`, found `int` +torch/_inductor/ir.py:3514:19: error[invalid-assignment] Object of type `Expr` is not assignable to `int | None` +torch/_inductor/ir.py:3514:45: error[invalid-argument-type] Argument to function `handle_negative_index` is incorrect: Expected `Expr`, found `int` +torch/_inductor/ir.py:3515:26: error[invalid-argument-type] Argument to function `clamp` is incorrect: Expected `Expr`, found `int | None` torch/_inductor/ir.py:3517:17: error[invalid-assignment] Object of type `Expr | int` is not assignable to `int` torch/_inductor/ir.py:3517:38: error[invalid-argument-type] Argument to function `clamp_wrap` is incorrect: Expected `int`, found `Expr` torch/_inductor/ir.py:3518:15: error[invalid-assignment] Object of type `Expr | int` is not assignable to `int` @@ -6330,7 +6847,7 @@ torch/_inductor/ir.py:5602:64: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:5606:29: error[invalid-assignment] Object of type `tuple[Expr | int, ...]` is not assignable to `Sequence[int]` torch/_inductor/ir.py:5619:17: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr] | None`, found `Sequence[int]` torch/_inductor/ir.py:5631:52: error[invalid-argument-type] Argument to bound method `create` is incorrect: Expected `int`, found `Unknown | Expr` -torch/_inductor/ir.py:5636:41: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `Never`, found `Unknown & Buffer` +torch/_inductor/ir.py:5636:41: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `Never`, found `Buffer` torch/_inductor/ir.py:5723:17: error[invalid-assignment] Object of type `NonOwningLayout` is not assignable to attribute `layout` on type `IRNode & ` torch/_inductor/ir.py:5815:26: error[unresolved-attribute] Object of type `object` has no attribute `arguments` torch/_inductor/ir.py:5824:26: error[unresolved-attribute] Object of type `object` has no attribute `arguments` @@ -6340,6 +6857,8 @@ torch/_inductor/ir.py:5889:40: error[unresolved-attribute] Object of type `objec torch/_inductor/ir.py:5998:31: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject` torch/_inductor/ir.py:5998:72: error[unresolved-attribute] Module `torch` has no member `Generator` torch/_inductor/ir.py:6017:32: warning[possibly-missing-attribute] Submodule `ir` may not be available as an attribute on module `torch._inductor` +torch/_inductor/ir.py:6027:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown | FakeScriptObject` +torch/_inductor/ir.py:6027:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown | FakeScriptObject` torch/_inductor/ir.py:6089:35: error[unresolved-attribute] Module `torch` has no member `channels_last` torch/_inductor/ir.py:6092:35: error[unresolved-attribute] Module `torch` has no member `channels_last_3d` torch/_inductor/ir.py:6097:17: error[invalid-argument-type] Argument to bound method `freeze_layout_with_same_order` is incorrect: Expected `Sequence[int]`, found `tuple[Expr | int, ...]` @@ -6427,6 +6946,8 @@ torch/_inductor/ir.py:8346:38: error[unresolved-attribute] Module `torch` has no torch/_inductor/ir.py:8419:42: error[unresolved-attribute] Module `torch` has no member `device` torch/_inductor/ir.py:8464:24: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/ir.py:8724:25: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr] | None`, found `Sequence[int | Expr]` +torch/_inductor/ir.py:8793:21: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/ir.py:8795:20: error[invalid-assignment] Object of type `list[IRNode | Unknown]` is not assignable to `list[TensorBox | ShapeAsConstantBuffer]` torch/_inductor/ir.py:8858:21: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr]`, found `list[int | Expr | Unknown]` torch/_inductor/ir.py:8859:21: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr] | None`, found `list[int | Expr | Unknown]` torch/_inductor/ir.py:9089:37: error[unresolved-attribute] Module `torch` has no member `bool` @@ -6454,6 +6975,11 @@ torch/_inductor/kernel/conv.py:326:5: error[unresolved-attribute] Module `torch` torch/_inductor/kernel/conv.py:334:9: error[unresolved-attribute] Module `torch` has no member `squeeze` torch/_inductor/kernel/conv.py:334:23: error[unresolved-attribute] Module `torch` has no member `squeeze` torch/_inductor/kernel/conv.py:335:12: error[unresolved-attribute] Module `torch` has no member `matmul` +torch/_inductor/kernel/conv.py:366:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/kernel/conv.py:367:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/kernel/conv.py:368:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/_inductor/kernel/conv.py:372:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/_inductor/kernel/conv.py:374:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_inductor/kernel/conv.py:383:9: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `Sequence[Expr] | None`, found `Sequence[int]` torch/_inductor/kernel/custom_op.py:70:23: warning[possibly-missing-attribute] Attribute `__name__` may be missing on object of type `(Unknown & ~AlwaysFalsy) | (((...) -> Any) & (() -> object) & ~AlwaysFalsy)` torch/_inductor/kernel/custom_op.py:188:27: error[unresolved-attribute] Module `torch` has no member `empty` @@ -6894,12 +7420,23 @@ torch/_inductor/memory.py:948:61: error[unresolved-attribute] Object of type `(. torch/_inductor/mkldnn_ir.py:87:25: error[non-subscriptable] Cannot subscript object of type `None` with no `__getitem__` method torch/_inductor/mkldnn_ir.py:181:37: error[invalid-assignment] Object of type `list[Expr]` is not assignable to `list[int] | tuple[int, ...]` torch/_inductor/mkldnn_ir.py:216:35: error[invalid-argument-type] Argument to function `convert_shape_to_inductor` is incorrect: Expected `Iterable[int | SymInt]`, found `list[int] | tuple[Unknown | int, ...] | list[Expr]` +torch/_inductor/mkldnn_ir.py:414:17: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:492:17: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` torch/_inductor/mkldnn_ir.py:676:29: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/mkldnn_ir.py:676:44: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_inductor/mkldnn_ir.py:1051:29: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/mkldnn_ir.py:1051:44: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_inductor/mkldnn_ir.py:1174:29: error[unresolved-attribute] Module `torch` has no member `float32` torch/_inductor/mkldnn_ir.py:1174:44: error[unresolved-attribute] Module `torch` has no member `bfloat16` +torch/_inductor/mkldnn_ir.py:1223:13: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1228:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1230:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1232:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1234:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1236:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1239:14: error[invalid-assignment] Object of type `IRNode` is not assignable to `TensorBox` +torch/_inductor/mkldnn_ir.py:1282:47: error[invalid-argument-type] Argument to function `contiguous_strides` is incorrect: Expected `Sequence[int]`, found `Sequence[Expr]` +torch/_inductor/mkldnn_ir.py:1283:47: error[invalid-argument-type] Argument to function `contiguous_strides` is incorrect: Expected `Sequence[int]`, found `Sequence[Expr]` torch/_inductor/mkldnn_lowerings.py:60:33: error[unresolved-attribute] Module `torch` has no member `sum` torch/_inductor/mkldnn_lowerings.py:60:55: error[unresolved-attribute] Module `torch` has no member `float` torch/_inductor/mkldnn_lowerings.py:68:33: error[unresolved-attribute] Module `torch` has no member `sum` @@ -7031,6 +7568,10 @@ torch/_inductor/optimize_indexing.py:55:13: error[unresolved-attribute] Module ` torch/_inductor/optimize_indexing.py:92:15: error[unresolved-attribute] Module `torch` has no member `int32` torch/_inductor/optimize_indexing.py:108:33: error[unresolved-attribute] Module `torch` has no member `int64` torch/_inductor/output_code.py:118:16: error[invalid-return-type] Return type does not match returned value: expected `list[int]`, found `None` +torch/_inductor/output_code.py:124:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/output_code.py:124:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_inductor/output_code.py:124:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_inductor/output_code.py:124:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` torch/_inductor/output_code.py:137:8: error[unresolved-attribute] Module `torch` has no member `_debug_has_internal_overlap` torch/_inductor/output_code.py:165:19: warning[possibly-missing-attribute] Submodule `cudagraph_trees` may not be available as an attribute on module `torch._inductor` torch/_inductor/output_code.py:421:36: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject` @@ -7107,19 +7648,27 @@ torch/_inductor/runtime/benchmarking.py:247:18: error[unresolved-import] Cannot torch/_inductor/runtime/benchmarking.py:377:18: error[unresolved-attribute] Module `torch` has no member `empty` torch/_inductor/runtime/benchmarking.py:377:61: error[unresolved-attribute] Module `torch` has no member `int` torch/_inductor/runtime/caching/implementations.py:342:11: error[unresolved-import] Cannot resolve imported module `.fb.implementations` -torch/_inductor/runtime/caching/interfaces.py:67:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:79:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:94:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:110:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:126:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:136:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:149:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:160:17: error[unresolved-attribute] Object of type `(...) -> R@_intf_callback` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:182:23: error[unresolved-attribute] Object of type `(...) -> R@_make_key` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:444:65: error[unresolved-attribute] Object of type `(...) -> R@_get` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:479:65: error[unresolved-attribute] Object of type `(...) -> R@_insert` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:704:38: error[unresolved-attribute] Object of type `(...) -> R@_get` has no attribute `__name__` -torch/_inductor/runtime/caching/interfaces.py:752:38: error[unresolved-attribute] Object of type `(...) -> R@_insert` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:67:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:79:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:94:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:110:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:126:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:136:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:149:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:160:17: error[unresolved-attribute] Object of type `(**P@_intf_callback) -> R@_intf_callback` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:182:23: error[unresolved-attribute] Object of type `(**P@_make_key) -> R@_make_key` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:369:9: error[invalid-method-override] Invalid override of method `_make_record_wrapper`: Definition is incompatible with `_CacheIntf._make_record_wrapper` +torch/_inductor/runtime/caching/interfaces.py:433:9: error[invalid-method-override] Invalid override of method `_get`: Definition is incompatible with `_CacheIntf._get` +torch/_inductor/runtime/caching/interfaces.py:444:65: error[unresolved-attribute] Object of type `(**P@_get) -> R@_get` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:467:9: error[invalid-method-override] Invalid override of method `_insert`: Definition is incompatible with `_CacheIntf._insert` +torch/_inductor/runtime/caching/interfaces.py:479:65: error[unresolved-attribute] Object of type `(**P@_insert) -> R@_insert` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:602:9: error[invalid-method-override] Invalid override of method `_make_record_wrapper`: Definition is incompatible with `_CacheIntf._make_record_wrapper` +torch/_inductor/runtime/caching/interfaces.py:692:9: error[invalid-method-override] Invalid override of method `_get`: Definition is incompatible with `_CacheIntf._get` +torch/_inductor/runtime/caching/interfaces.py:704:38: error[unresolved-attribute] Object of type `(**P@_get) -> R@_get` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:733:9: error[invalid-method-override] Invalid override of method `_insert`: Definition is incompatible with `_CacheIntf._insert` +torch/_inductor/runtime/caching/interfaces.py:752:38: error[unresolved-attribute] Object of type `(**P@_insert) -> R@_insert` has no attribute `__name__` +torch/_inductor/runtime/caching/interfaces.py:781:9: error[invalid-method-override] Invalid override of method `get`: Definition is incompatible with `_CacheIntf.get` +torch/_inductor/runtime/caching/interfaces.py:800:9: error[invalid-method-override] Invalid override of method `insert`: Definition is incompatible with `_CacheIntf.insert` torch/_inductor/runtime/coordinate_descent_tuner.py:222:26: warning[possibly-missing-attribute] Attribute `Config` may be missing on object of type `Unknown | ` torch/_inductor/runtime/coordinate_descent_tuner.py:295:26: warning[possibly-missing-attribute] Attribute `Config` may be missing on object of type `Unknown | ` torch/_inductor/runtime/coordinate_descent_tuner.py:297:27: warning[possibly-missing-attribute] Attribute `Config` may be missing on object of type `Unknown | ` @@ -7299,6 +7848,8 @@ torch/_inductor/standalone_compile.py:211:18: warning[possibly-missing-attribute torch/_inductor/standalone_compile.py:377:19: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` torch/_inductor/standalone_compile.py:414:15: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` torch/_inductor/standalone_compile.py:416:9: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` +torch/_inductor/standalone_compile.py:417:9: error[missing-argument] No argument provided for required parameter `cls` +torch/_inductor/standalone_compile.py:417:9: error[missing-argument] No argument provided for required parameter `cls` torch/_inductor/standalone_compile.py:419:9: warning[possibly-missing-attribute] Submodule `_functorch` may not be available as an attribute on module `torch` torch/_inductor/subgraph_lowering.py:134:12: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/subgraph_lowering.py:135:13: error[unresolved-attribute] Module `torch` has no member `device` @@ -7388,6 +7939,7 @@ torch/_inductor/template_heuristics/triton.py:1684:22: error[unresolved-attribut torch/_inductor/template_heuristics/triton.py:1684:37: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_inductor/template_heuristics/triton.py:2160:9: error[invalid-method-override] Invalid override of method `_filter_configs`: Definition is incompatible with `BaseConfigHeuristic._filter_configs` torch/_inductor/test_operators.py:9:61: error[unresolved-attribute] Module `torch` has no member `Tag` +torch/_inductor/test_operators.py:20:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/tiling_utils.py:160:13: error[invalid-assignment] Invalid subscript assignment with key of type `Basic` and value of type `Literal[0]` on object of type `dict[Symbol, int]` torch/_inductor/tiling_utils.py:162:13: error[invalid-assignment] Invalid subscript assignment with key of type `Basic` and value of type `int` on object of type `dict[Symbol, int]` torch/_inductor/tiling_utils.py:162:37: error[invalid-argument-type] Argument to function `get_hint` is incorrect: Expected `Expr | int`, found `Basic` @@ -7543,6 +8095,8 @@ torch/_inductor/utils.py:3369:14: error[unresolved-import] Cannot resolve import torch/_inductor/utils.py:3400:24: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/utils.py:3406:41: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/utils.py:3410:34: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_inductor/utils.py:3432:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_inductor/utils.py:3432:74: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_inductor/utils.py:3459:37: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/utils.py:3468:37: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_inductor/utils.py:3497:32: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -7643,7 +8197,7 @@ torch/_library/custom_ops.py:847:17: error[unresolved-attribute] Module `torch._ torch/_library/custom_ops.py:847:41: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` torch/_library/custom_ops.py:848:18: error[unresolved-attribute] Module `torch._C` has no member `_ExcludeDispatchKeyGuard` torch/_library/custom_ops.py:866:37: error[unresolved-attribute] Module `torch` has no member `float64` -torch/_library/custom_ops.py:937:14: error[invalid-assignment] Object of type `object` is not assignable to `CustomOpDef | OpOverload[Unknown, Any] | str` +torch/_library/custom_ops.py:937:14: error[invalid-assignment] Object of type `object` is not assignable to `CustomOpDef | OpOverload[EllipsisType, Any] | str` torch/_library/effects.py:25:29: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/_library/effects.py:51:12: error[unresolved-attribute] Module `torch._C` has no member `_get_operation_overload` torch/_library/effects.py:54:22: error[unresolved-attribute] Module `torch._C` has no member `_get_schema` @@ -7865,6 +8419,8 @@ torch/_meta_registrations.py:799:12: error[unresolved-attribute] Module `torch` torch/_meta_registrations.py:804:5: error[unresolved-attribute] Module `torch` has no member `_resize_output_` torch/_meta_registrations.py:805:22: error[unresolved-attribute] Module `torch` has no member `angle` torch/_meta_registrations.py:832:12: error[unresolved-attribute] Module `torch` has no member `empty` +torch/_meta_registrations.py:847:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_meta_registrations.py:847:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/_meta_registrations.py:943:23: error[unresolved-attribute] Module `torch` has no member `float` torch/_meta_registrations.py:943:36: error[unresolved-attribute] Module `torch` has no member `double` torch/_meta_registrations.py:943:50: error[unresolved-attribute] Module `torch` has no member `cfloat` @@ -8076,6 +8632,11 @@ torch/_meta_registrations.py:5330:17: error[unresolved-attribute] Module `torch` torch/_meta_registrations.py:5341:12: error[unresolved-attribute] Module `torch` has no member `empty` torch/_meta_registrations.py:5354:18: error[unresolved-attribute] Module `torch` has no member `sparse_coo` torch/_meta_registrations.py:5360:15: error[unresolved-attribute] Module `torch` has no member `empty` +torch/_meta_registrations.py:5379:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_meta_registrations.py:5380:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_meta_registrations.py:5381:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_meta_registrations.py:5382:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/_meta_registrations.py:5383:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/_meta_registrations.py:5402:17: error[unresolved-attribute] Module `torch` has no member `get_default_dtype` torch/_meta_registrations.py:5406:18: error[unresolved-attribute] Module `torch` has no member `strided` torch/_meta_registrations.py:5407:12: error[unresolved-attribute] Module `torch` has no member `empty` @@ -8265,6 +8826,7 @@ torch/_meta_registrations.py:7629:16: error[unresolved-attribute] Module `torch` torch/_meta_registrations.py:7634:23: error[unresolved-attribute] Module `torch` has no member `bool` torch/_meta_registrations.py:7634:35: error[unresolved-attribute] Module `torch` has no member `complex128` torch/_meta_registrations.py:7634:53: error[unresolved-attribute] Module `torch` has no member `complex64` +torch/_meta_registrations.py:7677:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[-1]` torch/_meta_registrations.py:7708:24: error[unresolved-attribute] Module `torch` has no member `float16` torch/_meta_registrations.py:7708:39: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/_meta_registrations.py:7708:55: error[unresolved-attribute] Module `torch` has no member `float32` @@ -10458,12 +11020,12 @@ torch/_numpy/testing/utils.py:2394:16: error[unresolved-import] Cannot resolve i torch/_numpy/testing/utils.py:2440:15: warning[possibly-missing-attribute] Attribute `rsplit` may be missing on object of type `str | None` torch/_ops.py:26:22: error[unresolved-import] Module `torch._C` has no member `_dispatch_is_included_in_alias` torch/_ops.py:26:78: error[unresolved-import] Module `torch._C` has no member `DispatchKey` -torch/_ops.py:36:22: error[invalid-paramspec] The `default` parameter of `typing.ParamSpec` was added in Python 3.13 torch/_ops.py:118:20: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_is_alias_key` torch/_ops.py:225:9: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_get_backend_keyset_from_autograd` torch/_ops.py:240:13: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_autogradother_backends` torch/_ops.py:254:8: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_has_backend_fallback` torch/_ops.py:295:37: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_keyset_full` +torch/_ops.py:308:9: error[invalid-method-override] Invalid override of method `py_impl`: Definition is incompatible with `OperatorBase.py_impl` torch/_ops.py:326:20: error[unresolved-attribute] Module `torch` has no member `is_grad_enabled` torch/_ops.py:331:22: error[unresolved-attribute] Module `torch._C` has no member `_AutoDispatchBelowAutograd` torch/_ops.py:366:21: warning[possibly-missing-attribute] Submodule `_functorch` may not be available as an attribute on module `torch` @@ -10700,6 +11262,7 @@ torch/_prims/context.py:77:26: warning[possibly-missing-attribute] Submodule `_c torch/_prims/context.py:115:9: error[invalid-method-override] Invalid override of method `__torch_function__`: Definition is incompatible with `TorchFunctionMode.__torch_function__` torch/_prims/debug_prims.py:40:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_prims/debug_prims.py:41:17: error[unresolved-attribute] Module `torch` has no member `device` +torch/_prims/executor.py:62:68: error[invalid-argument-type] Argument to function `wrapper_and_args_for_make_fx` is incorrect: Expected `dict[str, object]`, found `P@make_traced.kwargs` torch/_prims/rng_prims.py:7:22: error[unresolved-import] Module `torch._C` has no member `DispatchKey` torch/_prims/rng_prims.py:52:12: error[unresolved-attribute] Module `torch` has no member `Size` torch/_prims/rng_prims.py:54:30: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -10880,9 +11443,9 @@ torch/_prims_common/wrappers.py:38:51: error[unresolved-attribute] Module `torch torch/_prims_common/wrappers.py:44:49: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_prims_common/wrappers.py:49:45: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_prims_common/wrappers.py:191:29: error[unresolved-attribute] Module `torch` has no member `memory_format` -torch/_prims_common/wrappers.py:282:33: error[unresolved-attribute] Object of type `(...) -> _T@out_wrapper` has no attribute `__name__` -torch/_prims_common/wrappers.py:346:34: error[unresolved-attribute] Object of type `(...) -> _T@out_wrapper` has no attribute `__name__` -torch/_prims_common/wrappers.py:360:24: error[unresolved-attribute] Object of type `(...) -> _T@out_wrapper` has no attribute `__name__` +torch/_prims_common/wrappers.py:282:33: error[unresolved-attribute] Object of type `(**_P@out_wrapper) -> _T@out_wrapper` has no attribute `__name__` +torch/_prims_common/wrappers.py:346:34: error[unresolved-attribute] Object of type `(**_P@out_wrapper) -> _T@out_wrapper` has no attribute `__name__` +torch/_prims_common/wrappers.py:360:24: error[unresolved-attribute] Object of type `(**_P@out_wrapper) -> _T@out_wrapper` has no attribute `__name__` torch/_prims_common/wrappers.py:433:14: error[unresolved-attribute] Module `torch._C` has no member `_AutoDispatchBelowAutograd` torch/_prims_common/wrappers.py:450:12: error[unresolved-attribute] Module `torch` has no member `is_grad_enabled` torch/_prims_common/wrappers.py:486:24: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -11055,9 +11618,29 @@ torch/_refs/__init__.py:3371:12: error[unresolved-attribute] Module `torch` has torch/_refs/__init__.py:3372:12: error[unresolved-attribute] Module `torch` has no member `squeeze` torch/_refs/__init__.py:3454:2: warning[possibly-missing-attribute] Submodule `fake_impls` may not be available as an attribute on module `torch._subclasses` torch/_refs/__init__.py:3503:19: error[unresolved-attribute] Module `torch` has no member `where` +torch/_refs/__init__.py:3567:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_refs/__init__.py:3567:80: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/_refs/__init__.py:3593:22: error[unresolved-attribute] Module `torch` has no member `ones` +torch/_refs/__init__.py:3595:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/_refs/__init__.py:3595:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_refs/__init__.py:3599:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/_refs/__init__.py:3599:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_refs/__init__.py:3599:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/_refs/__init__.py:3623:40: error[unresolved-attribute] Module `torch` has no member `view_as_real` torch/_refs/__init__.py:3700:19: error[unresolved-attribute] Module `torch` has no member `ones` +torch/_refs/__init__.py:3706:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/_refs/__init__.py:3706:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[int, int]` +torch/_refs/__init__.py:3706:85: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_refs/__init__.py:3734:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown, Unknown]` +torch/_refs/__init__.py:3735:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_refs/__init__.py:3736:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_refs/__init__.py:3737:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_refs/__init__.py:3741:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown, Unknown]` +torch/_refs/__init__.py:3742:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/_refs/__init__.py:3743:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_refs/__init__.py:3744:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_refs/__init__.py:3772:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[0], Unknown]` +torch/_refs/__init__.py:3772:76: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_refs/__init__.py:3815:16: error[unresolved-attribute] Module `torch` has no member `clone` torch/_refs/__init__.py:3829:16: error[unresolved-attribute] Module `torch` has no member `empty` torch/_refs/__init__.py:3854:21: error[unresolved-attribute] Module `torch` has no member `clone` @@ -11091,6 +11674,12 @@ torch/_refs/__init__.py:4290:34: error[unresolved-attribute] Module `torch` has torch/_refs/__init__.py:4311:16: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/_refs/__init__.py:4398:41: error[unresolved-attribute] Module `torch` has no member `long` torch/_refs/__init__.py:4409:25: error[invalid-assignment] Object of type `int | (Tensor & float) | (Tensor & complex) | ... omitted 6 union elements` is not assignable to `int` +torch/_refs/__init__.py:4432:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_refs/__init__.py:4432:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/_refs/__init__.py:4432:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/_refs/__init__.py:4448:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_refs/__init__.py:4448:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/_refs/__init__.py:4448:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/_refs/__init__.py:4548:16: error[unresolved-attribute] Module `torch` has no member `diag_embed` torch/_refs/__init__.py:4550:16: error[unresolved-attribute] Module `torch` has no member `diagonal_copy` torch/_refs/__init__.py:4648:13: error[unresolved-attribute] Module `torch` has no member `zeros` @@ -11104,6 +11693,7 @@ torch/_refs/__init__.py:4702:17: error[unresolved-attribute] Module `torch` has torch/_refs/__init__.py:4705:20: error[unresolved-attribute] Module `torch` has no member `cat` torch/_refs/__init__.py:4708:12: error[unresolved-attribute] Module `torch` has no member `cat` torch/_refs/__init__.py:4750:12: error[unresolved-attribute] Module `torch` has no member `transpose` +torch/_refs/__init__.py:4776:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_refs/__init__.py:4781:12: error[unresolved-attribute] Module `torch` has no member `permute` torch/_refs/__init__.py:4802:23: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/_refs/__init__.py:4812:21: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -11184,6 +11774,7 @@ torch/_refs/__init__.py:5372:44: error[unresolved-attribute] Module `torch` has torch/_refs/__init__.py:5376:13: error[unresolved-attribute] Module `torch` has no member `get_default_dtype` torch/_refs/__init__.py:5386:26: error[unresolved-attribute] Module `torch` has no member `get_default_dtype` torch/_refs/__init__.py:5387:30: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_refs/__init__.py:5409:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_refs/__init__.py:5418:9: error[unresolved-attribute] Module `torch` has no member `int64` torch/_refs/__init__.py:5430:11: error[unresolved-attribute] Module `torch` has no member `where` torch/_refs/__init__.py:5446:21: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -11394,6 +11985,9 @@ torch/_refs/linalg/__init__.py:318:34: error[invalid-argument-type] Argument to torch/_refs/nn/functional/__init__.py:94:50: error[unresolved-attribute] Module `torch` has no member `float32` torch/_refs/nn/functional/__init__.py:116:16: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_refs/nn/functional/__init__.py:130:9: error[unresolved-attribute] Module `torch` has no member `logical_not` +torch/_refs/nn/functional/__init__.py:148:13: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["inplace"]` and value of type `Literal[False]` on object of type `_P@_inplace_wrapper.kwargs` +torch/_refs/nn/functional/__init__.py:155:13: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["inplace"]` and value of type `Literal[False]` on object of type `_P@_inplace_wrapper.kwargs` +torch/_refs/nn/functional/__init__.py:156:13: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["out"]` and value of type `object` on object of type `_P@_inplace_wrapper.kwargs` torch/_refs/nn/functional/__init__.py:191:15: error[unresolved-attribute] Module `torch` has no member `expm1` torch/_refs/nn/functional/__init__.py:193:12: error[unresolved-attribute] Module `torch` has no member `where` torch/_refs/nn/functional/__init__.py:213:16: error[unresolved-attribute] Module `torch` has no member `zeros_like` @@ -11507,7 +12101,19 @@ torch/_subclasses/complex_tensor/_core.py:116:18: error[unresolved-attribute] Mo torch/_subclasses/complex_tensor/_core.py:117:18: error[unresolved-attribute] Module `torch` has no member `imag` torch/_subclasses/complex_tensor/_core.py:117:59: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_subclasses/complex_tensor/_core.py:121:16: error[unresolved-attribute] Module `torch` has no member `complex` +torch/_subclasses/complex_tensor/_ops/aten.py:36:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:36:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:36:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:45:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:45:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:45:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:45:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:46:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:46:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:46:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/aten.py:46:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` torch/_subclasses/complex_tensor/_ops/aten.py:65:49: error[unresolved-attribute] Module `torch` has no member `device` +torch/_subclasses/complex_tensor/_ops/aten.py:187:18: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` torch/_subclasses/complex_tensor/_ops/aten.py:199:14: error[unresolved-attribute] Module `torch` has no member `prod` torch/_subclasses/complex_tensor/_ops/aten.py:199:25: error[unresolved-attribute] Module `torch` has no member `abs` torch/_subclasses/complex_tensor/_ops/aten.py:200:15: error[unresolved-attribute] Module `torch` has no member `sum` @@ -11584,6 +12190,12 @@ torch/_subclasses/complex_tensor/_ops/aten.py:538:16: error[unresolved-attribute torch/_subclasses/complex_tensor/_ops/aten.py:544:13: error[unresolved-attribute] Module `torch` has no member `full_like` torch/_subclasses/complex_tensor/_ops/aten.py:545:13: error[unresolved-attribute] Module `torch` has no member `full_like` torch/_subclasses/complex_tensor/_ops/aten.py:552:44: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_subclasses/complex_tensor/_ops/aten.py:557:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:557:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:562:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:562:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:563:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:563:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_subclasses/complex_tensor/_ops/aten.py:597:13: error[unresolved-attribute] Module `torch` has no member `cat` torch/_subclasses/complex_tensor/_ops/aten.py:598:13: error[unresolved-attribute] Module `torch` has no member `cat` torch/_subclasses/complex_tensor/_ops/aten.py:607:16: error[unresolved-attribute] Module `torch` has no member `abs` @@ -11599,14 +12211,26 @@ torch/_subclasses/complex_tensor/_ops/aten.py:637:30: error[unresolved-attribute torch/_subclasses/complex_tensor/_ops/aten.py:638:30: error[unresolved-attribute] Module `torch` has no member `sin` torch/_subclasses/complex_tensor/_ops/aten.py:648:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_subclasses/complex_tensor/_ops/aten.py:652:34: error[unresolved-attribute] Module `torch` has no member `mm` +torch/_subclasses/complex_tensor/_ops/aten.py:670:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:670:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:670:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:670:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_subclasses/complex_tensor/_ops/aten.py:686:12: error[unresolved-attribute] Module `torch` has no member `logical_not` torch/_subclasses/complex_tensor/_ops/aten.py:692:12: error[unresolved-attribute] Module `torch` has no member `stack` torch/_subclasses/complex_tensor/_ops/aten.py:697:37: error[unresolved-attribute] Module `torch` has no member `abs` +torch/_subclasses/complex_tensor/_ops/aten.py:714:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:715:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_subclasses/complex_tensor/_ops/aten.py:727:12: error[unresolved-attribute] Module `torch` has no member `all` torch/_subclasses/complex_tensor/_ops/aten.py:728:9: error[unresolved-attribute] Module `torch` has no member `isclose` torch/_subclasses/complex_tensor/_ops/aten.py:735:9: error[unresolved-attribute] Module `torch` has no member `stack` torch/_subclasses/complex_tensor/_ops/aten.py:736:9: error[unresolved-attribute] Module `torch` has no member `stack` torch/_subclasses/complex_tensor/_ops/aten.py:752:30: error[unresolved-attribute] Module `torch` has no member `_neg_view` +torch/_subclasses/complex_tensor/_ops/aten.py:822:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:823:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:826:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:826:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/_subclasses/complex_tensor/_ops/aten.py:827:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:827:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/_subclasses/complex_tensor/_ops/aten.py:835:12: error[unresolved-attribute] Module `torch` has no member `var` torch/_subclasses/complex_tensor/_ops/aten.py:835:50: error[unresolved-attribute] Module `torch` has no member `var` torch/_subclasses/complex_tensor/_ops/aten.py:845:14: error[unresolved-attribute] Module `torch` has no member `scatter_add` @@ -11615,6 +12239,12 @@ torch/_subclasses/complex_tensor/_ops/aten.py:890:12: error[unresolved-attribute torch/_subclasses/complex_tensor/_ops/aten.py:893:21: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_subclasses/complex_tensor/_ops/aten.py:893:43: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_subclasses/complex_tensor/_ops/aten.py:894:27: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_subclasses/complex_tensor/_ops/aten.py:909:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:909:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:911:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:911:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:911:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/aten.py:911:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_subclasses/complex_tensor/_ops/common.py:25:5: error[unresolved-attribute] Module `torch` has no member `complex128` torch/_subclasses/complex_tensor/_ops/common.py:25:23: error[unresolved-attribute] Module `torch` has no member `float64` torch/_subclasses/complex_tensor/_ops/common.py:26:5: error[unresolved-attribute] Module `torch` has no member `complex64` @@ -11634,14 +12264,38 @@ torch/_subclasses/complex_tensor/_ops/common.py:81:22: error[unresolved-attribut torch/_subclasses/complex_tensor/_ops/common.py:167:21: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/_subclasses/complex_tensor/_ops/common.py:185:34: error[unresolved-attribute] Module `torch` has no member `dtype` torch/_subclasses/complex_tensor/_ops/common.py:185:50: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_subclasses/complex_tensor/_ops/common.py:222:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:222:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:19: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/common.py:223:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` torch/_subclasses/complex_tensor/_ops/common.py:237:44: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_subclasses/complex_tensor/_ops/common.py:249:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/common.py:249:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/common.py:250:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/common.py:250:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/_subclasses/complex_tensor/_ops/prims.py:18:56: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/_subclasses/complex_tensor/_ops/prims.py:21:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/prims.py:22:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/_subclasses/complex_tensor/_ops/prims.py:29:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` +torch/_subclasses/complex_tensor/_ops/prims.py:34:23: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `ComplexTensor` torch/_subclasses/fake_impls.py:42:10: warning[possibly-missing-attribute] Submodule `_pytree` may not be available as an attribute on module `torch.utils` torch/_subclasses/fake_impls.py:129:19: error[unresolved-attribute] Module `torch._C` has no member `TensorType` torch/_subclasses/fake_impls.py:143:64: error[unresolved-attribute] Module `torch._C` has no member `TensorType` -torch/_subclasses/fake_impls.py:156:34: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[Unknown, Any], /) -> bool) | OpOverload[Unknown, Any]`, found `object` -torch/_subclasses/fake_impls.py:184:19: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[Unknown, Any], /) -> bool) | OpOverload[Unknown, Any]`, found `list[Unknown]` -torch/_subclasses/fake_impls.py:192:13: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[Unknown, Any]`, found `Literal["torch.compile doesn't support named tensors"]` +torch/_subclasses/fake_impls.py:156:34: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[EllipsisType, Any], /) -> bool) | OpOverload[EllipsisType, Any]`, found `object` +torch/_subclasses/fake_impls.py:184:19: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[EllipsisType, Any], /) -> bool) | OpOverload[EllipsisType, Any]`, found `list[Unknown]` +torch/_subclasses/fake_impls.py:192:13: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[EllipsisType, Any]`, found `Literal["torch.compile doesn't support named tensors"]` torch/_subclasses/fake_impls.py:201:26: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_impls.py:205:28: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_impls.py:239:28: error[unresolved-attribute] Module `torch` has no member `device` @@ -11659,9 +12313,9 @@ torch/_subclasses/fake_impls.py:940:32: error[unresolved-attribute] Module `torc torch/_subclasses/fake_impls.py:949:50: error[unresolved-attribute] Module `torch` has no member `bool` torch/_subclasses/fake_impls.py:949:62: error[unresolved-attribute] Module `torch` has no member `uint8` torch/_subclasses/fake_impls.py:977:12: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_has_computed_kernel_for_dispatch_key` -torch/_subclasses/fake_impls.py:1096:9: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[Unknown, Any]`, found `Literal["torch.compile does not support strided NestedTensor"]` -torch/_subclasses/fake_impls.py:1101:5: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[Unknown, Any], /) -> bool) | OpOverload[Unknown, Any]`, found `list[Unknown]` -torch/_subclasses/fake_impls.py:1119:19: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[Unknown, Any], /) -> bool) | OpOverload[Unknown, Any]`, found `list[Unknown | OpOverload[Unknown, Any]]` +torch/_subclasses/fake_impls.py:1096:9: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[EllipsisType, Any]`, found `Literal["torch.compile does not support strided NestedTensor"]` +torch/_subclasses/fake_impls.py:1101:5: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[EllipsisType, Any], /) -> bool) | OpOverload[EllipsisType, Any]`, found `list[Unknown]` +torch/_subclasses/fake_impls.py:1119:19: error[invalid-argument-type] Argument to function `register_op_impl` is incorrect: Expected `((OpOverload[EllipsisType, Any], /) -> bool) | OpOverload[EllipsisType, Any]`, found `list[Unknown | OpOverload[EllipsisType, Any]]` torch/_subclasses/fake_impls.py:1140:32: error[unresolved-attribute] Module `torch._C` has no member `_select_conv_backend` torch/_subclasses/fake_impls.py:1142:32: error[unresolved-attribute] Module `torch._C` has no member `_select_conv_backend` torch/_subclasses/fake_impls.py:1166:23: error[unresolved-attribute] Module `torch._C` has no member `_conv_determine_backend_memory_format` @@ -11729,6 +12383,8 @@ torch/_subclasses/fake_tensor.py:818:17: warning[possibly-missing-attribute] Sub torch/_subclasses/fake_tensor.py:840:24: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_tensor.py:885:31: error[unresolved-attribute] Module `torch._C` has no member `_get_dispatch_mode` torch/_subclasses/fake_tensor.py:886:13: error[unresolved-attribute] Module `torch._C` has no member `_TorchDispatchModeKey` +torch/_subclasses/fake_tensor.py:899:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/_subclasses/fake_tensor.py:899:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/_subclasses/fake_tensor.py:904:16: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_tensor.py:924:38: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_tensor.py:1000:29: error[unresolved-attribute] Module `torch` has no member `device` @@ -11766,6 +12422,8 @@ torch/_subclasses/fake_tensor.py:1964:17: error[invalid-argument-type] Argument torch/_subclasses/fake_tensor.py:2031:21: error[unresolved-attribute] Module `torch` has no member `empty_strided` torch/_subclasses/fake_tensor.py:2041:13: error[unresolved-attribute] Module `torch._C` has no member `_set_conj` torch/_subclasses/fake_tensor.py:2043:13: error[unresolved-attribute] Module `torch._C` has no member `_set_neg` +torch/_subclasses/fake_tensor.py:2152:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/_subclasses/fake_tensor.py:2152:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/_subclasses/fake_tensor.py:2469:17: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_subclasses/fake_tensor.py:2470:17: error[unresolved-attribute] Module `torch` has no member `Tag` torch/_subclasses/fake_tensor.py:2478:17: error[unresolved-attribute] Object of type `object` has no attribute `constant` @@ -11786,6 +12444,8 @@ torch/_subclasses/fake_tensor.py:3161:20: error[unresolved-attribute] Object of torch/_subclasses/fake_tensor.py:3162:37: error[unresolved-attribute] Object of type `T@to_real_tensor` has no attribute `is_coalesced` torch/_subclasses/fake_tensor.py:3236:20: error[unresolved-attribute] Module `torch._C` has no member `TensorBase` torch/_subclasses/fake_tensor.py:3253:18: error[unresolved-attribute] Module `torch._C` has no member `DisableTorchFunctionSubclass` +torch/_subclasses/fake_tensor.py:3254:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/_subclasses/fake_tensor.py:3254:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/_subclasses/fake_tensor.py:3257:48: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_tensor.py:3266:16: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/fake_tensor.py:3371:9: warning[possibly-missing-attribute] Submodule `fake_impl` may not be available as an attribute on module `torch._library` @@ -11826,6 +12486,7 @@ torch/_subclasses/functional_tensor.py:248:9: error[unresolved-attribute] Module torch/_subclasses/functional_tensor.py:251:9: error[unresolved-attribute] Module `torch` has no member `_functionalize_sync` torch/_subclasses/functional_tensor.py:254:9: error[unresolved-attribute] Module `torch` has no member `_functionalize_mark_mutation_hidden_from_autograd` torch/_subclasses/functional_tensor.py:265:31: error[unresolved-attribute] Module `torch._C` has no member `_TorchDispatchModeKey` +torch/_subclasses/functional_tensor.py:267:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Self@to` torch/_subclasses/functional_tensor.py:282:46: error[unresolved-attribute] Module `torch` has no member `int8` torch/_subclasses/functional_tensor.py:283:46: error[unresolved-attribute] Module `torch` has no member `device` torch/_subclasses/functional_tensor.py:284:50: error[unresolved-attribute] Module `torch` has no member `bfloat16` @@ -11942,11 +12603,20 @@ torch/_subclasses/meta_utils.py:1132:26: warning[possibly-missing-attribute] Sub torch/_subclasses/meta_utils.py:1188:17: warning[possibly-missing-attribute] Submodule `symbolic_shapes` may not be available as an attribute on module `torch.fx.experimental` torch/_subclasses/meta_utils.py:1273:25: warning[possibly-missing-attribute] Submodule `symbolic_shapes` may not be available as an attribute on module `torch.fx.experimental` torch/_subclasses/meta_utils.py:1280:32: error[invalid-return-type] Return type does not match returned value: expected `Tensor`, found `None` +torch/_subclasses/meta_utils.py:1339:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | None` +torch/_subclasses/meta_utils.py:1340:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | None` +torch/_subclasses/meta_utils.py:1341:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[int, ...]` torch/_subclasses/meta_utils.py:1343:36: error[unresolved-attribute] Module `torch` has no member `sparse_coo` +torch/_subclasses/meta_utils.py:1344:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal["meta"]` torch/_subclasses/meta_utils.py:1373:37: error[unresolved-attribute] Module `torch` has no member `sparse_bsr` torch/_subclasses/meta_utils.py:1373:55: error[unresolved-attribute] Module `torch` has no member `sparse_bsc` torch/_subclasses/meta_utils.py:1381:37: error[unresolved-attribute] Module `torch` has no member `sparse_csr` torch/_subclasses/meta_utils.py:1381:55: error[unresolved-attribute] Module `torch` has no member `sparse_bsr` +torch/_subclasses/meta_utils.py:1390:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/_subclasses/meta_utils.py:1391:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | None` +torch/_subclasses/meta_utils.py:1392:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[int, ...]` +torch/_subclasses/meta_utils.py:1393:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[int, ...]` +torch/_subclasses/meta_utils.py:1397:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal["meta"]` torch/_subclasses/meta_utils.py:1435:33: error[unresolved-attribute] Module `torch` has no member `empty_strided` torch/_subclasses/meta_utils.py:1444:45: error[unresolved-attribute] Module `torch` has no member `empty_strided` torch/_subclasses/meta_utils.py:1483:34: warning[possibly-missing-attribute] Submodule `_functorch` may not be available as an attribute on module `torch` @@ -12098,6 +12768,7 @@ torch/_tensor_str.py:580:34: error[unresolved-attribute] Module `torch` has no m torch/_tensor_str.py:585:31: error[unresolved-attribute] Module `torch` has no member `per_channel_affine` torch/_tensor_str.py:586:34: error[unresolved-attribute] Module `torch` has no member `per_channel_symmetric` torch/_tensor_str.py:587:34: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` +torch/_tensor_str.py:602:58: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` torch/_tensor_str.py:605:10: error[unresolved-attribute] Module `torch` has no member `_is_functional_tensor` torch/_tensor_str.py:607:27: error[unresolved-attribute] Module `torch` has no member `_from_functional_tensor` torch/_tensor_str.py:614:30: error[unresolved-attribute] Module `torch` has no member `get_default_dtype` @@ -12597,16 +13268,17 @@ torch/_utils.py:974:13: error[unresolved-attribute] Module `torch._C` has no mem torch/_utils.py:980:17: error[unresolved-attribute] Module `torch._C` has no member `_set_dispatch_mode` torch/_utils.py:1063:17: warning[possibly-missing-attribute] Submodule `util` may not be available as an attribute on module `importlib` torch/_utils.py:1064:18: warning[possibly-missing-attribute] Submodule `util` may not be available as an attribute on module `importlib` +torch/_utils_internal.py:92:17: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["skip"]` and value of type `int` on object of type `_P@compile_time_strobelight_meta.kwargs` torch/_utils_internal.py:230:14: error[unresolved-import] Cannot resolve imported module `triton.testing` -torch/_utils_internal.py:314:17: error[unresolved-attribute] Object of type `(...) -> _T@decorator` has no attribute `__name__` -torch/_utils_internal.py:320:23: error[unresolved-attribute] Object of type `(...) -> _T@decorator` has no attribute `__name__` -torch/_utils_internal.py:330:26: error[unresolved-attribute] Object of type `(...) -> _T@decorator` has no attribute `__name__` +torch/_utils_internal.py:314:17: error[unresolved-attribute] Object of type `(**_P@decorator) -> _T@decorator` has no attribute `__name__` +torch/_utils_internal.py:320:23: error[unresolved-attribute] Object of type `(**_P@decorator) -> _T@decorator` has no attribute `__name__` +torch/_utils_internal.py:330:26: error[unresolved-attribute] Object of type `(**_P@decorator) -> _T@decorator` has no attribute `__name__` torch/_utils_internal.py:335:13: error[invalid-argument-type] Argument to class `deprecated` is incorrect: Expected `LiteralString`, found `str` -torch/_utils_internal.py:340:9: error[unresolved-attribute] Unresolved attribute `__name__` on type `(...) -> _T@decorator`. -torch/_utils_internal.py:343:19: error[unresolved-attribute] Object of type `(...) -> _T@decorator` has no attribute `__qualname__` -torch/_utils_internal.py:344:13: error[unresolved-attribute] Unresolved attribute `__qualname__` on type `(...) -> _T@decorator`. -torch/_utils_internal.py:344:34: error[unresolved-attribute] Object of type `(...) -> _T@decorator` has no attribute `__qualname__` -torch/_utils_internal.py:346:13: error[unresolved-attribute] Unresolved attribute `__qualname__` on type `(...) -> _T@decorator`. +torch/_utils_internal.py:340:9: error[unresolved-attribute] Unresolved attribute `__name__` on type `(**_P@decorator) -> _T@decorator`. +torch/_utils_internal.py:343:19: error[unresolved-attribute] Object of type `(**_P@decorator) -> _T@decorator` has no attribute `__qualname__` +torch/_utils_internal.py:344:13: error[unresolved-attribute] Unresolved attribute `__qualname__` on type `(**_P@decorator) -> _T@decorator`. +torch/_utils_internal.py:344:34: error[unresolved-attribute] Object of type `(**_P@decorator) -> _T@decorator` has no attribute `__qualname__` +torch/_utils_internal.py:346:13: error[unresolved-attribute] Unresolved attribute `__qualname__` on type `(**_P@decorator) -> _T@decorator`. torch/_vmap_internals.py:110:36: error[unresolved-attribute] Module `torch` has no member `_add_batch_dim` torch/_vmap_internals.py:142:17: error[unresolved-attribute] Module `torch` has no member `_remove_batch_dim` torch/_vmap_internals.py:150:13: error[unresolved-attribute] Module `torch` has no member `_remove_batch_dim` @@ -12726,22 +13398,61 @@ torch/ao/nn/intrinsic/qat/modules/linear_fused.py:140:9: error[unresolved-attrib torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:41:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:41:30: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:46:41: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:49:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:49:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:51:43: error[unresolved-attribute] Module `torch` has no member `float16` +torch/ao/nn/intrinsic/quantized/dynamic/modules/linear_relu.py:53:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:37:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:38:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:39:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:40:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:41:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:42:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:43:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:57:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `_BatchNorm.from_reference` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:86:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:87:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:88:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:89:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:90:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:91:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:92:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/intrinsic/quantized/modules/bn_relu.py:106:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `_BatchNorm.from_reference` +torch/ao/nn/intrinsic/quantized/modules/conv_add.py:64:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/intrinsic/quantized/modules/conv_add.py:77:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/intrinsic/quantized/modules/conv_add.py:133:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/intrinsic/quantized/modules/conv_add.py:146:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:75:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:97:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:156:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:180:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:239:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/intrinsic/quantized/modules/conv_relu.py:263:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:36:68: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:41:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:41:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:41:64: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:52:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `Linear.from_reference` torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:78:75: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:85:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:87:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:88:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:108:25: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:114:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_float` with custom `__setattr__` method. +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:115:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:119:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `Linear.from_reference` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:127:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_reference` with custom `__setattr__` method. +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:128:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_reference` with custom `__setattr__` method. torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:153:68: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:158:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:158:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:158:64: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:174:25: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:178:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_float` with custom `__setattr__` method. +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:179:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:183:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `Linear.from_reference` +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:188:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_reference` with custom `__setattr__` method. +torch/ao/nn/intrinsic/quantized/modules/linear_relu.py:189:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_reference` with custom `__setattr__` method. torch/ao/nn/qat/dynamic/modules/linear.py:32:29: error[unresolved-attribute] Module `torch` has no member `device` torch/ao/nn/qat/modules/conv.py:115:20: error[call-non-callable] Object of type `object` is not callable torch/ao/nn/qat/modules/embedding_ops.py:54:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `bool`, found `Unknown | None` @@ -12749,6 +13460,9 @@ torch/ao/nn/qat/modules/embedding_ops.py:57:44: error[unresolved-attribute] Modu torch/ao/nn/qat/modules/embedding_ops.py:91:34: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/qat/modules/embedding_ops.py:176:44: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/qat/modules/embedding_ops.py:214:34: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` +torch/ao/nn/quantizable/modules/activation.py:173:17: error[invalid-assignment] Object of type `None` is not assignable to attribute `bias` on type `Unknown | Linear` +torch/ao/nn/quantizable/modules/activation.py:175:17: error[invalid-assignment] Object of type `None` is not assignable to attribute `bias` on type `Unknown | Linear` +torch/ao/nn/quantizable/modules/activation.py:177:17: error[invalid-assignment] Object of type `None` is not assignable to attribute `bias` on type `Unknown | Linear` torch/ao/nn/quantizable/modules/activation.py:190:42: warning[deprecated] The function `prepare` is deprecated: torch.ao.quantization is deprecated and will be removed in 2.10. For migrations of users: 1. Eager mode quantization (torch.ao.quantization.quantize, torch.ao.quantization.quantize_dynamic), please migrate to use torchao eager mode quantize_ API instead @@ -12795,6 +13509,7 @@ torch/ao/nn/quantizable/modules/rnn.py:255:25: error[unresolved-attribute] Modul torch/ao/nn/quantizable/modules/rnn.py:285:9: error[unresolved-attribute] Cannot assign object of type `bool` to attribute `batch_first` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:286:9: error[unresolved-attribute] Cannot assign object of type `bool` to attribute `bidirectional` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:334:22: error[unresolved-attribute] Module `torch` has no member `cat` +torch/ao/nn/quantizable/modules/rnn.py:379:9: error[unresolved-attribute] Cannot assign object of type `Any | None` to attribute `qconfig` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:446:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `input_size` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:447:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `hidden_size` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:448:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `num_layers` on type `Self@__init__` with custom `__setattr__` method. @@ -12808,6 +13523,7 @@ torch/ao/nn/quantizable/modules/rnn.py:519:23: error[unresolved-attribute] Modul torch/ao/nn/quantizable/modules/rnn.py:524:25: error[unresolved-attribute] Module `torch` has no member `quantize_per_tensor` torch/ao/nn/quantizable/modules/rnn.py:550:21: error[unresolved-attribute] Module `torch` has no member `stack` torch/ao/nn/quantizable/modules/rnn.py:551:21: error[unresolved-attribute] Module `torch` has no member `stack` +torch/ao/nn/quantizable/modules/rnn.py:581:9: error[unresolved-attribute] Cannot assign object of type `Any | None` to attribute `qconfig` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/quantizable/modules/rnn.py:590:46: warning[deprecated] The function `prepare_qat` is deprecated: torch.ao.quantization is deprecated and will be removed in 2.10. For migrations of users: 1. Eager mode quantization (torch.ao.quantization.quantize, torch.ao.quantization.quantize_dynamic), please migrate to use torchao eager mode quantize_ API instead @@ -12820,9 +13536,22 @@ For migrations of users: 2. FX graph mode quantization (torch.ao.quantization.quantize_fx.prepare_fx,torch.ao.quantization.quantize_fx.convert_fx, please migrate to use torchao pt2e quantization API instead (prepare_pt2e, convert_pt2e) 3. pt2e quantization has been migrated to torchao (https://github.com/pytorch/ao/tree/main/torchao/quantization/pt2e) see https://github.com/pytorch/ao/issues/2259 for more details +torch/ao/nn/quantized/dynamic/modules/conv.py:108:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:108:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/conv.py:194:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:194:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/conv.py:281:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:281:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/conv.py:363:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:363:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/conv.py:446:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:446:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/conv.py:529:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/conv.py:529:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/ao/nn/quantized/dynamic/modules/linear.py:42:69: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/linear.py:48:9: error[unresolved-attribute] Cannot assign object of type `Literal[4]` to attribute `version` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/dynamic/modules/linear.py:52:41: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/dynamic/modules/linear.py:59:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/quantized/dynamic/modules/linear.py:61:43: error[unresolved-attribute] Module `torch` has no member `float16` torch/ao/nn/quantized/dynamic/modules/linear.py:74:41: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/linear.py:112:13: warning[possibly-missing-attribute] Submodule `dynamic` may not be available as an attribute on module `torch.ao.nn.qat` @@ -12852,13 +13581,54 @@ torch/ao/nn/quantized/dynamic/modules/rnn.py:162:28: error[unresolved-attribute] torch/ao/nn/quantized/dynamic/modules/rnn.py:163:62: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/rnn.py:165:28: error[unresolved-attribute] Module `torch` has no member `quantize_per_tensor` torch/ao/nn/quantized/dynamic/modules/rnn.py:166:62: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/dynamic/modules/rnn.py:179:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/quantized/dynamic/modules/rnn.py:328:34: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/dynamic/modules/rnn.py:340:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/quantized/dynamic/modules/rnn.py:372:35: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/rnn.py:372:48: error[unresolved-attribute] Module `torch` has no member `float16` torch/ao/nn/quantized/dynamic/modules/rnn.py:425:29: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/dynamic/modules/rnn.py:445:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/quantized/dynamic/modules/rnn.py:449:31: error[unresolved-attribute] Module `torch` has no member `float16` torch/ao/nn/quantized/dynamic/modules/rnn.py:546:21: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/ao/nn/quantized/dynamic/modules/rnn.py:564:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:565:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown, Unknown] | tuple[Tensor, Tensor]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:566:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:567:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[True]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:568:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:569:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/ao/nn/quantized/dynamic/modules/rnn.py:570:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/rnn.py:571:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:572:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:574:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:578:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:579:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:580:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Unknown, Unknown] | tuple[Tensor, Tensor]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:581:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:582:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[True]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:583:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:584:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/ao/nn/quantized/dynamic/modules/rnn.py:585:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/rnn.py:586:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:588:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` torch/ao/nn/quantized/dynamic/modules/rnn.py:842:21: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/ao/nn/quantized/dynamic/modules/rnn.py:860:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:861:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:862:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:863:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[True]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:864:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:865:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/dynamic/modules/rnn.py:866:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/rnn.py:867:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:868:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:872:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:873:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:874:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:875:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:876:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[True]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:877:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/dynamic/modules/rnn.py:878:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/dynamic/modules/rnn.py:879:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/dynamic/modules/rnn.py:880:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` torch/ao/nn/quantized/dynamic/modules/rnn.py:957:71: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/rnn.py:962:9: error[unresolved-attribute] Cannot assign object of type `Unknown | Literal[True]` to attribute `bias` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/dynamic/modules/rnn.py:965:28: error[unresolved-attribute] Module `torch` has no member `randn` @@ -12881,24 +13651,60 @@ torch/ao/nn/quantized/dynamic/modules/rnn.py:1093:25: error[unresolved-attribute torch/ao/nn/quantized/dynamic/modules/rnn.py:1223:78: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/rnn.py:1226:9: error[unresolved-attribute] Cannot assign object of type `Unknown | Literal["tanh"]` to attribute `nonlinearity` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/dynamic/modules/rnn.py:1234:18: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1240:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1241:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1249:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1250:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` torch/ao/nn/quantized/dynamic/modules/rnn.py:1299:21: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1306:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1307:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Tensor, Tensor] | tuple[Unknown, Unknown]` torch/ao/nn/quantized/dynamic/modules/rnn.py:1340:66: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/dynamic/modules/rnn.py:1349:18: error[unresolved-attribute] Module `torch` has no member `zeros` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1354:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/dynamic/modules/rnn.py:1355:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` torch/ao/nn/quantized/functional.py:184:11: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:227:23: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:231:24: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/functional.py:240:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/functional.py:242:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/functional.py:242:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` torch/ao/nn/quantized/functional.py:256:11: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:299:23: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:303:24: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/functional.py:312:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/functional.py:314:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/functional.py:314:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` torch/ao/nn/quantized/functional.py:328:11: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:375:23: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/functional.py:379:24: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/functional.py:388:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/ao/nn/quantized/functional.py:390:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/functional.py:390:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/ao/nn/quantized/functional.py:473:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:473:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/functional.py:474:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:474:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | Unknown` +torch/ao/nn/quantized/functional.py:474:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | Unknown` +torch/ao/nn/quantized/functional.py:553:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:553:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/functional.py:553:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/functional.py:553:63: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/ao/nn/quantized/functional.py:580:18: error[unresolved-attribute] Module `torch` has no member `_empty_affine_quantized` torch/ao/nn/quantized/functional.py:583:9: error[unresolved-attribute] Module `torch._C` has no member `_nn` torch/ao/nn/quantized/functional.py:586:18: error[unresolved-attribute] Module `torch._C` has no member `_nn` torch/ao/nn/quantized/functional.py:588:18: error[unresolved-attribute] Module `torch._C` has no member `_nn` torch/ao/nn/quantized/functional.py:599:16: error[unresolved-attribute] Module `torch._C` has no member `_nn` torch/ao/nn/quantized/functional.py:600:12: error[unresolved-attribute] Module `torch._C` has no member `_nn` +torch/ao/nn/quantized/functional.py:613:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:613:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/functional.py:613:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/functional.py:633:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:633:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/functional.py:633:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/functional.py:647:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/functional.py:647:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/functional.py:647:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/functional.py:647:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` torch/ao/nn/quantized/functional.py:656:12: error[unresolved-attribute] Module `torch._C` has no member `_nn` torch/ao/nn/quantized/functional.py:672:12: error[unresolved-attribute] Module `torch` has no member `clamp` torch/ao/nn/quantized/modules/__init__.py:111:39: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -12906,15 +13712,27 @@ torch/ao/nn/quantized/modules/__init__.py:114:13: error[unresolved-attribute] Mo torch/ao/nn/quantized/modules/__init__.py:116:23: error[unresolved-attribute] Module `torch` has no member `long` torch/ao/nn/quantized/modules/__init__.py:123:16: error[unresolved-attribute] Module `torch` has no member `quantize_per_tensor` torch/ao/nn/quantized/modules/activation.py:46:9: error[unresolved-attribute] Cannot assign object of type `Unknown | Literal[False]` to attribute `inplace` on type `Self@__init__` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/activation.py:49:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/ao/nn/quantized/modules/activation.py:71:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/activation.py:73:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/activation.py:76:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/activation.py:76:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/activation.py:144:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/activation.py:146:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/activation.py:150:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/activation.py:150:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/ao/nn/quantized/modules/activation.py:150:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/activation.py:150:67: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/activation.py:176:9: error[unresolved-attribute] Cannot assign object of type `int | float` to attribute `output_scale` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/activation.py:177:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `output_zero_point` on type `Self@__init__` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/activation.py:181:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int | float` +torch/ao/nn/quantized/modules/activation.py:181:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/quantized/modules/activation.py:204:9: error[unresolved-attribute] Cannot assign object of type `Unknown | None` to attribute `dim` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/activation.py:205:9: error[unresolved-attribute] Cannot assign object of type `Unknown | float` to attribute `scale` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/activation.py:206:9: error[unresolved-attribute] Cannot assign object of type `Unknown | Literal[0]` to attribute `zero_point` on type `Self@__init__` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/activation.py:217:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/modules/activation.py:217:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/activation.py:217:68: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` torch/ao/nn/quantized/modules/activation.py:251:43: warning[deprecated] The function `convert` is deprecated: torch.ao.quantization is deprecated and will be removed in 2.10. For migrations of users: 1. Eager mode quantization (torch.ao.quantization.quantize, torch.ao.quantization.quantize_dynamic), please migrate to use torchao eager mode quantize_ API instead @@ -12934,6 +13752,10 @@ torch/ao/nn/quantized/modules/activation.py:301:13: error[unresolved-attribute] torch/ao/nn/quantized/modules/activation.py:301:47: error[unresolved-attribute] Module `torch` has no member `float` torch/ao/nn/quantized/modules/activation.py:302:14: error[unresolved-attribute] Module `torch` has no member `quantize_per_tensor` torch/ao/nn/quantized/modules/activation.py:302:74: error[unresolved-attribute] Module `torch` has no member `quint8` +torch/ao/nn/quantized/modules/activation.py:310:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/activation.py:310:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/ao/nn/quantized/modules/activation.py:310:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int | float` +torch/ao/nn/quantized/modules/activation.py:310:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/quantized/modules/activation.py:323:30: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/activation.py:329:19: error[unresolved-attribute] Module `torch` has no member `quantize_per_tensor` torch/ao/nn/quantized/modules/activation.py:330:52: error[unresolved-attribute] Module `torch` has no member `quint8` @@ -12942,6 +13764,22 @@ torch/ao/nn/quantized/modules/activation.py:347:19: error[unresolved-attribute] torch/ao/nn/quantized/modules/activation.py:348:52: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/batchnorm.py:16:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/batchnorm.py:18:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/batchnorm.py:77:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/batchnorm.py:78:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/batchnorm.py:79:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/batchnorm.py:80:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/batchnorm.py:81:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/batchnorm.py:82:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/batchnorm.py:83:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/batchnorm.py:84:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/batchnorm.py:116:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/batchnorm.py:117:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/batchnorm.py:118:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/batchnorm.py:119:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/batchnorm.py:120:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/batchnorm.py:121:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/batchnorm.py:122:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/batchnorm.py:123:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/conv.py:93:9: error[unresolved-attribute] Cannot assign object of type `Unknown | Literal["zeros"]` to attribute `padding_mode` on type `Self@_init` with custom `__setattr__` method. torch/ao/nn/quantized/modules/conv.py:99:19: error[unresolved-attribute] Module `torch` has no member `_empty_affine_quantized` torch/ao/nn/quantized/modules/conv.py:103:19: error[unresolved-attribute] Module `torch` has no member `qint8` @@ -12955,15 +13793,43 @@ torch/ao/nn/quantized/modules/conv.py:203:9: error[unresolved-attribute] Cannot torch/ao/nn/quantized/modules/conv.py:205:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/quantized/modules/conv.py:250:45: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/modules/conv.py:269:49: error[unresolved-attribute] Module `torch` has no member `float` +torch/ao/nn/quantized/modules/conv.py:274:13: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@get_qconv` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/conv.py:275:13: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@get_qconv` with custom `__setattr__` method. torch/ao/nn/quantized/modules/conv.py:325:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/quantized/modules/conv.py:348:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_reference` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/conv.py:349:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_reference` with custom `__setattr__` method. torch/ao/nn/quantized/modules/conv.py:435:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:438:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:438:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:442:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:442:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:467:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/quantized/modules/conv.py:567:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:570:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:570:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:574:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:574:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:597:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/quantized/modules/conv.py:698:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:701:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:701:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:705:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:705:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/conv.py:728:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` torch/ao/nn/quantized/modules/conv.py:815:45: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/modules/conv.py:820:17: error[missing-argument] No argument provided for required parameter `padding_mode` of bound method `__init__` torch/ao/nn/quantized/modules/conv.py:835:53: error[unresolved-attribute] Module `torch` has no member `float` +torch/ao/nn/quantized/modules/conv.py:840:13: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_float` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/conv.py:841:13: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/quantized/modules/conv.py:960:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:962:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:963:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/ao/nn/quantized/modules/conv.py:1083:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:1085:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:1086:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/ao/nn/quantized/modules/conv.py:1208:9: error[invalid-method-override] Invalid override of method `set_weight_bias`: Definition is incompatible with `_ConvNd.set_weight_bias` +torch/ao/nn/quantized/modules/conv.py:1210:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/conv.py:1211:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/ao/nn/quantized/modules/embedding_ops.py:16:61: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:19:27: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:19:41: error[unresolved-attribute] Module `torch` has no member `quint4x2` @@ -12974,6 +13840,7 @@ torch/ao/nn/quantized/modules/embedding_ops.py:21:61: error[unresolved-attribute torch/ao/nn/quantized/modules/embedding_ops.py:22:18: error[unresolved-attribute] Module `torch` has no member `_empty_per_channel_affine_quantized` torch/ao/nn/quantized/modules/embedding_ops.py:37:27: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:37:41: error[unresolved-attribute] Module `torch` has no member `quint4x2` +torch/ao/nn/quantized/modules/embedding_ops.py:38:77: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/ao/nn/quantized/modules/embedding_ops.py:46:27: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:46:41: error[unresolved-attribute] Module `torch` has no member `quint4x2` torch/ao/nn/quantized/modules/embedding_ops.py:131:15: error[unresolved-attribute] Module `torch` has no member `quint8` @@ -12986,6 +13853,8 @@ torch/ao/nn/quantized/modules/embedding_ops.py:140:61: error[unresolved-attribut torch/ao/nn/quantized/modules/embedding_ops.py:141:23: error[unresolved-attribute] Module `torch` has no member `_empty_per_channel_affine_quantized` torch/ao/nn/quantized/modules/embedding_ops.py:146:23: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:161:26: error[unresolved-attribute] Module `torch` has no member `quint4x2` +torch/ao/nn/quantized/modules/embedding_ops.py:163:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/embedding_ops.py:167:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/ao/nn/quantized/modules/embedding_ops.py:226:40: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/quantized/modules/embedding_ops.py:232:25: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:232:50: error[unresolved-attribute] Module `torch` has no member `quint4x2` @@ -12994,6 +13863,22 @@ torch/ao/nn/quantized/modules/embedding_ops.py:301:9: error[unresolved-attribute torch/ao/nn/quantized/modules/embedding_ops.py:302:9: error[unresolved-attribute] Cannot assign object of type `Literal[False]` to attribute `pruned_weights` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/embedding_ops.py:303:9: error[unresolved-attribute] Cannot assign object of type `bool` to attribute `include_last_offset` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/embedding_ops.py:313:26: error[unresolved-attribute] Module `torch` has no member `quint4x2` +torch/ao/nn/quantized/modules/embedding_ops.py:316:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/embedding_ops.py:317:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:318:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/ao/nn/quantized/modules/embedding_ops.py:319:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/nn/quantized/modules/embedding_ops.py:320:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/modules/embedding_ops.py:321:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:322:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:323:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | bool` +torch/ao/nn/quantized/modules/embedding_ops.py:328:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/embedding_ops.py:329:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:330:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/ao/nn/quantized/modules/embedding_ops.py:331:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/nn/quantized/modules/embedding_ops.py:332:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/ao/nn/quantized/modules/embedding_ops.py:333:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:334:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/quantized/modules/embedding_ops.py:335:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | bool` torch/ao/nn/quantized/modules/embedding_ops.py:370:40: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/quantized/modules/embedding_ops.py:376:25: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/modules/embedding_ops.py:376:50: error[unresolved-attribute] Module `torch` has no member `quint4x2` @@ -13018,6 +13903,30 @@ torch/ao/nn/quantized/modules/functional_modules.py:200:41: error[unresolved-att torch/ao/nn/quantized/modules/functional_modules.py:201:46: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/functional_modules.py:213:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/quantized/modules/functional_modules.py:214:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@_load_from_state_dict` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/functional_modules.py:240:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:240:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:240:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/functional_modules.py:240:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` +torch/ao/nn/quantized/modules/functional_modules.py:247:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:247:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/functional_modules.py:255:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:255:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:255:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/functional_modules.py:255:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` +torch/ao/nn/quantized/modules/functional_modules.py:262:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:262:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/functional_modules.py:270:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/ao/nn/quantized/modules/functional_modules.py:270:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/functional_modules.py:270:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` +torch/ao/nn/quantized/modules/functional_modules.py:270:80: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/modules/functional_modules.py:277:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:277:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:277:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/functional_modules.py:277:60: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` +torch/ao/nn/quantized/modules/functional_modules.py:284:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:284:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/functional_modules.py:284:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/functional_modules.py:284:58: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/quantized/modules/functional_modules.py:296:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `QFunctional` with custom `__setattr__` method. torch/ao/nn/quantized/modules/functional_modules.py:297:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `QFunctional` with custom `__setattr__` method. torch/ao/nn/quantized/modules/linear.py:21:30: error[unresolved-attribute] Module `torch` has no member `qint8` @@ -13028,7 +13937,11 @@ torch/ao/nn/quantized/modules/linear.py:28:28: error[unresolved-attribute] Modul torch/ao/nn/quantized/modules/linear.py:29:18: error[unresolved-attribute] Module `torch` has no member `zeros` torch/ao/nn/quantized/modules/linear.py:29:44: error[unresolved-attribute] Module `torch` has no member `float` torch/ao/nn/quantized/modules/linear.py:34:26: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/modules/linear.py:35:70: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/linear.py:35:78: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/ao/nn/quantized/modules/linear.py:36:28: error[unresolved-attribute] Module `torch` has no member `float16` +torch/ao/nn/quantized/modules/linear.py:37:75: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/linear.py:37:83: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` torch/ao/nn/quantized/modules/linear.py:43:26: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/modules/linear.py:45:28: error[unresolved-attribute] Module `torch` has no member `float16` torch/ao/nn/quantized/modules/linear.py:86:26: error[unresolved-attribute] Module `torch` has no member `qint8` @@ -13043,23 +13956,57 @@ torch/ao/nn/quantized/modules/linear.py:166:23: error[unresolved-attribute] Modu torch/ao/nn/quantized/modules/linear.py:166:70: error[unresolved-attribute] Module `torch` has no member `float` torch/ao/nn/quantized/modules/linear.py:172:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/quantized/modules/linear.py:173:9: error[unresolved-attribute] Cannot assign object of type `Literal[0]` to attribute `zero_point` on type `Self@__init__` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/linear.py:189:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/modules/linear.py:189:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/quantized/modules/linear.py:189:64: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/quantized/modules/linear.py:223:41: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/linear.py:224:46: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/linear.py:239:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/quantized/modules/linear.py:242:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/quantized/modules/linear.py:337:25: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/quantized/modules/linear.py:341:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_float` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/linear.py:342:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_float` with custom `__setattr__` method. torch/ao/nn/quantized/modules/linear.py:346:9: error[invalid-method-override] Invalid override of method `from_reference`: Definition is incompatible with `WeightedQuantizedModule.from_reference` +torch/ao/nn/quantized/modules/linear.py:359:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_reference` with custom `__setattr__` method. +torch/ao/nn/quantized/modules/linear.py:360:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_reference` with custom `__setattr__` method. torch/ao/nn/quantized/modules/normalization.py:41:13: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `bool`, found `Unknown | None` torch/ao/nn/quantized/modules/normalization.py:46:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/normalization.py:48:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/normalization.py:53:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[int, ...]` +torch/ao/nn/quantized/modules/normalization.py:54:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:55:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:56:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/normalization.py:57:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/normalization.py:58:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/normalization.py:120:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/normalization.py:122:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/normalization.py:127:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/modules/normalization.py:128:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:129:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:130:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/normalization.py:131:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/normalization.py:132:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/normalization.py:184:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/normalization.py:186:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/normalization.py:190:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:190:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:190:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/normalization.py:190:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/normalization.py:190:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/normalization.py:253:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/normalization.py:255:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/normalization.py:259:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:259:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:259:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/normalization.py:259:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/normalization.py:259:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/normalization.py:322:39: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/quantized/modules/normalization.py:324:44: error[unresolved-attribute] Module `torch` has no member `tensor` +torch/ao/nn/quantized/modules/normalization.py:328:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:328:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Parameter` +torch/ao/nn/quantized/modules/normalization.py:328:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/ao/nn/quantized/modules/normalization.py:328:54: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` +torch/ao/nn/quantized/modules/normalization.py:328:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Module` torch/ao/nn/quantized/modules/rnn.py:55:43: warning[deprecated] The function `convert` is deprecated: torch.ao.quantization is deprecated and will be removed in 2.10. For migrations of users: 1. Eager mode quantization (torch.ao.quantization.quantize, torch.ao.quantization.quantize_dynamic), please migrate to use torchao eager mode quantize_ API instead @@ -13189,11 +14136,22 @@ torch/ao/nn/quantized/reference/modules/utils.py:214:26: error[unresolved-attrib torch/ao/nn/quantized/reference/modules/utils.py:215:29: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/reference/modules/utils.py:215:43: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/reference/modules/utils.py:215:56: error[unresolved-attribute] Module `torch` has no member `qint32` +torch/ao/nn/quantized/reference/modules/utils.py:222:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:223:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:224:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:225:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:226:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/ao/nn/quantized/reference/modules/utils.py:231:9: error[unresolved-attribute] Module `torch` has no member `per_channel_affine` torch/ao/nn/quantized/reference/modules/utils.py:232:9: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/quantized/reference/modules/utils.py:235:29: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/reference/modules/utils.py:235:43: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/reference/modules/utils.py:235:56: error[unresolved-attribute] Module `torch` has no member `qint32` +torch/ao/nn/quantized/reference/modules/utils.py:242:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:243:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:244:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:245:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:246:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:247:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/ao/nn/quantized/reference/modules/utils.py:256:21: error[unresolved-attribute] Module `torch` has no member `qscheme` torch/ao/nn/quantized/reference/modules/utils.py:257:19: error[unresolved-attribute] Module `torch` has no member `dtype` torch/ao/nn/quantized/reference/modules/utils.py:265:35: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -13210,11 +14168,22 @@ torch/ao/nn/quantized/reference/modules/utils.py:279:26: error[unresolved-attrib torch/ao/nn/quantized/reference/modules/utils.py:280:29: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/reference/modules/utils.py:280:43: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/reference/modules/utils.py:280:56: error[unresolved-attribute] Module `torch` has no member `qint32` +torch/ao/nn/quantized/reference/modules/utils.py:282:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:283:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:284:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:285:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:286:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/ao/nn/quantized/reference/modules/utils.py:291:9: error[unresolved-attribute] Module `torch` has no member `per_channel_affine` torch/ao/nn/quantized/reference/modules/utils.py:292:9: error[unresolved-attribute] Module `torch` has no member `per_channel_affine_float_qparams` torch/ao/nn/quantized/reference/modules/utils.py:295:29: error[unresolved-attribute] Module `torch` has no member `quint8` torch/ao/nn/quantized/reference/modules/utils.py:295:43: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/quantized/reference/modules/utils.py:295:56: error[unresolved-attribute] Module `torch` has no member `qint32` +torch/ao/nn/quantized/reference/modules/utils.py:297:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:298:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:299:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/quantized/reference/modules/utils.py:300:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:301:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/quantized/reference/modules/utils.py:302:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/ao/nn/quantized/reference/modules/utils.py:311:21: error[unresolved-attribute] Module `torch` has no member `qscheme` torch/ao/nn/quantized/reference/modules/utils.py:312:19: error[unresolved-attribute] Module `torch` has no member `dtype` torch/ao/nn/quantized/reference/modules/utils.py:317:24: error[unresolved-attribute] Module `torch` has no member `float16` @@ -13248,12 +14217,17 @@ torch/ao/nn/sparse/quantized/dynamic/linear.py:45:20: error[unresolved-attribute torch/ao/nn/sparse/quantized/dynamic/linear.py:45:57: error[unresolved-attribute] Module `torch` has no member `float` torch/ao/nn/sparse/quantized/dynamic/linear.py:49:19: error[unresolved-attribute] Module `torch` has no member `_empty_affine_quantized` torch/ao/nn/sparse/quantized/dynamic/linear.py:50:71: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/sparse/quantized/dynamic/linear.py:69:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/ao/nn/sparse/quantized/dynamic/linear.py:173:25: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/dynamic/linear.py:176:24: error[unresolved-attribute] Module `torch` has no member `any` torch/ao/nn/sparse/quantized/linear.py:17:66: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:20:21: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:23:14: error[unresolved-attribute] Module `torch` has no member `_empty_affine_quantized` torch/ao/nn/sparse/quantized/linear.py:24:52: error[unresolved-attribute] Module `torch` has no member `qint8` +torch/ao/nn/sparse/quantized/linear.py:41:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/sparse/quantized/linear.py:41:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/ao/nn/sparse/quantized/linear.py:41:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/ao/nn/sparse/quantized/linear.py:41:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/ao/nn/sparse/quantized/linear.py:116:15: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:120:21: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:129:20: error[unresolved-attribute] Module `torch` has no member `zeros` @@ -13262,12 +14236,17 @@ torch/ao/nn/sparse/quantized/linear.py:133:19: error[unresolved-attribute] Modul torch/ao/nn/sparse/quantized/linear.py:134:71: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:142:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@__init__` with custom `__setattr__` method. torch/ao/nn/sparse/quantized/linear.py:143:9: error[unresolved-attribute] Cannot assign object of type `Literal[0]` to attribute `zero_point` on type `Self@__init__` with custom `__setattr__` method. +torch/ao/nn/sparse/quantized/linear.py:160:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/ao/nn/sparse/quantized/linear.py:160:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/nn/sparse/quantized/linear.py:160:64: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | int` torch/ao/nn/sparse/quantized/linear.py:165:41: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/sparse/quantized/linear.py:166:46: error[unresolved-attribute] Module `torch` has no member `tensor` torch/ao/nn/sparse/quantized/linear.py:178:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/sparse/quantized/linear.py:181:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@_load_from_state_dict` with custom `__setattr__` method. torch/ao/nn/sparse/quantized/linear.py:249:25: error[unresolved-attribute] Module `torch` has no member `qint8` torch/ao/nn/sparse/quantized/linear.py:252:24: error[unresolved-attribute] Module `torch` has no member `any` +torch/ao/nn/sparse/quantized/linear.py:272:9: error[unresolved-attribute] Cannot assign object of type `float` to attribute `scale` on type `Self@from_float` with custom `__setattr__` method. +torch/ao/nn/sparse/quantized/linear.py:273:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `zero_point` on type `Self@from_float` with custom `__setattr__` method. torch/ao/ns/_numeric_suite.py:9:35: warning[deprecated] The function `prepare` is deprecated: torch.ao.quantization is deprecated and will be removed in 2.10. For migrations of users: 1. Eager mode quantization (torch.ao.quantization.quantize, torch.ao.quantization.quantize_dynamic), please migrate to use torchao eager mode quantize_ API instead @@ -14039,6 +15018,7 @@ torch/ao/quantization/fx/_decomposed.py:1212:13: error[unresolved-attribute] Mod torch/ao/quantization/fx/_decomposed.py:1214:16: error[unresolved-attribute] Module `torch` has no member `logical_and` torch/ao/quantization/fx/_decomposed.py:1249:12: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/ao/quantization/fx/_decomposed.py:1262:54: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/ao/quantization/fx/_decomposed.py:1263:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/ao/quantization/fx/_decomposed.py:1267:59: error[unresolved-attribute] Module `torch` has no member `dtype` torch/ao/quantization/fx/_decomposed.py:1268:12: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/ao/quantization/fx/_equalize.py:39:5: error[unresolved-attribute] Module `torch` has no member `per_tensor_affine` @@ -14546,6 +15526,24 @@ torch/ao/quantization/pt2e/qat_utils.py:102:23: error[unresolved-attribute] Modu torch/ao/quantization/pt2e/qat_utils.py:110:21: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/ao/quantization/pt2e/qat_utils.py:144:23: error[unresolved-attribute] Module `torch` has no member `sqrt` torch/ao/quantization/pt2e/qat_utils.py:184:13: error[unresolved-attribute] Module `torch` has no member `int8` +torch/ao/quantization/pt2e/qat_utils.py:188:40: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/quantization/pt2e/qat_utils.py:188:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:188:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:188:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-127]` +torch/ao/quantization/pt2e/qat_utils.py:188:75: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[127]` +torch/ao/quantization/pt2e/qat_utils.py:189:42: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/quantization/pt2e/qat_utils.py:189:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:189:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:189:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-127]` +torch/ao/quantization/pt2e/qat_utils.py:189:77: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[127]` +torch/ao/quantization/pt2e/qat_utils.py:191:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/quantization/pt2e/qat_utils.py:191:46: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:191:50: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-127]` +torch/ao/quantization/pt2e/qat_utils.py:191:56: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[127]` +torch/ao/quantization/pt2e/qat_utils.py:192:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/ao/quantization/pt2e/qat_utils.py:192:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[0]` +torch/ao/quantization/pt2e/qat_utils.py:192:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-127]` +torch/ao/quantization/pt2e/qat_utils.py:192:58: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[127]` torch/ao/quantization/pt2e/qat_utils.py:222:23: error[unresolved-attribute] Module `torch` has no member `sqrt` torch/ao/quantization/pt2e/qat_utils.py:236:25: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/ao/quantization/pt2e/qat_utils.py:656:9: error[unresolved-attribute] Module `torch` has no member `randn` @@ -14598,6 +15596,12 @@ torch/ao/quantization/pt2e/representation/rewrite.py:183:9: error[unresolved-att torch/ao/quantization/pt2e/representation/rewrite.py:189:53: error[unresolved-attribute] Module `torch` has no member `int32` torch/ao/quantization/pt2e/representation/rewrite.py:219:64: error[unresolved-attribute] Module `torch` has no member `int8` torch/ao/quantization/pt2e/representation/rewrite.py:227:9: error[unresolved-attribute] Module `torch` has no member `int8` +torch/ao/quantization/pt2e/representation/rewrite.py:233:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/ao/quantization/pt2e/representation/rewrite.py:234:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/ao/quantization/pt2e/representation/rewrite.py:235:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/ao/quantization/pt2e/representation/rewrite.py:236:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/ao/quantization/pt2e/representation/rewrite.py:237:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/ao/quantization/pt2e/representation/rewrite.py:238:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` torch/ao/quantization/pt2e/representation/rewrite.py:241:76: error[unresolved-attribute] Module `torch` has no member `int8` torch/ao/quantization/pt2e/representation/rewrite.py:275:21: error[unresolved-attribute] Module `torch` has no member `int16` torch/ao/quantization/pt2e/representation/rewrite.py:276:31: error[unresolved-attribute] Module `torch` has no member `int16` @@ -14622,11 +15626,23 @@ torch/ao/quantization/pt2e/representation/rewrite.py:448:13: error[unresolved-at torch/ao/quantization/pt2e/representation/rewrite.py:448:76: error[unresolved-attribute] Module `torch` has no member `int32` torch/ao/quantization/pt2e/representation/rewrite.py:449:13: error[unresolved-attribute] Module `torch` has no member `round` torch/ao/quantization/pt2e/representation/rewrite.py:449:76: error[unresolved-attribute] Module `torch` has no member `int32` +torch/ao/quantization/pt2e/representation/rewrite.py:453:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[-128]` +torch/ao/quantization/pt2e/representation/rewrite.py:453:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[127]` torch/ao/quantization/pt2e/representation/rewrite.py:453:69: error[unresolved-attribute] Module `torch` has no member `int8` torch/ao/quantization/pt2e/representation/rewrite.py:474:64: error[unresolved-attribute] Module `torch` has no member `int8` +torch/ao/quantization/pt2e/representation/rewrite.py:477:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:477:30: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:477:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/quantization/pt2e/representation/rewrite.py:477:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:477:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/ao/quantization/pt2e/representation/rewrite.py:480:76: error[unresolved-attribute] Module `torch` has no member `int8` torch/ao/quantization/pt2e/representation/rewrite.py:502:12: error[unresolved-attribute] Module `torch` has no member `clamp` torch/ao/quantization/pt2e/representation/rewrite.py:503:21: error[unresolved-attribute] Module `torch` has no member `int32` +torch/ao/quantization/pt2e/representation/rewrite.py:505:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:505:44: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:505:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/ao/quantization/pt2e/representation/rewrite.py:505:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/ao/quantization/pt2e/representation/rewrite.py:505:71: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/ao/quantization/pt2e/representation/rewrite.py:508:16: error[unresolved-attribute] Module `torch` has no member `clamp` torch/ao/quantization/pt2e/representation/rewrite.py:509:26: error[unresolved-attribute] Module `torch` has no member `int8` torch/ao/quantization/pt2e/representation/rewrite.py:515:58: error[unresolved-attribute] Module `torch` has no member `int8` @@ -15284,6 +16300,8 @@ torch/autograd/profiler.py:12:22: error[unresolved-import] Module `torch._C` has torch/autograd/profiler.py:748:23: warning[unsupported-base] Unsupported class base with type ` | ` torch/autograd/profiler.py:818:18: error[unresolved-attribute] Module `torch._C` has no member `DisableTorchFunctionSubclass` torch/autograd/profiler.py:856:18: error[unresolved-attribute] Module `torch._C` has no member `DisableTorchFunctionSubclass` +torch/autograd/profiler.py:859:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Future[Any]` +torch/autograd/profiler.py:864:25: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Future[Any]` torch/autograd/profiler.py:1094:28: error[unresolved-attribute] Module `torch._C` has no member `_demangle` torch/autograd/profiler_legacy.py:81:13: warning[possibly-missing-attribute] Submodule `_profiler` may not be available as an attribute on module `torch._C` torch/autograd/profiler_util.py:975:21: error[unresolved-attribute] Module `torch._C` has no member `_demangle` @@ -15547,8 +16565,6 @@ torch/cuda/_device_limits.py:87:27: error[unresolved-attribute] Module `torch` h torch/cuda/_device_limits.py:90:27: error[unresolved-attribute] Module `torch` has no member `float32` torch/cuda/_device_limits.py:92:27: error[unresolved-attribute] Module `torch` has no member `int8` torch/cuda/_device_limits.py:94:27: error[unresolved-attribute] Module `torch` has no member `float64` -torch/cuda/_gpu_trace.py:12:46: error[invalid-type-arguments] Too many type arguments to class `CallbackRegistry`: expected 1, got 2 -torch/cuda/_gpu_trace.py:15:44: error[invalid-type-arguments] Too many type arguments to class `CallbackRegistry`: expected 1, got 2 torch/cuda/_sanitizer.py:473:13: error[unresolved-attribute] Module `torch` has no member `FunctionSchema` torch/cuda/_sanitizer.py:474:21: error[unresolved-attribute] Module `torch` has no member `Argument` torch/cuda/_sanitizer.py:514:17: error[unresolved-attribute] Module `torch` has no member `FunctionSchema` @@ -15748,18 +16764,53 @@ torch/distributed/_dist2.py:151:14: error[unresolved-attribute] Module `torch` h torch/distributed/_functional_collectives.py:10:43: warning[possibly-missing-import] Member `DeviceMesh` of module `torch.distributed.device_mesh` may be missing torch/distributed/_functional_collectives.py:94:5: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` torch/distributed/_functional_collectives.py:96:12: warning[possibly-missing-attribute] Submodule `tensor` may not be available as an attribute on module `torch.distributed` +torch/distributed/_functional_collectives.py:149:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:149:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives.py:149:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:171:52: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:171:58: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:171:76: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:202:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:202:15: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives.py:202:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_functional_collectives.py:211:15: error[unresolved-attribute] Module `torch` has no member `cat` torch/distributed/_functional_collectives.py:211:25: error[unresolved-attribute] Module `torch` has no member `chunk` +torch/distributed/_functional_collectives.py:235:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:235:15: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives.py:235:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_functional_collectives.py:244:15: error[unresolved-attribute] Module `torch` has no member `cat` torch/distributed/_functional_collectives.py:244:25: error[unresolved-attribute] Module `torch` has no member `chunk` torch/distributed/_functional_collectives.py:278:23: error[unresolved-attribute] Module `torch` has no member `chunk` torch/distributed/_functional_collectives.py:279:16: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_functional_collectives.py:282:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/distributed/_functional_collectives.py:283:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:284:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/distributed/_functional_collectives.py:318:23: error[unresolved-attribute] Module `torch` has no member `chunk` torch/distributed/_functional_collectives.py:319:16: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_functional_collectives.py:322:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | Unknown` +torch/distributed/_functional_collectives.py:323:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:324:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives.py:352:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/distributed/_functional_collectives.py:353:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:354:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:381:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/distributed/_functional_collectives.py:382:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives.py:383:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_functional_collectives.py:423:27: error[unresolved-attribute] Module `torch` has no member `chunk` torch/distributed/_functional_collectives.py:424:27: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_functional_collectives.py:427:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/distributed/_functional_collectives.py:428:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:429:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/distributed/_functional_collectives.py:443:8: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_has_kernel_for_dispatch_key` torch/distributed/_functional_collectives.py:444:21: error[unresolved-attribute] Module `torch` has no member `DispatchKey` +torch/distributed/_functional_collectives.py:499:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:500:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives.py:501:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives.py:502:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives.py:541:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives.py:542:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives.py:543:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives.py:544:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_functional_collectives.py:572:19: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/_functional_collectives.py:574:19: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/_functional_collectives.py:659:24: error[index-out-of-bounds] Index 0 is out of bounds for tuple `tuple[()]` with length 0 @@ -15795,6 +16846,24 @@ torch/distributed/_functional_collectives.py:1142:22: warning[possibly-missing-a torch/distributed/_functional_collectives.py:1163:22: warning[possibly-missing-attribute] Member `group` may be missing on module `torch.distributed` torch/distributed/_functional_collectives.py:1192:22: warning[possibly-missing-attribute] Member `group` may be missing on module `torch.distributed` torch/distributed/_functional_collectives.py:1217:5: warning[deprecated] The function `_reduce_scatter_base` is deprecated: `torch.distributed._reduce_scatter_base` is a private function and will be deprecated. Please use `torch.distributed.reduce_scatter_tensor` instead. +torch/distributed/_functional_collectives_impl.py:19:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:28:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:37:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:46:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:55:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:68:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives_impl.py:69:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:70:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives_impl.py:71:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:84:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/distributed/_functional_collectives_impl.py:85:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:86:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_functional_collectives_impl.py:87:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:110:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_functional_collectives_impl.py:111:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives_impl.py:112:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int] | list[Unknown]` +torch/distributed/_functional_collectives_impl.py:113:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_functional_collectives_impl.py:118:51: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_local_tensor/__init__.py:68:19: error[unresolved-import] Module `torch` has no member `Size` torch/distributed/_local_tensor/__init__.py:69:22: error[unresolved-import] Module `torch._C` has no member `DispatchKey` torch/distributed/_local_tensor/__init__.py:69:35: error[unresolved-import] Module `torch._C` has no member `DispatchKeySet` @@ -15806,6 +16875,7 @@ torch/distributed/_local_tensor/__init__.py:105:17: error[unresolved-attribute] torch/distributed/_local_tensor/__init__.py:106:13: error[unresolved-attribute] Object of type `object` has no attribute `arguments` torch/distributed/_local_tensor/__init__.py:107:17: error[unresolved-attribute] Object of type `object` has no attribute `returns` torch/distributed/_local_tensor/__init__.py:108:13: error[unresolved-attribute] Object of type `object` has no attribute `returns` +torch/distributed/_local_tensor/__init__.py:220:16: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:252:20: error[unresolved-attribute] Module `torch` has no member `empty` torch/distributed/_local_tensor/__init__.py:307:45: error[unresolved-attribute] Module `torch` has no member `Tag` torch/distributed/_local_tensor/__init__.py:320:27: error[unresolved-attribute] Module `torch._C` has no member `DispatchKeySet` @@ -15820,18 +16890,25 @@ torch/distributed/_local_tensor/__init__.py:439:16: error[unresolved-attribute] torch/distributed/_local_tensor/__init__.py:444:16: error[unresolved-attribute] Module `torch._C` has no member `_get_constant_bool_symnode` torch/distributed/_local_tensor/__init__.py:449:16: error[unresolved-attribute] Module `torch._C` has no member `_get_constant_bool_symnode` torch/distributed/_local_tensor/__init__.py:454:16: error[unresolved-attribute] Module `torch._C` has no member `_get_constant_bool_symnode` +torch/distributed/_local_tensor/__init__.py:513:16: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:557:51: warning[possibly-missing-import] Member `_get_device_handle` of module `torch.distributed.device_mesh` may be missing torch/distributed/_local_tensor/__init__.py:568:16: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/_local_tensor/__init__.py:609:61: error[unresolved-attribute] Module `torch` has no member `int64` +torch/distributed/_local_tensor/__init__.py:659:33: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:730:5: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/_local_tensor/__init__.py:731:5: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_local_tensor/__init__.py:732:5: error[unresolved-attribute] Module `torch` has no member `layout` +torch/distributed/_local_tensor/__init__.py:862:16: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:892:21: error[unresolved-attribute] Module `torch` has no member `Size` +torch/distributed/_local_tensor/__init__.py:902:16: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:952:24: error[unresolved-attribute] Module `torch` has no member `memory_format` torch/distributed/_local_tensor/__init__.py:952:46: error[unresolved-attribute] Module `torch` has no member `contiguous_format` +torch/distributed/_local_tensor/__init__.py:955:16: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:965:24: error[unresolved-attribute] Module `torch` has no member `memory_format` torch/distributed/_local_tensor/__init__.py:965:46: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/distributed/_local_tensor/__init__.py:994:20: error[unresolved-attribute] Module `torch` has no member `equal` +torch/distributed/_local_tensor/__init__.py:1203:20: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` +torch/distributed/_local_tensor/__init__.py:1220:20: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/__init__.py:1239:13: error[invalid-assignment] Implicit shadowing of function `manual_seed` torch/distributed/_local_tensor/__init__.py:1240:13: error[invalid-assignment] Implicit shadowing of function `manual_seed` torch/distributed/_local_tensor/__init__.py:1244:13: error[invalid-assignment] Implicit shadowing of function `initial_seed` @@ -15844,10 +16921,14 @@ torch/distributed/_local_tensor/__init__.py:1727:28: error[non-subscriptable] Ca torch/distributed/_local_tensor/__init__.py:1734:29: error[unresolved-attribute] Module `torch` has no member `tensor` torch/distributed/_local_tensor/__init__.py:1735:39: error[unresolved-attribute] Module `torch` has no member `uint64` torch/distributed/_local_tensor/__init__.py:1736:20: error[unresolved-attribute] Module `torch` has no member `uint8` +torch/distributed/_local_tensor/__init__.py:1740:37: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/_c10d.py:8:22: error[unresolved-import] Module `torch._C` has no member `ScriptObject` torch/distributed/_local_tensor/_c10d.py:85:13: warning[possibly-missing-attribute] Member `get_process_group_ranks` may be missing on module `torch.distributed` torch/distributed/_local_tensor/_c10d.py:126:27: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_local_tensor/_c10d.py:132:14: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` +torch/distributed/_local_tensor/_c10d.py:172:14: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/_c10d.py:197:27: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_local_tensor/_c10d.py:214:14: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@__new__]`, found `` torch/distributed/_local_tensor/_c10d.py:271:14: error[unresolved-attribute] Module `torch` has no member `minimum` torch/distributed/_local_tensor/_c10d.py:273:14: error[unresolved-attribute] Module `torch` has no member `maximum` torch/distributed/_local_tensor/_c10d.py:275:14: error[unresolved-attribute] Module `torch` has no member `bitwise_and` @@ -16168,29 +17249,58 @@ torch/distributed/_symmetric_memory/__init__.py:451:11: error[unresolved-attribu torch/distributed/_symmetric_memory/__init__.py:461:11: error[unresolved-attribute] Module `torch._C` has no member `Tag` torch/distributed/_symmetric_memory/__init__.py:499:18: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/distributed/_symmetric_memory/__init__.py:541:22: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/distributed/_symmetric_memory/__init__.py:612:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:614:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:635:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:659:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:745:22: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:767:9: error[unresolved-attribute] Module `torch` has no member `empty` +torch/distributed/_symmetric_memory/__init__.py:783:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:801:32: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/_symmetric_memory/__init__.py:818:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_symmetric_memory/__init__.py:818:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_symmetric_memory/__init__.py:823:16: error[unresolved-attribute] Module `torch` has no member `cat` torch/distributed/_symmetric_memory/__init__.py:824:16: error[unresolved-attribute] Module `torch` has no member `matmul` torch/distributed/_symmetric_memory/__init__.py:831:12: error[unresolved-attribute] Module `torch` has no member `matmul` torch/distributed/_symmetric_memory/__init__.py:939:17: error[unresolved-attribute] Module `torch` has no member `zeros` torch/distributed/_symmetric_memory/__init__.py:939:47: error[unresolved-attribute] Module `torch` has no member `uint32` +torch/distributed/_symmetric_memory/__init__.py:948:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:948:63: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/distributed/_symmetric_memory/__init__.py:999:15: error[unresolved-attribute] Module `torch` has no member `Size` +torch/distributed/_symmetric_memory/__init__.py:1004:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1004:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_symmetric_memory/__init__.py:1004:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:1005:13: error[unresolved-attribute] Module `torch` has no member `matmul` torch/distributed/_symmetric_memory/__init__.py:1018:22: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/distributed/_symmetric_memory/__init__.py:1025:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_symmetric_memory/__init__.py:1025:43: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` +torch/distributed/_symmetric_memory/__init__.py:1036:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/distributed/_symmetric_memory/__init__.py:1036:47: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/_symmetric_memory/__init__.py:1056:20: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/distributed/_symmetric_memory/__init__.py:1062:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1063:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1064:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1065:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/distributed/_symmetric_memory/__init__.py:1066:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/distributed/_symmetric_memory/__init__.py:1067:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/distributed/_symmetric_memory/__init__.py:1068:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/distributed/_symmetric_memory/__init__.py:1092:22: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1243:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1255:29: error[unresolved-attribute] Module `torch` has no member `sum` torch/distributed/_symmetric_memory/__init__.py:1257:29: error[unresolved-attribute] Module `torch` has no member `mean` +torch/distributed/_symmetric_memory/__init__.py:1269:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:1273:28: error[unresolved-attribute] Module `torch` has no member `empty` +torch/distributed/_symmetric_memory/__init__.py:1303:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1303:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:1336:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1390:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1407:9: error[unresolved-attribute] Module `torch` has no member `_scaled_mm` torch/distributed/_symmetric_memory/__init__.py:1434:16: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1453:29: error[unresolved-attribute] Module `torch` has no member `sum` torch/distributed/_symmetric_memory/__init__.py:1455:29: error[unresolved-attribute] Module `torch` has no member `mean` +torch/distributed/_symmetric_memory/__init__.py:1506:35: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/_symmetric_memory/__init__.py:1506:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Tensor` +torch/distributed/_symmetric_memory/__init__.py:1506:78: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/distributed/_symmetric_memory/__init__.py:1576:11: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/_symmetric_memory/__init__.py:1584:12: error[unresolved-attribute] Module `torch` has no member `uint8` torch/distributed/_symmetric_memory/__init__.py:1585:12: error[unresolved-attribute] Module `torch` has no member `int8` @@ -16234,6 +17344,8 @@ torch/distributed/_symmetric_memory/_nvshmem_triton.py:1206:38: warning[possibly torch/distributed/_tools/fake_collectives.py:14:1: warning[possibly-missing-attribute] Member `batch_isend_irecv` may be missing on module `torch.distributed` torch/distributed/_tools/fsdp2_mem_tracker.py:107:31: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/_tools/fsdp2_mem_tracker.py:109:38: error[unresolved-attribute] Module `torch` has no member `device` +torch/distributed/_tools/fsdp2_mem_tracker.py:239:28: error[invalid-assignment] Object of type `tuple[@Todo, ...]` is not assignable to `_P@_fsdp_state_pre_forward.args` +torch/distributed/_tools/fsdp2_mem_tracker.py:239:28: error[invalid-assignment] Object of type `dict[str, Any]` is not assignable to `_P@_fsdp_state_pre_forward.kwargs` torch/distributed/_tools/fsdp2_mem_tracker.py:538:19: error[non-subscriptable] Cannot subscript object of type `EllipsisType` with no `__getitem__` method torch/distributed/_tools/fsdp2_mem_tracker.py:555:29: error[non-subscriptable] Cannot subscript object of type `EllipsisType` with no `__getitem__` method torch/distributed/_tools/fsdp2_mem_tracker.py:566:28: error[non-subscriptable] Cannot subscript object of type `EllipsisType` with no `__getitem__` method @@ -16442,8 +17554,8 @@ torch/distributed/c10d_logger.py:61:30: warning[possibly-missing-attribute] Memb torch/distributed/c10d_logger.py:62:31: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/c10d_logger.py:63:30: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/c10d_logger.py:66:28: warning[possibly-missing-attribute] Submodule `nccl` may not be available as an attribute on module `torch.cuda` -torch/distributed/c10d_logger.py:85:38: error[unresolved-attribute] Object of type `(...) -> _T@_exception_logger` has no attribute `__name__` -torch/distributed/c10d_logger.py:96:56: error[unresolved-attribute] Object of type `(...) -> _T@_time_logger` has no attribute `__name__` +torch/distributed/c10d_logger.py:85:38: error[unresolved-attribute] Object of type `(**_P@_exception_logger) -> _T@_exception_logger` has no attribute `__name__` +torch/distributed/c10d_logger.py:96:56: error[unresolved-attribute] Object of type `(**_P@_time_logger) -> _T@_time_logger` has no attribute `__name__` torch/distributed/checkpoint/__init__.py:17:38: warning[deprecated] The function `load_state_dict` is deprecated: `load_state_dict` is deprecated and will be removed in future versions. Please use `load` instead. torch/distributed/checkpoint/__init__.py:20:49: warning[deprecated] The function `save_state_dict` is deprecated: `save_state_dict` is deprecated and will be removed in future versions.Please use `save` instead. torch/distributed/checkpoint/_async_executor.py:23:33: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` @@ -16566,7 +17678,7 @@ torch/distributed/checkpoint/hf_storage.py:361:33: error[unresolved-attribute] M torch/distributed/checkpoint/hf_storage.py:361:59: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/checkpoint/hf_storage.py:367:57: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/checkpoint/hf_storage.py:378:31: error[unresolved-attribute] Module `torch` has no member `Size` -torch/distributed/checkpoint/logger.py:78:17: error[unresolved-attribute] Object of type `(...) -> _T@_dcp_method_logger` has no attribute `__name__` +torch/distributed/checkpoint/logger.py:78:17: error[unresolved-attribute] Object of type `(**_P@_dcp_method_logger) -> _T@_dcp_method_logger` has no attribute `__name__` torch/distributed/checkpoint/metadata.py:30:14: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/checkpoint/metadata.py:31:12: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/checkpoint/metadata.py:47:12: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -16870,7 +17982,7 @@ torch/distributed/elastic/rendezvous/etcd_store.py:124:9: error[invalid-method-o torch/distributed/elastic/rendezvous/static_tcp_rendezvous.py:14:31: warning[possibly-missing-import] Member `PrefixStore` of module `torch.distributed` may be missing torch/distributed/elastic/rendezvous/static_tcp_rendezvous.py:14:44: warning[possibly-missing-import] Member `Store` of module `torch.distributed` may be missing torch/distributed/elastic/rendezvous/static_tcp_rendezvous.py:14:51: warning[possibly-missing-import] Member `TCPStore` of module `torch.distributed` may be missing -torch/distributed/elastic/timer/file_based_local_timer.py:50:71: error[unresolved-attribute] Object of type `(...) -> _R@wrapper` has no attribute `__name__` +torch/distributed/elastic/timer/file_based_local_timer.py:50:71: error[unresolved-attribute] Object of type `(**_P@wrapper) -> _R@wrapper` has no attribute `__name__` torch/distributed/elastic/utils/data/elastic_distributed_sampler.py:73:13: error[unresolved-attribute] Module `torch` has no member `Generator` torch/distributed/elastic/utils/data/elastic_distributed_sampler.py:77:13: error[unresolved-attribute] Module `torch` has no member `randperm` torch/distributed/elastic/utils/distributed.py:81:21: warning[possibly-missing-attribute] Member `TCPStore` may be missing on module `torch.distributed` @@ -17014,6 +18126,10 @@ torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:241:24: error[unresolve torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:242:13: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:254:21: error[unresolved-attribute] Module `torch` has no member `uint8` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:256:24: error[unresolved-attribute] Module `torch` has no member `uint8` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:266:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:267:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:268:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:270:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:333:35: error[unresolved-attribute] Module `torch` has no member `empty` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:337:9: error[unresolved-attribute] Module `torch` has no member `_foreach_copy_` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:348:12: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` @@ -17022,6 +18138,12 @@ torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:388:17: error[unresolve torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:394:35: error[unresolved-attribute] Module `torch` has no member `uint8` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:395:44: error[unresolved-attribute] Module `torch` has no member `uint8` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:400:22: warning[deprecated] The function `is_compiling` is deprecated: `torch._dynamo.external_utils.is_compiling` is deprecated. Use `torch.compiler.is_compiling` instead. +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:411:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:411:66: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:411:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:415:32: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:415:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:415:69: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:437:26: error[unresolved-attribute] Module `torch` has no member `chunk` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:443:17: error[unresolved-attribute] Module `torch` has no member `cat` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:450:27: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` @@ -17039,6 +18161,9 @@ torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:514:34: error[unresolve torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:581:17: warning[possibly-missing-attribute] Member `all_reduce` may be missing on module `torch.distributed` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:610:32: error[unresolved-attribute] Module `torch` has no member `as_strided` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:626:21: error[unresolved-attribute] Module `torch` has no member `device` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:673:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Tensor]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:673:26: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[0]` +torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:673:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:679:22: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:679:54: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/fsdp/_fully_shard/_fsdp_collectives.py:680:46: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -17097,6 +18222,7 @@ torch/distributed/fsdp/_fully_shard/_fsdp_param.py:470:17: error[unresolved-attr torch/distributed/fsdp/_fully_shard/_fsdp_param.py:476:13: error[unresolved-attribute] Module `torch` has no member `empty` torch/distributed/fsdp/_fully_shard/_fsdp_param.py:476:25: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/fsdp/_fully_shard/_fsdp_param.py:535:27: error[unresolved-attribute] Module `torch` has no member `as_strided` +torch/distributed/fsdp/_fully_shard/_fsdp_param.py:557:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | DTensor` torch/distributed/fsdp/_fully_shard/_fsdp_param.py:602:39: error[unresolved-attribute] Module `torch` has no member `as_strided` torch/distributed/fsdp/_fully_shard/_fsdp_param.py:611:34: error[invalid-argument-type] Argument to bound method `_setattr_on_modules` is incorrect: Expected `Parameter`, found `Unknown | None | Parameter` torch/distributed/fsdp/_fully_shard/_fsdp_param.py:797:17: error[unresolved-attribute] Module `torch` has no member `empty` @@ -17174,6 +18300,10 @@ torch/distributed/fsdp/_optim_utils.py:350:8: warning[possibly-missing-attribute torch/distributed/fsdp/_optim_utils.py:364:18: error[unresolved-attribute] Module `torch` has no member `zeros` torch/distributed/fsdp/_optim_utils.py:367:5: warning[possibly-missing-attribute] Member `broadcast` may be missing on module `torch.distributed` torch/distributed/fsdp/_optim_utils.py:415:21: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` +torch/distributed/fsdp/_optim_utils.py:480:22: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:480:22: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:480:45: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.RESHARDING]` +torch/distributed/fsdp/_optim_utils.py:480:45: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.RESHARDING]` torch/distributed/fsdp/_optim_utils.py:703:35: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/fsdp/_optim_utils.py:762:18: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/fsdp/_optim_utils.py:764:9: error[unresolved-attribute] Module `torch` has no member `flatten` @@ -17197,13 +18327,53 @@ torch/distributed/fsdp/_optim_utils.py:1368:21: error[unresolved-attribute] Modu torch/distributed/fsdp/_optim_utils.py:1382:25: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/fsdp/_optim_utils.py:1442:24: error[unresolved-attribute] Module `torch` has no member `equal` torch/distributed/fsdp/_optim_utils.py:1486:32: error[unresolved-attribute] Module `torch` has no member `Size` +torch/distributed/fsdp/_optim_utils.py:1522:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1522:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1522:41: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["clone"]` +torch/distributed/fsdp/_optim_utils.py:1522:41: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["clone"]` +torch/distributed/fsdp/_optim_utils.py:1526:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1526:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1526:41: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.D2H]` +torch/distributed/fsdp/_optim_utils.py:1526:41: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.D2H]` torch/distributed/fsdp/_optim_utils.py:1544:33: warning[possibly-missing-attribute] Member `get_debug_level` may be missing on module `torch.distributed` torch/distributed/fsdp/_optim_utils.py:1544:59: warning[possibly-missing-attribute] Member `DebugLevel` may be missing on module `torch.distributed` torch/distributed/fsdp/_optim_utils.py:1573:9: error[unresolved-attribute] Module `torch` has no member `empty` torch/distributed/fsdp/_optim_utils.py:1659:23: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/fsdp/_optim_utils.py:1668:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1668:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1668:37: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.ALLGATHER]` +torch/distributed/fsdp/_optim_utils.py:1668:37: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.ALLGATHER]` torch/distributed/fsdp/_optim_utils.py:1669:13: warning[possibly-missing-attribute] Member `all_gather_into_tensor` may be missing on module `torch.distributed` +torch/distributed/fsdp/_optim_utils.py:1721:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1721:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1721:33: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.RESHARDING]` +torch/distributed/fsdp/_optim_utils.py:1721:33: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.RESHARDING]` +torch/distributed/fsdp/_optim_utils.py:1722:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1722:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1722:37: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.ALLGATHER_OBJ]` +torch/distributed/fsdp/_optim_utils.py:1722:37: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.ALLGATHER_OBJ]` +torch/distributed/fsdp/_optim_utils.py:1798:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1798:18: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1798:41: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["none_fsdp_managed_copy"]` +torch/distributed/fsdp/_optim_utils.py:1798:41: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["none_fsdp_managed_copy"]` torch/distributed/fsdp/_optim_utils.py:1925:21: warning[possibly-missing-attribute] Member `ProcessGroup` may be missing on module `torch.distributed` +torch/distributed/fsdp/_optim_utils.py:1980:22: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1980:22: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1980:45: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal[Type.ALL]` +torch/distributed/fsdp/_optim_utils.py:1980:45: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal[Type.ALL]` torch/distributed/fsdp/_optim_utils.py:1982:33: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` +torch/distributed/fsdp/_optim_utils.py:1984:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1984:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:1984:33: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["preprocessing"]` +torch/distributed/fsdp/_optim_utils.py:1984:33: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["preprocessing"]` +torch/distributed/fsdp/_optim_utils.py:2001:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:2001:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:2001:33: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["preprocessing_with_comm"]` +torch/distributed/fsdp/_optim_utils.py:2001:33: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["preprocessing_with_comm"]` +torch/distributed/fsdp/_optim_utils.py:2014:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:2014:10: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_optim_utils.py:2014:33: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["state_converting"]` +torch/distributed/fsdp/_optim_utils.py:2014:33: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["state_converting"]` torch/distributed/fsdp/_runtime_utils.py:151:18: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/fsdp/_runtime_utils.py:1440:12: error[unresolved-attribute] Module `torch` has no member `is_grad_enabled` torch/distributed/fsdp/_runtime_utils.py:1446:8: warning[possibly-missing-attribute] Submodule `_functional_collectives` may not be available as an attribute on module `torch.distributed` @@ -17224,6 +18394,14 @@ torch/distributed/fsdp/_shard_utils.py:65:13: warning[possibly-missing-attribute torch/distributed/fsdp/_shard_utils.py:87:27: error[unresolved-attribute] Module `torch` has no member `contiguous_format` torch/distributed/fsdp/_state_dict_utils.py:79:36: warning[possibly-missing-attribute] Attribute `param_module_names` may be missing on object of type `FlatParamHandle | None` torch/distributed/fsdp/_state_dict_utils.py:90:36: warning[possibly-missing-attribute] Attribute `shared_param_module_names` may be missing on object of type `FlatParamHandle | None` +torch/distributed/fsdp/_state_dict_utils.py:357:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_state_dict_utils.py:357:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_state_dict_utils.py:357:37: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["_enter_unshard_params_ctx"]` +torch/distributed/fsdp/_state_dict_utils.py:357:37: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["_enter_unshard_params_ctx"]` +torch/distributed/fsdp/_state_dict_utils.py:368:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_state_dict_utils.py:368:14: error[missing-argument] No argument provided for required parameter `profile_type` +torch/distributed/fsdp/_state_dict_utils.py:368:37: error[invalid-argument-type] Argument is incorrect: Expected `type[Self@profile]`, found `Literal["_exit_unshard_params_ctx"]` +torch/distributed/fsdp/_state_dict_utils.py:368:37: error[invalid-argument-type] Argument is incorrect: Expected `Self@profile`, found `Literal["_exit_unshard_params_ctx"]` torch/distributed/fsdp/_state_dict_utils.py:385:17: warning[possibly-missing-attribute] Attribute `uses_sharded_strategy` may be missing on object of type `FlatParamHandle | None` torch/distributed/fsdp/_state_dict_utils.py:477:18: warning[possibly-missing-attribute] Attribute `flat_param` may be missing on object of type `FlatParamHandle | None` torch/distributed/fsdp/_state_dict_utils.py:516:17: warning[possibly-missing-attribute] Attribute `uses_sharded_strategy` may be missing on object of type `FlatParamHandle | None` @@ -17288,6 +18466,10 @@ torch/distributed/nn/api/remote_module.py:474:17: warning[possibly-missing-attri torch/distributed/nn/api/remote_module.py:477:9: error[unresolved-attribute] Cannot assign object of type `bool` to attribute `is_device_map_set` on type `Self@_prepare_init` with custom `__setattr__` method. torch/distributed/nn/api/remote_module.py:484:45: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/nn/api/remote_module.py:515:22: warning[possibly-missing-attribute] Member `RRef` may be missing on module `torch.distributed.rpc` +torch/distributed/nn/api/remote_module.py:593:13: error[unresolved-attribute] Cannot assign object of type `Literal[True]` to attribute `is_scriptable` on type `RemoteModule` with custom `__setattr__` method. +torch/distributed/nn/api/remote_module.py:601:13: error[unresolved-attribute] Cannot assign object of type `Literal[False]` to attribute `is_scriptable` on type `RemoteModule` with custom `__setattr__` method. +torch/distributed/nn/api/remote_module.py:607:9: error[unresolved-attribute] Cannot assign object of type `RRef[Module]` to attribute `module_rref` on type `RemoteModule` with custom `__setattr__` method. +torch/distributed/nn/api/remote_module.py:715:5: error[unresolved-attribute] Cannot assign object of type `PyRRef[Unknown]` to attribute `module_rref` on type `RemoteModule` with custom `__setattr__` method. torch/distributed/nn/api/remote_module.py:715:21: warning[possibly-missing-attribute] Member `PyRRef` may be missing on module `torch.distributed.rpc` torch/distributed/nn/functional.py:9:31: warning[possibly-missing-import] Member `group` of module `torch.distributed` may be missing torch/distributed/nn/functional.py:9:38: warning[possibly-missing-import] Member `ReduceOp` of module `torch.distributed` may be missing @@ -17423,12 +18605,16 @@ torch/distributed/optim/zero_redundancy_optimizer.py:96:8: warning[possibly-miss torch/distributed/optim/zero_redundancy_optimizer.py:101:25: error[unresolved-attribute] Module `torch` has no member `LongTensor` torch/distributed/optim/zero_redundancy_optimizer.py:102:28: error[unresolved-attribute] Module `torch` has no member `ByteTensor` torch/distributed/optim/zero_redundancy_optimizer.py:104:9: warning[possibly-missing-attribute] Member `broadcast` may be missing on module `torch.distributed` +torch/distributed/optim/zero_redundancy_optimizer.py:104:53: error[invalid-argument-type] Argument is incorrect: Expected `ProcessGroup | None`, found `object` torch/distributed/optim/zero_redundancy_optimizer.py:106:9: warning[possibly-missing-attribute] Member `broadcast` may be missing on module `torch.distributed` +torch/distributed/optim/zero_redundancy_optimizer.py:106:56: error[invalid-argument-type] Argument is incorrect: Expected `ProcessGroup | None`, found `object` torch/distributed/optim/zero_redundancy_optimizer.py:109:25: error[unresolved-attribute] Module `torch` has no member `LongTensor` torch/distributed/optim/zero_redundancy_optimizer.py:111:9: warning[possibly-missing-attribute] Member `broadcast` may be missing on module `torch.distributed` +torch/distributed/optim/zero_redundancy_optimizer.py:111:53: error[invalid-argument-type] Argument is incorrect: Expected `ProcessGroup | None`, found `object` torch/distributed/optim/zero_redundancy_optimizer.py:112:28: error[unresolved-attribute] Module `torch` has no member `empty` torch/distributed/optim/zero_redundancy_optimizer.py:113:48: error[unresolved-attribute] Module `torch` has no member `uint8` torch/distributed/optim/zero_redundancy_optimizer.py:116:9: warning[possibly-missing-attribute] Member `broadcast` may be missing on module `torch.distributed` +torch/distributed/optim/zero_redundancy_optimizer.py:116:56: error[invalid-argument-type] Argument is incorrect: Expected `ProcessGroup | None`, found `object` torch/distributed/optim/zero_redundancy_optimizer.py:175:22: error[unresolved-attribute] Module `torch` has no member `device` torch/distributed/optim/zero_redundancy_optimizer.py:262:48: warning[possibly-missing-attribute] Member `GradBucket` may be missing on module `torch.distributed` torch/distributed/optim/zero_redundancy_optimizer.py:273:62: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` @@ -17678,16 +18864,25 @@ torch/distributed/tensor/_collective_utils.py:17:60: warning[possibly-missing-im torch/distributed/tensor/_collective_utils.py:35:21: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/distributed/tensor/_collective_utils.py:40:9: error[unresolved-attribute] Module `torch` has no member `cat` torch/distributed/tensor/_collective_utils.py:57:15: error[unresolved-attribute] Module `torch` has no member `chunk` +torch/distributed/tensor/_collective_utils.py:65:39: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `str` torch/distributed/tensor/_collective_utils.py:219:46: warning[possibly-missing-attribute] Member `get_world_size` may be missing on module `torch.distributed` torch/distributed/tensor/_collective_utils.py:220:5: warning[possibly-missing-attribute] Member `all_gather_object` may be missing on module `torch.distributed` torch/distributed/tensor/_dispatch.py:13:43: warning[possibly-missing-import] Member `DeviceMesh` of module `torch.distributed.device_mesh` may be missing +torch/distributed/tensor/_dispatch.py:84:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_dispatch.py:84:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_dispatch.py:163:16: error[unresolved-attribute] Module `torch._C` has no member `_get_dtensor_allow_implicit_replication` torch/distributed/tensor/_dispatch.py:167:16: error[unresolved-attribute] Module `torch._C` has no member `_set_dtensor_allow_implicit_replication` torch/distributed/tensor/_dispatch.py:181:16: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_has_kernel_for_dispatch_key` torch/distributed/tensor/_dispatch.py:182:33: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` +torch/distributed/tensor/_dispatch.py:186:41: error[invalid-argument-type] Argument to bound method `decompose` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_dispatch.py:186:48: error[invalid-argument-type] Argument to bound method `decompose` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_dispatch.py:224:21: error[invalid-argument-type] Argument to function `tree_unflatten` is incorrect: Expected `PyTreeSpec`, found `(PyTreeSpec & ~AlwaysFalsy) | (TreeSpec & ~AlwaysFalsy)` torch/distributed/tensor/_dispatch.py:224:21: error[invalid-argument-type] Argument to function `tree_unflatten` is incorrect: Expected `TreeSpec`, found `(PyTreeSpec & ~AlwaysFalsy) | (TreeSpec & ~AlwaysFalsy)` torch/distributed/tensor/_dispatch.py:248:43: error[unresolved-attribute] Module `torch` has no member `Generator` +torch/distributed/tensor/_dispatch.py:261:45: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_dispatch.py:261:65: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_dispatch.py:264:41: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_dispatch.py:264:61: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_dispatch.py:287:36: error[unresolved-attribute] Module `torch` has no member `zeros` torch/distributed/tensor/_dispatch.py:290:36: error[unresolved-attribute] Module `torch` has no member `tensor` torch/distributed/tensor/_dispatch.py:332:21: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -17748,7 +18943,7 @@ torch/distributed/tensor/_ops/_view_ops.py:785:27: error[unresolved-attribute] M torch/distributed/tensor/_ops/_view_ops.py:791:25: error[unresolved-attribute] Module `torch` has no member `transpose` torch/distributed/tensor/_ops/_view_ops.py:793:56: error[unresolved-attribute] Module `torch` has no member `view_as_complex` torch/distributed/tensor/_ops/_view_ops.py:794:53: error[unresolved-attribute] Module `torch` has no member `view_as_real` -torch/distributed/tensor/_ops/utils.py:50:17: error[invalid-argument-type] Argument to bound method `register_sharding_prop_rule` is incorrect: Expected `OpOverload[Unknown, Any]`, found `object` +torch/distributed/tensor/_ops/utils.py:50:17: error[invalid-argument-type] Argument to bound method `register_sharding_prop_rule` is incorrect: Expected `OpOverload[EllipsisType, Any]`, found `object` torch/distributed/tensor/_ops/utils.py:224:19: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/tensor/_ops/utils.py:224:44: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/tensor/_ops/utils.py:239:12: error[unresolved-attribute] Module `torch` has no member `Size` @@ -17771,6 +18966,8 @@ torch/distributed/tensor/_random.py:453:12: error[unresolved-attribute] Module ` torch/distributed/tensor/_redistribute.py:460:36: error[invalid-argument-type] Argument to function `heappush` is incorrect: Expected `list[tuple[Unknown, Literal[1], DistState, Unknown]]`, found `list[tuple[int, int, DistState, list[DistState]]] & ~AlwaysFalsy` torch/distributed/tensor/_redistribute.py:849:33: error[unresolved-attribute] Module `torch` has no member `dtype` torch/distributed/tensor/_redistribute.py:850:34: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/distributed/tensor/_sharding_prop.py:186:37: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_sharding_prop.py:186:49: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_sharding_prop.py:365:9: error[unresolved-attribute] Module `torch._C` has no member `_log_api_usage_once` torch/distributed/tensor/_shards_wrapper.py:50:17: error[unresolved-attribute] Module `torch` has no member `Size` torch/distributed/tensor/_shards_wrapper.py:55:22: error[unresolved-attribute] Module `torch` has no member `Size` @@ -17818,11 +19015,19 @@ torch/distributed/tensor/_tp_conv.py:101:41: error[unresolved-attribute] Module torch/distributed/tensor/_tp_conv.py:104:40: error[unresolved-attribute] Module `torch` has no member `add` torch/distributed/tensor/_tp_conv.py:118:12: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/tensor/_tp_conv.py:119:12: warning[possibly-missing-attribute] Member `get_world_size` may be missing on module `torch.distributed` +torch/distributed/tensor/_tp_conv.py:128:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_tp_conv.py:128:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_tp_conv.py:148:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_tp_conv.py:148:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_tp_conv.py:172:12: warning[possibly-missing-attribute] Member `get_rank` may be missing on module `torch.distributed` torch/distributed/tensor/_tp_conv.py:173:12: warning[possibly-missing-attribute] Member `get_world_size` may be missing on module `torch.distributed` +torch/distributed/tensor/_tp_conv.py:183:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_tp_conv.py:183:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_tp_conv.py:203:34: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[Literal[0], @Todo]` torch/distributed/tensor/_tp_conv.py:207:34: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[@Todo, Literal[0]]` torch/distributed/tensor/_tp_conv.py:211:34: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[@Todo, @Todo]` +torch/distributed/tensor/_tp_conv.py:219:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/distributed/tensor/_tp_conv.py:219:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/distributed/tensor/_tp_conv.py:268:12: error[invalid-assignment] Object of type `list[object]` is not assignable to `tuple[object, ...]` torch/distributed/tensor/_tp_conv.py:271:5: error[invalid-assignment] Cannot assign to a subscript on an object of type `tuple[object, ...]` torch/distributed/tensor/_utils.py:10:43: warning[possibly-missing-import] Member `DeviceMesh` of module `torch.distributed.device_mesh` may be missing @@ -17938,6 +19143,12 @@ torch/distributed/tensor/experimental/_context_parallel/_attention.py:577:27: er torch/distributed/tensor/experimental/_context_parallel/_attention.py:578:25: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/distributed/tensor/experimental/_context_parallel/_attention.py:579:27: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/distributed/tensor/experimental/_context_parallel/_attention.py:618:24: error[unresolved-attribute] Module `torch` has no member `cat` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:669:9: error[invalid-argument-type] Argument to function `_templated_ring_attention` is incorrect: Expected `_AttentionOp`, found `OpOverloadPacket[EllipsisType, Any]` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:704:9: error[invalid-argument-type] Argument to function `_templated_ring_attention` is incorrect: Expected `_AttentionOp`, found `OpOverloadPacket[EllipsisType, Any]` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:742:9: error[invalid-argument-type] Argument to function `_templated_ring_attention` is incorrect: Expected `_AttentionOp`, found `OpOverloadPacket[EllipsisType, Any]` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:780:9: error[invalid-argument-type] Argument to function `_templated_ring_attention_backward` is incorrect: Expected `_AttentionOp`, found `OpOverload[EllipsisType, Any]` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:823:9: error[invalid-argument-type] Argument to function `_templated_ring_attention_backward` is incorrect: Expected `_AttentionOp`, found `OpOverload[EllipsisType, Any]` +torch/distributed/tensor/experimental/_context_parallel/_attention.py:867:9: error[invalid-argument-type] Argument to function `_templated_ring_attention_backward` is incorrect: Expected `_AttentionOp`, found `OpOverload[EllipsisType, Any]` torch/distributed/tensor/experimental/_context_parallel/_attention.py:977:24: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__name__` torch/distributed/tensor/experimental/_context_parallel/_attention.py:978:40: error[unresolved-attribute] Object of type `(...) -> Unknown` has no attribute `__name__` torch/distributed/tensor/experimental/_context_parallel/_attention.py:1096:30: error[unresolved-attribute] Module `torch` has no member `index_select` @@ -17973,7 +19184,7 @@ torch/distributed/tensor/experimental/_func_map.py:276:53: error[invalid-argumen torch/distributed/tensor/experimental/_register_sharding.py:116:41: error[unresolved-attribute] Module `torch` has no member `IntType` torch/distributed/tensor/experimental/_register_sharding.py:117:42: error[unresolved-attribute] Module `torch` has no member `OptionalType` torch/distributed/tensor/experimental/_register_sharding.py:118:63: error[unresolved-attribute] Module `torch` has no member `IntType` -torch/distributed/tensor/experimental/_register_sharding.py:130:17: error[invalid-argument-type] Argument to bound method `register_op_strategy` is incorrect: Expected `OpOverload[Unknown, Any]`, found `object` +torch/distributed/tensor/experimental/_register_sharding.py:130:17: error[invalid-argument-type] Argument to bound method `register_op_strategy` is incorrect: Expected `OpOverload[EllipsisType, Any]`, found `object` torch/distributed/tensor/experimental/_tp_transform.py:87:45: error[unresolved-attribute] Module `torch` has no member `arange` torch/distributed/tensor/experimental/_tp_transform.py:241:72: error[invalid-argument-type] Argument to function `_get_output_spec_from_output_sharding` is incorrect: Expected `OutputSharding`, found `object` torch/distributed/tensor/experimental/_tp_transform.py:243:33: error[unresolved-attribute] Object of type `object` has no attribute `redistribute_schema` @@ -18859,7 +20070,7 @@ torch/futures/__init__.py:313:41: error[unresolved-attribute] Module `torch._C` torch/futures/__init__.py:334:20: error[unresolved-attribute] Module `torch._C` has no member `_collect_all` torch/futures/__init__.py:334:52: error[unresolved-attribute] Module `torch._C` has no member `Future` torch/fx/_graph_pickler.py:101:30: warning[possibly-missing-attribute] Submodule `_guards` may not be available as an attribute on module `torch` -torch/fx/_graph_pickler.py:208:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[(Self@reduce_helper, _UnpickleState, /) -> _SymNodeT@reduce_helper, tuple[Self@reduce_helper, _UnpickleStateToken]]`, found `tuple[def unpickle_sym_int(self, unpickle_state: _UnpickleState) -> SymInt, tuple[Unknown, Unknown | _UnpickleStateToken]]` +torch/fx/_graph_pickler.py:208:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[(Self@reduce_helper, _UnpickleState, /) -> _SymNodeT@reduce_helper, tuple[Self@reduce_helper, _UnpickleStateToken]]`, found `tuple[def unpickle_sym_int(self, unpickle_state: _UnpickleState) -> SymInt, tuple[Self@reduce_helper, Unknown | _UnpickleStateToken]]` torch/fx/_graph_pickler.py:250:33: warning[possibly-missing-attribute] Submodule `meta_utils` may not be available as an attribute on module `torch._subclasses` torch/fx/_graph_pickler.py:278:68: error[unresolved-attribute] Module `torch` has no member `device` torch/fx/_graph_pickler.py:317:16: warning[possibly-missing-attribute] Submodule `variables` may not be available as an attribute on module `torch._dynamo` @@ -18961,7 +20172,11 @@ torch/fx/experimental/proxy_tensor.py:624:5: error[type-assertion-failure] Type torch/fx/experimental/proxy_tensor.py:695:71: error[invalid-argument-type] Argument to function `_extract_tensor_metadata` is incorrect: Expected `Tensor`, found `SymInt | SymFloat | SymBool | ... omitted 10 union elements` torch/fx/experimental/proxy_tensor.py:952:18: error[unresolved-attribute] Module `torch` has no member `bfloat16` torch/fx/experimental/proxy_tensor.py:952:34: error[unresolved-attribute] Module `torch` has no member `float16` +torch/fx/experimental/proxy_tensor.py:1056:32: error[invalid-argument-type] Argument to bound method `decompose` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1056:39: error[invalid-argument-type] Argument to bound method `decompose` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1073:8: error[unresolved-attribute] Module `torch` has no member `Tag` +torch/fx/experimental/proxy_tensor.py:1145:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1145:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1190:9: error[unresolved-attribute] Module `torch` has no member `Tag` torch/fx/experimental/proxy_tensor.py:1382:13: warning[possibly-missing-attribute] Submodule `triton_kernel_wrap` may not be available as an attribute on module `torch._higher_order_ops` torch/fx/experimental/proxy_tensor.py:1383:13: warning[possibly-missing-attribute] Submodule `triton_kernel_wrap` may not be available as an attribute on module `torch._higher_order_ops` @@ -18969,6 +20184,8 @@ torch/fx/experimental/proxy_tensor.py:1411:53: error[unresolved-attribute] Modul torch/fx/experimental/proxy_tensor.py:1495:69: error[unresolved-attribute] Object of type `((...) -> Unknown) & ~Module` has no attribute `__name__` torch/fx/experimental/proxy_tensor.py:1496:12: warning[possibly-missing-attribute] Submodule `_lazy_graph_module` may not be available as an attribute on module `torch.fx` torch/fx/experimental/proxy_tensor.py:1569:22: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` +torch/fx/experimental/proxy_tensor.py:1577:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1577:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1599:22: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` torch/fx/experimental/proxy_tensor.py:1616:17: error[unresolved-attribute] Module `torch._C` has no member `_set_grad_enabled` torch/fx/experimental/proxy_tensor.py:1623:24: error[unresolved-attribute] Module `torch._C` has no member `_set_grad_enabled` @@ -18977,12 +20194,20 @@ torch/fx/experimental/proxy_tensor.py:1633:13: warning[possibly-missing-attribut torch/fx/experimental/proxy_tensor.py:1634:13: warning[possibly-missing-attribute] Submodule `predispatch` may not be available as an attribute on module `torch._functorch` torch/fx/experimental/proxy_tensor.py:1635:13: warning[possibly-missing-attribute] Submodule `predispatch` may not be available as an attribute on module `torch._functorch` torch/fx/experimental/proxy_tensor.py:1636:13: warning[possibly-missing-attribute] Submodule `vmap` may not be available as an attribute on module `torch._functorch` +torch/fx/experimental/proxy_tensor.py:1645:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1645:31: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1648:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1648:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1670:14: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` torch/fx/experimental/proxy_tensor.py:1679:26: error[unresolved-attribute] Module `torch._C` has no member `_TorchDispatchModeKey` torch/fx/experimental/proxy_tensor.py:1693:22: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` +torch/fx/experimental/proxy_tensor.py:1701:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1701:36: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1707:51: error[unresolved-attribute] Module `torch._C` has no member `_TorchDispatchModeKey` torch/fx/experimental/proxy_tensor.py:1711:9: error[invalid-method-override] Invalid override of method `__exit__`: Definition is incompatible with `TorchDispatchMode.__exit__` torch/fx/experimental/proxy_tensor.py:1733:22: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` +torch/fx/experimental/proxy_tensor.py:1749:20: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` +torch/fx/experimental/proxy_tensor.py:1749:27: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `object` torch/fx/experimental/proxy_tensor.py:1998:17: error[unresolved-attribute] Module `torch` has no member `is_autocast_cache_enabled` torch/fx/experimental/proxy_tensor.py:1999:5: error[unresolved-attribute] Module `torch` has no member `set_autocast_cache_enabled` torch/fx/experimental/proxy_tensor.py:2003:9: error[unresolved-attribute] Module `torch` has no member `set_autocast_cache_enabled` @@ -19003,6 +20228,18 @@ torch/fx/experimental/recording.py:169:56: error[unresolved-attribute] Object of torch/fx/experimental/recording.py:245:20: error[unresolved-attribute] Object of type `((...) -> Unknown) & (() -> object)` has no attribute `__name__` torch/fx/experimental/schema_type_annotation.py:110:38: error[unresolved-attribute] Module `torch._C` has no member `_jit_try_infer_type` torch/fx/experimental/shape_inference/infer_shape.py:53:30: error[unresolved-attribute] Module `torch` has no member `randn` +torch/fx/experimental/sym_node.py:491:21: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(args)`, found `tuple[tuple[Unknown, ...]]` +torch/fx/experimental/sym_node.py:492:21: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(args)`, found `dict[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1378:47: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `tuple[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1378:84: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `dict[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1463:58: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `tuple[Unknown]` +torch/fx/experimental/sym_node.py:1463:78: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `dict[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1507:25: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(b, t, f)`, found `tuple[Unknown, Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1512:25: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(b, t, f)`, found `dict[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1547:51: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `Overload[(number: _SupportsRound1[_T@round], ndigits: None = None) -> Unknown, (number: _SupportsRound2[_T@round], ndigits: SupportsIndex) -> Unknown]`, found `tuple[Unknown, Unknown | None]` +torch/fx/experimental/sym_node.py:1547:79: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `Overload[(number: _SupportsRound1[_T@round], ndigits: None = None) -> Unknown, (number: _SupportsRound2[_T@round], ndigits: SupportsIndex) -> Unknown]`, found `dict[Unknown, Unknown]` +torch/fx/experimental/sym_node.py:1599:21: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `tuple[list[Unknown], list[Unknown]]` +torch/fx/experimental/sym_node.py:1600:21: error[invalid-argument-type] Argument to function `handle_sym_dispatch` is incorrect: Expected `(...)`, found `dict[Unknown, Unknown]` torch/fx/experimental/symbolic_shapes.py:253:9: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int | SymInt, int]`, found `tuple[Literal[1], Unknown, int] | tuple[Literal[0], @Todo(StarredExpression)]` torch/fx/experimental/symbolic_shapes.py:253:13: warning[possibly-missing-attribute] Attribute `node` may be missing on object of type `int | SymInt` torch/fx/experimental/symbolic_shapes.py:326:9: warning[possibly-missing-attribute] Submodule `experimental` may not be available as an attribute on module `torch.fx` @@ -19040,7 +20277,7 @@ torch/fx/experimental/symbolic_shapes.py:4568:20: warning[possibly-missing-attri torch/fx/experimental/symbolic_shapes.py:4571:20: warning[possibly-missing-attribute] Attribute `node` may be missing on object of type `int | SymInt` torch/fx/experimental/symbolic_shapes.py:4758:16: error[invalid-return-type] Return type does not match returned value: expected `list[Expr]`, found `list[Unknown | None]` torch/fx/experimental/symbolic_shapes.py:5074:17: error[invalid-assignment] Invalid subscript assignment with key of type `Unknown` and value of type `int` on object of type `dict[Symbol, Integer]` -torch/fx/experimental/symbolic_shapes.py:5379:30: error[invalid-assignment] Object of type `list[StatelessSymbolicContext[Unknown, Unknown] | None | Unknown]` is not assignable to `list[SymbolicContext] | None` +torch/fx/experimental/symbolic_shapes.py:5379:30: error[invalid-assignment] Object of type `list[StatelessSymbolicContext[(...), Unknown] | None | Unknown]` is not assignable to `list[SymbolicContext] | None` torch/fx/experimental/symbolic_shapes.py:5677:62: error[invalid-argument-type] Argument to function `__new__` is incorrect: Expected `Iterable[SymbolicContext]`, found `list[SymbolicContext] | None` torch/fx/experimental/symbolic_shapes.py:6000:61: error[invalid-argument-type] Argument to bound method `doprint` is incorrect: Expected `Expr`, found `And` torch/fx/experimental/symbolic_shapes.py:6069:57: warning[possibly-missing-import] Member `PopulateValidator` of module `torch.fx.experimental.validator` may be missing @@ -19140,11 +20377,15 @@ torch/fx/operator_schemas.py:237:19: error[unresolved-attribute] Module `torch._ torch/fx/operator_schemas.py:328:51: error[unresolved-attribute] Module `torch` has no member `dtype` torch/fx/operator_schemas.py:382:18: error[invalid-assignment] Object of type `object` is not assignable to `(...) -> Unknown` torch/fx/passes/_tensorify_python_scalars.py:94:2: warning[possibly-missing-attribute] Submodule `_compatibility` may not be available as an attribute on module `torch.fx` +torch/fx/passes/_tensorify_python_scalars.py:149:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `MetaProxy` torch/fx/passes/_tensorify_python_scalars.py:157:25: error[unresolved-attribute] Module `torch` has no member `bool` torch/fx/passes/_tensorify_python_scalars.py:160:25: error[unresolved-attribute] Module `torch` has no member `int64` torch/fx/passes/_tensorify_python_scalars.py:163:25: error[unresolved-attribute] Module `torch` has no member `float64` +torch/fx/passes/_tensorify_python_scalars.py:174:73: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/fx/passes/_tensorify_python_scalars.py:228:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `MetaProxy` torch/fx/passes/_tensorify_python_scalars.py:228:46: error[unresolved-attribute] Module `torch` has no member `float64` torch/fx/passes/_tensorify_python_scalars.py:296:46: error[unresolved-attribute] Module `torch` has no member `bool` +torch/fx/passes/_tensorify_python_scalars.py:300:33: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `MetaProxy` torch/fx/passes/dialect/common/cse_pass.py:45:2: warning[possibly-missing-attribute] Submodule `_compatibility` may not be available as an attribute on module `torch.fx` torch/fx/passes/dialect/common/cse_pass.py:50:2: warning[possibly-missing-attribute] Submodule `_compatibility` may not be available as an attribute on module `torch.fx` torch/fx/passes/graph_drawer.py:18:12: error[unresolved-import] Cannot resolve imported module `pydot` @@ -19221,12 +20462,17 @@ torch/jit/_builtins.py:189:30: warning[possibly-missing-attribute] Member `get_g torch/jit/_builtins.py:190:30: warning[possibly-missing-attribute] Member `backward` may be missing on module `torch.distributed.autograd` torch/jit/_decomposition_utils.py:6:52: error[unresolved-attribute] Module `torch._C` has no member `Graph` torch/jit/_decomposition_utils.py:12:5: error[unresolved-attribute] Module `torch._C` has no member `_jit_register_decomposition_for_schema` -torch/jit/_decompositions.py:81:16: error[unresolved-attribute] Object of type `(...) -> _T@register_decomposition` has no attribute `__name__` -torch/jit/_decompositions.py:82:41: error[unresolved-attribute] Object of type `(...) -> _T@register_decomposition` has no attribute `__name__` -torch/jit/_decompositions.py:84:31: error[unresolved-attribute] Object of type `(...) -> _T@register_decomposition` has no attribute `__name__` +torch/jit/_decompositions.py:81:16: error[unresolved-attribute] Object of type `(**_P@register_decomposition) -> _T@register_decomposition` has no attribute `__name__` +torch/jit/_decompositions.py:82:41: error[unresolved-attribute] Object of type `(**_P@register_decomposition) -> _T@register_decomposition` has no attribute `__name__` +torch/jit/_decompositions.py:84:31: error[unresolved-attribute] Object of type `(**_P@register_decomposition) -> _T@register_decomposition` has no attribute `__name__` torch/jit/_decompositions.py:87:9: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_inline` torch/jit/_decompositions.py:90:13: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_peephole` torch/jit/_decompositions.py:91:13: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_constant_propagation` +torch/jit/_decompositions.py:120:22: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/jit/_decompositions.py:120:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/jit/_decompositions.py:120:34: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/jit/_decompositions.py:123:24: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[int]` +torch/jit/_decompositions.py:123:29: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/jit/_freeze.py:117:33: error[unresolved-attribute] Module `torch._C` has no member `_freeze_module` torch/jit/_freeze.py:174:9: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_optimize_frozen_graph` torch/jit/_freeze.py:180:9: error[unresolved-attribute] Module `torch._C` has no member `_jit_pass_optimize_frozen_graph` @@ -19461,9 +20707,9 @@ torch/library.py:731:24: warning[possibly-missing-attribute] Submodule `utils` m torch/library.py:764:12: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_key_for_device` torch/library.py:782:36: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` torch/library.py:837:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:844:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:844:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:897:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:907:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:907:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:913:11: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:915:25: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:928:35: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` @@ -19474,13 +20720,13 @@ torch/library.py:934:13: error[unresolved-attribute] Module `torch._C` has no me torch/library.py:934:37: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` torch/library.py:935:14: error[unresolved-attribute] Module `torch._C` has no member `_ExcludeDispatchKeyGuard` torch/library.py:1051:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:1056:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:1056:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:1067:30: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1101:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:1109:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:1109:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:1114:20: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1215:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:1222:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:1222:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:1229:10: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1231:12: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1237:8: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` @@ -19488,10 +20734,10 @@ torch/library.py:1244:12: warning[possibly-missing-attribute] Submodule `autogra torch/library.py:1245:23: warning[possibly-missing-attribute] Submodule `autograd` may not be available as an attribute on module `torch._library` torch/library.py:1246:25: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1306:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:1313:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:1313:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:1319:30: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1420:42: warning[possibly-missing-attribute] Submodule `custom_ops` may not be available as an attribute on module `torch._library` -torch/library.py:1425:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[Unknown, Any] | str`, found `object` +torch/library.py:1425:30: error[invalid-argument-type] Argument to function `_maybe_get_opdef` is incorrect: Expected `CustomOpDef | OpOverload[EllipsisType, Any] | str`, found `object` torch/library.py:1430:10: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1432:8: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` torch/library.py:1442:29: warning[possibly-missing-attribute] Submodule `utils` may not be available as an attribute on module `torch._library` @@ -19504,9 +20750,9 @@ torch/library.py:1528:50: error[unresolved-attribute] Module `torch` has no memb torch/library.py:1529:6: error[unresolved-attribute] Module `torch._C` has no member `_SafeKernelFunction` torch/library.py:1594:28: error[unresolved-attribute] Module `torch._C` has no member `DispatchKey` torch/library.py:1598:12: error[unresolved-attribute] Module `torch._C` has no member `_dispatch_get_computed_kernel_for_dispatch_key` -torch/masked/_ops.py:42:36: error[unresolved-attribute] Object of type `(...) -> _T@_apply_docstring_templates` has no attribute `__name__` -torch/masked/_ops.py:45:54: error[unresolved-attribute] Object of type `(...) -> _T@_apply_docstring_templates` has no attribute `__name__` -torch/masked/_ops.py:54:20: error[unresolved-attribute] Object of type `(...) -> _T@_apply_docstring_templates` has no attribute `__name__` +torch/masked/_ops.py:42:36: error[unresolved-attribute] Object of type `(**_P@_apply_docstring_templates) -> _T@_apply_docstring_templates` has no attribute `__name__` +torch/masked/_ops.py:45:54: error[unresolved-attribute] Object of type `(**_P@_apply_docstring_templates) -> _T@_apply_docstring_templates` has no attribute `__name__` +torch/masked/_ops.py:54:20: error[unresolved-attribute] Object of type `(**_P@_apply_docstring_templates) -> _T@_apply_docstring_templates` has no attribute `__name__` torch/masked/_ops.py:295:21: error[unresolved-attribute] Module `torch` has no member `tensor` torch/masked/_ops.py:296:20: error[unresolved-attribute] Module `torch` has no member `tensor` torch/masked/_ops.py:300:48: error[unresolved-attribute] Module `torch` has no member `float32` @@ -19690,6 +20936,7 @@ torch/masked/maskedtensor/_ops_refs.py:135:28: error[unresolved-attribute] Modul torch/masked/maskedtensor/_ops_refs.py:165:48: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/masked/maskedtensor/_ops_refs.py:214:46: error[unresolved-attribute] Module `torch` has no member `where` torch/masked/maskedtensor/_ops_refs.py:368:30: error[unresolved-attribute] Module `torch` has no member `bool` +torch/masked/maskedtensor/_ops_refs.py:380:72: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[2]` torch/masked/maskedtensor/_ops_refs.py:434:31: error[unresolved-attribute] Module `torch` has no member `ones_like` torch/masked/maskedtensor/_ops_refs.py:434:57: error[unresolved-attribute] Module `torch` has no member `bool` torch/masked/maskedtensor/_ops_refs.py:436:31: error[unresolved-attribute] Module `torch` has no member `ones_like` @@ -19900,21 +21147,34 @@ torch/nested/_internal/ops.py:648:13: error[unresolved-attribute] Module `torch` torch/nested/_internal/ops.py:658:14: error[unresolved-attribute] Module `torch` has no member `matmul` torch/nested/_internal/ops.py:667:18: error[unresolved-attribute] Module `torch` has no member `sum` torch/nested/_internal/ops.py:780:28: error[unresolved-attribute] Module `torch` has no member `strided` +torch/nested/_internal/ops.py:894:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/nested/_internal/ops.py:895:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/nested/_internal/ops.py:896:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/nested/_internal/ops.py:902:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nested/_internal/ops.py:903:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:1099:28: error[unresolved-attribute] Module `torch` has no member `cumsum` torch/nested/_internal/ops.py:1186:9: error[unresolved-attribute] Module `torch` has no member `narrow` torch/nested/_internal/ops.py:1362:20: error[unresolved-attribute] Module `torch` has no member `stack` +torch/nested/_internal/ops.py:1819:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/nested/_internal/ops.py:1820:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:1824:13: error[unresolved-attribute] Module `torch` has no member `ones` +torch/nested/_internal/ops.py:1825:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/nested/_internal/ops.py:1826:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:1836:13: error[unresolved-attribute] Module `torch` has no member `sum` torch/nested/_internal/ops.py:1849:13: error[unresolved-attribute] Module `torch` has no member `sum` torch/nested/_internal/ops.py:1850:17: error[unresolved-attribute] Module `torch` has no member `square` torch/nested/_internal/ops.py:1857:15: error[unresolved-attribute] Module `torch` has no member `sqrt` +torch/nested/_internal/ops.py:1862:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:2009:5: error[unresolved-attribute] Module `torch` has no member `_assert_async` torch/nested/_internal/ops.py:2011:9: error[unresolved-attribute] Module `torch` has no member `all` torch/nested/_internal/ops.py:2410:31: error[unresolved-attribute] Module `torch` has no member `bool` torch/nested/_internal/ops.py:2412:28: error[unresolved-attribute] Module `torch` has no member `half` +torch/nested/_internal/ops.py:2415:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` +torch/nested/_internal/ops.py:2416:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:2420:36: error[unresolved-attribute] Module `torch` has no member `bool` torch/nested/_internal/ops.py:2457:31: error[unresolved-attribute] Module `torch` has no member `bool` torch/nested/_internal/ops.py:2459:28: error[unresolved-attribute] Module `torch` has no member `half` +torch/nested/_internal/ops.py:2461:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown]` torch/nested/_internal/ops.py:2464:28: error[unresolved-attribute] Module `torch` has no member `bool` torch/nested/_internal/ops.py:2610:18: error[unresolved-attribute] Module `torch` has no member `zeros_like` torch/nested/_internal/ops.py:2728:21: error[unresolved-attribute] Module `torch` has no member `matmul` @@ -19926,6 +21186,18 @@ torch/nested/_internal/sdpa.py:660:24: warning[possibly-missing-attribute] Submo torch/nested/_internal/sdpa.py:694:47: error[unresolved-attribute] Module `torch` has no member `is_autocast_enabled` torch/nested/_internal/sdpa.py:700:24: error[unresolved-attribute] Module `torch` has no member `get_autocast_dtype` torch/nested/_internal/sdpa.py:704:27: error[unresolved-attribute] Module `torch` has no member `float64` +torch/nested/_internal/sdpa.py:801:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/nested/_internal/sdpa.py:802:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/nested/_internal/sdpa.py:803:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nested/_internal/sdpa.py:834:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nested/_internal/sdpa.py:839:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/nested/_internal/sdpa.py:840:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nested/_internal/sdpa.py:842:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/nested/_internal/sdpa.py:874:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor | None` +torch/nested/_internal/sdpa.py:880:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | float` +torch/nested/_internal/sdpa.py:881:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[False]` +torch/nested/_internal/sdpa.py:882:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nested/_internal/sdpa.py:883:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` torch/nested/_internal/sdpa.py:904:25: error[unresolved-attribute] Module `torch` has no member `transpose` torch/nested/_internal/sdpa.py:914:20: error[unresolved-attribute] Module `torch` has no member `_scaled_dot_product_attention_math` torch/nn/attention/__init__.py:10:22: error[unresolved-import] Module `torch._C` has no member `_SDPBackend` @@ -19956,6 +21228,23 @@ torch/nn/attention/bias.py:171:22: error[unresolved-attribute] Module `torch` ha torch/nn/attention/bias.py:239:60: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[Literal[0], Unknown]` torch/nn/attention/bias.py:240:56: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[Literal[0], Unknown]` torch/nn/attention/bias.py:241:60: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[Literal[0], Unknown]` +torch/nn/attention/bias.py:243:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/bias.py:244:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/bias.py:245:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/bias.py:246:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/nn/attention/bias.py:247:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/nn/attention/bias.py:248:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/attention/bias.py:249:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/nn/attention/bias.py:260:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/bias.py:261:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/bias.py:262:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/bias.py:263:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/bias.py:264:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/bias.py:265:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/nn/attention/bias.py:266:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/bias.py:267:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/nn/attention/bias.py:268:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float | None` +torch/nn/attention/bias.py:269:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` torch/nn/attention/experimental/_paged_attention.py:47:28: error[unresolved-attribute] Module `torch` has no member `ones` torch/nn/attention/experimental/_paged_attention.py:48:51: error[unresolved-attribute] Module `torch` has no member `int64` torch/nn/attention/experimental/_paged_attention.py:52:25: error[unresolved-attribute] Module `torch` has no member `zeros` @@ -20020,6 +21309,28 @@ torch/nn/attention/flex_attention.py:1229:52: error[unresolved-attribute] Module torch/nn/attention/flex_attention.py:1272:46: error[unresolved-attribute] Module `torch` has no member `is_grad_enabled` torch/nn/attention/flex_attention.py:1340:9: error[unresolved-attribute] Module `torch` has no member `float8_e4m3fn` torch/nn/attention/flex_attention.py:1341:9: error[unresolved-attribute] Module `torch` has no member `float8_e5m2` +torch/nn/attention/varlen.py:58:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:59:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:60:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:61:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/attention/varlen.py:62:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:63:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:64:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:65:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:66:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/nn/attention/varlen.py:67:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/nn/attention/varlen.py:68:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/nn/attention/varlen.py:69:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/attention/varlen.py:76:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:77:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:78:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:79:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:80:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:81:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:82:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:83:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/nn/attention/varlen.py:84:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/nn/attention/varlen.py:85:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` torch/nn/attention/varlen.py:88:18: error[unresolved-attribute] Module `torch` has no member `zeros` torch/nn/attention/varlen.py:89:21: error[unresolved-attribute] Module `torch` has no member `uint64` torch/nn/attention/varlen.py:113:14: error[unresolved-attribute] Module `torch` has no member `empty_like` @@ -20027,10 +21338,75 @@ torch/nn/attention/varlen.py:118:17: error[unresolved-attribute] Module `torch` torch/nn/attention/varlen.py:119:37: error[unresolved-attribute] Module `torch` has no member `float` torch/nn/attention/varlen.py:122:17: error[unresolved-attribute] Module `torch` has no member `empty` torch/nn/attention/varlen.py:122:41: error[unresolved-attribute] Module `torch` has no member `uint64` +torch/nn/attention/varlen.py:199:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:199:16: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:199:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:199:28: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:199:38: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:199:48: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:199:55: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:199:62: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` torch/nn/attention/varlen.py:232:14: error[unresolved-attribute] Module `torch` has no member `empty` +torch/nn/attention/varlen.py:238:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:239:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:240:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:241:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:242:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:243:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:244:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:245:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:246:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:247:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:248:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/nn/attention/varlen.py:249:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/nn/attention/varlen.py:250:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:256:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:257:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:258:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:259:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:260:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:261:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:262:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:263:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/attention/varlen.py:264:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:265:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int` +torch/nn/attention/varlen.py:266:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `float` +torch/nn/attention/varlen.py:267:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `bool` +torch/nn/attention/varlen.py:268:13: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/nn/attention/varlen.py:293:18: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/nn/attention/varlen.py:294:16: error[unresolved-attribute] Module `torch` has no member `empty_like` torch/nn/attention/varlen.py:295:18: error[unresolved-attribute] Module `torch` has no member `empty_like` +torch/nn/attention/varlen.py:310:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` +torch/nn/grad.py:47:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:51:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:52:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:53:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:54:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` +torch/nn/grad.py:95:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:99:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:100:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:101:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:102:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[False], Literal[True], Literal[False]]` +torch/nn/grad.py:145:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:149:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:150:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:151:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:152:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` +torch/nn/grad.py:193:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:197:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:198:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:199:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:200:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[False], Literal[True], Literal[False]]` +torch/nn/grad.py:243:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:247:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:248:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:249:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:250:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` +torch/nn/grad.py:290:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `None` +torch/nn/grad.py:294:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[False]` +torch/nn/grad.py:295:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `list[Unknown | int]` +torch/nn/grad.py:296:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | Literal[1]` +torch/nn/grad.py:297:9: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[False], Literal[True], Literal[False]]` torch/nn/init.py:70:62: error[unresolved-attribute] Module `torch` has no member `Generator` torch/nn/init.py:80:26: error[unresolved-attribute] Module `torch` has no member `Generator` torch/nn/init.py:92:26: error[unresolved-attribute] Module `torch` has no member `Generator` @@ -20047,7 +21423,7 @@ torch/nn/init.py:634:26: error[unresolved-attribute] Module `torch` has no membe torch/nn/init.py:669:9: error[unresolved-attribute] Module `torch` has no member `diag` torch/nn/init.py:686:26: error[unresolved-attribute] Module `torch` has no member `Generator` torch/nn/init.py:714:27: error[unresolved-attribute] Module `torch` has no member `randperm` -torch/nn/init.py:722:16: error[unresolved-attribute] Object of type `(...) -> _R@_make_deprecate` has no attribute `__name__` +torch/nn/init.py:722:16: error[unresolved-attribute] Object of type `(**_P@_make_deprecate) -> _R@_make_deprecate` has no attribute `__name__` torch/nn/modules/_functions.py:23:47: error[unresolved-attribute] Module `torch` has no member `channels_last` torch/nn/modules/_functions.py:24:50: error[unresolved-attribute] Module `torch` has no member `channels_last_3d` torch/nn/modules/_functions.py:39:28: error[unresolved-attribute] Module `torch` has no member `batch_norm_stats` @@ -20324,6 +21700,10 @@ torch/nn/modules/module.py:1949:13: error[unresolved-attribute] Cannot assign ob torch/nn/modules/module.py:2258:13: error[unresolved-attribute] Unresolved attribute `_metadata` on type `OrderedDict[Unknown, Unknown]`. torch/nn/modules/module.py:2262:13: error[invalid-assignment] Cannot assign to a subscript on an object of type `object` torch/nn/modules/module.py:2897:9: error[unresolved-attribute] Cannot assign object of type `bool` to attribute `training` on type `Self@train` with custom `__setattr__` method. +torch/nn/modules/module.py:3028:9: error[unresolved-attribute] Cannot assign object of type `dict[str, Any]` to attribute `__dict__` on type `Self@_replicate_for_data_parallel` with custom `__setattr__` method. +torch/nn/modules/module.py:3032:9: error[unresolved-attribute] Cannot assign object of type `dict[Unknown, Unknown]` to attribute `_parameters` on type `Self@_replicate_for_data_parallel` with custom `__setattr__` method. +torch/nn/modules/module.py:3033:9: error[unresolved-attribute] Cannot assign object of type `dict[str, Tensor | None]` to attribute `_buffers` on type `Self@_replicate_for_data_parallel` with custom `__setattr__` method. +torch/nn/modules/module.py:3034:9: error[unresolved-attribute] Cannot assign object of type `dict[str, Module | None]` to attribute `_modules` on type `Self@_replicate_for_data_parallel` with custom `__setattr__` method. torch/nn/modules/module.py:3048:9: error[unresolved-attribute] Cannot assign object of type `(...) -> Unknown` to attribute `_compiled_call_impl` on type `Self@compile` with custom `__setattr__` method. torch/nn/modules/normalization.py:6:19: error[unresolved-import] Module `torch` has no member `Size` torch/nn/modules/normalization.py:57:9: error[unresolved-attribute] Cannot assign object of type `int` to attribute `size` on type `Self@__init__` with custom `__setattr__` method. @@ -20577,6 +21957,7 @@ torch/nn/parameter.py:125:9: error[unresolved-attribute] Module `torch` has no m torch/nn/parameter.py:146:21: error[unresolved-attribute] Module `torch` has no member `empty` torch/nn/parameter.py:148:26: error[unresolved-attribute] Object of type `Self@materialize` has no attribute `cls_to_become` torch/nn/parameter.py:172:34: error[unresolved-attribute] Object of type `Self@__reduce_ex__` has no attribute `requires_grad` +torch/nn/parameter.py:182:20: error[unresolved-attribute] Object of type `, >` has no attribute `__torch_function__` torch/nn/parameter.py:222:16: error[unresolved-attribute] Module `torch` has no member `empty` torch/nn/parameter.py:236:19: error[unresolved-attribute] Module `torch._C` has no member `_TensorMeta` torch/nn/parameter.py:247:1: error[conflicting-metaclass] The metaclass of a derived class (`Buffer`) must be a subclass of the metaclasses of all its bases, but `_BufferMeta` (metaclass of `Buffer`) and `type` (metaclass of base class `Tensor`) have no subclass relationship @@ -20587,6 +21968,7 @@ torch/nn/parameter.pyi:3:27: error[unresolved-import] Module `torch` has no memb torch/nn/utils/__init__.py:5:5: warning[deprecated] The function `clip_grad_norm` is deprecated: `torch.nn.utils.clip_grad_norm` is now deprecated in favor of `torch.nn.utils.clip_grad_norm_`. torch/nn/utils/_expanded_weights/conv_utils.py:184:23: error[unresolved-attribute] Module `torch` has no member `narrow` torch/nn/utils/_expanded_weights/conv_utils.py:336:17: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `list[int]`, found `tuple[Unknown, Unknown, Unknown, Unknown, Unknown, Unknown]` +torch/nn/utils/_expanded_weights/embedding_expanded_weights.py:72:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/nn/utils/_expanded_weights/expanded_weights_impl.py:18:5: error[unresolved-attribute] Module `torch` has no member `rnn_relu` torch/nn/utils/_expanded_weights/expanded_weights_impl.py:22:5: error[unresolved-attribute] Module `torch` has no member `rnn_tanh` torch/nn/utils/_expanded_weights/expanded_weights_impl.py:26:5: error[unresolved-attribute] Module `torch` has no member `lstm` @@ -20595,11 +21977,19 @@ torch/nn/utils/_expanded_weights/expanded_weights_impl.py:135:17: error[index-ou torch/nn/utils/_expanded_weights/expanded_weights_impl.py:143:20: error[unresolved-attribute] Module `torch` has no member `_cudnn_rnn_flatten_weight` torch/nn/utils/_expanded_weights/expanded_weights_utils.py:134:28: error[unresolved-attribute] Module `torch` has no member `zeros` torch/nn/utils/_expanded_weights/group_norm_expanded_weights.py:35:13: error[unresolved-attribute] Module `torch` has no member `native_group_norm` +torch/nn/utils/_expanded_weights/group_norm_expanded_weights.py:75:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/nn/utils/_expanded_weights/group_norm_expanded_weights.py:82:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[1] | Unknown` +torch/nn/utils/_expanded_weights/group_norm_expanded_weights.py:84:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:21:33: error[unresolved-attribute] Module `torch` has no member `instance_norm` torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:59:20: error[unresolved-attribute] Module `torch` has no member `mean` torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:62:19: error[unresolved-attribute] Module `torch` has no member `var` torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:68:24: error[unresolved-attribute] Module `torch` has no member `sqrt` +torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:76:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:77:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Unknown | None` +torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:80:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal[True]` +torch/nn/utils/_expanded_weights/instance_norm_expanded_weights.py:82:17: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` torch/nn/utils/_expanded_weights/layer_norm_expanded_weights.py:32:13: error[unresolved-attribute] Module `torch` has no member `native_layer_norm` +torch/nn/utils/_expanded_weights/layer_norm_expanded_weights.py:71:21: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `tuple[Literal[True], Literal[False], Literal[False]]` torch/nn/utils/clip_grad.py:83:16: error[unresolved-attribute] Module `torch` has no member `tensor` torch/nn/utils/clip_grad.py:86:15: error[unresolved-attribute] Module `torch` has no member `device` torch/nn/utils/clip_grad.py:86:29: error[unresolved-attribute] Module `torch` has no member `dtype` @@ -20829,7 +22219,7 @@ torch/onnx/_internal/exporter/_testing.py:79:14: error[unresolved-attribute] Mod torch/onnx/_internal/exporter/_testing.py:80:42: error[unresolved-attribute] Module `torch` has no member `view_as_real` torch/onnx/_internal/exporter/_torchlib/_tensor_typing.py:7:6: error[unresolved-import] Cannot resolve imported module `onnxscript` torch/onnx/_internal/exporter/_torchlib/_torchlib_registry.py:13:8: error[unresolved-import] Cannot resolve imported module `onnxscript` -torch/onnx/_internal/exporter/_torchlib/_torchlib_registry.py:76:25: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[Unknown, Any] | BuiltinFunctionType | ((...) -> Unknown)`, found `object` +torch/onnx/_internal/exporter/_torchlib/_torchlib_registry.py:76:25: error[invalid-argument-type] Argument is incorrect: Expected `OpOverload[EllipsisType, Any] | BuiltinFunctionType | ((...) -> Unknown)`, found `object` torch/onnx/_internal/exporter/_torchlib/ops/core.py:10:6: error[unresolved-import] Cannot resolve imported module `onnxscript.onnx_opset` torch/onnx/_internal/exporter/_torchlib/ops/hop.py:31:10: error[unresolved-import] Cannot resolve imported module `onnxscript.ir` torch/onnx/_internal/exporter/_torchlib/ops/symbolic.py:7:6: error[unresolved-import] Cannot resolve imported module `onnxscript.ir` @@ -21011,7 +22401,7 @@ torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:280:43: error[unres torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:280:62: error[unresolved-attribute] Module `torch._C` has no member `Value` torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:352:95: error[unresolved-attribute] Object of type `(...) -> _T@parse_args` has no attribute `__name__` torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:359:27: error[unresolved-attribute] Object of type `(...) -> _T@parse_args` has no attribute `__name__` -torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:365:20: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to `tuple[@Todo, ...]` +torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:365:20: error[invalid-assignment] Object of type `list[Unknown]` is not assignable to `_P@wrapper.args` torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:371:38: error[unresolved-attribute] Object of type `(...) -> _T@parse_args` has no attribute `__name__` torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:378:42: error[unresolved-attribute] Object of type `(...) -> _T@parse_args` has no attribute `__name__` torch/onnx/_internal/torchscript_exporter/symbolic_helper.py:442:51: error[unresolved-attribute] Module `torch` has no member `tensor` @@ -23453,10 +24843,10 @@ torch/utils/_pytree.py:1281:34: error[unresolved-attribute] Special form `typing torch/utils/_pytree.py:1341:18: warning[deprecated] The class `LeafSpec` is deprecated: `isinstance(treespec, LeafSpec)` is deprecated, use `isinstance(treespec, TreeSpec) and treespec.is_leaf()` instead. torch/utils/_pytree.py:1344:24: warning[deprecated] The class `LeafSpec` is deprecated: `isinstance(treespec, LeafSpec)` is deprecated, use `isinstance(treespec, TreeSpec) and treespec.is_leaf()` instead. torch/utils/_pytree.py:1917:40: error[invalid-argument-type] Argument to function `_treespec_to_json` is incorrect: Expected `TreeSpec`, found `` -torch/utils/_stats.py:26:12: error[unresolved-attribute] Object of type `(...) -> _R@count` has no attribute `__qualname__` -torch/utils/_stats.py:27:33: error[unresolved-attribute] Object of type `(...) -> _R@count` has no attribute `__qualname__` -torch/utils/_stats.py:28:29: error[unresolved-attribute] Object of type `(...) -> _R@count` has no attribute `__qualname__` -torch/utils/_stats.py:28:68: error[unresolved-attribute] Object of type `(...) -> _R@count` has no attribute `__qualname__` +torch/utils/_stats.py:26:12: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__` +torch/utils/_stats.py:27:33: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__` +torch/utils/_stats.py:28:29: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__` +torch/utils/_stats.py:28:68: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__` torch/utils/_strobelight/examples/cli_function_profiler_example.py:22:20: error[unresolved-attribute] Module `torch` has no member `rand` torch/utils/_strobelight/examples/cli_function_profiler_example.py:22:38: error[unresolved-attribute] Module `torch` has no member `rand` torch/utils/_strobelight/examples/cli_function_profiler_example.py:22:56: error[unresolved-attribute] Module `torch` has no member `rand` @@ -23531,9 +24921,12 @@ torch/utils/_sympy/reference.py:224:23: error[unresolved-attribute] Module `torc torch/utils/_sympy/reference.py:226:23: error[unresolved-attribute] Module `torch` has no member `bool` torch/utils/_sympy/reference.py:260:21: error[unresolved-attribute] Module `torch` has no member `float64` torch/utils/_sympy/reference.py:348:39: error[unresolved-attribute] Module `torch` has no member `dtype` +torch/utils/_sympy/reference.py:349:57: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Tensor` torch/utils/_sympy/reference.py:372:21: error[unresolved-attribute] Module `torch` has no member `int64` torch/utils/_sympy/reference.py:374:23: error[unresolved-attribute] Module `torch` has no member `double` torch/utils/_sympy/reference.py:376:23: error[unresolved-attribute] Module `torch` has no member `bool` +torch/utils/_sympy/reference.py:380:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `int | float` +torch/utils/_sympy/reference.py:497:53: error[invalid-argument-type] Argument to bound method `__call__` is incorrect: Expected `EllipsisType`, found `Literal["floor"]` torch/utils/_sympy/solve.py:23:31: error[invalid-argument-type] Argument to bound method `get` is incorrect: Expected `type[Basic]`, found `type` torch/utils/_sympy/value_ranges.py:134:18: error[unresolved-reference] Name `ValueRanges` used when not defined torch/utils/_sympy/value_ranges.py:136:18: error[unresolved-reference] Name `ValueRanges` used when not defined @@ -23950,8 +25343,6 @@ torch/xpu/__init__.py:474:28: error[unresolved-attribute] Module `torch` has no torch/xpu/__init__.py:474:45: error[unresolved-attribute] Module `torch._C` has no member `Generator` torch/xpu/__init__.py:487:42: error[unresolved-attribute] Module `torch` has no member `device` torch/xpu/__init__.py:505:51: error[unresolved-attribute] Module `torch` has no member `device` -torch/xpu/_gpu_trace.py:8:46: error[invalid-type-arguments] Too many type arguments to class `CallbackRegistry`: expected 1, got 2 -torch/xpu/_gpu_trace.py:11:44: error[invalid-type-arguments] Too many type arguments to class `CallbackRegistry`: expected 1, got 2 torch/xpu/_utils.py:29:18: error[unresolved-attribute] Module `torch` has no member `device` torch/xpu/_utils.py:30:27: error[unresolved-attribute] Module `torch` has no member `device` torch/xpu/memory.py:23:9: error[unresolved-attribute] Module `torch._C` has no member `_xpu_emptyCache` @@ -23971,4 +25362,4 @@ torch/xpu/random.py:52:18: error[unresolved-attribute] Module `torch` has no mem torch/xpu/random.py:54:18: error[unresolved-attribute] Module `torch` has no member `device` torch/xpu/streams.py:14:14: error[unresolved-attribute] Module `torch._C` has no member `_XpuStreamBase` torch/xpu/streams.py:103:13: error[unresolved-attribute] Module `torch._C` has no member `_XpuEventBase` -Found 23801 diagnostics +Found 25192 diagnostics diff --git a/scripts/ty_benchmark/src/benchmark/projects.py b/scripts/ty_benchmark/src/benchmark/projects.py index 5e2ead0b3b..a2c3278969 100644 --- a/scripts/ty_benchmark/src/benchmark/projects.py +++ b/scripts/ty_benchmark/src/benchmark/projects.py @@ -177,7 +177,7 @@ ALL: Final = [ Project( name="homeassistant", repository="https://github.com/home-assistant/core.git", - revision="7fd440c4a06777bc4cfd90a3c176ded80c87a8fd", + revision="7b6df1a8a074afefff6a50b3495dafd5954b6dac", python_version="3.14", include=["homeassistant"], skip="Missing dependencies on Windows" if sys.platform == "win32" else None, diff --git a/scripts/ty_benchmark/src/benchmark/venv.py b/scripts/ty_benchmark/src/benchmark/venv.py index b8c45e224b..1462780545 100644 --- a/scripts/ty_benchmark/src/benchmark/venv.py +++ b/scripts/ty_benchmark/src/benchmark/venv.py @@ -73,7 +73,7 @@ class Venv: # our projects isn't unexpectedly broken by a change in the # annotations of one of that project's dependencies "--exclude-newer", - "2025-12-06T00:00:00Z", + "2025-12-13T00:00:00Z", "mypy", # We need to install mypy into the virtual environment or it fails to load plugins. *pip_install_args, ] diff --git a/scripts/ty_benchmark/uv.lock b/scripts/ty_benchmark/uv.lock index 7b344a684d..4ea85b2e83 100644 --- a/scripts/ty_benchmark/uv.lock +++ b/scripts/ty_benchmark/uv.lock @@ -116,23 +116,23 @@ wheels = [ [[package]] name = "pyrefly" -version = "0.44.1" +version = "0.45.2" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/da/d8/b2ae5bdb24be6d81728a5de6b7bf10d2e84f9dcbdc29d084aca724f87262/pyrefly-0.44.1.tar.gz", hash = "sha256:9ec70988588f39c20bab25827ffb706f6b985acc43ec5f6bad6d3bc1f6881def", size = 3942165, upload-time = "2025-12-04T00:08:04.103Z" } +sdist = { url = "https://files.pythonhosted.org/packages/ce/1f/f9a64686ccc487906f97fb55a155875e600634a96f506a9b764b7c58fbb1/pyrefly-0.45.2.tar.gz", hash = "sha256:3f2f011e3fe6ed6662c8aab86c05365336b2bb07d44852fe7428be61239a9fe1", size = 5055002, upload-time = "2025-12-11T00:27:43.027Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/de/ed/87c2ecbf796dd8868db889e02f4bf7cd3e41c53ef7dbbf9a0803a093fbba/pyrefly-0.44.1-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:99e2e5d388eeeecf51c30d430563f04e40a5fc5352f3dab82a8f85aca1af2318", size = 9977353, upload-time = "2025-12-04T00:07:40.433Z" }, - { url = "https://files.pythonhosted.org/packages/0b/df/1923f02370b92d84ccc2634342f2c9635e6c5a4ff53d81fc0e1540a47753/pyrefly-0.44.1-py3-none-macosx_11_0_arm64.whl", hash = "sha256:89c9d503b040613da2a8ae7044c6530a1d8b8c6dbb13465617e1adb2c99b2e31", size = 9565577, upload-time = "2025-12-04T00:07:43.133Z" }, - { url = "https://files.pythonhosted.org/packages/08/8a/26e95330ba127d642a11026f5e926ba84daaa1f4930c6c546c57d6aa3aa5/pyrefly-0.44.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:64969d6b44018f70670b416d74c56d80b949933f2651c0673a89359a6816bdde", size = 9813767, upload-time = "2025-12-04T00:07:45.788Z" }, - { url = "https://files.pythonhosted.org/packages/73/c4/79625096a3fa4f3a2c043df4fdb842b65e37f5ff4df741229b9b7bcc4117/pyrefly-0.44.1-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:82a90514f452912c5013162e0d00c5d3eac1265e77be69dd47a73530eced1cdc", size = 10654009, upload-time = "2025-12-04T00:07:49.43Z" }, - { url = "https://files.pythonhosted.org/packages/0c/b7/45c60666403606274715cc6c5e6112ca3f1377af7d23b1495f0ba24c4748/pyrefly-0.44.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:30b4fa577509f927cbcb2f7ad092307ca5a91bc137d74679671e1a6e4fb6f629", size = 10293339, upload-time = "2025-12-04T00:07:52.548Z" }, - { url = "https://files.pythonhosted.org/packages/26/6d/aa934774460a9f7ac8f4dbf0423e058901589d8afe3ad4dd1e1ae8eadab0/pyrefly-0.44.1-py3-none-win32.whl", hash = "sha256:d77d7b7f7df7edf40dfca16cc6e2de17ac5c377ba558c9b350d10484a807b04b", size = 9717767, upload-time = "2025-12-04T00:07:55.586Z" }, - { url = "https://files.pythonhosted.org/packages/47/4f/7705110ae44d42b0f006745c9f432a19090d2002daf25f5f356608b1112e/pyrefly-0.44.1-py3-none-win_amd64.whl", hash = "sha256:7c0ca181400fdd382b4eb24ade6a6f6787c513566b77acb8f79750f80e80133b", size = 10371240, upload-time = "2025-12-04T00:07:58.823Z" }, - { url = "https://files.pythonhosted.org/packages/88/ff/b3e20628f6477489a366f6ff98d0ec6c74de643913c58c82eb4d73b1ef1a/pyrefly-0.44.1-py3-none-win_arm64.whl", hash = "sha256:5e8cc66acd173e2612361c03ef7b45d7245c04b09cbd24042b27c6081f6cd809", size = 9946460, upload-time = "2025-12-04T00:08:01.8Z" }, + { url = "https://files.pythonhosted.org/packages/50/b8/67798a7db5520fa85420e270f323dc091d5fd73a492eaf8c143d14fc9859/pyrefly-0.45.2-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:33467adbb9aa4993666a1e3dcb35d00facdea1750692ccb2a07fdb9204cf1f10", size = 11194425, upload-time = "2025-12-11T00:27:23.364Z" }, + { url = "https://files.pythonhosted.org/packages/c2/1b/f5f36b053f2b31e1c3348e259dfa9dd17fbf796b782a3de530ededa5ce9a/pyrefly-0.45.2-py3-none-macosx_11_0_arm64.whl", hash = "sha256:5eded1227406f57cffe240c232fbee6f585f9441709b9e1cfb994a6b175a28cf", size = 10787764, upload-time = "2025-12-11T00:27:25.557Z" }, + { url = "https://files.pythonhosted.org/packages/23/49/a6528dac16638748e60c31768aa591b6cfef5a5cd917693937a075daccfa/pyrefly-0.45.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f2007e49807f6564505615fa7422a3278c58aa648e2b8b2d9b89ea04cf4ce5dc", size = 11035893, upload-time = "2025-12-11T00:27:27.997Z" }, + { url = "https://files.pythonhosted.org/packages/3a/ea/46e48be259e6e003ee4c9d2d4151df5204924e3b1f81a61401145b2e0c9a/pyrefly-0.45.2-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:f49ec5535b3a4c6f342d6429439e078c1344ff4a5d2592fd05bc51d1d748e5d4", size = 11903460, upload-time = "2025-12-11T00:27:30.343Z" }, + { url = "https://files.pythonhosted.org/packages/c4/72/573457118d41cdd20d5ed09d4a2bc8bd692ab18a08bf3a450c239d041fe4/pyrefly-0.45.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:597a3e0f8eb3ffe798368906cf14edacafe73c336ce8ee83c80f2a259a2c8f2b", size = 11534889, upload-time = "2025-12-11T00:27:32.966Z" }, + { url = "https://files.pythonhosted.org/packages/b8/a5/a2eea3093b20d7a02fcf23419c99c31a7ebc95c25ba70746c1dc8eb93fbd/pyrefly-0.45.2-py3-none-win32.whl", hash = "sha256:a71a9efcba0cc8afacee248430c27a7d76ea9ff0f8c6d975329a5c6deabbb682", size = 10956305, upload-time = "2025-12-11T00:27:36.357Z" }, + { url = "https://files.pythonhosted.org/packages/a9/fb/30a6bbee4a89812644621ecfcbe830d4f6e8c519c6e722d09691fe59434c/pyrefly-0.45.2-py3-none-win_amd64.whl", hash = "sha256:d48b92c619a217bc4992b4899bf0eac3d049344a235e4d566088e6476b3d027e", size = 11632887, upload-time = "2025-12-11T00:27:38.513Z" }, + { url = "https://files.pythonhosted.org/packages/67/4f/ab7daab11f1abb0b5ebb8b343c834f87930f651e5b811cc55eaa51a03c0f/pyrefly-0.45.2-py3-none-win_arm64.whl", hash = "sha256:b1678936383471076c99c12fe15ebe1f9bc7ada5f499f40b01d9c934c1c8308f", size = 11184966, upload-time = "2025-12-11T00:27:40.836Z" }, ] [[package]] name = "pytest" -version = "9.0.1" +version = "9.0.2" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "colorama", marker = "sys_platform == 'win32'" }, @@ -141,9 +141,9 @@ dependencies = [ { name = "pluggy" }, { name = "pygments" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/07/56/f013048ac4bc4c1d9be45afd4ab209ea62822fb1598f40687e6bf45dcea4/pytest-9.0.1.tar.gz", hash = "sha256:3e9c069ea73583e255c3b21cf46b8d3c56f6e3a1a8f6da94ccb0fcf57b9d73c8", size = 1564125, upload-time = "2025-11-12T13:05:09.333Z" } +sdist = { url = "https://files.pythonhosted.org/packages/d1/db/7ef3487e0fb0049ddb5ce41d3a49c235bf9ad299b6a25d5780a89f19230f/pytest-9.0.2.tar.gz", hash = "sha256:75186651a92bd89611d1d9fc20f0b4345fd827c41ccd5c299a868a05d70edf11", size = 1568901, upload-time = "2025-12-06T21:30:51.014Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/0b/8b/6300fb80f858cda1c51ffa17075df5d846757081d11ab4aa35cef9e6258b/pytest-9.0.1-py3-none-any.whl", hash = "sha256:67be0030d194df2dfa7b556f2e56fb3c3315bd5c8822c6951162b92b32ce7dad", size = 373668, upload-time = "2025-11-12T13:05:07.379Z" }, + { url = "https://files.pythonhosted.org/packages/3b/ab/b3226f0bd7cdcf710fbede2b3548584366da3b19b5021e74f5bde2a8fa3f/pytest-9.0.2-py3-none-any.whl", hash = "sha256:711ffd45bf766d5264d487b917733b453d917afd2b0ad65223959f59089f875b", size = 374801, upload-time = "2025-12-06T21:30:49.154Z" }, ] [[package]] diff --git a/ty.schema.json b/ty.schema.json index 5630ec353c..13d1ac9c47 100644 --- a/ty.schema.json +++ b/ty.schema.json @@ -112,7 +112,7 @@ ] }, "root": { - "description": "The root paths of the project, used for finding first-party modules.\n\nAccepts a list of directory paths searched in priority order (first has highest priority).\n\nIf left unspecified, ty will try to detect common project layouts and initialize `root` accordingly:\n\n* if a `./src` directory exists, include `.` and `./src` in the first party search path (src layout or flat)\n* if a `.//` directory exists, include `.` and `./` in the first party search path\n* otherwise, default to `.` (flat layout)\n\nBesides, if a `./python` or `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file),\nit will also be included in the first party search path.", + "description": "The root paths of the project, used for finding first-party modules.\n\nAccepts a list of directory paths searched in priority order (first has highest priority).\n\nIf left unspecified, ty will try to detect common project layouts and initialize `root` accordingly:\n\n* if a `./src` directory exists, include `.` and `./src` in the first party search path (src layout or flat)\n* if a `.//` directory exists, include `.` and `./` in the first party search path\n* otherwise, default to `.` (flat layout)\n\nAdditionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` or `__init__.pyi` file),\nit will also be included in the first party search path.", "type": [ "array", "null" @@ -1171,7 +1171,7 @@ ] }, "root": { - "description": "The root of the project, used for finding first-party modules.\n\nIf left unspecified, ty will try to detect common project layouts and initialize `src.root` accordingly:\n\n* if a `./src` directory exists, include `.` and `./src` in the first party search path (src layout or flat)\n* if a `.//` directory exists, include `.` and `./` in the first party search path\n* otherwise, default to `.` (flat layout)\n\nBesides, if a `./tests` directory exists and is not a package (i.e. it does not contain an `__init__.py` file),\nit will also be included in the first party search path.", + "description": "The root of the project, used for finding first-party modules.\n\nIf left unspecified, ty will try to detect common project layouts and initialize `src.root` accordingly:\n\n* if a `./src` directory exists, include `.` and `./src` in the first party search path (src layout or flat)\n* if a `.//` directory exists, include `.` and `./` in the first party search path\n* otherwise, default to `.` (flat layout)\n\nAdditionally, if a `./python` directory exists and is not a package (i.e. it does not contain an `__init__.py` file),\nit will also be included in the first party search path.", "anyOf": [ { "$ref": "#/definitions/RelativePathBuf"