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

Endless loop when installing Eclipse in force mode #663

Closed
hohwille opened this issue Sep 30, 2024 · 0 comments · Fixed by #665
Closed

Endless loop when installing Eclipse in force mode #663

hohwille opened this issue Sep 30, 2024 · 0 comments · Fixed by #665
Labels
bug Something isn't working CLI IDEasy command-line-interface (parsing args, etc.) install installation process of IDE + tools and install commandlet

Comments

@hohwille
Copy link
Member

Expected behavior

As a IDEasy user, I want to be able to combine CLI options with tool installations seamlessly so that I do not end up in errors.

Actual behavior

When installing eclipse with --force mode I end up in an infinity loop.

Steps to reproduce (bug) / Use Case of feature request (enhancement)

  1. Ensure eclipse is not installed or not up-to-date.
  2. ide -f eclipse

Comments/Hints:

This is causing the error:

if (this.context.isForceMode()) {
fileAccess.delete(installationPath);

The problem is that at the end of the installation postInstall is called that then triggers the plugin installation what for Eclipse needs to run the tool itself to install plugins via runTool. The latter again calls install to ensure the tool is already installed before running it.
This is rather a design problem than a real implementation bug.
We could somehow keep a state to track that we just installed eclipse and then consider this state to prevent the deletion in force-mode but for KISS I would suggest to remove this force feature here. The user can do ide uninstall eclipse && ide install eclipse to get this behaviour consistently.
IMHO: --force should rather disable caches like git-cache timeouts or download-cache. Besides for the end-user the behaviour of --force is so far rather undocumented or at least unclear:

-f | --force    enable force mode.

So what does that mean?

Affected version:

  • 2024.09.002-beta-SNAPSHOT
@hohwille hohwille added bug Something isn't working CLI IDEasy command-line-interface (parsing args, etc.) install installation process of IDE + tools and install commandlet labels Sep 30, 2024
@hohwille hohwille added this to the release:2024.09.002 milestone Sep 30, 2024
@github-project-automation github-project-automation bot moved this to 🆕 New in IDEasy board Sep 30, 2024
hohwille added a commit to hohwille/IDEasy that referenced this issue Sep 30, 2024
hohwille added a commit to hohwille/IDEasy that referenced this issue Sep 30, 2024
hohwille added a commit to hohwille/IDEasy that referenced this issue Sep 30, 2024
hohwille added a commit to hohwille/IDEasy that referenced this issue Sep 30, 2024
hohwille added a commit to hohwille/IDEasy that referenced this issue Sep 30, 2024
hohwille added a commit that referenced this issue Sep 30, 2024
@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in IDEasy board Sep 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working CLI IDEasy command-line-interface (parsing args, etc.) install installation process of IDE + tools and install commandlet
Projects
Status: ✅ Done
Development

Successfully merging a pull request may close this issue.

1 participant