External system: EA-48201 - assert: ComponentManagerImpl.getPicoContainer

This commit is contained in:
Vladislav.Soroka
2013-10-31 10:08:59 +04:00
parent 7668b0feed
commit 1bb68c4a37
5 changed files with 7 additions and 2 deletions
@@ -62,7 +62,7 @@ public class ExternalSystemTaskId implements Serializable {
@NotNull
public static String getProjectId(@NotNull Project project) {
return project.getName() + ":" + project.getLocationHash();
return project.isDisposed() ? project.getName() : project.getName() + ":" + project.getLocationHash();
}
@Nullable
@@ -138,6 +138,8 @@ public class ExternalSystemRunConfiguration extends LocatableConfigurationBase {
@Nullable
@Override
public ExecutionResult execute(Executor executor, @NotNull ProgramRunner runner) throws ExecutionException {
if(myProject.isDisposed()) return null;
ExternalSystemUtil.updateRecentTasks(new ExternalTaskExecutionInfo(mySettings.clone(), executor.getId()), myProject);
ConsoleView console = new TextConsoleBuilderImpl(myProject).getConsole();
final List<ExternalTaskPojo> tasks = ContainerUtilRt.newArrayList();
@@ -295,7 +295,7 @@ public class ExternalSystemAutoImporter implements BulkFileListener, DocumentLis
}
private void refreshFilesIfNecessary() {
if (myFilesToRefresh.isEmpty()) {
if (myFilesToRefresh.isEmpty() || myProject.isDisposed()) {
return;
}
@@ -156,6 +156,7 @@ public abstract class AbstractExternalProjectImportBuilder<C extends AbstractImp
new Task.Backgroundable(project, progressText, false) {
@Override
public void run(@NotNull final ProgressIndicator indicator) {
if(project.isDisposed()) return;
ExternalSystemResolveProjectTask task
= new ExternalSystemResolveProjectTask(myExternalSystemId, project, projectSettings.getExternalProjectPath(), false);
task.execute(indicator, ExternalSystemTaskNotificationListener.EP_NAME.getExtensions());
@@ -437,6 +437,8 @@ public class ExternalSystemUtil {
@SuppressWarnings({"ThrowableResultOfMethodCallIgnored", "IOResourceOpenedButNotSafelyClosed"})
@Override
public void execute(@NotNull ProgressIndicator indicator) {
if(project.isDisposed()) return;
ExternalSystemResolveProjectTask task
= new ExternalSystemResolveProjectTask(externalSystemId, project, externalProjectPath, isPreviewMode);