[Sugar-devel] Port to TelepathyGLib

James Cameron quozl at laptop.org
Tue May 15 18:26:26 EDT 2018


On Tue, May 15, 2018 at 11:02:49PM +0530, Rahul Bothra wrote:
> - Rahul will also contact upstream(s) of Telepathy to ask their
>   plans of a Python 3.x Telepathy version

Telepathy upstream suggested using PyGObject API, available for both
Python 2 and Python 3.

https://lazka.github.io/pgi-docs/#TelepathyGLib-0.12

On Ubuntu 18.04 install package gir1.2-telepathyglib-0.12 and then
this test passes;

$ python2
>>> from gi.repository import TelepathyGLib

$ python3
>>> from gi.repository import TelepathyGLib

For the moment, development can happen with your static binding port
of Telepathy, but we should not plan to rely on it, because
downstreams already have a Python 3 Telepathy in the form of
TelepathyGLib.

So we must port.

https://github.com/orgs/sugarlabs/projects updated with new "Port to
TelepathyGLib"
https://github.com/orgs/sugarlabs/projects/4

<quote>
Change from

	from telepathy.foo import bar

to

	import gi
	gi.require_version('TelepathyGLib', '0.12')
	from gi.repository import TelepathyGLib

Prerequisite for Port to Python 3.
</quote>

-- 
James Cameron
http://quozl.netrek.org/


More information about the Sugar-devel mailing list