Commit Graph

96 Commits

Author SHA1 Message Date
Andrey Vlasovskikh
b4031d33bd IDEA-282297 [NPW] Disabled old New Project Wizard node for Python
You can now create a Python project either via the New Project node or via framework-specific nodes: Django, Flask, FastAPI.

GitOrigin-RevId: 690c9f6571c91e8a60c12efe932dc9b7efafe0cd
2022-02-21 23:16:56 +00:00
Semyon Proshev
8071ab7dc7 No need to wait for write-action, it is enough to schedule (IDEA-289174)
GitOrigin-RevId: 3b66b14aa08433fe3cc7c89db9dc12ef90dfc7a7
2022-02-21 11:33:01 +00:00
Alexey Kudravtsev
965f6c769c cleanup: method is identical to its super method
GitOrigin-RevId: 350ea63057fc436a3bcebed964228c43db8d5923
2022-01-27 13:29:12 +00:00
Dmitry Jemerov
e7511f7713 Delete JRuby and Python framework detectors
They're confusing, and their reason for existence is much better served with "No Python/Ruby interpreter configured" editor notifications

GitOrigin-RevId: 4c6705d5aa61476dfaedcf0fe79f56caa2833823
2022-01-07 10:13:20 +00:00
Dmitry.Krasilschikov
4841ada34b NPW IDEA-285493 fixed order for languages
GitOrigin-RevId: 06ddf0e815e4b9a1dfaf9d3fd81fc1db5419e46b
2022-01-03 17:02:39 +00:00
Dmitry.Krasilschikov
7263e04455 New Project Wizard: IDEA-285493 let's fixate languages order
GitOrigin-RevId: 694ed2074c21a422c9fd0f3da0b4577c321dc460
2021-12-22 17:09:21 +00:00
Lada Gagina
18d0c28655 PY-50160 Implement the redesigned dialog for package installation failures
IJ-CR-13328

GitOrigin-RevId: 2cfa6c468411391772639441f0d2aeda4fddc435
2021-10-19 15:30:24 +00:00
Irina.Fediaeva
6c243ee77f PY-50769: Make python completion contributors DumbAware
Completion contributors already wrapped in `DumbModeAccessType.RELIABLE_DATA_ONLY.ignoreDumbMode` in `CompletionProgressIndicator#calculateItems` so we don't need any extra-wrappings to prevent IndexNotReadyException

(cherry picked from commit 83c120ed2502474f3ddcfa2a52c6e9552d02e55e)

IJ-CR-14512

GitOrigin-RevId: e806ecb879708a75a8e7f544ea6d16a0648ca069
2021-10-14 08:38:49 +00:00
Andrey Vlasovskikh
ca954ebf09 PY-50536 [NPW] Added New Python project wizard for IntelliJ
GitOrigin-RevId: ef728d8ec331182f18ee19948d96dd7e3c89291f
2021-10-12 16:06:33 +00:00
Tagir Valeev
81d730447a Add type parameters for raw type casts where it's safe
GitOrigin-RevId: 49c3dd961c5c7122d6644b7e4959d0e86ad271da
2021-10-01 07:59:54 +00:00
Semyon Proshev
f78223592b Attempt to improve logging (PY-49082)
Especially for projects with only a few python modules.

GitOrigin-RevId: 676b25dce385e4fbc848880edb0c7473d110dc39
2021-06-11 10:11:07 +00:00
Semyon Proshev
2334617c1b Don't configure python interpreter for modules without py files (PY-49082, PY-49122)
GitOrigin-RevId: 2c5d38216461134f5bf06cfeb47acea0c55c38bb
2021-06-04 12:44:24 +00:00
Semyon Proshev
bf9324167f Fix configuring inner venv for idea + python plugin (PY-49082)
Python project base directory stored in context was ignored during looking for virtual envs because module was not passed.
Such inner venv did not have a precedence in sorting by the same reason.

