Skip to content

Conversation

@AndriiFilippov
Copy link
Collaborator

@AndriiFilippov AndriiFilippov commented Aug 19, 2025

Description

Implementing a conditional check to read a system property testRun and use it to optionally skip certain validations.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How has this been tested?

I have tested implemented code locally on my Windows 11 machine by running:
mvn clean install -Djarsigner.skip=true -DskipTests=false -DtestRun=TEST

Validations controlled by the 'testRun' flag were skipped during the run ✅
All tests passed successfully ✅

Test Configuration:

  • ESP-IDF Version:
  • OS (Windows,Linux and macOS): Windows 11 / Linux Ubuntu

Checklist

  • PR Self Reviewed
  • Applied Code formatting
  • Added Documentation
  • Added Unit Test
  • Verified on all platforms - Windows,Linux and macOS

Summary by CodeRabbit

  • New Features

    • Integrated Espressif Installation Manager (EIM): download/launch from IDE, new ESP-IDF Manager editor, auto tool setup, and change detection with prompts.
    • Added console feedback and improved onboarding, including migration of old workspaces.
  • Refactor

    • Simplified environment handling; removed legacy installers, wizards, and update command.
    • UI/UX updates in manager view; product version bumped to 4.0.0.
  • CI

    • Modernized workflows, added beta tag handling, Maven caching, updated actions, and test flags.
  • Documentation

    • New EIM-based installation flow and migration guide; docs versioning added.
  • Tests

    • Updated integration tests, timeouts, and paths.

alirana01 and others added 30 commits July 24, 2025 14:11
* Initial integration

Initial integration for the eim starting from the start to handle the empty workspace. Tools activation is still to be done along with code cleanup. Just the basic display is working which will also be enhanced.

* Initial first flow with successful installation and loading of env in IDE with EIM

* constants moved to single place and added refresh function

* minor cleanup and logging for user

