0

I am using elpy with emacs and flake8 as my syntax checker.

I find that it keeps checking for syntax everytime i type, like if start opening a parenthesis it complains of syntax error, this leads to me not being able to see function declarations while typing and slows down emacs too.

How do i remove this functionality so that syntax is checked only when i save the file.

Here are the relevant lines from my emacs configuration.

(elpy-enable)
(pyvenv-activate (expand-file-name "~/lpackages/anaconda3/envs/MLenv"))
(setq elpy-rpc-backend "jedi")
;;(elpy-use-ipython)

(require 'python)
(setq python-shell-interpreter "ipython"
   python-shell-interpreter-args "--simple-prompt -i")

(require 'py-autopep8)
(add-hook 'elpy-mode-hook 'py-autopep8-enable-on-save)


;;import company settings
(require 'company-config)
4
  • This could be a problem of flycheck. What is your configuration for that plugin?
    – Trung Ta
    Aug 17, 2016 at 2:51
  • No configuration, i just left it as default, i thought elpy uses flymake? And flycheck will only work if i add a hook for it in elpy-mode-hook right? Aug 17, 2016 at 6:24
  • Sorry, I mistook flycheck and flymake. In the case of using external syntax checker, it sould be flymake. Btw, this post seems to address the same issue with you. Can you check if it is helpful? stackoverflow.com/questions/6110691/…
    – Trung Ta
    Aug 17, 2016 at 6:37
  • Thanks, that solves the issue, i didn't notice that question, differently worded title and all. Aug 17, 2016 at 6:52

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.