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 530 - Importing division from future breaks QPoint division
: Importing division from future breaks QPoint division
Status: CLOSED FIXED
Product: PySide
Classification: Unclassified
Component: QtCore
: HEAD
: Macintosh Mac OS
: P3 normal
Assigned To: Hugo Parente Lima
:
:
:
  Show dependency treegraph
 
Reported: 2010-12-06 18:40 EET by Daniel Ashbrook
Modified: 2011-01-21 15:44 EET (History)
8 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Ashbrook 2010-12-06 18:40:42 EET
The following code:

from __future__ import division
from PySide.QtCore import QPointF
QPointF(5, 10) / 2

Throws the exception: "TypeError: unsupported operand type(s) for /:
'PySide.QtCore.QPointF' and 'int'".

However, commenting the "from __future__" line allows it to work.

Similarly, running the code (without the future line) with "python -Qnew"
causes the same failure.

The same breakage occurs with QPoint as well.
Comment 1 Matti Airas 2010-12-07 06:41:24 EET
Thanks for the bug! I'm prioritizing this P3 - the issue will be taken into our
upcoming sprints.
Comment 2 Hugo Parente Lima 2011-01-07 17:54:50 EET
Fixed in commit:

shiboken/635ae97b304dae295bf15d666c06c6e67660629b
Comment 3 renato filho 2011-01-21 15:44:41 EET
release beta4