Skip to content

Undo service init can fail from lack of await #46

@thedustinmiller

Description

@thedustinmiller

Hello,

Currently the undo service doesn't await ui.warning calls, which causes the validation to fail and the application to exit without explanation. This makes silly issues, like git exiting with 128 due to not setting email and name, more difficult to debug.

Very cool work, thanks!

except subprocess.TimeoutExpired as e:
error = GitOperationError(
operation="commit", message="Git commit timed out", original_error=e
)
ui.warning(str(error))
return False
except Exception as e:
error = GitOperationError(operation="commit", message=str(e), original_error=e)
ui.warning(f"Error creating undo commit: {e}")
return False

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions