python - Colorama green and yellow does not work -


from colorama import fore, init, style  init(convert=true)  print(fore.green + "green") print(fore.yellow + "yellow") print(fore.red + "red") print(fore.black + "black") print(fore.blue + "blue") print(fore.cyan + "cyan")  print(style.reset_all + '')  input() 

output

what can fix it? using windows 10

since mentioned running in cmd works try using peice of code, had similar issue when using colorama. force program open in cmd fix error.

if "started_with_prompt" not in sys.argv:     cmd = 'cmd /c "'+sys.executable+' '+" ".join(sys.argv)+' started_with_prompt"'     os.system(cmd)     sys.exit() 

Comments