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

[BUG] RHDA is attempting to put a slash at the beginning of the path to my POM, causing the help:effective-pom mvn command to fail #681

Closed
natereprogle opened this issue Feb 7, 2024 · 24 comments · Fixed by fabric8-analytics/fabric8-analytics-lsp-server#244
Assignees

Comments

@natereprogle
Copy link

natereprogle commented Feb 7, 2024

Describe the bug
Every time I focus on my pom.xml in my project, I get the following error:

Command failed: mvn -q help:effective-pom -Doutput="\v:\Development Projects\<project-here>\effective-pom.xml" -f "/v:/Development Projects/<project-here>/pom.xml" POM file "/v:/Development Projects/<project-here>/pom.xml" specified the -f/--file command-line argument does not exist

Running this command manually also gives the same error, but removing the / from in front of v:/ in the -f argument generates the effective-pom as expected. I have attempted to look through different configuration settings, update Maven to the latest version, etc. with no results.

To Reproduce
Steps to reproduce the behavior:

  1. Simply open any pom.xml in my project. I have two
  2. Receive error, nothing happens

Expected behavior
The effective-pom.xml is generated, and I am able to analyze dependencies as normal

Screenshots
image
I am able to control click the file it says doesn't exist and navigate to it within VSCode without issue. This is not a symlink or shortcut, it is the actual file itself.

Logs
The only logs I see are in the output window of VSCode, which just state the error I am receiving above.
log.log

VSCode(please complete the following information):

  • OS: Windows 11 23H2 build 22631.3085
  • VSCode version: 1.86.0
  • Dependency Analytics Version v0.9.2

Additional context
The -Doutput flag doesn't need to change, strangely enough. It uses \ instead of /, but the file is generated fine. However, even if I change the -f argument to use \ instead of /, it still fails when run manually, with the same result.

@enielrodriguez
Copy link

I think I have a problem like yours:
ENOENT: no such file or directory, open '/c:/projects/myproject/pom.xml'

@ionutcbn
Copy link

ionutcbn commented Feb 10, 2024

Same for me:
mvn -q help:effective-pom -Doutput="\c:\Users\some-path\effective-pom.xml" -f "/c:\Users\some-path\pom.xml"
does not work issuing file not found, but:

mvn -q help:effective-pom -Doutput="c:\Users\some-path\effective-pom.xml" -f "c:\some-path\pom.xml"
works without any issue.

mvn -q help:effective-pom -Doutput="\c:\Users\some-path\effective-pom.xml" -f "c:\Users\some-path\pom.xml" also works, so it seems that only the slash after the -f option is the issue.

@wuzhi2009
Copy link

me too, so it seems that only the slash after the -f option is the issue.

@GKPavesi
Copy link

GKPavesi commented Feb 15, 2024

same thing happening here, I've downgraded the extension for now and it is working, but the current version is bugged

@natereprogle
Copy link
Author

same thing happening here, I've downgraded the extension for now and it is working, but the current version is bugged

Which version did you downgrade to? I'd love to know so I can make the switch. I'm working on moving my projects to Gradle right now, but until then I would love to have this plugin working for my Maven stuff.

@GKPavesi
Copy link

same thing happening here, I've downgraded the extension for now and it is working, but the current version is bugged

Which version did you downgrade to? I'd love to know so I can make the switch. I'm working on moving my projects to Gradle right now, but until then I would love to have this plugin working for my Maven stuff.

I've downgraded to version 0.7.3 which was released about 3 months ago.
image
I have not tested version 0.9.0 and version 0.9.1, just downgraded directly to 0.7.3 and realized it was working and left if there, but maybe you can also try these versions to see if they work.

@windwhim
Copy link

I downgraded to 0.9.0, which fixes the problem.

same thing happening here, I've downgraded the extension for now and it is working, but the current version is bugged

Which version did you downgrade to? I'd love to know so I can make the switch. I'm working on moving my projects to Gradle right now, but until then I would love to have this plugin working for my Maven stuff.

I've downgraded to version 0.7.3 which was released about 3 months ago. image I have not tested version 0.9.0 and version 0.9.1, just downgraded directly to 0.7.3 and realized it was working and left if there, but maybe you can also try these versions to see if they work.

