Bug 22206 - deprecate all _run_ methods
Summary: deprecate all _run_ methods
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: git master
Hardware: Other All
: medium normal
Assignee: Simon McVittie
QA Contact: Telepathy bugs list
URL: http://git.collabora.co.uk/?p=user/sm...
Whiteboard: review+
Keywords: patch
Depends on: 27375
Blocks:
  Show dependency treegraph
 
Reported: 2009-06-10 06:46 UTC by Simon McVittie
Modified: 2010-03-31 09:33 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Simon McVittie 2009-06-10 06:46:38 UTC
+++ This bug was initially created as a clone of Bug #22205 +++

11:52 < barisione> _run_ functions are evil

The reentrant methods in telepathy-glib client code turn out not to be such a good idea.

Mission Control hasn't had them for a while, and has a slightly outdated fork of glib-client-gen.py that supports a command-line option to not generate them (and also a command-line option to generate blocking versions, but that's WONTFIX from my point of view, and no longer used anyway).

If we add a similar command-line option to telepathy-glib's glib-client-gen.py, we can replace MC's fork with the real one.

Also, in the long term (early in the 0.9 series?) we should deprecate _run_ altogether. I've added a command-line option to deprecate these methods, which works per "class".

My plan is that when I add Client, ChannelDispatcher etc. bindings, they will lack the _run_ methods altogether; existing classes will keep them, deprecate them in 0.9.0, and delete them when we break ABI.
Comment 1 Simon McVittie 2010-01-21 06:33:41 UTC
I have a rather half-baked branch for this, 'deprecations'.
Comment 2 Simon McVittie 2010-03-30 12:58:18 UTC
This branch deprecates tp_connection_run_until_ready, tp_channel_run_until_ready, and tp_cli_*_run_*, but in such a way that telepathy-glib's own regression tests are still allowed to use them:

http://git.collabora.co.uk/?p=user/smcv/telepathy-glib-smcv.git;a=shortlog;h=refs/heads/deprecations

Remaining uses of _run_ functions appear to be in regression tests, which can legitimately use them (although the tests should ideally be using the wrappers from tests/lib/util.c, except as necessary to exercise the deprecated functions).

(Please review my trivia branch first; the branches are stacked.)
Comment 3 Danielle Madeley 2010-03-30 19:41:40 UTC
Looks good.
Comment 4 Simon McVittie 2010-03-31 09:08:56 UTC
Thanks, merge in progress, will be in 0.11.0...
Comment 5 Simon McVittie 2010-03-31 09:33:46 UTC
Fixed in master for 0.11.0.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.