nim-lang / nim-mode

An emacs major mode for the Nim programming language
139 stars 46 forks source link

nimsuggest mode doesn't work anymore #165

Closed krux02 closed 7 years ago

krux02 commented 7 years ago

I am on development branch of nim-mode, whenever I open Nim-mode without nimsugggest-mode works, but as soon as I start nimsuggest-mode, I get the following error.

Manjaro Linux GNU Emacs 25.2.1 master branch of nim-mode (git hash: 05ac362f97874d50131ea38277cf95a5cfecb250)

nimsuggest --version                                                                                                                   [git:devel]
Nim Compiler Version 0.17.1 (2017-07-24) [Linux: amd64]
Copyright (c) 2006-2017 by Andreas Rumpf

git hash: 52ff244d5d2775fa4d13f4e2b9a996f411281312
active boot switches: -d:release --gc:markAndSweep
Debugger entered--Lisp error: (file-error "make client process failed" "Verbindungsaufbau abgelehnt" :name "epc con 432" :buffer #<buffer *epc con 432*> :host "localhost" :service 39137 :nowait nil)
  signal(file-error ("make client process failed" "Verbindungsaufbau abgelehnt" :name "epc con 432" :buffer #<buffer *epc con 432*> :host "localhost" :service 39137 :nowait nil))
  flycheck-buffer()
  flycheck-select-checker(nim-nimsuggest)
  (progn (flycheck-select-checker (quote nim-nimsuggest)))
  (if (and (and (boundp (quote nim-use-flycheck-nimsuggest)) nim-use-flycheck-nimsuggest) (not flycheck-checker)) (progn (flycheck-select-checker (quote nim-nimsuggest))))
  flycheck-nimsuggest-setup()
  (progn (if (or (and (boundp (quote eldoc-mode)) eldoc-mode) (and (boundp (quote global-eldoc-mode)) global-eldoc-mode)) (progn (advice--add-function :before-until (cons (function (lambda nil (advice--buffer-local ...))) (function (lambda (gv--val) (advice--set-buffer-local ... gv--val)))) (quote nim-eldoc-function) nil))) (flycheck-nimsuggest-setup))
  (if (and (derived-mode-p (quote nim-mode)) (nim-suggest-available-p)) (progn (if (or (and (boundp (quote eldoc-mode)) eldoc-mode) (and (boundp (quote global-eldoc-mode)) global-eldoc-mode)) (progn (advice--add-function :before-until (cons (function (lambda nil ...)) (function (lambda ... ...))) (quote nim-eldoc-function) nil))) (flycheck-nimsuggest-setup)))
  (if nimsuggest-mode (if (and (derived-mode-p (quote nim-mode)) (nim-suggest-available-p)) (progn (if (or (and (boundp (quote eldoc-mode)) eldoc-mode) (and (boundp (quote global-eldoc-mode)) global-eldoc-mode)) (progn (advice--add-function :before-until (cons (function ...) (function ...)) (quote nim-eldoc-function) nil))) (flycheck-nimsuggest-setup))) (let* ((new (advice--remove-function (advice--buffer-local (quote eldoc-documentation-function)) (quote nim-eldoc-function)))) (if (eq new (advice--buffer-local (quote eldoc-documentation-function))) nil (advice--set-buffer-local (quote eldoc-documentation-function) new))))
  (let ((last-message (current-message))) (setq nimsuggest-mode (if (eq arg (quote toggle)) (not nimsuggest-mode) (> (prefix-numeric-value arg) 0))) (if nimsuggest-mode (if (and (derived-mode-p (quote nim-mode)) (nim-suggest-available-p)) (progn (if (or (and (boundp ...) eldoc-mode) (and (boundp ...) global-eldoc-mode)) (progn (advice--add-function :before-until (cons ... ...) (quote nim-eldoc-function) nil))) (flycheck-nimsuggest-setup))) (let* ((new (advice--remove-function (advice--buffer-local (quote eldoc-documentation-function)) (quote nim-eldoc-function)))) (if (eq new (advice--buffer-local (quote eldoc-documentation-function))) nil (advice--set-buffer-local (quote eldoc-documentation-function) new)))) (run-hooks (quote nimsuggest-mode-hook) (if nimsuggest-mode (quote nimsuggest-mode-on-hook) (quote nimsuggest-mode-off-hook))) (if (called-interactively-p (quote any)) (progn nil (if (and (current-message) (not (equal last-message (current-message)))) nil (let ((local " in current buffer")) (message "Nimsuggest mode %sabled%s" (if nimsuggest-mode "en" "dis") local))))))
  nimsuggest-mode(toggle)
  funcall-interactively(nimsuggest-mode toggle)
  call-interactively(nimsuggest-mode record nil)
  command-execute(nimsuggest-mode record)
  helm-M-x(nil #("nimsuggest-mode" 0 15 (match-part "nimsuggest-mode")))
  funcall-interactively(helm-M-x nil #("nimsuggest-mode" 0 15 (match-part "nimsuggest-mode")))
  call-interactively(helm-M-x nil nil)
  command-execute(helm-M-x)
yuutayamada commented 7 years ago

I installed new OS (Ubuntu) few days ago, so my emacs packages should be up-to-date and I don't have no errors. (I just checked nimsuggest.nim and koch.nim though)

Nim Compiler Version 0.17.1 (2017-07-24) [Linux: amd64]
Copyright (c) 2006-2017 by Andreas Rumpf

git hash: 52ff244d5d2775fa4d13f4e2b9a996f411281312
active boot switches: -d:release
krux02 commented 7 years ago

Well I found out the issue, it was me. I edited /etc/hosts and by accident I removed the ip4 entry for localhost. Yea, my bad.