You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by hi...@apache.org on 2010/09/01 11:06:18 UTC
svn commit: r991483 -
/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java
Author: hibou
Date: Wed Sep 1 09:06:18 2010
New Revision: 991483
URL: http://svn.apache.org/viewvc?rev=991483&view=rev
Log:
Handle an unexpected exception
Modified:
ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java
Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java?rev=991483&r1=991482&r2=991483&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/src/java/org/apache/ivyde/eclipse/cpcontainer/IvyResolveJob.java Wed Sep 1 09:06:18 2010
@@ -124,7 +124,13 @@ public class IvyResolveJob extends Job {
// The version matcher used will be the one configured for the first project
ResolveRequest request = (ResolveRequest) inworkspaceModules.values().iterator().next();
- Ivy ivy = request.getContainer().getState().getCachedIvy();
+ Ivy ivy;
+ try {
+ // here we expect to find the ivy and the md we have just computed
+ ivy = request.getContainer().getState().getCachedIvy();
+ } catch (IvyDEException e) {
+ return new Status(IStatus.ERROR, IvyPlugin.ID, "Unexpected error");
+ }
VersionMatcher versionMatcher = ivy.getSettings().getVersionMatcher();
WarningNonMatchingVersionReporter nonMatchingVersionReporter = new WarningNonMatchingVersionReporter();