Codeintel2: Python3 compatibility: TextInfo encodings

TextInfo initially opens an unencoded file (bytes) then it tries to
find the encoding from small portions of the file (head and tail)
If it finds the encoding it decodes the file and further tries to
find out more information about it (like the language, etc.) This
time, however, the content is in Unicode form. The patch adds both
versions of the checkers.
Sitelib: Python3 compatibility: mimetools.Message was renamed to email.Message
Python 3 compatibility: Process.py compatible with both Python 2 and Python 3
Python3: string module doesn't have lower() in Python 3