-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Server doesn't consider a file with no extension #12539
Comments
Yeah, that's happening because a file without an extension is excluded as it's not in the inclusion set. This is a side effect of 0bb2fc6. Maybe in the LSP context, we should look at the |
I just wasted several hours trying to debug why the Ruff server wasn't working for me in Zed, where I was editing extension-less Python scripts that Ruff apparently silently skips. There really needs to be a way for the server to consider these files to make it generally useful. |
Apologies for the trouble, I can make this a priority. Thanks for sharing your experience. |
Thanks for the fix! Sorry if I came across as a bit rude, I was just frustrated because according to all the logs I could find everything seemed to be fine, but it still wasn't working. Maybe it would be useful to log ignored files at debug level? |
No need to apologize, sharing your experience is helpful and bugs are always considered high priority :) The PR that fixes this also added debug level log for cases where this kind of exlusion happens. |
consider this minimal example
#!/usr/bin/python3 target = None if target != None: print ("target's not none")
if the file that contains the script has a .py extension it will display the following
and if i remove the .py extension ,no warnings will display nor file can be formatted even though vscode detects
that it's a python file.
ruff version: 0.5.5
Python version: 3.12.4
vscode version: 1.91.1
OS: archlinux
The text was updated successfully, but these errors were encountered: