Skip to content

Clean Code for ui/org.eclipse.pde.ui#1771

Merged
akurtakov merged 2 commits intomasterfrom
clean-code/ui/org.eclipse.pde.ui
Jun 9, 2025
Merged

Clean Code for ui/org.eclipse.pde.ui#1771
akurtakov merged 2 commits intomasterfrom
clean-code/ui/org.eclipse.pde.ui

Conversation

@eclipse-pde-bot
Copy link
Copy Markdown
Contributor

@eclipse-pde-bot eclipse-pde-bot commented May 9, 2025

The following cleanups where applied:

  • Add final modifier to private fields
  • Add missing '@Deprecated' annotations
  • Add missing '@Override' annotations
  • Add missing '@Override' annotations to implementations of interface methods
  • Convert control statement bodies to block
  • Make inner classes static where possible
  • Remove trailing white spaces on all lines
  • Remove unnecessary array creation for varargs
  • Remove unnecessary suppress warning tokens
  • Remove unused imports
  • Replace deprecated calls with inlined content where possible
  • Use pattern matching for instanceof

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 9, 2025

Test Results

   765 files  ±0     765 suites  ±0   57m 54s ⏱️ + 3m 12s
 3 611 tests  - 1   3 535 ✅ ±0   76 💤 ±0  0 ❌ ±0 
10 833 runs   - 1  10 602 ✅ ±0  231 💤 ±0  0 ❌ ±0 

Results for commit 7dac48f. ± Comparison against base commit 77b9fa8.

This pull request removes 1 test.
[21: View contribution using 4.x API] ‑ Unknown test

♻️ This comment has been updated with latest results.

@fedejeanne
Copy link
Copy Markdown
Contributor

This one fails because an already existing unused import in ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/dialogs/RepositoryDialog.java. What I find odd is that the check is detecting it as a new problem, which is why the check fails.

Since organize imports tends to do a lot (removing/adding, reordering, compacting i.e. adding .*), I'd say we go for the more subtle remove unused imports --> eclipse-platform/eclipse.platform.releng.aggregator#3040

@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch 4 times, most recently from 4b7730a to f004c02 Compare May 15, 2025 06:37
@fedejeanne
Copy link
Copy Markdown
Contributor

Hm, odd. According to the PR message, Remove unused imports is being used, but the changes in this PR say otherwise and the check still shows:

Error:  Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:4.0.13-SNAPSHOT:compile (default-compile) on project org.eclipse.pde.ui: Compilation failure: Compilation failure: 
Error:  /home/runner/work/eclipse.pde/eclipse.pde/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/dialogs/RepositoryDialog.java:[32] 
Error:  	import org.eclipse.swt.dnd.Transfer;
Error:  	       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error:  The import org.eclipse.swt.dnd.Transfer is never used

@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch from f004c02 to c5fb689 Compare May 16, 2025 03:28
@fedejeanne
Copy link
Copy Markdown
Contributor

The error has been reproduced and reported here: eclipse-jdt/eclipse.jdt.ui#2222

Copy link
Copy Markdown
Contributor

@laeubi laeubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Contributor

@fedejeanne fedejeanne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✔️

@laeubi the bug has been fixed. I think one can be merged now.

@iloveeclipse
Copy link
Copy Markdown
Member

LGTM ✔️

@laeubi the bug has been fixed. I think one can be merged now.

Please do NOT merge now but after 4.37 master starts. We are in RC2 phase now and this is not a white space change.

@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch from 5f14882 to ab16759 Compare May 28, 2025 03:38
@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch from ab16759 to cf58e8a Compare June 5, 2025 03:16
@eclipse-pde-bot
Copy link
Copy Markdown
Contributor Author

eclipse-pde-bot commented Jun 5, 2025

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

ui/org.eclipse.pde.ui/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 54985fa872da255ff9c2d82b8c4a232bbb1a5398 Mon Sep 17 00:00:00 2001
From: Eclipse PDE Bot <pde-bot@eclipse.org>
Date: Mon, 9 Jun 2025 03:34:47 +0000
Subject: [PATCH] Version bump(s) for 4.37 stream


diff --git a/ui/org.eclipse.pde.ui/META-INF/MANIFEST.MF b/ui/org.eclipse.pde.ui/META-INF/MANIFEST.MF
index 645e581c4d..69ac002d3d 100644
--- a/ui/org.eclipse.pde.ui/META-INF/MANIFEST.MF
+++ b/ui/org.eclipse.pde.ui/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
 Bundle-ManifestVersion: 2
 Bundle-Name: %name
 Bundle-SymbolicName: org.eclipse.pde.ui; singleton:=true
-Bundle-Version: 3.16.100.qualifier
+Bundle-Version: 3.16.200.qualifier
 Bundle-Activator: org.eclipse.pde.internal.ui.PDEPlugin
 Bundle-Vendor: %provider-name
 Bundle-Localization: plugin
-- 
2.49.0

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

@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch 3 times, most recently from 1cb46de to a6575a4 Compare June 8, 2025 03:27
@eclipse-pde-bot eclipse-pde-bot force-pushed the clean-code/ui/org.eclipse.pde.ui branch from 17cc923 to c20debc Compare June 9, 2025 03:29
@akurtakov
Copy link
Copy Markdown
Member

@laeubi your review is blocking this one. Would you please review it again?

Copy link
Copy Markdown
Contributor

@laeubi laeubi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now

@akurtakov akurtakov merged commit 59e5453 into master Jun 9, 2025
19 checks passed
@akurtakov akurtakov deleted the clean-code/ui/org.eclipse.pde.ui branch June 9, 2025 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants