emacsemacs-helm

Initialization error caused by helm-match-plugin


I'm running GNU Emacs Version 24.3 (9.0) on OS X Lion (obtained from http://emacsformacosx.com/). I'm relatively new to emacs, so I may be ignorant of a simple fix for my problem.

I recently expanded my use of helm-mode to include helm-locate and have helm offer extended-command suggestions. Unfortunately, I can't remember exactly how I activated these, but I think it must have been from the Customize Group interface, since my .emacs file doesn't have anything else about helm-mode except for binding C-x C-f to helm-find-files. Ever since I started using those features, when I open emacs I get the following error:

Warning (initialization): An error occurred while loading `/Users/aporiac/.emacs':

File error: Cannot open load file, helm-match-plugin

To ensure normal operation, you should investigate and remove the
cause of the error in your initialization file.  Start Emacs with
the `--debug-init' option to view a complete error backtrace. 

When I start emacs from the command line with the --debut-init flag, I get the following:

Debugger entered--Lisp error: (file-error "Cannot open load file" "helm-match-plugin")
require(helm-match-plugin)
mapc(require (helm-match-plugin))
custom-theme-set-variables(user (Linum-format "%7i ") (ansi-color-names-vector ["#212526" "#ff4b4b" "#b4fa70" "#fce94f" "#729fcf" "#ad7fa8" "#8cc4ff" "#eeeeec"]) (ansi-term-color$
  apply(custom-theme-set-variables user ((Linum-format "%7i ") (ansi-color-names-vector ["#212526" "#ff4b4b" "#b4fa70" "#fce94f" "#729fcf" "#ad7fa8" "#8cc4ff" "#eeeeec"]) (ansi-ter$
  custom-set-variables((Linum-format "%7i ") (ansi-color-names-vector ["#212526" "#ff4b4b" "#b4fa70" "#fce94f" "#729fcf" "#ad7fa8" "#8cc4ff" "#eeeeec"]) (ansi-term-color-vector [un$
  eval-buffer(#<buffer  *load*> nil "/Users/aporiac/.emacs" nil t)  ; Reading at buffer position 5073
  load-with-code-conversion("/Users/aporiac/.emacs" "/Users/aporiac/.emacs" t t)
  load("~/.emacs" t t)
  #[nil "^H\205\276^@   \306=\203^Q^@\307^H\310Q\202A^@ \311=\2033^@\312\307\313\314#\203#^@\315\202A^@\312\307\313\316#\203/^@\317\202A^@\315\202A^@   \320=\203=^@\321\202A^@\307^$
  command-line()
  normal-top-level()

I can't deactivate helm-match-plugin from Customize Group and don't even know if this the problem. Any help would be greatly appreciated.


Solution

  • With the help of phils helpful advice and information, I discovered that the problem was not specific to helm-mode or the helm-match-plugin but, rather, due to my crappy .emacs file. I was able to determine this by deleting helm using package-list-packages and then commenting out all functions involving helm in my .emcas file. On restarting emacs yet another error was reported and I commented out the corresponding function only to face another error on a subsequent restart. Finally, I copied and cleared my .emacs file and began piecing it back together bit by bit, restarting emacs after every significant change. It seems like the principle problem was the presence of numerous (require 'modename-mode) functions. I added these functions to .emacs following the instructions of the many packages I had installed, however, I installed those packages from either melpa or marmalade and I guess you don't need to require packages if they've been installed thus.

    I removed all the (require 'modename-mode) functions (except for (require 'package), which, for whatever reason, doesn't seem to cause problems) and some other chaff littering my .emacs, then I reinstalled helm. Things seem to be back in order.

    Update:

    For the last year I have managed my packages through Spacemacs's wonderful layers system. I have had virtually no package or init-related problems since.