@tommai78101
Copy link

tommai78101 commented Feb 21, 2024

I decided to test to see if downgrading to 0.9.1 fixes the problem, but unfortunately, it's a no-go. I got some invalid JSON response and requests to the https://rhdacloud.com/api/v4/analysis failures.

EDIT: It seems downgrading to any versions are all no-goes. I get a lot of invalid JSON response bodies for each downgrade: 0.9.0, 0.7.3, etc.

I downgraded to 0.9.0, which fixes the problem.

same thing happening here, I've downgraded the extension for now and it is working, but the current version is bugged

Which version did you downgrade to? I'd love to know so I can make the switch. I'm working on moving my projects to Gradle right now, but until then I would love to have this plugin working for my Maven stuff.

I've downgraded to version 0.7.3 which was released about 3 months ago. image I have not tested version 0.9.0 and version 0.9.1, just downgraded directly to 0.7.3 and realized it was working and left if there, but maybe you can also try these versions to see if they work.

@elTorres
Copy link

elTorres commented Mar 5, 2024

Same here: I can´t generate effective pom with extension v0.9.2 because the slash at the beginning of the path.

If I downgrade to v0.9.0 RHDA don´t work with error "request to https://rhda.rhcloud.com/api/v4/analysis failed, reason: connect ETIMEDOUT 18.119.151.206:443"

@IlonaShishov
Copy link
Collaborator

Thank you @natereprogle and all for reaching out regarding this issue.
A fix for this bug will be available soon.

@natereprogle
Copy link
Author

Thank you @natereprogle and all for reaching out regarding this issue.

A fix for this bug will be available soon.

Thank you! That's awesome 👏🏼

@wuzhi2009
Copy link

Thank you @natereprogle and all for reaching out regarding this issue. A fix for this bug will be available soon.

Vielen Dank für Ihre harte Arbeit!

@raffian
Copy link

raffian commented Mar 11, 2024

I too have suffered from this problem for a while now on 0.9.3 . At first I thought it was some kind of curse, how something fundamental like maven was broken. Glad to see I'm not alone 🌝

@elTorres
Copy link

Hi @IlonaShishov

2 versions (v0.9.3 and v0.9.4) of the RHDA extension have been published after the fix fabric8-analytics/fabric8-analytics-lsp-server#244, but neither of them includes it.

When do you expect to release a version of RHDA that includes it?

Is it possible to download a packaged version of RHDA LSP Server to manually replace it locally?

Thanks in advance

@dennis-yemelyanov
Copy link

Same issue. I don't want to disable the extension just to get rid of this error, but it would be great to have a fix

@sa-schiefer
Copy link

Downgraded to 0.9.1 and it seems to be working without the issue.

@IlonaShishov
Copy link
Collaborator

@elTorres the fix will be included in the next release, version 0.9.5. You can expect it very soon.

We don't offer pre-packaged versions for manual replacement, but once 0.9.5 is out, you'll be able to update your RHDA extension.

Thanks for your patience.

@rozerinyildiz
Copy link

Downgrading RHDA fixed my problem too, thank you.

@aphage
Copy link

aphage commented May 23, 2024

v1.30.0 appears again.

@tommai78101
Copy link

tommai78101 commented Jun 1, 2024

@aphage It is likely because 0.9.5 isn't out publicly. I'm just guessing.

@shi0rik0
Copy link

I encountered the same problem on v0.9.4. When will the fix be published?

@elTorres
Copy link

elTorres commented Jul 8, 2024

@elTorres the fix will be included in the next release, version 0.9.5. You can expect it very soon.

We don't offer pre-packaged versions for manual replacement, but once 0.9.5 is out, you'll be able to update your RHDA extension.

Thanks for your patience.

Any news @IlonaShishov ?

@IlonaShishov
Copy link
Collaborator

We are still working on the fix for your issue and apologize for the delays. We will notify you as soon as it is available.
Thank you for your patience.

@IlonaShishov
Copy link
Collaborator

Hello,

This issue has been resolved in the latest release, version 0.9.5. We appreciate your help in improving the project. If you have any further issues or suggestions, please feel free to reach out.

Best regards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment