[PyKDE] qsqlcursor lifetime for qdatatable

Andreas Kloeckner kloeckner at rtna.daimlerchrysler.com
Tue Jun 25 20:44:01 BST 2002

hi all,

  i just discovered another problem in pyqt, or rather in the
  cooperation of qt's and pyqt's interface. the qsqlcursor that
  you pass on to qdatatable's constructor is supposed to be available 
  throughout the whole lifetime of the qdatatable. if you just create
  a qsqlcursor locally and pass it to the constructor, you'll soon run
  into a segfault because the garbage collector has gotten rid of

  i propose that we redefine the semantics of qdatatable in such a way
  that the table always takes posession of its cursor and frees it
  itself. (possible by means of setCursor with the autoDelete parameter)
  i would be willing to provide a patch for this, if there is
  any demand.

  i have one more question: how can you avoid the lengthy (~1.5 h)
  complete recompile if you just make *one* change to *one* .sip file?
  "make" doesn't do the trick for me, it just does nothing.


More information about the PyQt mailing list