-
Notifications
You must be signed in to change notification settings - Fork 3
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
#47 🥅 catch pyenv vs. system python configuration mismatch #48
Conversation
@@ -139,7 +139,7 @@ public void execute() throws MojoExecutionException, MojoFailureException { | |||
} | |||
|
|||
if (!missingRequiredToolMsgs.isEmpty()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I (Informational): just making it easier to read the error
@@ -191,6 +191,17 @@ private String validatateAndConfigurePyenv(List<String> missingRequiredToolMsgs, | |||
currentPythonVersion = pyenvHelper.getCurrentPythonVersion(); | |||
} | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I: this is the meat of the change - when pyenv isn't configured correctly but we have configured habushu to use it, pyenv says your python version is one thing, but python calls on the path say another.
@@ -21,17 +22,17 @@ public class PythonVersionHelper { | |||
|
|||
private static final String PYTHON_COMMAND = "python"; | |||
private static final String PYTHON_3_COMMAND = "python3"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I: some minor sonarlint tidying while I was here - this class is easier to review if you hide whitespace
} | ||
|
||
/** | ||
* Executes a python command with the given arguments, logs the executed | ||
* command, and returns the resultant process output as a string. | ||
* at DEBUG level, and returns the resultant process output as a string. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I: creature comfort so we just have less output since this now runs every time we get the pyenv version
fbb23fd
to
7c38b53
Compare
habushu-maven-plugin/src/main/java/org/technologybrewery/habushu/exec/PythonVersionHelper.java
Outdated
Show resolved
Hide resolved
7c38b53
to
e9cb6eb
Compare
No description provided.