default void validateRunTarget(@SuppressWarnings("unused") @NotNull Project project) throws RuntimeConfigurationException {
    String targetName = TargetEnvironmentConfigurations.getEffectiveTargetName(this, project);
    if (targetName == null) {
      return;
    }

    TargetEnvironmentConfiguration target = ContainerUtil.find(
      TargetEnvironmentsManager.getInstance(project).getTargets().resolvedConfigs(),
      next -> targetName.equals(next.getDisplayName()));

    if (target == null) {
      throw new RuntimeConfigurationError(
        ExecutionBundle.message("TargetEnvironmentAwareRunProfile.error.cannot.find.run.target", targetName));
    }
    try {
      target.validateConfiguration();
    }
    catch (RuntimeConfigurationException e) {
      throw new RuntimeConfigurationError(
        ExecutionBundle.message("TargetEnvironmentAwareRunProfile.error.run.target.error.0", e.getMessage()));
    }
  }
default void validateRunTarget(@SuppressWarnings("unused") @NotNull Project project)