https://bugzilla.wikimedia.org/show_bug.cgi?id=64958
Bug ID: 64958 Summary: representation string fails for page object Product: Pywikibot Version: core (2.0) Hardware: All OS: All Status: NEW Severity: normal Priority: Unprioritized Component: General Assignee: Pywikipedia-bugs@lists.wikimedia.org Reporter: info@gno.de Web browser: --- Mobile Platform: ---
sample:
import pwb import pywikibot as py s = py.Site('af') p = py.Page(s, 'user:xqt') p
Page(Gebruiker:Xqt)
s = py.Site('fa') p = py.Page(s, 'user:xqt') p
Traceback (most recent call last): File "<pyshell#12>", line 1, in <module> p File "pywikibot\page.py", line 224, in __repr__ self.title().encode(config.console_encoding)) File "C:\Python27\lib\encodings\cp850.py", line 12, in encode return codecs.charmap_encode(input,errors,encoding_map) UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-4: character maps to <undefined>