Remove Python GI API version warnings

- reported in Clock-19 testing.
This commit is contained in:
James Cameron 2017-05-30 14:10:23 +10:00
parent 2c3d1d0707
commit c26c902dc7

View File

@ -18,6 +18,9 @@ import os
import logging import logging
from gettext import gettext as _ from gettext import gettext as _
import gi
gi.require_version('Gtk', '3.0')
from gi.repository import Gio from gi.repository import Gio
from gi.repository import Gtk from gi.repository import Gtk
from gi.repository import Gdk from gi.repository import Gdk
@ -25,6 +28,7 @@ from gi.repository import GObject
_HAS_GST = True _HAS_GST = True
try: try:
gi.require_version('Gst', '1.0')
from gi.repository import Gst from gi.repository import Gst
Gst.init(None) Gst.init(None)
Gst.parse_launch('espeak') Gst.parse_launch('espeak')