The logic for disabling the unused warning on unresolved imports was dependent on the visit order. Moving sustracting unresolved imports to the end of computation fixes the problem.
GitOrigin-RevId: adeb85e59c17261a5bf9f64dfb4a7836a2403f43
Previously, we relied on TypeEvalContext.getType() to interpret typing.Generic
parameters as type hints. Now we use PyTypingTypeProvider.getType() for that.
As a side effect, we no longer allow confusing aliasing of type parameters
similarly to other type checkers.
GitOrigin-RevId: 6994d417e16f179e0ebb51c43bf61e6be32f479c
Namely, the syntax `[type1, type2, ..., typeN]` used for Callable and
generic classes parameterized with ParamSpec.
GitOrigin-RevId: 928afadd862a5af587ef94776e3f166d028770d9
Also fixes 'Unable to load ML model' exception on Windows
Merge-request: IJ-MR-153007
Merged-by: Gleb Marin <Gleb.Marin@jetbrains.com>
GitOrigin-RevId: 2d5421dbee4ed86c81b9eba1f6d65dfdf4557698
* Iterate over the type arguments to check their validity and infer the type at the same time, add a test for it
* Do not expose `PyTypingTypeProvider.getIndexTypes`
GitOrigin-RevId: f22e34aa65425c147b43052ec592c6351c0c6ff0
In such cases, no additional wrapping in square brackets is needed
```
class Clazz(Generic[P]): ...
# Both are valid and equal
c1 = Clazz[int, str, bool]()
c2 = Clazz[[int, str, bool]]()
```
GitOrigin-RevId: 1134f4e9f47f5d29f447ee73febb44c4a07a7ae1
Instead of reporting not enough / too many type arguments passed to a class, simply report the fact of type arguments mismatch.
It will help to avoid false positives and will extend the checks to both incorrect number and incorrect types of passed type arguments
Update the tests
GitOrigin-RevId: 6f0ae3fc1c46f74162da7cc3fccc370f4646ffdc
Do not analyze the references inside the default expression, wrong ones will be reported later
GitOrigin-RevId: 99065e43fd75bd9d6592e017a1c141feefbc9dd4
Small refactoring in `PyNewStyleGenericSyntaxInspection`, updated test in `PyNewStyleGenericSyntaxInspectionTest`
GitOrigin-RevId: 7cd842f5b3cac4f6a57c334c54eb1685255a7253
Temporary. It will be changed along with the support for the checks for TypeAlias-es
Better naming
GitOrigin-RevId: 1a56e31e4fba26072fdc1cd104203cf888c89df9
Briefly:
* Get the clarified type parameter type from `PyTypingTypeProvider` for further checks to be able to check the defaults of ParamSpec and TypeVarTuple as well.
* Use a set of declaration elements as the set of processed generics
* Better naming
Add missing tests
GitOrigin-RevId: 0a78b350a997508d325228335490712214e03773
Fix build issues
Fix build issues
Remove redundant extension point
Fix build issues
Fix rebase issues
import rank
# Conflicts:
# .idea/libraries/jetbrains_ml_models_python_imports_ranking_model.xml
# .idea/libraries/jetbrains_mlapi_ml_feature_api.xml
# build/expected/ultimate-content-platform.yaml
# community/.idea/libraries/jetbrains_mlapi_ml_building_blocks.xml
# community/.idea/libraries/jetbrains_mlapi_ml_feature_api.xml
# community/platform/ml-api/intellij.platform.ml.iml
# community/platform/ml-impl/intellij.platform.ml.impl.iml
# community/platform/ml-impl/src/com/intellij/platform/ml/impl/logs/fus/IntelliJFusEventRegister.kt
# community/platform/ml-impl/src/com/intellij/platform/ml/impl/logs/fus/eventFields.kt
# community/platform/ml-impl/src/com/intellij/platform/ml/impl/tools/logs/IntelliJFusEventRegister.kt
# community/platform/ml-impl/src/com/intellij/platform/ml/impl/tools/logs/eventFields.kt
# community/platform/ml-tools/src/com/intellij/platform/ml/tools/logs/fus/IntelliJFusEventRegister.kt
# community/platform/ml-tools/src/com/intellij/platform/ml/tools/logs/fus/eventFields.kt
# community/platform/platform-impl/codeinsight-inline/src/com/intellij/codeInsight/inline/completion/ml/TypingSpeedFeatureProvider.kt
# community/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/README.md
# community/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/mlModel.kt
# community/python/pluginCore/plugin-content.yaml
# community/python/src/com/jetbrains/python/codeInsight/imports/mlapi/mlAnalysis.kt
# community/python/src/com/jetbrains/python/codeInsight/imports/mlapi/mlImplementation.kt
# community/python/src/com/jetbrains/python/codeInsight/imports/mlapi/mlLogs.kt
# community/python/src/com/jetbrains/python/codeInsight/imports/mlapi/mlTask.kt
Fix some tests
Refactor RelevanceEvaluationFeatures.kt to fix null handling
Improved the handling of `null` cases for `MODULE_SOURCE_TYPE` in `RelevanceEvaluationFeatures.kt`. This ensures more robust feature addition by checking conditions and setting the value accordingly when it's `null`. Minor formatting adjustments were also made.
Update ML model version in project configuration
Changed the Maven artifact ID from "lilac-coua" to "daffy-pony" for the python imports ranking ML model.
Fix some tests
Fix some tests
Fix some tests
Fix some tests
Fix some tests
Update Maven dependencies for JetBrains ML libraries
Update ML model version & fix missing read action
Update ML API version & update Imports Ranking implementation
Update mlapi version
Co-authored-by: Andrey Vokin <andrey.vokin@jetbrains.com>
Co-authored-by: Nikita Ermolenko <ermolenko.dev@gmail.com>
Merge-request: IJ-MR-147271
Merged-by: Gleb Marin <Gleb.Marin@jetbrains.com>
GitOrigin-RevId: 7aa520df915bb8a62263524868a17a984b619728