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

Keep support for prompt_toolkit 2 #1197

Merged
merged 2 commits into from
Jul 8, 2020
Merged

Keep support for prompt_toolkit 2 #1197

merged 2 commits into from
Jul 8, 2020

Conversation

meeuw
Copy link
Contributor

@meeuw meeuw commented Jul 6, 2020

Description

It turns out that Fedora 32 doesn't have prompt-toolkit 3 yet :-(

Seems we still support Prompt Toolkit 2 without any code changes (the tests don't fail on my system).

Checklist

  • I've added this contribution to the changelog.rst.
  • I've added my name to the AUTHORS file (or it's already there).
  • I installed pre-commit hooks (pip install pre-commit && pre-commit install), and ran black on my code.
  • Please squash merge this pull request (uncheck if you'd like us to merge as multiple commits)

@meeuw meeuw requested review from j-bennet and laixintao July 6, 2020 19:23
@codecov-commenter
Copy link

codecov-commenter commented Jul 6, 2020

Codecov Report

Merging #1197 into master will decrease coverage by 0.03%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1197      +/-   ##
==========================================
- Coverage   83.89%   83.85%   -0.04%     
==========================================
  Files          21       21              
  Lines        2552     2552              
==========================================
- Hits         2141     2140       -1     
- Misses        411      412       +1     
Impacted Files Coverage Δ
pgcli/pgstyle.py 64.00% <ø> (ø)
pgcli/main.py 76.07% <0.00%> (-0.14%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 41dd24e...345a527. Read the comment docs.

setup.py Outdated Show resolved Hide resolved
setup.py Outdated Show resolved Hide resolved
@meeuw
Copy link
Contributor Author

meeuw commented Jul 7, 2020

Whoops thanks for checking this @laixintao that was my idea (to include pt 3). Fixed in 36e6047

@meeuw meeuw requested a review from laixintao July 7, 2020 18:53
@j-bennet
Copy link
Contributor

j-bennet commented Jul 8, 2020

@meeuw Did you verify that pgcli can work with both prompt_toolkit 2.x and 3.x? I thought they are not compatible.

@laixintao
Copy link
Member

@meeuw Did you verify that pgcli can work with both prompt_toolkit 2.x and 3.x? I thought they are not compatible.

I think it's compatible, I didn't change any code while upgrading from 2.x: https://github.com/dbcli/pgcli/pull/1149/files , and I checked the changelog.

Can @jonathanslenders confirm?

Copy link
Contributor

@j-bennet j-bennet left a comment

Choose a reason for hiding this comment

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

You are right @laixintao , it looks like the only breaking changes are in get_event_loop and dialogs, and we're not using those calls in pgcli:

https://python-prompt-toolkit.readthedocs.io/en/stable/pages/upgrading/3.0.html

This is good.

@j-bennet j-bennet merged commit 80bf05a into master Jul 8, 2020
@j-bennet j-bennet deleted the meeuw/prompt-toolkit-2 branch July 8, 2020 19:28
@meeuw
Copy link
Contributor Author

meeuw commented Jul 9, 2020

🎉 yes, I've checked that pgcli still works with pt-2. Thanks a lot for merging!

laixintao added a commit that referenced this pull request Sep 14, 2020
This was introduced by: e9c9707 (  Use
InputMode.REPLACE_SINGLE (#1208) )

see also: #1197
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.

5 participants