[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-bindings
Subject:    [Kde-bindings] [Bug 295948] New: PyKDE4: KMountPoint::List is not special-cased
From:       Josef Spillner <spillner () kde ! org>
Date:       2012-03-13 17:40:13
Message-ID: bug-295948-22004 () http ! bugs ! kde ! org/
[Download RAW message or body]

https://bugs.kde.org/show_bug.cgi?id=295948

            Bug ID: 295948
          Severity: normal
           Version: unspecified
          Priority: NOR
          Assignee: kde-bindings@kde.org
           Summary: PyKDE4: KMountPoint::List is not special-cased
    Classification: Unclassified
                OS: Linux
          Reporter: spillner@kde.org
          Hardware: Other
            Status: NEW
         Component: general
           Product: bindings

The C++ flavour of the KDE libraries define an internal KMountPoint::List class
which is a QList. The Python bindings don't treat it as such:

>>> import PyKDE4.kio
>>> 
>>> allmountpoints = PyKDE4.kio.KMountPoint.possibleMountPoints()
>>> allmountpoints
<PyKDE4.kio.List object at 0x7f7f5f5c83b0>
>>> dir(allmountpoints)
['__class__', '__delattr__', '__dict__', '__doc__', '__format__',
'__getattribute__', '__hash__', '__init__', '__module__', '__new__',
'__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__',
'__str__', '__subclasshook__', '__weakref__', 'findByDevice', 'findByPath']
>>> len(allmountpoints)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: object of type 'List' has no len()

Apparently, the file kio/kmountpoint.sip needs special-case code just like for
example kurl.sip. The SIP files seem to be generated by a tool called twine but
have a 2008 copyright so I wonder if this would have to be added by hand or
some twine invocation is necessary.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Kde-bindings mailing list
Kde-bindings@kde.org
https://mail.kde.org/mailman/listinfo/kde-bindings
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic