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 766949 - Gio.ApplicationCommandLine.do_print_literal() and .do_printerr_literal() hiccups
Gio.ApplicationCommandLine.do_print_literal() and .do_printerr_literal() hiccups
Status: RESOLVED OBSOLETE
Product: pygobject
Classification: Bindings
Component: gio
3.20.x
Other All
: Normal minor
: ---
Assigned To: Nobody's working on this now (help wanted and appreciated)
Python bindings maintainers
Depends on:
Blocks:
 
 
Reported: 2016-05-27 17:34 UTC by Christian Stadelmann
Modified: 2018-01-10 20:54 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Christian Stadelmann 2016-05-27 17:34:16 UTC
1. Both methods don't have any documentation.
2. Why aren't they just called print() and printerr() as are their C counterparts?
3. Do they have to be virtual? This is quite inconvenient.
Comment 1 Christoph Reiter (lazka) 2016-05-28 19:10:19 UTC
> 1. Both methods don't have any documentation.

Afaik there is currently no way to document a virtual in C (or I can't find it in giscanner). All the docs for do_ are just copies of their counterpart methods with the same name and signature.

For these two virtual methods their callers are g_application_command_line_print and g_application_command_line_printerr. Both are not introspectable due to their usage of var args and can't be accessed from Python.

I should probably remove any documentation of vfuncs in the docs and just point to the methods, if there are any available. Imho the gir writer shouldn't write them in the first place..

> 2. Why aren't they just called print() and printerr() as are their C counterparts?

They represent the fields print_literal and prenterr_literal in the GApplicationCommandLineClass struct.

> 3. Do they have to be virtual? This is quite inconvenient.

You probably want binding friendly alternatives for g_application_command_line_print and g_application_command_line_printerr. But, looking at the code all the action happens in the default vfunc imeplementations, so just calling them should work too.

----

* For the docs I've opened https://github.com/lazka/pgi-docgen/issues/125 . For real docs for vfuncs, I'm not sure where to start/look -> Needs to be fixed in gobject-introspection
* For binding friendly versions of the print methods -> Needs to be fixed in glib
Comment 2 GNOME Infrastructure Team 2018-01-10 20:54:18 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/pygobject/issues/116.