GitOrigin-RevId: 99bf42d3c9c254878e944cbfc186bdd26b8e580b
2021-06-03 10:28:46 +00:00
Semyon Proshev
94ae100455 Don't resolve to a directory considered as a java package if it is not located under jvm module (PY-49082)
Otherwise, some typeshed directory could be considered as a package and name would be resolved to it even if the corresponding python package is not installed (PyTypeShed.maySearchForStubInRoot is ignored in this case).

GitOrigin-RevId: c453b28655b710f092c9ece3d868a0ee5141c0dd
2021-06-02 18:05:24 +00:00
Semyon Proshev
52b113935a Update configuring python interpreter for idea + plugin (QD-570)
Main change: setup detected sdk.

 Iterate through modules and configure python for all of them instead of doing so file by file.

GitOrigin-RevId: 6a19eeaa42aa78e1b959a413e2533ad33fca810b
2021-06-02 09:51:49 +00:00
Dmitry Jemerov
749ce8a332 Cleanup: remove @author tags
GitOrigin-RevId: 9174eb8d77215b16f9f6c6074e6aced654d95ef1
2021-05-03 13:07:48 +00:00
Nikolay Chashnikov
804cff19da [project structure] avoid unnecessary creation of ModifiableRootModel in ModuleConfigurationState
This commit introduces ModuleConfigurationState::getCurrentRootModel method which can be used if we need to just read the current state of the model and don't need to modify it, and explicit 'getModifiableRootModel' method. The old 'getRootModel' method is deprecated and all its usages are replaced by usages of one of the new methods. This way we avoid creating unnecessary instances of ModifiableRootModel to improve performance and avoid exceptions (EA-251419) which may happen if ModifiableRootModel is created during commit (when ClasspathPanelImpl creates modifiable model to update the table during processing 'rootsChanged').

GitOrigin-RevId: 4cbd410ed6039a5ee652d2585bdeee429baf7df7
2021-01-30 01:37:35 +00:00
Anna Kozlova
cfa826f9b6 java 11 migration: explicit -> diamond for anonymous classes
GitOrigin-RevId: ce15f37f8882fb7915cf5c8b62e3cc4601a5cc76
2021-01-17 11:16:51 +00:00
Semyon Proshev
9109ab3521 Use editable copy of sdk instead of sdk modificator (PY-39477)
SdkModificator is not well supported in PythonSdkUpdater and editable copy could play its role instead.
The consequence is that changes are applied only after OK is clicked in `Show All` dialog.
Previously it could be came over by creating sdk modificator for original sdk.

GitOrigin-RevId: 5415eb3bb6c971342b1c1ff576c44bc4571d0bde
2020-11-05 18:58:08 +00:00
Mikhail Golubev
7b6cc1fe1f PY-43773 More robust synchronization of Python SDK background updates
Previous synchronization of background updates in PythonSdkUpdater was flawed.
It didn't prevent us from launching several concurrent updates for the same
SDK, but only blocked subsequent refresh tasks on a BlockingSet, still showing
the corresponding progress indicators, piling up threads and exhausting system
resources.

The new implementation attempts to enforce the following policy: no two updates
for the same SDK can be run concurrently, and all subsequent updates for an SDK
already being refreshed are squashed and queued to be executed once it finished.

We also adjusted PythonSdkUpdater interface to better indicate synchronization
of individual methods. The old update() method, which performed a few of update
operations in a blocking fashion, is now deprecated and replaced with more
explicit scheduleUpdate(), always asynchronous, and internal
updateVersionAndPathsSynchronouslyAndScheduleRemaining() that replicates the old
behavior for the time being due to a number of existing usages, but is to be
revised. Synchronous version and paths refreshes are now performed under a modal
progress indicator.

The legacy updating mechanism can be restored as a fallback if
"python.use.new.sdk.updater" Registry flag is reset.

Additionally, internal PyUpdateProjectSdk action was added for diagnostic.

These changes are a result of a joint effort with Alexey Kniazev.

GitOrigin-RevId: 6260cda7a22c4f5932f7d78eb6660a50e2b972b6
2020-09-25 20:03:59 +00:00
Vladimir Krivosheev
a67c59c561 platform.core.impl — remove dependency on intellij.platform.util.ui and intellij.platform.core.ui
java.psi.iml — remove dependency on intellij.platform.core.ui

