<https://lh3.googleusercontent.com/-nAR0P4NJK6E/WAQrdBn_DrI/AAAAAAAABxU/JhV3Oc2rdWcTJgQmH_dU6z471PAM_gd3QCLcB/s1600/%25E9%2580%2589%25E5%258C%25BA_003.png> Found it !!! Line 207 in pylint-leo-rc-ref.txt You committed on 29 Feb.
I changed the test py codes below. Add codecs.utf_8_decode(line), please have a ref @language python @tabwidth -4 import codecs # path = r'c:\leo.repo\leo-editor\leo\test\pylint-leo-rc.txt' path = r'/home/swot/leo-editor/leo/test/pylint-leo-rc.txt' # path = r'/home/swot/app/keyLog.py' f = open(path) s = f.read() f.close() print(len(s)) errors = [] n = 0 for i, line in enumerate(g.splitLines(s)): try: print(' %3s %4s %s' % (i+1, n, line.rstrip())) codecs.utf_8_decode(line) except UnicodeEncodeError: print('**%3s %4s %s' % (i+1, n, len(line.rstrip()))) errors.append(i) n += len(line) print('error lines: %s' % errors) 在 2016年10月17日星期一 UTC+8上午12:56:44,Edward K. Ream写道: > > On Sunday, October 16, 2016 at 10:16:04 AM UTC-5, zhaohe wang wrote: > > Would you tell me which line like plain ascii? >> error == [], when I run your script both wiht pylint-leo-rc.txt and my py >> file. >> > > Hmm. It looks like all the lines of these two files are ascii. So it's > even more of a mystery why you are getting Unicode errors. > > Edward > -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+unsubscr...@googlegroups.com. To post to this group, send email to leo-editor@googlegroups.com. Visit this group at https://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/d/optout.