PyQt3D: "None" enum members

Florian Bruhin me at the-compiler.org
Mon May 4 17:18:33 BST 2020


Hey,

From PyQt3D-5.14.1.dev2002081011/sip/Qt3DAnimation/qkeyframeanimation.sip:

    enum RepeatMode
    {
        None,
        Constant,
        Repeat,
    };

Which results in this with the generated PyQt stubs:

    class RepeatMode(int): ...
    None = ... # type: 'QKeyframeAnimation.RepeatMode'
    Constant = ... # type: 'QKeyframeAnimation.RepeatMode'
    Repeat = ... # type: 'QKeyframeAnimation.RepeatMode'

Which then results in this with mypy:

    PyQt5-stubs/Qt3DAnimation.pyi:334: error: can't assign to keyword

Could that member be missing a /PyName=None_/ annotation?

Same for:

  - QAbstractTexture.Status
  - QClearBuffers.BufferType
  - QMemoryBarrier.Operation
  - QMesh.Status
  - QSceneLoader.Status
  - QTextureImage.Status
  - QSGTexture.Filtering

Florian

-- 
me at the-compiler.org (Mail/XMPP) | https://www.qutebrowser.org 
       https://bruhin.software/ | https://github.com/sponsors/The-Compiler/
       GPG: 916E B0C8 FD55 A072 | https://the-compiler.org/pubkey.asc
             I love long mails! | https://email.is-not-s.ms/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20200504/70b51c9d/attachment.sig>


More information about the PyQt mailing list