-4

i was installing python 3.8.2 + visual studio code. when im done with step to installing python extension. but when im try to code some print ('hello world') things the linter pylint always showed up? and i got syntax error like this

SyntaxError: Non-UTF-8 code starting with '\xff' in file c:\Users\Dell on line 1

what shouold i do, master?

linter pylint is not installed

when i click install button on linter pylint popup

Karl Knechtel
  • 62,466
  • 11
  • 102
  • 153
  • 1
    According to the screenshot, the program works correctly. There are no syntax errors shown. Please clarify your question. – DYZ May 01 '20 at 07:48
  • What happened when you clicked that `Install` button? – Jongware May 01 '20 at 07:48
  • 1
    Obviously, the cause of the error is a space in the path. I think this is not your problem, because the command can be executed correctly after adding the quotation marks. I think you can go to the github page of python-extension to submit an issue – alexzshl May 01 '20 at 11:49
  • Never use spaces in any file or directory name – rioV8 May 01 '20 at 12:53
  • Does this answer your question? ["SyntaxError: Non-ASCII character ..." or "SyntaxError: Non-UTF-8 code starting with ..." trying to use non-ASCII text in a Python script](https://stackoverflow.com/questions/10589620/syntaxerror-non-ascii-character-or-syntaxerror-non-utf-8-code-starting) – Karl Knechtel Mar 16 '23 at 08:36

1 Answers1

0

you can install pylint to help catch bugs in your code. You can find out how to do so here:Linter pylint is not installed

As for the syntax error, its likely to be caused by additional characters added to the code because the text was copied from a word processor, you can rewrite the code to fix the issue. You can find out more about the issue here: SyntaxError: Non-UTF-8 code starting with '\x91'

In the future it might be helpful to search the error code on the internet first before posting a question. e.g. searching "SyntaxError: Non-UTF-8 code starting with" on Google to get answers more quickly since its likely someone else has answered the same question already. Good luck! :>