Skip to content

ThreadedHistory: invoke Buffer.new_history_item() on event loop from background thread #1159

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

Closed
wants to merge 18 commits into from

Conversation

bobhy
Copy link

@bobhy bobhy commented Jun 7, 2020

Fixes issue #1158, and seems to work in Xonsh as well.

Depends on ThreadedHistory and Application being able to rendezvous on same event loop. While this may not be possible for history in general, I think it is an acceptable restriction on ThreadedHistory.

@bobhy
Copy link
Author

bobhy commented Jun 7, 2020

Oh noes! many errors from mypy for code I haven't touched! Has there been a recent change to project build or is there some other trick I need to use to get the PR to pass?

OTOH, this check did find some nits in code I did touch, and I will push fixes for those...

@bobhy
Copy link
Author

bobhy commented Jun 9, 2020

Resolved remaining mypy complaints, but why was this necessary?

@jonathanslenders
Copy link
Member

Thanks for this. The Mypy errors are probably because of a new recent mypy release. I look into that.
(It's intentional that we use the latest mypy all the time, because it helps us discovering new possible bugs.)

Thanks again for the fix! I review it ASAP.

@jonathanslenders
Copy link
Member

Hi @bobhy,

The mypy issues were solved in this PR: #1167 (comment) (slightly differently - I don't like to ignore errors.)

Can you rebase this branch on master, and squash the remaining changes?

@bobhy
Copy link
Author

bobhy commented Jun 17, 2020

My git fu is weak. I have merged from master and will work on the rebase next.

bobhy added 9 commits June 18, 2020 20:38
author Bob Hyman <bob.hyman@gmail.com> 1590979000 -0400
committer Bob Hyman <bob.hyman@gmail.com> 1592529344 -0400

sample to try the scenario.

blacken updated files.

flake8 fixes

More syntax nits from CI.
author Bob Hyman <bob.hyman@gmail.com> 1590979000 -0400
committer Bob Hyman <bob.hyman@gmail.com> 1592530366 -0400

sample to try the scenario.

blacken updated files.

flake8 fixes

More syntax nits from CI.
@bobhy
Copy link
Author

bobhy commented Jun 19, 2020

.. have rebased on master, but still cannot get rebase to squash my subsequent interim commits, need advise or help!

@bobhy
Copy link
Author

bobhy commented Jun 20, 2020

I have successfully squashed all the commits, but now cannot merge that tree into this branch (error is "error: failed to push some refs, hint: Updates were rejected because the tip of squashed branch is behind its remote counterpart")

Will push nice, clean PR to new branch and close this one.

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