GitOrigin-RevId: c1d4feb04c0471c7d17b5331b86738ee54a97f80
2020-09-21 13:40:47 +00:00
Alexey Kudravtsev
5d41e42767 cleanup: notnull and fix Processor type parameter types
GitOrigin-RevId: 694f1cf4f8b2602e5a0e199c92490e68ec303c1b
2020-09-14 13:46:01 +00:00
Lada Gagina
2f53b0d8f2 i18n: Interpreter settings
GitOrigin-RevId: 6eed8f2f1e4725ec617e7df0c861744cdf8e2be9
2020-08-20 17:44:55 +00:00
Nikita Eshkeev
52f0baa14d [i18n] idea-ui
This patch replaces hard coded strings with i18n properties in idea-ui

Signed-off-by: Nikita Eshkeev <nikita.eshkeev@jetbrains.com>

GitOrigin-RevId: f481ab904b8648a9f0d68d4de91e1f31c01be49f
2020-08-07 00:16:50 +00:00
Vladimir Krivosheev
d4e9b09e26 cleanup (final)
GitOrigin-RevId: 93607e195763f2acf29ee0d7a280d7e07e8d2f14
2020-06-26 12:21:17 +03:00
Eugene Petrenko
7fcd50760f CommandLineInspectionProjectConfigurator - add getName and getDescription
Preparation step to allow providing configurator hints for a project

GitOrigin-RevId: 5e6422cd64abad9d81fef8249195eea12dbb8422
2020-05-27 00:15:28 +03:00
Eugene Petrenko
86618d10a8 extend CommandLineInspectionProjectConfigurator API to pass more options into extensions
GitOrigin-RevId: 04db41ad3e5bdce2c2504b6bb5fdc129ead1297a
2020-05-13 11:19:09 +00:00
alexey.afanasiev
1f7b08bfc6 Move inspect starter from edt thread. Cleanup.
GitOrigin-RevId: ca5a8127664004b5bfa934d4aea5a74e3019883e
2020-05-08 06:55:57 +00:00
alexey.afanasiev
55d8285218 Move inspect starter from edt thread. Add jdk auto configure.
GitOrigin-RevId: ffd639e452b473fcc2478f73a767ad8c76665550
2020-05-08 06:55:57 +00:00
alexey.afanasiev
d4e0e3dae6 move to write thread two write actions in InspectionConfigurators
GitOrigin-RevId: dfbe6f04a745c1c3679b7ca86016292f1c1ccf8b
2020-05-08 06:55:57 +00:00
alexey.afanasiev
8bd7dcca66 move call JdkAuto to InspectionConfiguration step
GitOrigin-RevId: 814955cf64bf2bba14c7f3fcf5c6aa534a0a7af3
2020-05-08 06:55:57 +00:00
Evgeniy.Stepanov
4b81851c82 Remove dependency intellij.platform.lang.impl -> intellij.platform.inspect, IDEA-CR-1366
GitOrigin-RevId: da769ac77292c954371076a5e80f7d5f8b1114a8
2020-04-28 19:16:33 +00:00
Vladimir Krivosheev
0532f2be19 cleanup, getByKey - add value mapper
GitOrigin-RevId: 4a6356dc2cb9f1a1834d64a524f824dab7af10a0
2020-04-21 09:24:18 +00:00
Lada Gagina
8a29a375f3 PY-40431 Extract messages to the message bundles for i18n
GitOrigin-RevId: c7b652bab17e0b37959d71fe7335212395212bdb
2020-02-18 20:57:58 +00:00
Semyon Proshev
8f58988590 i18n
GitOrigin-RevId: c6b70355ca538e522a1b896f412c972fe7aa56e9
2020-02-13 16:19:54 +00:00
Alexander Koshevoy
5ac4b8ae3d PY-40431 Extract messages from forms in intellij.pycharm.community.* modules to the message bundle
GitOrigin-RevId: 600e2a879ea56690617ba59cd317cad2b2b42b03
2020-02-10 14:20:15 +00:00
Vladimir Krivosheev
ba98224912 remove author (only some, where it is ok)
GitOrigin-RevId: 7dbab7524fe4efc5d17a04b95dee88b6f80fbe8d
2020-01-21 17:36:52 +00:00
Tagir Valeev
78a91459c4 Array annotations changed to type-use style (not compilable now)
GitOrigin-RevId: 68aa4ba200618083684599228e13dfdba35967a4
2020-01-16 08:11:51 +00:00
Dmitry.Krasilschikov
151f01503b more localized configurable display names
GitOrigin-RevId: 6cd673382a243910bd993a7802baf78e6a92f7ef
2020-01-10 10:07:45 +00:00
Andrey Vlasovskikh
543ca840b7 Extracted "impl" modules from Python Community and PyCharm Community Customization to use them in other Python plugins for builds and runs
The non-impl modules for these plugins now contain more or less just their plugin.xml files
that declare corresponding dependencies.

