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

Abortable merge, clone, and checkout commands #542

Closed
nelsonni opened this issue Oct 4, 2021 · 0 comments · Fixed by #946
Closed

Abortable merge, clone, and checkout commands #542

nelsonni opened this issue Oct 4, 2021 · 0 comments · Fixed by #946
Assignees
Labels
bug Bug reports or bug fixes feature Feature requests or improvements

Comments

@nelsonni
Copy link
Member

nelsonni commented Oct 4, 2021

Is your feature request related to a problem? Please describe.
Long running processes should be cancelable by the user. For version control systems, the commands that can become long-running are merge, clone, and checkout; the long-running nature of these commands stems from accessing and downloading files from remote repositories.

The need for cancelling asynchronous tasks was identified shortly after Promise was added to the ES2015 standard. However, the AbortController option that was introduced only for the fetch() command and needs to be manually added to other commands (per the article, Aborting a signal: How to cancel an asynchronous task in JavaScript).

Describe the solution you'd like
Since merge, clone, and checkout rely on isomorphic-git, we need to wait for the introduction of isomorphic-git/isomorphic-git#867.

Describe alternatives you've considered
Adding AbortController and AbortSignal parameters to the merge, clone, and checkout functions, which already wrap around the comparable functions in isomorphic-git. However, this option would not be able to interject an abort into the isomorphic-git portion of the process, which contain the potentially long-running code, and therefore only allow for aborting the additional paths wrapped around them.

Additional context
N/A

@nelsonni nelsonni added bug Bug reports or bug fixes feature Feature requests or improvements labels Oct 4, 2021
@nelsonni nelsonni added this to the v1.x.x milestone Oct 4, 2021
@nelsonni nelsonni self-assigned this Oct 4, 2021
@nelsonni nelsonni removed this from the v1.x.x milestone Jun 22, 2022
@nelsonni nelsonni mentioned this issue Oct 6, 2022
@nelsonni nelsonni linked a pull request Oct 6, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug reports or bug fixes feature Feature requests or improvements
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant