Skip to content
[Unmaintained: Use PyGObject instead] GTK+ / GObject Introspection Bindings for PyPy.
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
benchmarks benchmark: add some require_version Jan 31, 2016
pgi overrides: backport get_variant() annotation workaround Feb 15, 2019
.gitignore Update .gitignore Mar 26, 2014
COPYING Relicense to LGPL-V2.1+ Dec 5, 2012 Make the matplotlib example work under PyPy Jul 11, 2014
NEWS release Jun 25, 2018
README.rst Remove pep8/pyflakes tests, broken and outdated Jan 5, 2019


PGI - Pure Python GObject Introspection Bindings

GObject Introspection bindings written in pure Python using ctypes and cffi (optional). API compatible with PyGObject.

Development Status:

WARNING: Lots of things are not implemented/supported.

See the 'examples' directory for working examples. Anything else will probably not work.


License: LGPL 2.1+



from pgi.repository import Gtk, GObject

or (preferred)

import pgi
from gi.repository import Gtk, GObject

Search paths

Typelibs will be loaded from paths in the environment variable GI_TYPELIB_PATH and /usr/lib/girepository-1.0/.

Shared libraries from paths in LD_LIBRARY_PATH and the default system search paths (see dlopen(3)).


PGI docs:
Autogenerated GI docs:

  • ./ test will run unit tests using PGI and PyGObject
  • ./ test --pgi-only to skip PyGObject tests
  • ./ test --filter=StructTest to run tests which include StructTest (regexp)

./tests/libs/ includes additional libraries that will be used for testing if present. Call make in ./tests/libs/ to build them.

  • ./ quality will run pep8 and pyflakes tests
  • ./ coverage will create a test coverage report
You can’t perform that action at this time.