PTVS icon indicating copy to clipboard operation
PTVS copied to clipboard

Error al utilizar ñ en una cadena interpolada

Open vsfeedback opened this issue 2 years ago • 1 comments

This issue has been moved from a ticket on Developer Community.


[severity:It bothers me. A fix would be nice] Realizando un ejercicio de interpolación de cadenas en python, me di cuenta que al usar una palabre que contenga la letra 'ñ' el ide lanza un SyntaxError: 'utf-8' codec can't decode byte 0xf1. Esto solo ocurre en VS 2022.Trate el mismo ejercicio en vscode y se ejecuto sin problema El codigo que utilice gue el siguiente: print("Soy %s, tengo %i años y mido %f"%("Jose",25,1.76))


Original Comments

Feedback Bot on 7/31/2022, 07:27 PM:

(private comment, text removed)

Feedback Bot on 8/10/2022, 08:25 AM:

(private comment, text removed)


Original Solutions

(no solutions)

vsfeedback avatar Aug 10 '22 17:08 vsfeedback

Hi, can you try going to File -> Save As -> Pick "Save with Encoding..." from the Save dropdown menu -> Pick UTF-8 and see if that issue still persists?

StellaHuang95 avatar Aug 10 '22 18:08 StellaHuang95

Going to close this out. If the issue still persists, please reopen with the information requested. Thanks.😊

StellaHuang95 avatar Sep 06 '22 19:09 StellaHuang95