masterking32 / MasterHamsterKombatBot

Master Hamster Kombat Bot is a Python-based automation tool specifically designed for the game Hamster Kombat. This bot is capable of performing all in-game tasks, including auto-tapping, cipher tasks, and purchasing the best cards on your behalf. It's a free and fully automated farming bot that enhances your Hamster Kombat gaming experience.
https://masterking32.com
Apache License 2.0
267 stars 88 forks source link

Cyrillic character sent by game instead of Latin character #239

Closed tboy1337 closed 2 weeks ago

tboy1337 commented 2 weeks ago
[Master HamsterKombat Bot][INFO] 2024-08-27 02:03:55 [Account 10] Best upgrade is Сoindesk with profit 193 and price 159.84k, Level: 14
--- Logging error ---
Traceback (most recent call last):
  File "C:\Program Files\Python312\Lib\logging\__init__.py", line 1163, in emit
    stream.write(msg + self.terminator)
  File "C:\Program Files\Python312\Lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)[0]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
UnicodeEncodeError: 'charmap' codec can't encode character '\u0421' in position 85: character maps to <undefined>
Call stack:
  File "C:\Users\FARM\Downloads\Hamster Kombat\MasterHamsterKombatBot-main-7\main.py", line 1554, in <module>
    main()
  File "C:\Users\FARM\Downloads\Hamster Kombat\MasterHamsterKombatBot-main-7\main.py", line 1548, in main
    asyncio.run(RunAccounts())
  File "C:\Users\FARM\Downloads\Hamster Kombat\MasterHamsterKombatBot-main-7\main.py", line 1515, in RunAccounts
    account.Start()
  File "C:\Users\FARM\Downloads\Hamster Kombat\MasterHamsterKombatBot-main-7\main.py", line 1409, in Start
    if not self.BuyBestCard():
  File "C:\Users\FARM\Downloads\Hamster Kombat\MasterHamsterKombatBot-main-7\main.py", line 718, in BuyBestCard
    log.info(
Message: '[Account 10] Best upgrade is Сoindesk with profit 193 and price 159.84k, Level: 14'
Arguments: ()
[Master HamsterKombat Bot][INFO] 2024-08-27 02:03:55 [Account 10] Attempting to buy the best card...

error

I know this is because of the updates in https://github.com/masterking32/MasterHamsterKombatBot/pull/238 which have been fixed by adding kwargs['encoding'] = 'utf-8' but it might be useful to know.

masterking32 commented 2 weeks ago

We don't have any support for PRs, Just Merged PRs can be checked.