Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eaf-open broken in Kali Linux #16

Closed
Qquanwei opened this issue Jul 9, 2018 · 14 comments
Closed

eaf-open broken in Kali Linux #16

Qquanwei opened this issue Jul 9, 2018 · 14 comments

Comments

@Qquanwei
Copy link
Contributor

Qquanwei commented Jul 9, 2018

Stage:
sudo apt install python-xlib python-pyqt5 python-pymediainfo success
sudo pip install PyMuPDF grip success
emacs -Q
M-x eaf-open with ~/doc/RealWorldHaskell.pdf

Output Message:

EAF process starting...
*eaf* exited abnormally with code 1

When I manual execute python ~/.emacs.d/emacs-application-framework/app/pdfviewer/buffer.py
with error:

Traceback (most recent call last):
  File "buffer.py", line 28, in <module>
    from core.buffer import Buffer
ImportError: No module named core.buffer

Sys info:

Linux kali 4.15.0-kali2-amd64 #1 SMP Debian 4.15.11-1kali1 (2018-03-21) x86_64 GNU/Linux
emacs --version GNU Emacs 27.0.50
python --version  Python 2.7.14+
python3 --version ython 3.6.5rc1
@manateelazycat
Copy link
Member

manateelazycat commented Jul 10, 2018

When you got exited anhormally error, please switch to buffer eaf, then paste output from eaf, it's useful.

Don't do

python ~/.emacs.d/emacs-application-framework/app/pdfviewer/buffer.py

Because all code is execute from /emacs-application-framework/eaf.py by eaf.el

If you execute from app directory, it's wrong root directory to execute, "No module" error of course will throw, but it's not problem.

Please paste buffer eaf content.

@Qquanwei
Copy link
Contributor Author

eaf buffer:

Traceback (most recent call last):
  File "/home/quanwei/.emacs.d/emacs-application-framework/eaf.py", line 23, in <module>
    from core.fake_key_event import fake_key_event
ImportError: No module named core.fake_key_event

@manateelazycat
Copy link
Member

Can you do "ls -al" in your emacs-application-framework/core directory ?

@Qquanwei
Copy link
Contributor Author

~/.emacs.d/emacs-application-framework/core $ ls -al
total 20
drwxr-xr-x   2 quanwei        quanwei  4096 2018-07-09 21:36 .
drwxr-xr-x   6 quanwei        quanwei  4096 2018-07-09 21:36 ..
-rw-r--r--   1 quanwei        quanwei  2299 2018-07-09 21:36 buffer.py
-rw-r--r--   1 quanwei        quanwei  2695 2018-07-09 21:36 fake_key_event.py
-rw-r--r--   1 quanwei        quanwei  1909 2018-07-09 21:36 utils.py
-rw-r--r--   1 quanwei        quanwei  4168 2018-07-09 21:36 view.py
-rw-r--r--   1 quanwei        quanwei  1470 2018-07-09 21:36 xutils.py

Sorry I'm late, I only work on my computer at night.

@manateelazycat
Copy link
Member

@Qquanwei Can you touch empty file "init.py" in core directory, then try again?

@Qquanwei
Copy link
Contributor Author

I touch init,py and output the same error. I just clone this project to .emacs.d.

@manateelazycat
Copy link
Member

It's so strange.

@manateelazycat
Copy link
Member

@Qquanwei I mean touch file name with:

__init__.py

in core directory, github convert

__

string, not init.py, is:

__init__.py

@Qquanwei
Copy link
Contributor Author

It still not work.

I touch __init__.py and M-x eaf-open with a picture path.

dbus-call-method: D-Bus error: "Traceback (most recent call last):
  File \"/usr/lib/python2.7/dist-packages/dbus/service.py\", line 707, in _message_cb
    retval = candidate_method(self, *args, **keywords)
  File \"/home/quanwei/.emacs.d/emacs-application-framework/eaf.py\", line 71, in new_buffer
    return self.create_app(buffer_id, url, \"app.imageviewer.buffer\")
  File \"/home/quanwei/.emacs.d/emacs-application-framework/eaf.py\", line 92, in create_app
    if importlib.util.find_spec(module_path) is not None:
AttributeError: 'module' object has no attribute 'util'

@Qquanwei
Copy link
Contributor Author

Is that I miss some package ?

@manateelazycat
Copy link
Member

@Qquanwei you need use python3 execute those code, all your error is you use python2

@manateelazycat
Copy link
Member

@Qquanwei I have patch 12e6e82

Force use python3, please try again.

@Qquanwei
Copy link
Contributor Author

@manateelazycat It works.
I saw you fixed, so I closed this issue.

@manateelazycat
Copy link
Member

@Qquanwei Thanks for your feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants