Skip to main content

Twisted Qt Integration

Project description

PyPI version supported Python versions Travis build status AppVeyor build status Circle build status source on GitHub

Using the Qt5Reactor

Qt5Reactor is compatible with both PyQt5 and PySide2.

Install using pip

pip install qt5reactor

Before running / importing any other Twisted code, invoke:

app = QApplication(sys.argv) # your code to init QtCore
from twisted.application import reactors
reactors.installReactor('qt5')

or

app = QApplication(sys.argv) # your code to init QtCore
import qt5reactor
qt5reactor.install()

Testing

trial --reactor=qt5 [twisted] [twisted.test] [twisted.test.test_internet]

Make sure the plugin directory is in path or in the current directory for reactor discovery to work.

There is also pytest-twisted for use with pytest. You can specify to use the qt5reactor by adding --reactor=qt5reactor.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for qt5reactor, version 0.6.1
Filename, size File type Python version Upload date Hashes
Filename, size qt5reactor-0.6.1-py3-none-any.whl (9.2 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size qt5reactor-0.6.1.tar.gz (22.9 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page