After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 733893 - Differences in GObject.get_property vs. GObject.props accessor
Differences in GObject.get_property vs. GObject.props accessor
Status: RESOLVED FIXED
Product: pygobject
Classification: Bindings
Component: gobject
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Nobody's working on this now (help wanted and appreciated)
Python bindings maintainers
Depends on: 726999
Blocks:
 
 
Reported: 2014-07-29 04:28 UTC by Simon Feltman
Modified: 2014-08-18 08:34 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Simon Feltman 2014-07-29 04:28:14 UTC
While working through bug 726999 I noticed a few property types which differ in return values between GObject.get_property() and the GObject.props accessor. 

These should be fixed to be made consistent, the problem is some of the changes might be considered an API break.

GIMarshallingTests.PropertiesObject.some-boxed-glist:
    get_property() returns None with an empty list and a GIMarshallingTestsBoxedGList object when it has contents. props returns a Python list in both cases. I think we can get away with updating get_property() to also return a Python list as this seems like a bug.

GIMarshallingTests.PropertiesObject.some-char/uchar:
    get_property() returns a single character string whereas the props accessor returns an integer. get_property() seems somewhat broken because it cannot represent the full range of values that we test with the props accessor. We should attempt changing get_property() to always return integers for G_TYPE_CHAR and G_TYPE_UCHAR properties.