-
Bug
-
Resolution: Unresolved
-
P4: Low
-
None
-
6.4.3
-
None
Mypy does not recognize components of QColorConstants.
bug.py:
from PySide6.QtGui import QColorConstants
print(QColorConstants.Red)
Output:
(project_3.11) C:\code\project>python bug.py PySide6.QtGui.QColor.fromRgbF(1.000000, 0.000000, 0.000000, 1.000000) (project_3.11) C:\code\project>mypy bug.py bug.py:3: error: "Type[QColorConstants]" has no attribute "Red" [attr-defined] Found 1 error in 1 file (checked 1 source file)
In fact, QtGui.pyi looks incomplete:
class QColorConstants(Shiboken.Object): class Svg(Shiboken.Object): ...
Related: https://bugreports.qt.io/browse/PYSIDE-1224
namespace QColorConstants
{
// Qt::GlobalColor names
constexpr inline QColor Color0 {QColor::Rgb, 0xff * 0x101, 0x00 * 0x101, 0x00 * 0x101, 0x00 * 0x101};
- relates to
-
PYSIDE-1603 Missing signals in stubs
-
- Closed
-
For Gerrit Dashboard: PYSIDE-2263 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
543006,3 | pyi: support class attributes | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
543227,2 | pyi: support class attributes | 6.6 | pyside/pyside-setup | Status: MERGED | -1 | 0 |
543350,2 | pyi: support class attributes | tqtc/lts-6.5 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
543415,3 | pyi: support class attributes | tqtc/lts-6.2 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
551585,2 | pyi: Fix syntax error in class attributes | 6.7 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
551593,2 | pyi: Fix syntax error in class attributes | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
551687,2 | pyi: Fix syntax error in class attributes | 6.6 | pyside/pyside-setup | Status: MERGED | -1 | 0 |
551717,2 | pyi: Fix syntax error in class attributes | tqtc/lts-6.5 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
551750,5 | pyi: Fix syntax error in class attributes | tqtc/lts-6.2 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
551812,3 | pyi: Fix syntax error in class attributes | 6.6.3.1 | pyside/pyside-setup | Status: MERGED | -1 | 0 |
552073,2 | pyi: Fix syntax error in class attributes | tqtc/6.6.3.1 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
556297,4 | pyi: avoid ellipsis on classes with attributes | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
556315,2 | pyi: avoid ellipsis on classes with attributes | 6.7 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
556493,3 | pyi: avoid ellipsis on classes with attributes | tqtc/lts-6.5 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |
582871,3 | pyi: avoid ellipsis on classes with attributes | tqtc/lts-6.2 | pyside/tqtc-pyside-setup | Status: MERGED | -1 | 0 |