GitOrigin-RevId: 84fc4761a595912d676cff1e2ab58fba03a8cd22
2019-11-18 19:07:46 +00:00
Alexey Kudravtsev
850cf546dc replace Logger.getInstance(#fqn) with Logger.getInstance(klass.class) to reduce constant pool and code size and make code more refactorable
GitOrigin-RevId: 4ef94813858973e44449a20cf8b09174c8df5fce
2019-11-07 17:02:46 +00:00
Andrey Vlasovskikh
48bec77033 PY-38634 Revert registration of PyCharm-specific (vs Python plugin) components
During the recent refactoring a Python plugin only file python-community-plugin-core.xml got included
into the Python plugin which is now bundled with PyCharm. It resulted in using Python plugin specific
components that were designed for the UI of IntelliJ, not PyCharm. This change restores the
registration of PyIdeCommonOptionsFormFactory and moves all includes of python-community-plugin-core.xml
to Python plugin specific files.

GitOrigin-RevId: cd8b6d9b68266ca99f206c005ba73a2e77657950
2019-10-21 20:03:52 +00:00
Gregory.Shrago
ca26ab8089 IDEA-CR-53226 extract pluginJava and avoid Java in PyCharm
GitOrigin-RevId: da2f300874c363085d5965bee1d0520da8ce3fd6
2019-10-14 22:41:29 +00:00
Dmitry Jemerov
cbda6e7ccf Better names for CLI inspection logger API (IDEA-CR-52729)
GitOrigin-RevId: 0d98a57f3d9db6469c88015fab98722325029e40
2019-09-24 10:32:13 +00:00
Dmitry Trofimov
525e9f1aec Use local virtual env for inspections if available
GitOrigin-RevId: 10bb1c24430b854e79be07f1d0ff0e7f3e9f14f2
2019-09-24 09:02:48 +00:00
Dmitry Jemerov
ef81a93f72 CLI project configuration: add logging, don't walk the project if environment is already configured
GitOrigin-RevId: b73fec673a3524185d152fe4455736c9d7578540
2019-09-23 13:02:12 +00:00
Dmitry Trofimov
87a915e8a6 Add facet only to modules that contain Python files from change list
GitOrigin-RevId: 8dfe7051b43d04850e19e4cf12d849938ba63392
2019-09-23 13:02:12 +00:00
Dmitry Trofimov
bf6cbda222 Setup Python SDK and facet to run inspections on Python projects
GitOrigin-RevId: f1b3be8207ae5ed8674ff81ca02fcb26d7b4afe4
2019-09-23 13:02:12 +00:00
Dmitry Trofimov
a0bc048dcc python-psi-impl extracted
GitOrigin-RevId: e3d808c147ac793701c7b628dbf825a99bb71f2a
2019-09-11 19:15:01 +00:00
Semyon Proshev
16a77f4042 Provide completion and resolve for from tensorflow.<...> statements (PY-33034)
GitOrigin-RevId: 5886d44f185f918cf0089249209495de3145b6d1
2019-08-02 15:03:24 +03:00