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

Do not duplicate '=' when tab completing a kwarg with the cursor on '=' #10547

Merged
merged 1 commit into from
May 14, 2017

Conversation

bartz
Copy link
Contributor

@bartz bartz commented May 11, 2017

Fix for #9404:

Adjust completion text when the last character is an '=' and the cursor is on a '='

@@ -43,6 +43,11 @@ def _elide(string, *, min_elide=30):
return '{}.{}\N{HORIZONTAL ELLIPSIS}{}.{}'.format(parts[0], parts[1][0], parts[-2][-1], parts[-1])


def _adjust_completion_text_based_on_context(text, body, offset):
Copy link
Member

Choose a reason for hiding this comment

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

Could the naming be a bit clearer about what this function does? 'adjust based on context' is rather generic. Or maybe add a comment explaining the idea.

@takluyver
Copy link
Member

Thanks. Do you also want to add a brief description in docs/source/whatsnew/pr/, to go into the release notes.

@Carreau
Copy link
Member

Carreau commented May 14, 2017

Thanks. Do you also want to add a brief description in docs/source/whatsnew/pr/, to go into the release notes.

I think we can do that ourself when we write the release notes. It should be about time to release IPyhon 6.1 in a week or so as I believe we have a couple of bugfixes.

@Carreau Carreau merged commit 5c21c0a into ipython:master May 14, 2017
@Carreau Carreau added this to the 6.1 milestone May 29, 2017
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.

3 participants