-
-
Notifications
You must be signed in to change notification settings - Fork 809
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
Log more when resolving Python #4185
Log more when resolving Python #4185
Conversation
Users often have problems configuring their Python installations
Adds additional logging to plugin tasks to align with the logging that scrapers output.
8b38b16
to
109202e
Compare
pkg/scraper/script.go
Outdated
logger.Debugf("Scraper script <%s> started", strings.Join(cmd.Args, " ")) | ||
logger.Infof("Scraper script <%s> started", strings.Join(cmd.Args, " ")) |
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 don't think this is necessary.
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.
Changing the level or logging that the scraper script is running? This was mostly for the support cases were we get "ran the scraper, nothing in the log" and I think it'd be helpful to at least see that Stash ran the scraper successfully even if it didn't produce correct output. We always ask users to turn their logging level to Debug and then there's usually some output 🙂
pkg/scraper/script.go
Outdated
logger.Debugf("Scraper script finished") | ||
logger.Infof("Scraper script finished") |
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.
As above.
* Log more when resolving Python Users often have problems configuring their Python installations * Convert if-else ladder to switch statement * Consolidate Python resolution Adds additional logging to plugin tasks to align with the logging that scrapers output.
It's very common for users to struggle with configuring their Python environment for use with Stash and more verbose logging will help us when diagnosing the common issue of not knowing which (if any) Python executable they are using.
I also think the
Resolve
method could use the result ofLookPath
directly to use the absolute path for the Python executables it might find: this should make no difference to its usage, but allows us to log the absolute path.