Repository navigation
Pull Pylance with Pyright 1.1.413 - #11697
Heejae Chang (heejaechang) merged 1 commit into
Conversation
|
🔒 Automated review in progress — Bill Schnurr (@bschnurr) is auto-reviewing this PR. |
|
Diff from mypy_primer, showing the effect of this PR on open source code: sympy (https://github.com/sympy/sympy)
- .../projects/sympy/sympy/solvers/ode/lie_group.py:619:61 - error: Operator "-" not supported for type "Unknown | Basic" (reportOperatorIssue)
+ .../projects/sympy/sympy/solvers/ode/riccati.py:275:12 - error: No overloads for "__init__" match the provided arguments (reportCallIssue)
+ .../projects/sympy/sympy/solvers/ode/riccati.py:275:17 - error: Argument of type "zip[Unknown]" cannot be assigned to parameter "iterable" of type "Iterable[list[bytes]]" in function "__init__"
+ "zip[Unknown]" is incompatible with protocol "Iterable[list[bytes]]"
+ "__iter__" is an incompatible type
+ Type "() -> zip[Unknown]" is not assignable to type "() -> Iterator[_T_co@Iterable]"
+ Function return type "zip[Unknown]" is incompatible with type "Iterator[_T_co@Iterable]"
+ "zip[Unknown]" is incompatible with protocol "Iterator[_T_co@Iterable]" (reportArgumentType)
+ .../projects/sympy/sympy/solvers/ode/single.py:867:9 - error: Expression with type "tuple[ComplexInfinity | NaN | Rational | Zero | Infinity | NegativeInfinity | Float | NotImplementedType | Expr | Unknown | Any, list[tuple[Unknown, Unknown]] | list[Unknown]] | tuple[ComplexInfinity | NaN | Rational | Zero | Infinity | NegativeInfinity | Float | NotImplementedType | Expr | Unknown | Any, list[tuple[Unknown, Unknown]] | list[Unknown], list[tuple[Unknown, Unknown]] | list[Unknown]]" cannot be assigned to target tuple
+ Type "tuple[ComplexInfinity | NaN | Rational | Zero | Infinity | NegativeInfinity | Float | NotImplementedType | Expr | Unknown | Any, list[tuple[Unknown, Unknown]] | list[Unknown], list[tuple[Unknown, Unknown]] | list[Unknown]]" is incompatible with target tuple
+ Tuple size mismatch; expected 2 but received 3 (reportAssignmentType)
- .../projects/sympy/sympy/solvers/recurr.py:424:16 - error: Cannot access attribute "is_polynomial" for class "tuple[Unknown, list[Expr | Unknown]]"
+ .../projects/sympy/sympy/solvers/recurr.py:424:16 - error: Cannot access attribute "is_polynomial" for class "tuple[Unknown, list[Unknown]]"
- .../projects/sympy/sympy/solvers/recurr.py:424:16 - error: Cannot access attribute "is_polynomial" for class "tuple[Unknown | tuple[Unknown, list[Poly]], list[Poly] | Unknown | Unbound]"
+ .../projects/sympy/sympy/solvers/recurr.py:424:16 - error: Cannot access attribute "is_polynomial" for class "tuple[Unknown, Unknown | Unbound]"
- .../projects/sympy/sympy/solvers/recurr.py:424:16 - error: Cannot access attribute "is_polynomial" for class "tuple[Unknown, list[Poly]]"
- Attribute "is_polynomial" is unknown (reportAttributeAccessIssue)
- .../projects/sympy/sympy/solvers/recurr.py:425:20 - error: Cannot access attribute "as_numer_denom" for class "tuple[Unknown, list[Expr | Unknown]]"
+ .../projects/sympy/sympy/solvers/recurr.py:425:20 - error: Cannot access attribute "as_numer_denom" for class "tuple[Unknown, list[Unknown]]"
- .../projects/sympy/sympy/solvers/recurr.py:425:20 - error: Cannot access attribute "as_numer_denom" for class "tuple[Unknown | tuple[Unknown, list[Poly]], list[Poly] | Unknown | Unbound]"
- Attribute "as_numer_denom" is unknown (reportAttributeAccessIssue)
- .../projects/sympy/sympy/solvers/recurr.py:425:20 - error: Cannot access attribute "as_numer_denom" for class "tuple[Unknown, list[Poly]]"
+ .../projects/sympy/sympy/solvers/recurr.py:425:20 - error: Cannot access attribute "as_numer_denom" for class "tuple[Unknown, Unknown | Unbound]"
- .../projects/sympy/sympy/solvers/recurr.py:440:26 - error: Cannot access attribute "subs" for class "Alg"
- Attribute "subs" is unknown (reportAttributeAccessIssue)
- .../projects/sympy/sympy/solvers/recurr.py:442:26 - error: Cannot access attribute "subs" for class "Alg"
- Attribute "subs" is unknown (reportAttributeAccessIssue)
- .../projects/sympy/sympy/solvers/recurr.py:449:13 - error: No overloads for "__setitem__" match the provided arguments (reportCallIssue)
- .../projects/sympy/sympy/solvers/recurr.py:449:13 - error: Argument of type "Expr | Unknown | Poly" cannot be assigned to parameter "value" of type "Zero" in function "__setitem__"
- Type "Expr | Unknown | Poly" is not assignable to type "Zero"
- "Expr" is not assignable to "Zero" (reportArgumentType)
+ .../projects/sympy/sympy/solvers/solveset.py:4138:23 - error: No overloads for "__init__" match the provided arguments (reportCallIssue)
+ .../projects/sympy/sympy/solvers/solveset.py:4138:28 - error: Argument of type "zip[Unknown]" cannot be assigned to parameter "iterable" of type "Iterable[list[bytes]]" in function "__init__"
+ "zip[Unknown]" is incompatible with protocol "Iterable[list[bytes]]"
+ "__iter__" is an incompatible type
+ Type "() -> zip[Unknown]" is not assignable to type "() -> Iterator[_T_co@Iterable]"
+ Function return type "zip[Unknown]" is incompatible with type "Iterator[_T_co@Iterable]"
+ "zip[Unknown]" is incompatible with protocol "Iterator[_T_co@Iterable]" (reportArgumentType)
- .../projects/sympy/sympy/stats/drv.py:269:22 - error: Argument of type "Generator[Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | int | None, None, None]" cannot be assigned to parameter "iterable" of type "Iterable[_SupportsSumNoDefaultT@sum]" in function "sum"
+ .../projects/sympy/sympy/stats/drv.py:269:22 - error: Argument of type "Generator[Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | int | None, None, None]" cannot be assigned to parameter "iterable" of type "Iterable[_SupportsSumNoDefaultT@sum]" in function "sum"
- "Generator[Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | int | None, None, None]" is not assignable to "Iterable[_SupportsSumNoDefaultT@sum]"
+ "Generator[Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | int | None, None, None]" is not assignable to "Iterable[_SupportsSumNoDefaultT@sum]"
- Type parameter "_T_co@Iterable" is covariant, but "Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | int | None" is not a subtype of "_SupportsSumNoDefaultT@sum"
+ Type parameter "_T_co@Iterable" is covariant, but "Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | int | None" is not a subtype of "_SupportsSumNoDefaultT@sum"
- Type "Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | int | None" is not assignable to type "_SupportsSumWithNoDefaultGiven"
+ Type "Self@Basic | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | int | None" is not assignable to type "_SupportsSumWithNoDefaultGiven"
- Type "Basic* | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | int | None" is not assignable to type "_SupportsSumWithNoDefaultGiven"
+ Type "Basic* | tuple[Unknown, ...] | Unknown | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | int | None" is not assignable to type "_SupportsSumWithNoDefaultGiven"
- .../projects/sympy/sympy/stats/drv_types.py:293:16 - error: Operator "*" not supported for types "Expr" and "tuple[Unknown, ...] | Unknown | Self@Basic | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic"
+ .../projects/sympy/sympy/stats/drv_types.py:293:16 - error: Operator "*" not supported for types "Expr" and "tuple[Unknown, ...] | Unknown | Self@Basic | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic"
- .../projects/sympy/sympy/stats/rv.py:473:25 - error: Argument of type "Expr | Lambda | Zero | One | Integral | Unknown | Probability | Self@Basic | tuple[Unknown, ...] | Sum | ZeroMatrix | Add | NaN | Piecewise | Basic | int | NegativeOne | Integer | ComplexInfinity | Rational | Infinity | NegativeInfinity | Float | Number" cannot be assigned to parameter "args" of type "Expr | complex" in function "__new__"
+ .../projects/sympy/sympy/stats/rv.py:473:25 - error: Argument of type "Expr | Lambda | Zero | One | Integral | Unknown | Probability | Self@Basic | tuple[Unknown, ...] | Sum | ZeroMatrix | NaN | Piecewise | Basic | int | NegativeOne | Integer | ComplexInfinity | Rational | Infinity | NegativeInfinity | Float | Number" cannot be assigned to parameter "args" of type "Expr | complex" in function "__new__"
- Type "Expr | Lambda | Zero | One | Integral | Unknown | Probability | Self@Basic | tuple[Unknown, ...] | Sum | ZeroMatrix | Add | NaN | Piecewise | Basic | int | NegativeOne | Integer | ComplexInfinity | Rational | Infinity | NegativeInfinity | Float | Number" is not assignable to type "Expr | complex"
+ Type "Expr | Lambda | Zero | One | Integral | Unknown | Probability | Self@Basic | tuple[Unknown, ...] | Sum | ZeroMatrix | NaN | Piecewise | Basic | int | NegativeOne | Integer | ComplexInfinity | Rational | Infinity | NegativeInfinity | Float | Number" is not assignable to type "Expr | complex"
- .../projects/sympy/sympy/stats/stochastic_process_types.py:1839:25 - error: Argument of type "tuple[Unknown, ...] | Unknown | Self@Basic | Sum | Expr | ZeroMatrix | Add | Zero | NaN | Piecewise | Basic | Integral | Any | int" cannot be assigned to parameter "args" of type "Expr | complex" in function "__new__"
+ .../projects/sympy/sympy/stats/stochastic_process_types.py:1839:25 - error: Argument of type "tuple[Unknown, ...] | Unknown | Self@Basic | Sum | Expr | ZeroMatrix | Zero | NaN | Piecewise | Basic | Integral | Any | int" cannot be assigned to parameter "args" of type "Expr | complex" in function "__new__"
... (truncated 136 lines) ...
|
|
Result: 🔴 Verification detailsVerification: Isolated verification observed failures that were not classified as caused by this PR: Repository and dependency discovery, Locked offline dependency bootstrap. The relevant tests could not be fully run in the isolated environment; this review is not fully verified. Summary: No meaningful tests could execute because the verification image lacks `pnpm`, so the required locked offline bootstrap failed. The PR adds four symlink-watcher tests and one stub-generator test; hover expectations are also updated in existing fourslash coverage. Runtime confidence is therefore low. Test runs: 2 failed, 4 not run
|
|
/benchmark |
|
Compared candidate Type checker benchmark🟢 No performance regressions detected. Regression threshold:
Pyright stats
|
Synchronizes Pylance compatibility changes with the current Pyright codebase.
Rollup:
REVIEWER: Review only Pyright/Pylance synchronization and compatibility changes in this PR; do not leave unrelated feedback.