tpapp / julia-repl

Run an inferior Julia REPL in a terminal inside Emacs
Other
170 stars 35 forks source link

REPL won't start, exiting abnormally with code 127 #81

Closed snlawrence closed 4 years ago

snlawrence commented 4 years ago
  1. GNU Emacs 25.3.1 (x86_64-pc-linux-gnu, GTK+ Version 3.22.10) of 2018-02-22
  2. Julia: Version 1.3.1 (2019-12-30)
  3. the version of julia-repl latest master (cloned 3/2/20)

Error replication:

  1. Cloned julia-repl into my emacs directory
  2. Added the following to my init.el file:
    
    (add-to-list 'load-path "~/.emacs.d/elpa/julia-emacs")
    (add-to-list 'load-path "~/.emacs.d/elpa/julia-repl")

(require 'julia-mode) (require 'julia-repl) (add-hook 'julia-mode-hook 'julia-repl-mode)

3. Open a `.jl` file and start a Julia REPL with `C-c C-z`. `*julia*` buffer opens with the following error:

..: line 0: exec: julia: not found

Process julia exited abnormally with code 127



I don't believe there's anything wrong with my Julia install. It runs fine in Atom (/Juno), in the terminal, and also works fine when I start a `multi-term` session inside emacs. I am not really sure how to go about troubleshooting the issue, so any help would be greatly appreciated.
tpapp commented 4 years ago

I guess Julia cannot be found in your path. You may want to modify the executable records, see

https://github.com/tpapp/julia-repl#julia-executables

LauraBMo commented 4 years ago

Sorry for reopening, I had the very same problem (same versions, just Julia 1.4.1) A working julia in "~/src/julia-1.4.1/bin/julia" and ".../julia-1.4.1/bin" in my executable path. So, for example from emacs + term running just "julia" (without the whole path to the executable) works. But with the following code, nither default nor master worked

(setq julia-repl-executable-records '((default "julia") ; in the executable path (master "~/src/julia-1.4.1/bin/julia"))) ; compiled from the repository

If it can help someone, I solved it with expand-file-name using master with

(setq julia-repl-executable-records ``((default "julia") ; in the executable path (master ,(expand-file-name "~/src/julia-1.4.1/bin/julia")))) ; compiled from the repository