Skip to content

Enhance stack trace information for rule conflicts in BuildManager#2279

Merged
vogella merged 1 commit intoeclipse-platform:masterfrom
vogella:claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo
May 1, 2026
Merged

Enhance stack trace information for rule conflicts in BuildManager#2279
vogella merged 1 commit intoeclipse-platform:masterfrom
vogella:claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo

Conversation

@vogella
Copy link
Copy Markdown
Contributor

@vogella vogella commented Nov 14, 2025

Fixes #2278

When a builder attempts to begin or end a scheduling rule that doesn't match the outer scope rule, the error message now includes:

  • Builder name and label
  • Builder class name
  • Plugin ID
  • Project name
  • The conflicting rule

This makes it much easier to identify which builder is causing the rule mismatch, especially in complex build scenarios with multiple builders.

The enhancement catches IllegalArgumentException at the point where beginRule() and endRule() are called in BuildManager.basicBuild() and wraps it with detailed context before re-throwing.

@vogella vogella marked this pull request as draft November 14, 2025 11:31
@vogella vogella force-pushed the claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo branch from e5b4927 to b906eae Compare November 14, 2025 11:32
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Nov 14, 2025

Test Results

    54 files      54 suites   37m 54s ⏱️
 4 849 tests  4 827 ✅  22 💤 0 ❌
12 435 runs  12 279 ✅ 156 💤 0 ❌

Results for commit 985256c.

♻️ This comment has been updated with latest results.

@vogella vogella force-pushed the claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo branch 3 times, most recently from f754b17 to 02578f4 Compare November 14, 2025 15:52
@vogella vogella force-pushed the claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo branch from 02578f4 to d4e060e Compare December 12, 2025 08:36
@eclipse-platform-bot
Copy link
Copy Markdown
Contributor

This pull request changes some projects for the first time in this development cycle.
Therefore the following files need a version increment:

resources/bundles/org.eclipse.core.resources/META-INF/MANIFEST.MF

An additional commit containing all the necessary changes was pushed to the top of this PR's branch. To obtain these changes (for example if you want to push more changes) either fetch from your fork or apply the git patch.

Git patch
From 37e6a615020f7bbe10eeba250515120c8b3ee017 Mon Sep 17 00:00:00 2001
From: Eclipse Platform Bot <platform-bot@eclipse.org>
Date: Fri, 12 Dec 2025 08:44:01 +0000
Subject: [PATCH] Version bump(s) for 4.39 stream


diff --git a/resources/bundles/org.eclipse.core.resources/META-INF/MANIFEST.MF b/resources/bundles/org.eclipse.core.resources/META-INF/MANIFEST.MF
index 82730f0630..f089e0fbcc 100644
--- a/resources/bundles/org.eclipse.core.resources/META-INF/MANIFEST.MF
+++ b/resources/bundles/org.eclipse.core.resources/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
 Bundle-ManifestVersion: 2
 Bundle-Name: %pluginName
 Bundle-SymbolicName: org.eclipse.core.resources; singleton:=true
-Bundle-Version: 3.23.100.qualifier
+Bundle-Version: 3.23.200.qualifier
 Bundle-Activator: org.eclipse.core.resources.ResourcesPlugin
 Bundle-Vendor: %providerName
 Bundle-Localization: plugin
-- 
2.52.0

Further information are available in Common Build Issues - Missing version increments.

@vogella vogella marked this pull request as ready for review December 12, 2025 08:59
@vogella vogella force-pushed the claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo branch from 32c5cdf to a3346dd Compare April 30, 2026 10:11
@vogella
Copy link
Copy Markdown
Contributor Author

vogella commented Apr 30, 2026

Old (without the patch what the JobManager throws raw):

Begin-rule conflict:
Attempted to beginRule: P/Foo/bar, does not match outer scope rule: P/Other

End-rule conflict:
Attempted to endRule: P/Foo/bar, does not match most recent begin: P/Foo. See log for trace information if rule tracing is enabled.


Nothing in the message or stack reveals which builder caused it. You see "some builder requested a wrong rule" with no way to find out which one without enabling rule tracing.
New (with the patch):
Begin-rule conflict:
beginRule failed for builder com.example.MyBuilder ('My Builder', plugin com.example) on project /Foo: Attempted to beginRule: P/Foo/bar, does not match outer scope rule: P/Other

End-rule conflict:
endRule failed for builder com.example.MyBuilder ('My Builder', plugin com.example) on project /Foo: Attempted to endRule: P/Foo/bar, does not match most recent begin: P/Foo. See log for trace information if rule tracing is enabled.


The original IllegalArgumentException is preserved as the cause, so the original stack and message are still fully accessible. The visible win: builder class, label, plugin id, and project path.

Fixes eclipse-platform#2278

When a builder attempts to begin or end a scheduling rule that doesn't
match the outer scope rule, the error message now includes:
- Builder name and label
- Builder class name
- Plugin ID
- Project name
- The conflicting rule

This makes it much easier to identify which builder is causing the
rule mismatch, especially in complex build scenarios with multiple
builders.

The enhancement catches IllegalArgumentException at the point where
beginRule() and endRule() are called in BuildManager.basicBuild() and
wraps it with detailed context before re-throwing.
@vogella vogella force-pushed the claude/enhance-stack-trace-info-01QAQgSR1KNnaVQwZBptdyDo branch from a3346dd to 985256c Compare April 30, 2026 18:15
@vogella vogella merged commit 5ccd447 into eclipse-platform:master May 1, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Attempted to beginRule: MultiRule[], does not match outer scope rule: R/

3 participants