ropemacs
ropemacs copied to clipboard
python 3.8 support
ropemacs does not seem to function at all on python 3.8.
Traceback (most recent call last):
File "/Users/glyph/Settings/Emacs/thirdparty/unpackaged/Pymacs.py", line 201, in loop
value = eval(text)
File "<string>", line 1, in <module>
File "/Users/glyph/Settings/Emacs/thirdparty/unpackaged/Pymacs.py", line 429, in pymacs_load_helper
module = __import__(module_name)
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemacs/__init__.py", line 675, in <module>
_load_ropemacs()
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemacs/__init__.py", line 653, in _load_ropemacs
_interface = ropemode.interface.RopeMode(env=LispUtils())
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemode/interface.py", line 19, in __init__
self._init_mode()
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemode/interface.py", line 33, in _init_mode
self.env.local_command(attrname, attr, key, prefix)
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemacs/__init__.py", line 306, in local_command
self._set_interaction(callback, prefix)
File "/Users/glyph/Library/Python/3.8/lib/python/site-packages/ropemacs/__init__.py", line 341, in _set_interaction
callback.interaction = ''
AttributeError: 'method' object has no attribute 'interaction'
Hello sir, I am not knowledgeable about ropemacs, I'm just another guy trying to get it to work. In fact I encountered this error and fixed it.
In ropemacs/init.py, it is referring to im_func
, which was changed to dunder __func__
in Python 3.
I changed both references to __func__
and ropemacs started working.
The other thing I had to do to get ropemacs working was to get pymacs working by adding the pymacs.el install location into the emacs loadpath in my .emacs/init.el
So far I've been able to do search for occurrences of a function successfully, and rename a function. I had to create a rope project and modify the config.py to exclude some folders with broken code for it to find things. N.B. Rope's search command fails on syntax errors.