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

fix: updating espressif openocd path during startup #910

Merged
merged 1 commit into from
Mar 13, 2024
Merged

Conversation

sigmaaa
Copy link
Collaborator

@sigmaaa sigmaaa commented Mar 7, 2024

Description

fixed an issue when during the first start of Espressif-IDE, the openocd path is undefined.

Fixes # (IEP-1176)

Type of change

Please delete options that are not relevant.

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

How has this been tested?

  • Download Espressif-IDE from this PR
  • copy esp-idf.json from the Espressif-IDE which comes from the offline installer into the new Espressif-IDE
  • start Espressif-IDE, verify environment variables, openocd path from the Espressif preferences page

Test Configuration:

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

Dependent components impacted by this PR:

  • openocd path

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
    • Improved tool initialization process for enhanced performance.

Copy link

coderabbitai bot commented Mar 7, 2024

Walkthrough

The update introduces an enhancement to the Eclipse plugin for the Espressif IDF, focusing on improving the user experience by ensuring the OpenOCD path is correctly set up. By importing IDFUtil and invoking IDFUtil.updateEspressifPrefPageOpenocdPath(), it aims to streamline the setup process, potentially addressing issues related to project import and debugging in different environments.

Changes

File Summary
bundles/.../InitializeToolsStartup.java Added import for IDFUtil and called IDFUtil.updateEspressifPrefPageOpenocdPath().

Related issues

🐇✨
In the burrow of the code, a change was made,
A path now clear, where once it strayed.
With a hop and a skip, the issues we evade,
For every builder and debugger's aid.
Let's celebrate this leap, so brightly arrayed.
🌟🐾

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

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>.
    • Generate unit-tests for this file.
    • 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. Examples:
    • @coderabbitai generate unit tests for this file.
    • @coderabbitai modularize this function.
  • 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 generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

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 resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

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.v2.json

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

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 376b484 and 3b281d9.
Files selected for processing (1)
  • bundles/com.espressif.idf.ui/src/com/espressif/idf/ui/InitializeToolsStartup.java (2 hunks)
Additional comments: 2
bundles/com.espressif.idf.ui/src/com/espressif/idf/ui/InitializeToolsStartup.java (2)
  • 44-44: The addition of the import statement for IDFUtil is appropriate for enabling the use of IDFUtil.updateEspressifPrefPageOpenocdPath() method later in the code. This change is necessary for the intended functionality.
  • 193-193: The invocation of IDFUtil.updateEspressifPrefPageOpenocdPath() is central to the PR's objective of updating the OpenOCD path during startup. It's correctly placed in the code flow. However, it's important to verify that this method does not introduce any side effects or dependencies that could negatively impact the startup process.

@sigmaaa sigmaaa changed the title [WIP] fix: updating espressif openocd path during startup fix: updating espressif openocd path during startup Mar 7, 2024
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. Tested

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.

LGTM

@kolipakakondal
Copy link
Collaborator

@AndriiFilippov Please verify

@kolipakakondal kolipakakondal added this to the v2.13.0 milestone Mar 8, 2024
@AndriiFilippov
Copy link
Collaborator

@sigmaaa hi !

Tested under:
OS - Windows 10

Able to debug esp32 target.
Do see Global OpenOCD path.

image

LGTM 👍

@kolipakakondal kolipakakondal merged commit 909b4d2 into master Mar 13, 2024
6 of 7 checks passed
@kolipakakondal kolipakakondal deleted the IEP-1176 branch March 13, 2024 03:56
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