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

Fixes for Known Errors #190

Merged
merged 3 commits into from
Mar 10, 2025
Merged

Conversation

rubberduck203
Copy link
Collaborator

Implementation for #160

cargo run -- analyze command --working-dir examples -- echo 'kaboom'
analyzing:  kaboom
 WARN Known error 'known-error-with-fix' found on line 0
 INFO   ==> The command had an error, try reading the logs around there to find out what happened.
 INFO found a fix!
> Would you like to run it? Yes
fixing:  Running some thing that will fix the error we found.
 INFO Fix succeeded
cargo run -- analyze command --working-dir examples -- echo 'error'
analyzing:  error
 WARN Known error 'error-exists' found on line 0
 INFO   ==> The command had an error, try reading the logs around there to find out what happened.
 INFO No automatic fix available

Uncomment out the false command to test failure mode

cargo run -- analyze command --working-dir examples -- echo 'kaboom'
analyzing:  kaboom
 WARN Known error 'known-error-with-fix' found on line 0
 INFO   ==> The command had an error, try reading the logs around there to find out what happened.
 INFO found a fix!
> This may destroy some data.
Do you wish to continue? Yes
ERROR Fix Help: This text displays when the fix fails.
ERROR For more help, please visit https://example.com
ERROR Fix failed

Copy link
Collaborator

@meaganewaller meaganewaller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excited about this feature!!

@rubberduck203 rubberduck203 merged commit f2337e3 into oscope-dev:main Mar 10, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants