mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 04:51:24 +07:00
These methods rely on the existence of `gradlePath` and `gradleIdentityPath` properties in `ModuleData`. However, these properties are not always initialized in `ModuleData`. That may cause errors like the one described in IDEA-321581. Unfortunately, we could not reproduce it. However, we found a suspicious place where a `ModuleData` could be created without initialized properties - `com.intellij.openapi.externalSystem.service.project.manage.ExternalProjectsDataStorage#convert`. But it's not clear if it causes the error. To avoid the errors, this commit replaces the usages of these methods with new nullable counterparts in `GradleModuleData`: `gradlePathOrNull` and `gradleIdentityPathOrNull`. Also, it adds a log in the case when the accessed property is null. Tests: - org.jetbrains.plugins.gradle.execution.build.GradleProjectTaskRunnerTest (does not cover the case of error in IDEA-321581) GitOrigin-RevId: 59d78dda860ebf0b8ab4e584b0f6a9634f64e7bb