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

REPL auto-indentation is wrong with comments #122237

Closed
HarryLHW opened this issue Jul 24, 2024 · 3 comments
Closed

REPL auto-indentation is wrong with comments #122237

HarryLHW opened this issue Jul 24, 2024 · 3 comments
Labels
topic-repl Related to the interactive shell type-bug An unexpected behavior, bug, or error

Comments

@HarryLHW
Copy link
Contributor

HarryLHW commented Jul 24, 2024

Bug report

Bug description:

Currently, the REPL auto indentation is like this:
image

The correct one should be:
image

I am working on a PR to fix this.

CPython versions tested on:

CPython main branch

Operating systems tested on:

macOS

Linked PRs

@HarryLHW HarryLHW added the type-bug An unexpected behavior, bug, or error label Jul 24, 2024
@HarryLHW
Copy link
Contributor Author

This is also incorrect when "#" happens to be the last non-whitespace character.
image

@Wulian233
Copy link
Contributor

Another #124096

2024-09-15 192801

@ambv
Copy link
Contributor

ambv commented Oct 23, 2024

That was fixed in GH-123196.

@ambv ambv closed this as completed Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic-repl Related to the interactive shell type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

4 participants