Bug 62459

Summary: Telepathy thinks you are offline if you connect to internet via other methods than Networkmanager, eg wvdial
Product: Telepathy Reporter: Sinclair <orion2000za>
Component: mission-controlAssignee: Telepathy bugs list <telepathy-bugs>
Status: RESOLVED DUPLICATE QA Contact: Telepathy bugs list <telepathy-bugs>
Severity: major    
Priority: medium    
Version: git master   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Sinclair 2013-03-18 09:31:47 UTC
connect to internet using command line wvdial and a USB (or other) modem. Other applications note that you are online, kde-telepathy thinks you are offline as you are not using Networkmanager

Reproducible: Always

Steps to Reproduce:
1. connect to internet using command wvdial from console
2. set status to "available"
Actual Results:  
other applications as KMail, Firefox etc works and notice you are online
Kde-telepathy thinks you are offline and will not connect, ktp-debugger confirms this

Expected Results:  
kde-telepathy. like other internet applications, notice that you are connected via other means than Networkmanager and connects to your accounts

Networkmanager can deal with most devices/connections but far from all. I have 2-3 USB 3G modems that are not working via Networkmanager but works perfect using wvdial command.
Other applications, be they KDE native as Rekonq and KMail or not as Firefox, note that I am connected. It is only kde-telepathy that does not.
Comment 1 Nicolas Dufresne 2013-03-22 15:22:00 UTC
I think mission-control should not be built with Network Manager if you are not going to use that.
Comment 2 Sinclair 2013-03-27 14:30:49 UTC
and how can I do that, build mission-control without Network Manager? And what consequence would it have the times when I do use Networkmanager to connect (most of the times in offices and so on)?
Comment 3 Simon McVittie 2013-03-28 11:07:22 UTC
If you do have NM installed but are currently bypassing it, a smaller hammer than recompiling MC is to configure it not to believe NM.

Empathy can do this through a GUI, but kde-telepathy probably can't. This might work:

    gsettings set im.telepathy.MissionControl.FromEmpathy use-conn false

(Yes, the name is pretty horrible - we inherited the setting from Empathy.)

There ought to be D-Bus API on Mission Control for this, if someone wants to add it.

I believe the way this is meant to work is:

    if (compiled with NM && NM is running && we are configured to believe it)
      {
        MC thinks we are online = NM thinks we are online
      }
    else
      {
        MC thinks we are online = TRUE
      }

... so people who don't have NM at all (even if their distribution compiled MC with NM support) don't have this problem either, it's only people who have NM but are not using it who get this. Please report any deviation from that as a bug.

The long-term solution would be to modify src/connectivity-monitor.c to use GNetworkMonitor, which doesn't care whether you're using NetworkManager or wvdial (it uses netlink on Linux, and assumes other platforms are always online).
Comment 4 Sinclair 2013-03-29 08:17:09 UTC
I can confirm that the

gsettings set im.telepathy.MissionControl.FromEmpathy use-conn false

workaround works! Am writing this connected with wvdial and can now use kde-telepathy for my IM contacts

I support the more thorough long-term solution but will point out this workaround to the kde-telepathy developers
Comment 5 Sinclair 2013-03-29 09:39:41 UTC
As I noted the workaround works but has the "flaw" of making telepathy unable to note if the system goes offline. It stays at state "online" regardless if the line goes down.

So the suggested recoding is clearly the way to go for a solution that covers connection via networkmanager or other means
Comment 6 Simon McVittie 2013-05-03 11:03:45 UTC
(In reply to comment #3)
> The long-term solution would be to modify src/connectivity-monitor.c to use
> GNetworkMonitor, which doesn't care whether you're using NetworkManager or
> wvdial

... which is Bug #56635.

*** This bug has been marked as a duplicate of bug 56635 ***

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.