satr / intellij-idea-plugin-connector-for-aws-lambda

The plugin for the IntelliJ IDEA: connector for AWS Lambda functions.
MIT License
14 stars 4 forks source link

maven clean does not work after using the plugin #17

Open rcastillosuazo opened 5 years ago

rcastillosuazo commented 5 years ago

For some reason after I use the plugin to update, I can not run maven again. The jar is taken by intellij. Close and open intellij solves the problem.

[INFO] Scanning for projects... [INFO]
[INFO] ------------------------------------------------------------------------ [INFO] Building "project"0.1.0 [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ project--- [INFO] Deleting E:\zzzz\xxxx\workspace\project\target [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE

satr commented 5 years ago

Thank you for the report. Let me look at this.

satr commented 5 years ago

I fix an issue with maven artifact path and closed the artifact file. Please try the pre-release v.1.7.RC4

The release 1.7* is not published as I faced periodical hanging of the IDEA. I'm not sure if the plugin can cause a problem. For reference https://intellij-support.jetbrains.com/hc/en-us/articles/206544899-Getting-a-thread-dump-when-IDE-hangs-and-doesn-t-respond

rcastillosuazo commented 5 years ago

Hi, thanks for your response. I tried the indicated version, but the problem continues. I describe my actions, I execute mvn clean package for the first time. Once the jar is created, I use the plugin to update the lambda in aws. So far so good. When making a change to the source and when rerunning mvn clean package, it gives the following error:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project XXXXXXX: Failed to clean project: Failed to delete E:\CCCC\RRRR\workspace\PPPPPPPP\target\XXXXXXXXX-0.1.0.jar -> [Help 1] org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project XXXXXXX: Failed to clean project: Failed to delete E:\CCCC\RRRR\workspace\PPPPPPPP\target\XXXXXXXXX-0.1.0.jar at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)

image

satr commented 5 years ago

Hi I did not try “clean” - only “compile” and “package” (I’m not such familiar with the maven workflow). Let me try this way also. At least now it tells in the log - delete file, not entire “target” folder (corrected this today). Thank you, will keep you updated.

satr commented 5 years ago

Hi So far I did not manage to make plugin fail as described - all the time after clean, compile, package it reports SUCCESS and can update the Lambda on AWS. Probably I do this different or wrong way (as I mentioned, I'm not much familiar with Maven projects). I will look at this more.

rcastillosuazo commented 5 years ago

I'm using version 2018.1 Community Edition, I do not think that's it. I will update intellij and try.

Greetings thank you

satr commented 5 years ago

I also for not think it is a version issue. Which OS do you use (I tested on MacOS). I can check on Windows and Linux as well. Maybe you can put a sample project to github or attach an archive with it here?

satr commented 5 years ago

On Windows it works ok. Please check out how I tested it video. Maybe you can see the difference with the way you do it (maybe I do it wrong).

rcastillosuazo commented 5 years ago

Here you can see how I get the error. video

satr commented 5 years ago

Thank you fo the video. Seems I perform the process a bit different. I tried to reproduce with some maven example project from github, but still do not fail. I will check more about maven workflow and test again. It would be helpful if you could create a simple maven project, which is failing on your IDEA and share it, so I can reproduce this more accurate. Also please let me know if you use some plugins for Maven.