Questions tagged [python-sip]

SIP is a python library used to port native C/C++ APIs into Python. SIP was originally written to manage the complex interfaces required by PyQT; however, it has general usage for anyone wishing to port C/C++ code into Python.

SIP is a python library used to port native C/C++ APIs into Python. SIP was originally written to manage the complex interfaces required by PyQT; however, it has general usage for anyone wishing to port C/C++ code into Python.

138 questions
5
votes
1 answer

python readthedocs how to satisfy the requirement sip (or pyqt)

I want to publish the documentation of my project https://bitbucket.org/oaltun/opn in readthedocs.org. The build fails. There are different errors shown in the log https://readthedocs.org/builds/opn/2247789/ , but the first is "no module named…
O. Altun
  • 685
  • 7
  • 20
5
votes
1 answer

Sharing widgets between PyQT and Boost.Python

I was wondering if it was possible to share widgets between PyQt and Boost.Python. I will be embedding a Python interpreter into an application of mine that uses Qt. I would like users of my application to be able to embed their own UI widgets into…
Kranar
  • 1,136
  • 2
  • 13
  • 24
4
votes
3 answers

PyQt5 installation error (QtCore Module Error: Unable to create the C++ code)

I'm trying to install PyQt5 on my PC to have access to QtDesigner. I'm facing following error during the installation: $ python3 configure.py --qmake=/usr/local/Cellar/qt/5.10.1/bin/qmake --sip=/usr/local/Cellar/sip/4.19.8_2/bin/sip Querying qmake…
A.Midany
  • 201
  • 1
  • 5
  • 16
4
votes
1 answer

CMake "OBJECT" library: clang not linking properly

I have a shared library (which currently compiles, loads and runs) mylib.so. From within this library, I want to use a new function (register it in another external library). The signature is bool my_function(const QVariant *, PyObject **). This new…
Matthias Kuhn
  • 1,162
  • 2
  • 14
  • 42
4
votes
2 answers

How to force using 64 bit python on Mac OS X?

I got the following error when compiling sip with --arch x86_64 option. prosseek:siplib smcho$ python -c 'import sip; print sip' Traceback (most recent call last): File "", line 1, in ImportError: dlopen(./sip.so, 2): no suitable image found. …
prosseek
  • 182,215
  • 215
  • 566
  • 871
4
votes
1 answer

How can access to pixel data with PYQt' QImage scanline()

I need to access the pixel data in a qimage object with PyQt4. The .pixel() is too slow so the docs say to use the scanline() method. In c++ I can get the pointer returned by the scanline() method and read/write the pixel RGB value from the…
risinglf
  • 41
  • 1
  • 2
3
votes
0 answers

python.exe has stopped working

Yesterday I succesfully installed sip, pyqt4 and vtk (including python's bindings) on a 64-bit Windows 7 virtual machine. However, when I do 'import vtk', a dialog pops up saying 'python.exe has stopped working'. The Event Viewer shows the error is…
user11869
  • 1,083
  • 2
  • 14
  • 29
3
votes
3 answers

Python: how to deal with several .pyd dependencies with the same name?

I have in my python workspace two Modules which need sip.pyd Module1.pyd needs sip.pyd (which implements v 8.0-8.1) Module2.pyd needs sip.pyd (another file, that implements v6.0) So I can't just choose the newer one, it doesn't work: I have to keep…
gon2024
  • 33
  • 4
3
votes
0 answers

Working with `PyQt5.QtCore.QLibrary` in Python: How to cast a `sip.voidptr` to a function?

I am trying to port (some of) the logic of void QgsPluginManager::getCppPluginsMetadata() from QGIS from C++ to Python. In C++, the relevant section looks about as follows: /* `lib` is a path (string) to a QGIS plugin shared object file, e.g.…
s-m-e
  • 3,433
  • 2
  • 34
  • 71
3
votes
0 answers

Installing SIP for Python 2.7 on Mac

I am currently installing ROS Melodic on my Mac and the installation requires to have python SIP library. Here is where the problem comes; when I try to pip install sip in my terminal I get the following response: Defaulting to user installation…
3
votes
1 answer

can not build qtermwidget from source

I'm trying to build qtermwidget from source, but it gives me error. I've successfully built lxqt-build-tools and then installed pyqt5 from both pip3 and apt: sudo -H pip3 install -U pyqt5 pyqtwebengine sudo apt install python3-sip-dev…
3
votes
2 answers

ImportError: No module named sip (python2.7 PyQt4)

I'm currently using Ubuntu 18.04 LTS. I'm trying to install a program that need PyQt4 and QtWebKit, so a manual installation is necessary as QtWebKit have been excluded from PyQt4. I downloaded sip 4.19.12 (with 4.19.14 installation of PyQt4 fails)…
Gabriel G.
  • 555
  • 1
  • 3
  • 13
3
votes
1 answer

PyQt5's PyQt5.sip File is Not Generated by the SIP Library

I'm building SIP 4.19.12 and PyQt 5.11.2 on Windows 10 with Visual Studio 2017. I'm planning to do that for Python x86 2.7.15. I downloaded the versions above and extracted them, installed enum34 with pip, the configured SIP with python configure.py…
Sam
  • 135
  • 1
  • 11
3
votes
0 answers

python 2.7 / pyqt5 and pyinstaller : sip module error

after trying pyqt5 with python3.+ i had some problems with the code than i used python2.7 + pyqt5(for python2.7) and everything worked fine from pycharm and when i run the script from cmd. now the problem with pyinstaller pyqt4 / python 2.7 :…
seghier
  • 167
  • 1
  • 2
  • 11
3
votes
3 answers

How to make super() work in this non-ideal situation in python?

class ClsOne(object): def __init__(self): super(ClsOne, self).__init__() print "Here's One" class ClsTwo(ClsOne): def __init__(self): super(ClsTwo, self).__init__() print "Here's Two" class ClsThree(ClsTwo):…
Calvin
  • 43
  • 5
1
2
3
9 10