Skip to content
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

IEP-1058 Incorrect toolchain list after updating esp-idf version #842

Merged
merged 1 commit into from
Oct 27, 2023

Conversation

sigmaaa
Copy link
Collaborator

@sigmaaa sigmaaa commented Oct 25, 2023

Description

To reproduce. Clean .espressif folder. Install 4.4.3 esp-idf and tools via IDE. After that install esp-idf master -> Toolchains are not updated properly

Fixes # (IEP-1058)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

How has this been tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Test 1:

  • install two different esp-idf versions with different toolchains. For example esp-idf 4.4.3 and esp-idf master.
  • After switching versions, toolchains must be changed accordingly.

Test Configuration:

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

Dependent components impacted by this PR:

  • Install Tools
  • Toolchains

Checklist

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

Summary by CodeRabbit

  • Refactor: Improved the efficiency of the ESPToolChainManager with a more streamlined code structure. This update enhances the software's performance by optimizing the methods used to find and manage toolchains.
  • New Feature: Introduced a new function to remove a matched toolchain from the manager. This feature provides users with more control over their toolchain management, improving the overall usability of the system.

@coderabbitai
Copy link

coderabbitai bot commented Oct 25, 2023

Walkthrough

The changes primarily focus on enhancing the readability and efficiency of the code in the ESPToolChainManager class. The findDebugger and findToolChain methods have been refactored using method chaining and lambda expressions. A new method removeMatchedToolChain has been introduced for better modularity.

Changes

File Summary
.../core/toolchain/ESPToolChainManager.java Refactored findDebugger and findToolChain methods for improved readability and efficiency. Introduced a new method removeMatchedToolChain for better modularity.

🐇

In the land of code, where logic intertwines,

A rabbit hopped and tweaked some lines.

With lambda expressions, method chains in sight,

The code now runs with improved might.

A new method born, in the toolchain's den,

Celebrate we must, for it's a win-win then! 🎉


Tips

Chat with CodeRabbit Bot (@coderabbitai)

  • If you reply to a review comment from CodeRabbit, the bot will automatically respond.
  • To engage with CodeRabbit bot directly around the specific lines of code in the PR, mention @coderabbitai in your review comment
  • Note: Review comments are made on code diffs or files, not on the PR overview.
  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai help to get help.

Note: For conversation with the bot, please use the review comments on code diffs or files.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • 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/coderabbit-overrides.json

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Review Status

Actionable comments generated: 0

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between b152760 and 04d9057.
Files selected for processing (1)
  • bundles/com.espressif.idf.core/src/com/espressif/idf/core/toolchain/ESPToolChainManager.java (4 hunks)
Files skipped from review due to trivial changes (1)
  • bundles/com.espressif.idf.core/src/com/espressif/idf/core/toolchain/ESPToolChainManager.java

@kolipakakondal kolipakakondal added this to the 2.11.1 milestone Oct 26, 2023
Copy link
Collaborator Author

@sigmaaa sigmaaa left a comment

Choose a reason for hiding this comment

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

self reviewed

@AndriiFilippov
Copy link
Collaborator

AndriiFilippov commented Oct 26, 2023

@sigmaaa , @kolipakakondal hi !
Tested under:
OS - MacOS, Windows 10, Linux Ubuntu

able to see correct toolchain list after updating esp-idf version (v4.4.6 -> v5.1.1 / master -> v4.4.6 / v5.0 -> master)
able to build / flash / monitor
LGTM 👍

@kolipakakondal kolipakakondal merged commit de91c43 into master Oct 27, 2023
@kolipakakondal kolipakakondal deleted the IEP-1058 branch May 10, 2024 15:50
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.

3 participants