* IEP-1334: code cleanup (Active Review) (#1125)

* cleanup of unused classes and code

* String internalization

* update to ci file

* ci error fixed

* ci error fix

* ci fix

* fixing ci error

* ci error fix

* ci error fix

* ci syntax fix

* ci syntax indentation fix

* ci syntax fix

* ci syntax fix

* ci fixed

* ci fixed2

* ci trigger

* workflow trigger fix

* cleanup

* ci deps isntalled

* eim fix

* using eim action to install

* using Petr's fork

* switched back to official action repo

* Revert "switched back to official action repo"

This reverts commit f8cd7a7.

* trying to fix action for eim

* trying with petrs fork again

* ci fix

* back to espressif

* name fixed

* updated url for eim

* old config export handling

* fixing tests env setup

* logging to verify skip tests

* fixing POSIX path resolution

* activation script properly sourced

* added test run variable in test pom directly

* adding cache option for the maven

* file name updated

* increasing timeout for tests

* test fixes and removing redundant and outdated tests

* cleanup and update for user messages

* updated to handle activation of single esp-idf from eim

* removing unwanted test for fixing failures

* increased timeout for tests

* ci updated for the release branch trigger as well

* ci error fix

* fix for sdkconfig server

* cleaning up the idf_tools_path configuration in the IDE

* added the option to include homebrew paths on macos

* changes for guide link

* Guidance link added to NLS

* fix: Launch ESP-IDF Manager view even there is no eim_idf.json file found

* fix: Don't launch multiple ESP-IDF Manager editors

* fix: Update the msg and convert it to MessageDialog

* fix: notify IDF not found while opening Manager view

* fix: java.lang.UnsupportedOperationException

* fix: File Not found issue and others

* updated code for eim watcher added

Next commits will do some refactoring and then implement the logic to handle these changes

* refactored startup classes

* initial base level logic for file watcher

So this is very basic first level of file watcher service that watches the file and then also takes care that the file is wasnt changes since last startup. Initial changes only take that the file last modified is verified and just any change in file simply will give you a message box telling that something changed. More advanced and robust checks in upcoming commits

* missing copyright added

---------

Co-authored-by: Kondal Kolipaka <kondal.kolipaka@espressif.com>
* automatic refresh added

* switched to message dialog

* improved null checks

* file watcher added first
…df.json (#1218)

* eim auto import for old config added
* IEP-1552: Fix for system python executable
IEP-1554: Launch and Download of EIM added
---------

Co-authored-by: Kondal Kolipaka <kondal.kolipaka@espressif.com>
* IEP-1557: Documentation for the ESP-IDF Manager

* version.js added
* IEP-1585: Fixed eim old config import handling
fix: added global modal lock to avoid multiple modals
* IEP-1583: Closing old editor window when old workspace is found

* fix: address NPE while launching

---------

Co-authored-by: Kondal Kolipaka <kondal.kolipaka@gmail.com>
* ci: update the beta workflow and merge release&beta ci
@coderabbitai
Copy link

coderabbitai bot commented Aug 19, 2025

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Walkthrough

Replaces legacy in-IDE tools management with EIM-based installation/management, adds EIM loader, parser, watcher, and startup flows; removes prior installers/wizards; updates environment handling to System.getenv; adjusts UI/editor to EIM; modernizes CI (triggers, actions, beta handling); bumps versions to 4.0.0; updates docs/tests accordingly.

Changes

Cohort / File(s) Summary
CI workflows modernization
.github/workflows/ci.yml, .github/workflows/ci_windows.yml, .github/workflows/ci_release.yml, .github/workflows/ci_beta.yml
Update triggers (incl. release/** and beta tags), modernize actions (checkout v4, install-esp-idf), adjust Maven flags, add dynamic S3 paths; remove macOS beta workflow.
Version and product bump
bundles/com.espressif.idf.branding/META-INF/MANIFEST.MF, features/com.espressif.idf.feature/feature.xml, releng/com.espressif.idf.configuration/pom.xml, releng/com.espressif.idf.product/idf.product
Increment versions from 3.5.0 to 4.0.0 qualifiers across branding, feature, releng, and product.
Core env/tooling refactor
.../idf/core/IDFEnvironmentVariables.java, .../idf/core/util/IDFUtil.java, .../idf/core/build/IDFBuildConfiguration.java, .../idf/core/logging/Logger.java, .../idf/core/util/EspToolCommands.java, .../idf/core/toolchain/ESPToolChainManager.java
Add new env constants; switch to System.getenv(); remove IDF_TOOLS_PATH propagation; add Logger overload; refine directory filtering; add python-env resolver.
Public constants cleanup
.../idf/core/IDFCorePreferenceConstants.java
Remove multiple public preference keys (GitHub assets, pip index URLs, IDF_TOOLS_PATH).
EIM core: constants, parser, loader, setup
.../idf/core/tools/EimConstants.java, .../idf/core/tools/EimIdfConfiguratinParser.java, .../idf/core/tools/EimLoader.java, .../idf/core/tools/SetupToolsInIde.java, .../idf/core/tools/ToolInitializer.java, .../idf/core/tools/DownloadListener.java, .../idf/core/tools/Messages.java, .../idf/core/tools/messages.properties
Introduce EIM constants, JSON parser, downloader/launcher, IDE setup job, initializer, download listener, and i18n for OpenOCD rules flow.
EIM VO models
.../idf/core/tools/vo/EimJson.java, .../idf/core/tools/vo/IdfInstalled.java
Add JSON-mapped value objects for EIM state and installed IDF entries.
File watcher for EIM JSON
.../idf/core/tools/watcher/*
Add watcher thread, state checker, change listener interface to react to eim_idf.json changes; export new package in core manifest.
Removal of legacy tools system
.../idf/core/tools/{IToolsInstallationWizardConstants.java, IToolsJsonKeys.java, JsonKey.java, ToolSetConfigurationManager.java, ToolsJsonParser.java, ToolsPlatformMapping.java, ToolsSystemWrapper.java}, .../idf/core/tools/vo/{IDFToolSet.java, ToolsVO.java, VersionDetailsVO.java, VersionsVO.java}
Delete old tool-set, parsers, annotations, platform mapping, and VO classes.
Tools utility shift
.../idf/core/tools/util/ToolsUtility.java
Replace tool-detection/extraction APIs with activation-script-based version retrieval and active-check helpers.
Core build/UI messages
.../idf/core/build/Messages.java, .../idf/core/build/messages.properties
Add new user-facing strings for EIM presence, workspace setup, and old-config migration; adjust some labels.
UI startup restructuring
bundles/com.espressif.idf.ui/plugin.xml, .../idf/ui/EspressifGeneralStartup.java, .../idf/ui/tools/EspressifToolStartup.java, .../idf/ui/InitializeToolsStartup.java
Replace old startup classes with general and tool startup; remove update command; delete old initializer.
UI EIM integration (manager/editor)
.../idf/ui/tools/manager/ESPIDFManagerEditor.java, .../idf/ui/tools/manager/EimEditorInput.java, .../idf/ui/tools/manager/pages/ESPIDFMainTablePage.java
Editor now consumes EIM JSON; add first-startup setup; table uses IdfInstalled list; add EIM launch/download control.
UI handlers and listeners
.../idf/ui/tools/EimButtonLaunchListener.java, .../idf/ui/tools/SetupToolsJobListener.java, .../idf/ui/LaunchBarListener.java, .../idf/ui/GlobalModalLock.java, .../idf/ui/tools/watcher/EimJsonUiChangeHandler.java
Add EIM button flow and job listener; serialize modals; adapt launch-bar confirmation; handle EIM JSON changes.
UI removals (install/update wizard)
.../idf/ui/install/*, .../idf/ui/tools/{ToolsActivationJob.java, ToolsInstallationJob.java, ToolsJob.java}, .../idf/ui/handlers/UpdateEspIdfHandler.java
Remove Git clone/download wizard, progress monitors, jobs, and update handler.
UI messages and prefs changes
.../idf/ui/tools/Messages.java, .../idf/ui/tools/messages.properties, .../idf/ui/preferences/EspresssifPreferencesPage.java, .../idf/ui/OSGI-INF/l10n/bundle.properties
Prune/replace messages for new flows; remove tools installation section from preferences; drop update command label.
UI utilities updated env sourcing
.../idf/ui/update/AbstractToolsHandler.java, .../idf/ui/dialogs/SbomCommandDialog.java, .../idf/ui/help/ProductInformationHandler.java, .../idf/ui/tracing/AppLvlTracingDialog.java, .../idf/serial/monitor/core/IDFMonitor.java
Switch to System.getenv(); remove dependency checks method in monitor.
Docs and static assets
docs/en/installation.rst, docs/_static/docs_version.js
Rewrite installation to EIM-centric process and migration steps; add docs version config (latest, release-v4.0.0).
Tests updates
tests/com.espressif.idf.ui.test/.../*.java, tests/.../configs/default-test-linux.properties, tests/pom.xml
Adapt flows to editor-based manager and EIM setup; tweak timeouts; update IDF path; add -DtestRun property; adjust test cases.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User
  participant IDE as IDE (Eclipse)
  participant Startup as EspressifToolStartup
  participant EIM as EIM (Manager)
  participant FS as eim_idf.json
  participant Core as SetupToolsInIde

  User->>IDE: Launch IDE
  IDE->>Startup: earlyStartup()
  Startup->>Startup: Check EIM installed / JSON present
  alt EIM not installed
    Startup->>EIM: Download & Launch (EimLoader)
    EIM-->>Startup: Exits after install
  end
  Startup->>FS: Read EIM JSON (EimIdfConfiguratinParser)
  alt Single IDF detected
    Startup->>Core: setupTools(idfInstalled, eimJson)
    Core-->>Startup: OK / Error (rollback on error)
  else Multiple/none
    Startup->>IDE: Open ESP‑IDF Manager Editor
  end
  note over IDE,FS: EimJsonWatchService monitors eim_idf.json and prompts to refresh on changes
Loading
sequenceDiagram
  participant Watcher as EimJsonWatchService
  participant FS as eim_idf.json
  participant UI as EimJsonUiChangeHandler
  participant Editor as ESPIDFManagerEditor
  participant Core as SetupToolsInIde

  FS-->>Watcher: Modify (create/delete/change)
  Watcher->>UI: onJsonFileChanged(path, paused=false)
  UI->>UI: Ask user to refresh (modal)
  alt Confirm
    UI->>FS: Reload EIM JSON
    alt Single IDF
      UI->>Core: setupTools(...)
    else Multiple
      UI->>Editor: Open manager and refresh
    end
  else Decline
    UI-->>Watcher: No action
  end
Loading

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120+ minutes

Possibly related PRs

Suggested labels

needs translation:CN

Suggested reviewers

  • alirana01
  • kolipakakondal
  • sigmaaa

Poem

A rabbit taps the build with gentle paws,
Watches EIM hop in with shiny jaws;
Old wands retired, new carrots in a row,
JSON rustles, watchers softly glow.
Tags and trails to “beta” now align—
4.0 blooms—thump-thump, all systems fine! 🥕🐇

✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/handle-test-run-property

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@AndriiFilippov AndriiFilippov changed the base branch from master to release/v4.0.0 August 19, 2025 13:01
Copy link
Collaborator

@alirana01 alirana01 left a comment

Choose a reason for hiding this comment

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

There are some changes that are required kindly go over it and another important thing before we do any of these changes is to pin point all the areas that are required to be modified for test runs. We can then come up with implementation plan for these kind of classes or how to avoid certain parts of these things maybe we will have to split the logic into more classes for Startup or move some to Utility classes and avoid the test run there.

Comment on lines 312 to 319
Display.getDefault().syncExec(() -> {
String testRunValue = System.getProperty("testRun");
Logger.log("testRun: " + testRunValue);

if (!StringUtil.isEmpty(testRunValue) && Boolean.parseBoolean(testRunValue))
{
return;
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do we need to run this code in Display thread? I think we can try to get the value without it or do you get any errors?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

separated non-UI operation from syncExec()


if (!StringUtil.isEmpty(testRunValue) && Boolean.parseBoolean(testRunValue))
{
return;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Also I am not sure how this is tested or working because this is just returning from the lambda block not the function!

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done


- name: Build with Maven
run: export NO_AT_BRIDGE=1 && mvn clean verify -Djarsigner.skip=true -DskipTests=false -DtestWorkspace=/opt/actions-runner/_work/workspace
run: export NO_AT_BRIDGE=1 && mvn clean verify -Djarsigner.skip=true -DskipTests=false -DtestRun=TEST -DtestWorkspace=/opt/actions-runner/_work/workspace
Copy link
Collaborator

Choose a reason for hiding this comment

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

we dont need an additional variable since we already have skipTests we can use that instead of adding a new one

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done


- name: Build with Maven
run: mvn clean verify "-Djarsigner.skip=true" "-DskipTests=false" "-DtestWorkspace=C:/actions-runner/_work/workspace"
run: mvn clean verify "-Djarsigner.skip=true" "-DskipTests=false" -DtestRun=TEST "-DtestWorkspace=C:/actions-runner/_work/workspace"
Copy link
Collaborator

Choose a reason for hiding this comment

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

similarly here we dont need an additional variable since we already have skipTests we can use that instead of adding a new one

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done

@sigmaaa sigmaaa added this to the v4.0.0 milestone Nov 4, 2025
@kolipakakondal
Copy link
Collaborator

Hi @AndriiFilippov Looks like this PR has all the 4.0.0 changes together with 37 commits, this only leads to conflicting changes and merge issues, can we make the specific PR for the changes you're working on.

Copy link
Collaborator

@kolipakakondal kolipakakondal left a comment

Choose a reason for hiding this comment

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

Please re-work on the clear PR as mentioned.

@AndriiFilippov AndriiFilippov deleted the feature/handle-test-run-property branch November 24, 2025 14:54
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.

5 participants