File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
jib-gradle-plugin/src/main/java/com/google/cloud/tools/jib/gradle/skaffold Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -253,14 +253,17 @@ private Set<ProjectDependency> findProjectDependencies(Project project) {
253253 * @return the resolved project
254254 * @throws RuntimeException if the dependent project could not be resolved
255255 */
256- private Project getDependentProject (ProjectDependency projectDependency ) {
256+ private Project getDependentProject (ProjectDependency projectDependency ) {
257257 // Try getDependencyProject() first (Gradle 6-8)
258258 try {
259259 java .lang .reflect .Method getDependencyProjectMethod =
260260 projectDependency .getClass ().getMethod ("getDependencyProject" );
261261 return (Project ) getDependencyProjectMethod .invoke (projectDependency );
262- } catch (ReflectiveOperationException e ) {
262+ } catch (NoSuchMethodException e ) {
263263 // Fall through to getPath() approach (Gradle 9+)
264+ } catch (ReflectiveOperationException e ) {
265+ throw new RuntimeException (
266+ "Failed to resolve dependent project from " + projectDependency , e );
264267 }
265268
266269 // Try getPath() approach (Gradle 9+)
You can’t perform that action at this time.
0 commit comments