sdvillal / whatami

Easily provide python objects with self-identification
Other
9 stars 1 forks source link

Full unicode support in python 2 #17

Closed sdvillal closed 6 years ago

sdvillal commented 6 years ago

I would rather ditch python 2 than supporting this.

Two main issues here: python 2 default encoding being "ascii" (so implicit conversions simply fail and one needs to litter code with decodes and encodes) and whatami relying too much in using repr + unicode repr adding these pesky 'u' (which litter identifiers and therefore would break old identifiers and warrant a major version update). By whatami nature, forcing these "u" in identifiers would also split up ids in py3 and py2, which should be avoided at all costs.

So this is a wontfix and the solution should be to move downstream dependants to use python 3 as everyone should be already doing these days.

Some basic literature:

sdvillal commented 6 years ago

Another problem is with arpeggio and text, we would need to override how terminals are handled. There is a py2 unicode experimenting branch that shows how this could be done, but as anything else, it just introduces too much variance and corner cases.