PySide Bugzilla Closed for New Bugs

PySide is now a Qt Add-on and uses the Qt Project's JIRA Bug Tracker instead of this Bugzilla instance. This Bugzilla is left for reference purposes.

Bug 736 - Signal/Slot is not working at all
: Signal/Slot is not working at all
Status: CLOSED FIXED
Product: PySide
Classification: Unclassified
Component: QtGui
: HEAD
: PC All
: P2 major
Assigned To: Hugo Parente Lima
:
:
:
  Show dependency treegraph
 
Reported: 2011-03-16 19:17 EET by Luciano Wolf
Modified: 2011-04-01 23:16 EEST (History)
9 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Luciano Wolf 2011-03-16 19:17:33 EET
From mailing list, by Gerald Storer:

I'm trying to get Matplotlib up and running on PySide with some quick
hacks on the PyQt backend and I'm having some trouble with the sliders.

This code:
         QtCore.QObject.connect( self.sliderleft,
                                 QtCore.SIGNAL( "valueChanged(int)" ),
                                 self.sliderright.setMinimum )

produces the following error:
Error calling slot "setMinimum"
TypeError: setMinimum() takes exactly one argument (0 given)


The following test program also creates the error when moving the first
slider:
import sys
from PySide import QtGui,QtCore

def test(*args):
     print len(args),args

app = QtGui.QApplication(sys.argv)

slider = QtGui.QSlider(QtCore.Qt.Horizontal)
slider2 = QtGui.QSlider(QtCore.Qt.Horizontal)

slider.valueChanged[int].connect(test)
slider.valueChanged[int].connect(slider2.setMaximum)

slider.show()
slider2.show()
app.exec_()
sys.exit()

Am I doing something wrong here or is this working as intended?  I know
that setMaximum and setMinimum aren't, strictly speaking, 'slots', but
it works in PyQt and you can use any old Python function for a slot most
of the time.  I've only been playing with PySide for a couple of weeks
so its quite possible I'm missing something obvious.

I know I could implement a function to use as the slot that does the
same thing as setMaximum/setMinimum but I'd like to keep any changes to
the PyQt code to a minimum.
Comment 1 Luciano Wolf 2011-03-16 19:34:44 EET
Rising to P2 as it's a regression.
Comment 2 Gerald 2011-03-17 11:51:32 EET
*** Bug 738 has been marked as a duplicate of this bug. ***
Comment 3 Luciano Wolf 2011-03-17 20:26:53 EET
It affects all architectures.
Comment 4 Hugo Parente Lima 2011-03-22 20:10:53 EET
Fixed in commit:

pyside/7849b4262ff33407274c3aa17747bba43cfd390d
Comment 5 Hugo Parente Lima 2011-04-01 23:16:07 EEST
Closing bug after release of PySide 1.0.1.