UnicodeDecodeError: Can't create a new project with Cocos new command


#1

Hi, I am new in Cocos, I just installed cocos2d-x 3.16 . I ran the python setup file and all the paths were configured correctly

Now, I want to create a new project in Cocos2d-x with the Cocos new command, but the project is not created and only appears a Python Unicode error message.

I’m using python 2.7.x because I was asked by an installation tutorial that I consulted, should I install a version 3.x of Python to recognize the encoding of those files?. Here is a pic of the error message:

error cocos


#2

Python 2.7 is fine. You might just need to make sure you are using UTF-8 on your system. Perhaps you are using a different encoding. Search these forums for UTF-8 and there are many answers.


#3

Hi, thanks, there are many answer of UTF-8 but I don’t know how to change the encode of my PC. I’m a novice in this.


#4

On Windows, I think it is an environment variable. Perhaps in System, Advanced someplace. I’d have boot up a Vm and I left my drive at the office. I can follow up in the morning.


#5

Ok, Thank you very much.


#6

Hello I don’t want to seem rude or demanding but I already have 2 weeks waiting for a solution to this problem. Two weeks ago I installed Cocos2d-x but I could not even create a new project to learn how to use it due to that UnicodeDecodeError. Is there someone in the forum who knows how to change the coding of my pc?