Issue #869 resolved

Tortoisehg-nautilus doesn't work at all

Joakim B
created an issue

Hi guys,

My main computer runs F15, and I've ran "sudo yum install tortoisehg tortoisehg-nautilus".

Running "yum info tortoisehg-nautilus" confirms that the package is installed: Name : tortoisehg-nautilus Architecture : i686 Version : 2.0.5

However I get no Tortoisehg-features in my folders where I earlier could perform the most daring HG-tasks all thanks to tortoisehg.

Running tortoisehg separately works though but not the Nautilus-integrations.

What can I do?

Comments (34)

  1. Joakim B reporter

    Hi Steve,

    Being bit of a newcomer on Fedora - only run Ubuntu in the past, I have a hard time installing the latest version (

    sudo rpm -Uhv
    tortoisehg = 2.0.5-1.fc15 is dependent on (installed) tortoisehg-nautilus-2.0.5-1.fc15.i686 

    What on earth is happening and what could I do?

  2. Joakim B reporter

    Ok. Uninstalled the previous tortoisehg & reinstalled:

    sudo yum remove tortoisehg tortoisehg-nautilus
    sudo yum install tortoisehg-tortoisehg-2.1-1.fc15.i686.rpm
    sudo yum install tortoisehg-nautilus-2.1-1.fc15.i686.rpm
    nautilus -q 

    No changes by neither running nautilus -q nor rebooting the system. Going into a folder where a hg repo exists makes no difference to the right-click context menu at all.

    Running "thg" opens the normal tortoisehg window though and everything seems to work from there, but the nautilus extension clearly doesn't appear, which would be super neat to have-

    Are there any dependencies that I am missing out or anything making this non-working for me? Any specific log files I can check for errors?


  3. Joakim B reporter

    I took a look at the file, searching for "tortoisehg" and this is the only related line found in the file:

    (gnome-shell:1732): Clutter-WARNING : The meta of type 'StScrollViewFade' with name 'vfade' is not attached to the actor 'notification-scrollview' Fönsterhanterarvarning: Received a _NET_WM_MOVERESIZE message for 0x3e0008e (tortoisehg); these messages lack timestamps and therefore suck.

    ...therefore suck? :)

    Any alternative logfiles that may contain valuable info?

  4. Steve Borho

    that is pretty unhelpful.

    If I were debugging this locally, I would uninstall the tortoisehg rpm packages and do a source install instead, following the instructions here:

    Then install the nautilus extension manually:

    mkdir -p ~/.nautilus/python-extensions/
    ln -s ~/path/to/clone/contrib/ ~/.nautilus/python-extensions/
    nautilus -q
  5. Joakim B reporter

    Ok. I've installed manually following the instructions.

    After running below to setup the nautilus extension, nautilus won't start at all:

    [jay@cookiemonster Downloads]$ ln -s /opt/tortoisehg/contrib/ ~/.nautilus/python-extensions/
    [jay@cookiemonster Downloads]$ nautilus -q
    [jay@cookiemonster Downloads]$ nautilus
    Initializing nautilus-open-terminal extension
    Initializing nautilus-gdu extension
    /usr/lib/python2.7/site-packages/gtk-2.0/gtk/ Warning: specified class size for type `PyGtkGenericCellRenderer' is smaller than the parent type's `GtkCellRenderer' class size
      from gtk import _gtk
    /usr/lib/python2.7/site-packages/gtk-2.0/gtk/ Warning: g_type_get_qdata: assertion `node != NULL' failed
      from gtk import _gtk
    Segmenteringsfel (minnesutskrift skapad)
    [jay@cookiemonster Downloads]$ rm ~/.nautilus/python-extensions/
    [jay@cookiemonster Downloads]$ nautilus -q // now nautilus starts!

    Have also attached Fedoras errorlog to this post. Any ideas on the next step?

  6. Steve Borho

    It's possible our nautilus extension is no longer compatible with the most recent nautilus-python library, but one would hope it had a better failure mode than taking down all of nautilus with a SEGV. I think someone with your O/S will have to debug this.

  7. Joakim B reporter

    That's a shame. If I would like to go back to the yum-handled version, can I just remove the symlink created in my installation?


  8. Robert Suijker

    I've been struggling with this also and I found out that it is related to Gnome 3 (GTK+3). Also the nautilus-python bindings have changed for the 1.0 release to match those to updates to Nautilus.

    The segmentation fault is caused by the 'import gtk' statement. Don't know why, but googling this shows up more people have problems with this.

    To get it going under Nautilus/Gnome 3 if have attached a patch. Note that the location to put the python-extension in has changed (at least copying the extension to '/.local/share/nautilus-python/extensions/' works with the patch applied).

    The icons in the context menu however don't show although I did enable 'Show icons' with (for some weird design decision the Gnome developers decided in all of there wisdom that it clutters too much) :

    "gconftool-2 –type bool –set /desktop/gnome/interface/menus_have_icons true"

    The icons in the TortoiseHg menus won't show either, so I think this might have something to do with QT4 under Gnome.

    At least for me I'm happy that with the patch applied integration in Nautilus works again under Gnome 3.

  9. Joakim B reporter

    Hi Robostyle,

    Thanks for you looking into this. I assumed that it were definitely related to Gnome3 as well, as everything worked like a charm with Nautilus with Gnome2.

    I will try your fix out soon as I'm away from my Gnome3 machine right now. Hopefully it will work for me as well!

  10. Mads Kiilerich
    • changed status to new

    Nautilus in Fedora 15 still crashes for me, even with an empty .py file in extensions, so I can't tell if this works or not.

    I guess the patch needs some cleanup so it still works with gtk2, and the list of requirements should perhaps be updated if it is applied.

    (By the way: Feel free to CC me on Fedora related issues.)

  11. Mads Kiilerich

    This patch combined with nautilus-python-1.0 (and nautilus-3.0.2) works for me in a quick test. It no longer crashes, overlays shows up, and there are context menus.

    This is definitely a step in the right direction.

  12. NeoPolus

    Hi Robostyle,

    I tried applied your patch to the lastest and then made a link to it from /.local/share/nautilus-python/extensions/, but it fails with a "metaclass conflict" error:

    neopolus@adrastea /opt/thg/contrib $ nautilus -q
    ** Message: Initializing gksu extension...
    Initializing nautilus-gdu extension
    Initializing nautilus-open-terminal extension
    /usr/lib/python2.7/dist-packages/gobject/ Warning: g_boxed_type_register_static: assertion `g_type_from_name (name) == 0' failed
      import gobject._gobject
    Traceback (most recent call last):
      File "/home/neopolus/.local/share/nautilus-python/extensions/", line 379, in <module>
        class HgExtension(HgExtensionIcons, gobject.GObject, Nautilus.MenuProvider, Nautilus.ColumnProvider, Nautilus.PropertyPageProvider, Nautilus.InfoProvider):
    TypeError: Error when calling the metaclass bases
        metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases

    Any ideas? (btw, I tried without the 'overlayicons' option and it fails too).

    Note: I have python-nautilus 1.0-0ubuntu2 and tortoisehg 2.2.2+94-3aacc518fa2d-0ppa1 installed (Linux Mint 12).

  13. Lester Caine

    I've just arrived at the same point on SUSE12.1 ... after going all around the houses with nautilus not starting at all, I finally got things under control and with the patch above I can at least get things running, but no inegration of TortoiseHg

    As an aside I don't have the context menu for Hg integrated either ... that is the next target ...

  14. Lester Caine

    I've managed to get running in nautilus3.2.1 now that I've found the right folder to put the file in, and I'm getting the flags on the hg repo folders, but I'm still not getting the menu items to access tortoisehg from within nautilus. Any thoughts on what I'm missing, or do I now need to load the scripts bodge to get thouse entries?

  15. Juha Sahakangas

    Good catch on the path, should've modified as well.

    The menus should work fine without any script kludges, I tested the patch with nautilus 3.0.2, 3.2.1 (both vanilla and ubuntu version), and even git head/3.4 and there weren't any menu issues with any of them.

  16. Anonymous

    I'm not sure if this is the right place to add my two-penneth but hopefully it'll help others should they find themselves with a broken installation of tortoisehg in nautilus.

    Having followed the conversation above and applied the patch to my copy of (which Ubuntu installed in /usr/lib/nautilus/extensions-2.0/python), I was still without tortoisehg integration. To cut a long story short, the solution was to...

    1. move nautilus-thg to /usr/share/nautilus-python/extensions and,
    2. add the following lines to in HgExtensionDefault's init method.
    if not os.path.exists(os.path.expanduser('~/.tortoisehg')): 
  17. Anonymous

    It doesn't work for me on Ubuntu 11. By "work" I mean that installing the package through the package manager should create the overlay icons and context menu shortcuts. If it does not work when installed the usual way, that counts as "not working" me. You shouldn't advertise on the main page that it "includes a Nautilus extension" if you have to manually apply patches to get it to work.

  18. BrenBarn

    This still doesn't work for me on Linux Mint 13. I tried both the distro tortoisehg version and the tortoisehg ppa. Neither seems to install anything related to tortoisehg-nautilus. The list of installed files shows nothing related to nautilus except some docs and icons.

  19. Log in to comment