On Fri, 27 Feb 2009, Sebastian Pipping wrote:
> Asheesh Laroia wrote:
>> Well, either (a) there's something with your package by which you
>> installed the Nautilus Python extensions, or (b) I'm using an outdated
>> way to call it.
>>
>> Does your distribution ship examples or documentation for
>> nautilus-python? (If not, the GNOME wiki might have some...?) If you
>> find them, can you see if those examples work and/or if the docs
>> indicate that we are using a current way to access Nautilus from Python?
>
> The examples do not work. What I tried so far:
>
> 1) Try importing nautilaus (where I left of last time)
>
> $ python -c 'import nautilus'
> Traceback (most recent call last):
> File "<string>", line 1, in <module>
> ImportError: No module named nautilus
>
> 2) Same but pointing python to path holding nautilus.so
>
> $ PYTHONPATH=/usr/lib/nautilus-python python -c 'import nautilus'
> ImportError: /usr/lib/nautilus-python/nautilus.so: undefined symbol:
> nautilus_file_info_get_vfs_file_info
Excellent. (This seems like a bug in your distribution's copy of Nautilus
or nautilus-python.)
> 3) Remove all occurrences of function
> "nautilus_file_info_get_vfs_file_info" from nautilus-python
> code, recompile, reinstall, then
>
> $ PYTHONPATH=/usr/lib/nautilus-python python -c 'import nautilus'
> Fatal Python error: This module can only be used from nautilus
> Aborted
Great!
> 4) See what related files nautilus is accessing on startup:
> $ strace nautilus 2>&1 | grep /usr/lib/.\*nautilus
> open("/usr/lib/libnautilus-extension.so.1", O_RDONLY) = 3
>
> What's next?
Try putting the CC Nautilus extension in the path that Nautilus looks in
for Python extensions and see if you get a new properties pane.
But one more thing:
> /usr/lib/pkgconfig/nautilus-python.pc
> /usr/share/doc/nautilus-python/README
> /usr/share/doc/nautilus-python/documentation.py
> /usr/share/doc/nautilus-python/examples
> /usr/share/doc/nautilus-python/examples/background-image.py
> /usr/share/doc/nautilus-python/examples/block-size-column.py
> /usr/share/doc/nautilus-python/examples/md5sum-property-page.py
> /usr/share/doc/nautilus-python/examples/open-terminal.py
Can you get these files to work? What does README or documentation.py say?
> Should 'extensions-1.0' be 'extensions-2.0'? Anything else?
No, I think.
-- Asheesh.
--
You had some happiness once, but your parents moved away, and you had to
leave it behind.
_______________________________________________
cc-devel mailing list
[email protected]
http://lists.ibiblio.org/mailman/listinfo/cc-devel