Installation#

  • Python Versions: py_gql supports CPython 3.5 and newer.

  • Platforms: Unix/Posix, MacOS X.

  • Dependencies: py_gql has no direct dependency.

Installing from PyPI#

A source distribution and universal wheel are available on PyPI.

To install, run:

pip install py-gql

Cython#

Warning

This is experimental and might be removed in the future. It may also present some rough edges.

The default pip install should install the universal wheel, however for some extra performance in production py-gql’s setup.py can detect the presence of Cython and compile (i.e. cythonize) its own code with the system’s default C compiler. This provides significant performance improvents almost for free.

To benefit from this, run:

pip install cython
pip install --no-binary :all: py-gql

Notes

  • The code is not written or optimized for Cython i.e. we use the pure python compilation mode.

  • Setting the CYTHON_TRACE environment variable will instruct Cython to compile with line trace information useful for profiling and debugging. See this document for more details.

  • You need Xcode Command Line Tools installed on MaxOS X for this to work.

Installing from source#

py-gql’s source code is hosted on Github.

You can install the development from source after either cloning locally:

git clone git@github.com:lirsacc/py-gql.git py_gql
cd py-gql
pip install -e .

Or you can directly install through pip VCS support:

pip install git+ssh://git@github.com/lirsacc/py-gql.git@master