@all, mainly @martiinsiimon take a look. The new unittests are still failing, but only! when all tests are run at the single time as in CI. I've spent couple of days dealing with this whole pain, so leaving them to 'error' for now so I can rest and keep some basic sanity :) Martin, you can take a look at those if you wish.
Commit messages describe the problem well enough. Bottom point -> we neglected (when making stuff bilingual) to consider what happens if we use unicode characters for a11y names - on two levels - 1. directly (in code) 2. when they pop from pyatspi. Most favorite example goes our beloved '…'
TestUnicodeNames: Covered the most troublesome py2 __future vs. py3 cases
i18y: much pain. Fixes findChild not finding anyting with unicode chars (like '…')..
Predicate uses rather messy methods to obtain a final search-against string from i18y and since we started using __future for the bilingual dogtail this was broken, we would search up unicode against its plain str() variant comming from pyatpsi. Took some search on 'where' this gets doomed, finally this looks like the point we can 'encode' it back for py2, while str(...) will work just fine in py3 (as usual).
Updated logging and debugName creation according to the failed unittests.
Discovered py2 unicode pain within Tree and elsewhere, if we get unicode characters from at-spi and are (now) using the __future unicode_character import. We're using __future, but that only makes directly declared strings unicode. Then we get say Node.name as plain str in py2. Should it contain unicode char, for example '…' an attempt to cat with declared strings that are unicode (and cannot be otherwise thanks to __future), we're doomed. Attempted solution: doing plain str() while we use __future seems to make things click as long as all parts of the concat are str(). Not absolutely sure why - but on the good side, works the same in both python versions without having to do .decode() on str strings and having to catch exception for python3. Sideline: unicode and py2 with py3 - lot's of pain.