Bug 1644404 - python2-nautilus seems to use Python 3.7 instead of 2.7
Summary: python2-nautilus seems to use Python 3.7 instead of 2.7
Keywords:
Status: CLOSED DUPLICATE of bug 1636626
Alias: None
Product: Fedora
Classification: Fedora
Component: nautilus-python
Version: 29
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Patrick Dignan
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-10-30 18:18 UTC by Franco Bugnano
Modified: 2018-10-30 19:50 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2018-10-30 19:50:52 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Franco Bugnano 2018-10-30 18:18:39 UTC
Description of problem:
I use the tortoisehg-nautilus and nextcloud-client-nautilus, which both use Python 2

After a clean install of Fedora 29, none of these Nautilus extensions work (In Fedora 28 they both worked fine).

Version-Release number of selected component (if applicable):
python2-nautilus-1.2.1-3.fc29.x86_64
tortoisehg-nautilus-4.6.1-1.fc29.noarch
nextcloud-client-nautilus-2.3.3-2.fc28.x86_64
nautilus-3.30.2-1.fc29.x86_64

How reproducible:
Always

Steps to Reproduce:
1. sudo dnf install tortoisehg-nautilus nextcloud-client-nautilus
2. Open Nautilus
3. Go to a folder that contains a Mercurial repository or a Nextcloud sync directory

Actual results:
The directory is shown as a normal directory, instead of having the overlays on the files and the additional context menu entries


Expected results:
The files show an overlay icon that indicate their up-to-date status in case of Mercurial, and their sync status in case of Nextcloud. Additionally, the right click on a file shows tortoisehg specific menu entries.

Additional info:
When running nautilus from the command line, there is this error message:
(nautilus:14412): Nautilus-Python-WARNING **: 19:13:53.377: g_module_open libpython failed: /usr/lib64/libpython3.7.so.1.0: cannot open shared object file: No such file or directory
ImportError: could not import gobject (error was: ImportError('/usr/lib64/python3.7/site-packages/gi/_gi.cpython-37m-x86_64-linux-gnu.so: undefined symbol: PyExc_NotImplementedError'))

(nautilus:14412): Nautilus-Python-WARNING **: 19:13:53.416: pygobject initialization failed

(nautilus:14412): Nautilus-Python-WARNING **: 19:13:53.416: nautilus_python_init_python failed
Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/syncstate-Nextcloud.py", line 23, in <module>
    from gi.repository import GObject, Nautilus
  File "/usr/lib64/python3.7/site-packages/gi/__init__.py", line 42, in <module>
    from . import _gi
ImportError: /usr/lib64/python3.7/site-packages/gi/_gi.cpython-37m-x86_64-linux-gnu.so: undefined symbol: PyExc_NotImplementedError
  File "/usr/share/nautilus-python/extensions/nautilus-thg.py", line 130
    except StandardError, e:
                        ^
SyntaxError: invalid syntax





The fact that it is searching /usr/lib64/python3.7 seems like it is looking for Python 3.7 instead of Python 2.7.
I have also tried to run Nautilus with the command:
env PYTHON=/usr/bin/python2 nautilus

but the result is the same.

As an additional info that can help, I have installed both python2-gobject and python3-gobject, and I have only installed python2-nautilus, and not python3-nautilus (to make sure that the Python extensions run in Python 2 instead of Python 3).

Comment 1 Raphael Groner 2018-10-30 19:50:52 UTC
Thanks for the report. This bug introduced with a first try to port to python3.

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


Note You need to log in before you can comment on or make changes to this bug.