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

On list prompts, only clearing the last line of the message when cursor is moved #162

Open
whinee opened this issue Apr 12, 2022 · 1 comment
Labels
bug Something isn't working duplicate This issue or pull request already exists

Comments

@whinee
Copy link

whinee commented Apr 12, 2022

OS: Arch Linux x86_64 5.17.1-arch1-1

Inquirer version: 2.9.2

What I did:
I placed a newline at the message of a list prompt. See the following code:

import inquirer

answer = inquirer.list_input(
    message="This will modify the file.\nAre you sure?",
    choices=[
        ["Yes", "y"],
        ["No", "n"],
        ["Cancel", "c"],
    ]
)
print(answer)

What did I expect:
For the whole message to clear when moving the cursor.

What did I see:
When I ran the code given above, it will display a normal list prompt. However, when I move the cursor, only the last line of the message is being cleared.
Upon further inspection, the same is true for messages with more newlines in it.

Additional Information:
I have not tested this with other prompts. I am using kitty terminal.

@Cube707 Cube707 added the bug Something isn't working label Dec 18, 2022
@Cube707
Copy link
Collaborator

Cube707 commented Dec 18, 2022

Duplicate of #26

@Cube707 Cube707 marked this as a duplicate of #26 Dec 18, 2022
@Cube707 Cube707 added the duplicate This issue or pull request already exists label Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants