Skip to content

fix unicode issues#1817

Closed
CapCap wants to merge 2 commits intoPokemonGoF:devfrom
CapCap:dev
Closed

fix unicode issues#1817
CapCap wants to merge 2 commits intoPokemonGoF:devfrom
CapCap:dev

Conversation

@CapCap
Copy link
Copy Markdown
Contributor

@CapCap CapCap commented Jul 30, 2016

Short Description:

Fixes:

- #1814

@CapCap CapCap closed this Jul 30, 2016
@CapCap CapCap reopened this Jul 30, 2016
@vieira
Copy link
Copy Markdown

vieira commented Jul 30, 2016

The problem is that the log function is sometimes called with an already decoded utf8 str while some other times it is called with an unicode sequence that needs to be decoded before print.

def log(string, color='white'):
    try:
        string = string.decode('utf8')
    except UnicodeEncodeError:
        pass

<rest of the original code>

This is enough to fix the problem and make log work with both str and unicode sequences.

@DayBr3ak
Copy link
Copy Markdown
Contributor

190640f makes this irrelevant

@vieira
Copy link
Copy Markdown

vieira commented Jul 30, 2016

@DayBr3ak still getting errors if the initial location contains any special characters.

@vieira
Copy link
Copy Markdown

vieira commented Jul 30, 2016

#1825 should fix the issue with the initial location.

hoanghuynh pushed a commit to hoanghuynh/PokemonGo-Bot that referenced this pull request Sep 28, 2016
* prevent multiple map-updates

In case a map-update took longer than 5s, multiple updates were started, this is a simple fix so there is always only one map-update running

* updated formatting

* updated formatting ^2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants