← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #385878]: UnicodeEncodeError ( 'ascii' codec can't encode character u'\u2018' in position 1: ordinal not in range(128) )

 

Question #385878 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/385878

Description changed to:
Hi. Pls Help.

I'm receiving error "UnicodeEncodeError ( 'ascii' codec can't encode character u'\u2018' in position 1: ordinal not in range(128) )"
when I run the code below:

I receive the error on line "print(text)".

    Settings.OcrTextRead = True
    reg=find(Pattern("1473260102302.png").targetOffset(-9,50))
    
    text = reg.text()
    print(text)             ********I receive error here*******

    if "1080" in text:
        if "59.94" in text:
            print("it is 1080 and 59.94")
        else:
            print("Not 59.94")
    else:
        print("Not 1080")

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.