QBluetoothUuid Constructor missing

Phil Thompson phil at riverbankcomputing.com
Thu Nov 18 15:49:48 GMT 2021


On 18/11/2021 15:00, Marko Luther wrote:
> Dear all,
> 
> according to the Qt documentation
> 
> https://doc-snapshots.qt.io/qt6-dev/qbluetoothuuid.html
> 
> there should be a constructor for QtBluetooth.QBluetoothUuid (marked
> with [since 5.4]) that takes an QBluetoothUuid::DescriptorType
> 
> QBluetoothUuid::QBluetoothUuid(QBluetoothUuid::DescriptorType uuid)
> 
> but this constructor seems not to be available under PyQt6.
> 
> # python3.10
> Python 3.10.0 (v3.10.0:b494f5935c, Oct  4 2021, 14:59:20) [Clang
> 12.0.5 (clang-1205.0.22.11)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> from PyQt6 import QtBluetooth
>>>> QtBluetooth.QBluetoothUuid(QtBluetooth.QBluetoothUuid.DescriptorType.ClientCharacteristicConfiguration)
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> TypeError: arguments did not match any overloaded call:
>   QBluetoothUuid(): too many arguments
>   QBluetoothUuid(int): argument 1 has unexpected type 'DescriptorType'
>   QBluetoothUuid(Tuple[int, int, int, int, int, int, int, int, int,
> int, int, int, int, int, int, int]): argument 1 has unexpected type
> 'DescriptorType'
>   QBluetoothUuid(str): argument 1 has unexpected type 'DescriptorType'
>   QBluetoothUuid(QBluetoothUuid): argument 1 has unexpected type
> 'DescriptorType'
>   QBluetoothUuid(QUuid): argument 1 has unexpected type 
> 'DescriptorType'
>>>> QtBluetooth.QBluetoothUuid.DescriptorType.ClientCharacteristicConfiguration
> <DescriptorType.ClientCharacteristicConfiguration: 10498>
> 
> Also the constructor
> 
> QBluetoothUuid::QBluetoothUuid(QBluetoothUuid::CharacteristicType uuid)
> 
> seems to be missing.
> 
> Am I wrong?
> Marko

Missing from PyQt5 as well. Should be fixed in the next snapshots.

Thanks,
Phil


More information about the PyQt mailing list