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

[BUG] Error message is appended to current file when E999 syntax error is found #11

Open
CyclisteBx opened this issue Jun 11, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@CyclisteBx
Copy link

Describe the bug

When a "E999 syntax error" is found, the text of the error is appended to the end of the current file. This additional text must be removed by hand to continue.

To Reproduce

Steps to reproduce the behavior:

  1. Open a TextMate file in Python Ruff mode
  2. Type syntaxically incorrect text eg a single line "1 = a"
  3. Save file
  4. The text Error error: Failed to parse test.py:1:1: Invalid assignment targettest.py: 1:1 E999 SyntaxError: Invalid assignment targetFound 1 error. is appended at the end to the opened file
    Untitled

Expected behavior

The error should only appear in the hovering window

Logs

Environment (please complete the following information):

  • OS: macOS 14.5 (23F79)
  • CPU: M3
  • TextMate version: 2.0.23
  • Bundle version: 1.1.5
@CyclisteBx CyclisteBx added the bug Something isn't working label Jun 11, 2024
@vigo
Copy link
Owner

vigo commented Jun 11, 2024

hmm... i have some idea. at that moment, ruff kind of fails, can not parse the input... i'll try to implement kind of workaround

@vigo
Copy link
Owner

vigo commented Jun 11, 2024

well, wrote the same code and it worked?

image

my ruff:

$ ruff --version
ruff 0.4.8

what about yours?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants