-
Notifications
You must be signed in to change notification settings - Fork 196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Load marker content generator details from marker content generator extensions (fix for #2193) #2207
Load marker content generator details from marker content generator extensions (fix for #2193) #2207
Conversation
Note that we are in the RC1 phase of development where it's more difficult to push though changes that might cause regressions. I think this will unfortunately need to wait until the 4.34 stream opens for development. Also, have a read through this: https://github.com/eclipse-platform/.github/blob/main/CONTRIBUTING.md#creating-a-pull-request E.g.,
|
4c8db88
to
10963bb
Compare
Thank you for the hints, Ed. I guess, I have to wait at least until the latest commit in the master branch has a successful CI run. When will the 4.34 stream be open for development? Is there a timeline? |
Here's the release train schedule: https://github.com/eclipse-simrel/.github/blob/main/wiki/SimRel/2024-09.md the calendar details: https://calendar.google.com/calendar/u/0/[email protected]&dates=20240901/20240930&hl=en&mode=AGENDA The platform is due to contribute its final build on August 30: So I expect the following week that new I-builds for 4.34 will be configured and at some point during that week master will be declared open. |
@merks , without putting much pressure, I think this is a very nice addition to the product, and if the new extension point is not used, an small change. Would it be possible to have it merged before RC1? |
Not used but going in a release means this will become API without being even used with changes following 2 years deprecation period. IMO this is really bad idea. Practically tonight should be the last build with functional changes for 4.33 and getting new functionality in it means there is no room for maneuver. |
627a21b
to
42cbbf0
Compare
I'd appreciate it if someone would review my PR, maybe @trancexpress? |
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Outdated
Show resolved
Hide resolved
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Outdated
Show resolved
Hide resolved
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Show resolved
Hide resolved
...rg.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/markers/MarkerSupportViewTest.java
Outdated
Show resolved
Hide resolved
...rg.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/markers/MarkerSupportViewTest.java
Outdated
Show resolved
Hide resolved
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Show resolved
Hide resolved
6566218
to
004743b
Compare
It seems, I fell into the pitfall of not knowing, I have to explicitly publish my answers to the reviewers' comments. |
Could you please add a screenshot with such example? |
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Outdated
Show resolved
Hide resolved
004743b
to
b0a02ab
Compare
I did grep what platform/Eclipse/Xtext repositories I have, the extension in question is barely used. I only find mentions in the platform UI repository.
|
b0a02ab
to
a9a1e3f
Compare
@travkin79 feel free to do code clean-ups after we've merged the PR, I've adjusted it to make the review as easy as possible. |
a9a1e3f
to
9d727cb
Compare
OK, last remaining item: @travkin79 , you mention groups in the original commit message. I didn't notice a change in the group code though (aside from removing the caching). Can you clarify? |
Hi @trancexpress,
I guess, you mean, before merging the PR, right? I think, I can only commit changes to my fork. I think, I'll make a few minor improvements in the fork / PR today.
You're right. I wanted to support groups, fields (all and the initially visible ones), and types. There were no significant changes on the groups code. |
No, I do mean after the PR is merged. Please keep clean-ups separate of this change, unless you mean to do clean-ups in the added code.
Why is there no change in the groups code? Shouldn't the groups also take groups of extensions? I.e. how its done for fields and marker types? |
...org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/ContentGeneratorDescriptor.java
Outdated
Show resolved
Hide resolved
Yes, you're right. But the code from master already does that. It's just not that obvious. The method
Ok. I guess that's for keeping the PRs as simple as possible to simplify reviews. |
There's another thing left open: We have to decide whether to change the default of making new marker fields invisible by default. I think, we can safely do that since the marker content generator extensions didn't work before. Thus, no fields would suddenly disappear because of our change. I'm not sure if we should also change the extension point, as suggested by @iloveeclipse, in order to make clear, in which views the fields will be visible. I tend to leave it as it is, assuming that new fields will be invisible by default and a user would decide whether to add them to certain views (e.g. problems view, markers view). |
From my POV this PR is a bug fix, adding missing functionality. If any client code unintentionally adds visible fields (either due to the default when not specifying visibility, or due to explicitly specifying a visible field), that client will have to be adjusted to work with latest the platform (i.e. set the visibility as desired). So from my side, leave as is - the change follows the API documentation. |
d012998
to
5e67afd
Compare
Will merge the PR tomorrow. Let me know if there is any feedback that has not been addressed. |
…m#2193 This change adds missing functionality for the extension 'markerContentGeneratorExtension'. So far, ContentGeneratorDescriptor supports this extension with only getFilterReferences(). I.e. ContentGeneratorDescriptor only lists filter references of extensions, on top of its own filter references. With this change, getAllFields(), getInitialVisible() and getMarkerTypes() are also aggregating values for ContentGeneratorDescriptor and its extensions. As a result, e.g. the problems view and markers view can be extended with new columns. For example, an issue ID and URL to a detailed problem description. Fixes: eclipse-platform#2193
5e67afd
to
b3741a3
Compare
This patch fixes issue #2193. The implementation and tests ensure loading of marker content generator extensions, including new marker fields, marker types, and groups provided via marker content generator extensions.
This way, it is now possible to extends, e.g. the Problems View and the Markers View with new columns. For example, you could add a column with a URL to a vulnerability issue's detailed description (e.g. CWE-200) or in my case to an issue's description found by clang-tidy in a C++ program, like e.g. https://clang.llvm.org/extra/clang-tidy/checks/readability/magic-numbers.html.
Fixes: #2193