-
Notifications
You must be signed in to change notification settings - Fork 330
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
Refresh open file on pull #1090
Conversation
Currently doing a pull does not update the contents of open files like switches branches does. Fixes jupyterlab#1086
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.
Thanks @ajbozarth
There is a bug in the existing method. And the call order needs to be set up a bit differently to ensure we get the correct value.
-
Store the top commit hash as we don't control its update - it may happen after the pull and before the changed files are requested.
-
We should wait for the task
const data = await this._taskHandler.execute
-
Get the changed files and revert
-
await for
this.refreshBranch()
Looking at the test failure, we need to check if |
@fcollonval I made the updates you suggested. I original had the top commit stored first, but I stream-lined my changes when I found that the |
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.
Thanks a lot @ajbozarth
@fcollonval Thanks for the merge, given I have users waiting on this fix what do you think the timeline is on releasing it? It looks like master has at least one feature merged since the last patch release so I assume the next release would have to be a minor release. In which case would we be waiting for the couple of recent open PRs to merge first? |
Release is in progress @ajbozarth |
Currently doing a pull does not update the contents of open files
like switching branches does.
This runs the same function to update files as switching branches but instead of diffing the branches it diffs the previous top commit to the new HEAD.
Fixes #1086