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

When using SPC as leader in all states, a strange error happens when opening new files. #31

Open
zeroDivisible opened this issue Dec 14, 2015 · 4 comments

Comments

@zeroDivisible
Copy link

Hey guys.

In my emacs.org, I've got the following configuration:

(evil-leader/set-leader "<SPC>")
(setq evil-leader/in-all-states t)
(evil-mode nil)
(global-evil-leader-mode)
(evil-mode 1)

I needed to use it like that as without the extra (evil-mode nil), leader wasn't bound in *Messages* buffer. I found the solution in #10

This works as expected, binding leader in *Messages* (which is ultimately what I'm trying to achieve), however, when opening new i.e Yaml buffer, I'm getting the following error message:

File mode specification error: (error "To bind the key C-SPC, use [?\\C- ], not [C-SPC]")
progn: To bind the key C-SPC, use [?\C- ], not [C-SPC]

The full and lengthy stacktrace which I'm getting with this is:

Debugger entered--Lisp error: (error "To bind the key C-SPC, use [?\\C- ], not [C-SPC]")
  define-key((keymap (67108896 keymap (119 keymap (61 . balance-windows) (114 . toggle-window-split)) (64 . google-this-noconfirm) (27 . ace-jump-mode-pop-mark) (33 . google-this-search) (83 . helm-org-agenda-files-headings) (111 keymap (116 keymap (116 . org-set-tags)) (112 . org-iswitchb) (115 . org-schedule) (111 . org-open-at-point) (110 keymap (110 . org-add-note)) (76 . org-insert-link-global) (108 . org-store-link) (103 . helm-multi-swoop-org) (101 . org-edit-special) (100 . org-deadline) (99 keymap (113 . org-clock-cancel) (111 . org-clock-out) (99 . org-clock-in))) (116 . org-todo) (115 . helm-semantic-or-imenu) (98 keymap (100 . bookmark-delete) (108 . helm-bookmarks) (98 . bookmark-jump) (97 . bookmark-set)) (112 keymap (100 . projectile-dired) (115 . helm-projectile-switch-project) (102 . helm-projectile-find-file-dwim) (114 . helm-projectile-recentf) (107 . helm-projectile-find-file-in-known-projects) (112 . helm-projectile-find-file)) (104 keymap (109 . helm-man-woman) (63 . help-for-help) (100 . helm-dash-at-point) (71 . helm-do-ag) (103 . helm-projectile-ag) (105 . helm-imenu) (102 . helm-for-files) (98 . helm-bookmarks)) (102 . helm-find-files) (32 . helm-mini) (42 . helm-swoop-from-evil-search) (47 . helm-swoop) (63 . helm-descbinds) (103 keymap (116 . magit-diff-working-tree) (118 . vc-revision-other-window) (109 . magit-branch-popup) (110 keymap (98 . magit-create-branch)) (99 . magit-commit) (76 . magit-file-log) (108 . magit-log) (115 . magit-status) (98 . magit-blame-mode) (97 . vc-annotate)) (45 . helm-flycheck) (113 . delete-window) (49 . delete-other-windows) (100 . dired))) [C-SPC] (keymap (119 keymap (61 . balance-windows) (114 . toggle-window-split)) (64 . google-this-noconfirm) (27 . ace-jump-mode-pop-mark) (33 . google-this-search) (83 . helm-org-agenda-files-headings) (111 keymap (116 keymap (116 . org-set-tags)) (112 . org-iswitchb) (115 . org-schedule) (111 . org-open-at-point) (110 keymap (110 . org-add-note)) (76 . org-insert-link-global) (108 . org-store-link) (103 . helm-multi-swoop-org) (101 . org-edit-special) (100 . org-deadline) (99 keymap (113 . org-clock-cancel) (111 . org-clock-out) (99 . org-clock-in))) (116 . org-todo) (115 . helm-semantic-or-imenu) (98 keymap (100 . bookmark-delete) (108 . helm-bookmarks) (98 . bookmark-jump) (97 . bookmark-set)) (112 keymap (100 . projectile-dired) (115 . helm-projectile-switch-project) (102 . helm-projectile-find-file-dwim) (114 . helm-projectile-recentf) (107 . helm-projectile-find-file-in-known-projects) (112 . helm-projectile-find-file)) (104 keymap (109 . helm-man-woman) (63 . help-for-help) (100 . helm-dash-at-point) (71 . helm-do-ag) (103 . helm-projectile-ag) (105 . helm-imenu) (102 . helm-for-files) (98 . helm-bookmarks)) (102 . helm-find-files) (32 . helm-mini) (42 . helm-swoop-from-evil-search) (47 . helm-swoop) (63 . helm-descbinds) (103 keymap (116 . magit-diff-working-tree) (118 . vc-revision-other-window) (109 . magit-branch-popup) (110 keymap (98 . magit-create-branch)) (99 . magit-commit) (76 . magit-file-log) (108 . magit-log) (115 . magit-status) (98 . magit-blame-mode) (97 . vc-annotate)) (45 . helm-flycheck) (113 . delete-window) (49 . delete-other-windows) (100 . dired)))
  (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map))
  (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map)))
  (progn (evil-normalize-keymaps) (define-key evil-motion-state-local-map no-prefix map) (define-key evil-normal-state-local-map no-prefix map) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map))) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix map) (define-key evil-insert-state-local-map no-prefix map))))
  (if evil-leader-mode (progn (evil-normalize-keymaps) (define-key evil-motion-state-local-map no-prefix map) (define-key evil-normal-state-local-map no-prefix map) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map))) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix map) (define-key evil-insert-state-local-map no-prefix map)))) (define-key evil-motion-state-local-map no-prefix nil) (define-key evil-normal-state-local-map no-prefix nil) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed nil) (define-key evil-insert-state-local-map prefixed nil) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix nil) (define-key evil-insert-state-local-map no-prefix nil))))))
  (let* ((prefixed (read-kbd-macro (concat evil-leader/non-normal-prefix evil-leader/leader))) (no-prefix (read-kbd-macro evil-leader/leader)) (mode-map (cdr (assoc major-mode evil-leader--mode-maps))) (map (or mode-map evil-leader--default-map)) (no-prefix-rx (if evil-leader/no-prefix-mode-rx (mapconcat (function identity) evil-leader/no-prefix-mode-rx "\\|") nil))) (if evil-leader-mode (progn (evil-normalize-keymaps) (define-key evil-motion-state-local-map no-prefix map) (define-key evil-normal-state-local-map no-prefix map) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map))) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix map) (define-key evil-insert-state-local-map no-prefix map)))) (define-key evil-motion-state-local-map no-prefix nil) (define-key evil-normal-state-local-map no-prefix nil) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed nil) (define-key evil-insert-state-local-map prefixed nil) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix nil) (define-key evil-insert-state-local-map no-prefix nil)))))))
  (let ((last-message (current-message))) (setq evil-leader-mode (if (eq arg (quote toggle)) (not evil-leader-mode) (> (prefix-numeric-value arg) 0))) (let* ((prefixed (read-kbd-macro (concat evil-leader/non-normal-prefix evil-leader/leader))) (no-prefix (read-kbd-macro evil-leader/leader)) (mode-map (cdr (assoc major-mode evil-leader--mode-maps))) (map (or mode-map evil-leader--default-map)) (no-prefix-rx (if evil-leader/no-prefix-mode-rx (mapconcat (function identity) evil-leader/no-prefix-mode-rx "\\|") nil))) (if evil-leader-mode (progn (evil-normalize-keymaps) (define-key evil-motion-state-local-map no-prefix map) (define-key evil-normal-state-local-map no-prefix map) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed map) (define-key evil-insert-state-local-map prefixed map))) (if (and no-prefix-rx (string-match-p no-prefix-rx (symbol-name major-mode))) (progn (define-key evil-emacs-state-local-map no-prefix map) (define-key evil-insert-state-local-map no-prefix map)))) (define-key evil-motion-state-local-map no-prefix nil) (define-key evil-normal-state-local-map no-prefix nil) (if evil-leader/in-all-states (progn (define-key evil-emacs-state-local-map prefixed nil) (define-key evil-insert-state-local-map prefixed nil) (if (and no-prefix-rx (string-match-p no-prefix-rx ...)) (progn (define-key evil-emacs-state-local-map no-prefix nil) (define-key evil-insert-state-local-map no-prefix nil))))))) (run-hooks (quote evil-leader-mode-hook) (if evil-leader-mode (quote evil-leader-mode-on-hook) (quote evil-leader-mode-off-hook))) (if (called-interactively-p (quote any)) (progn nil (if (and (current-message) (not (equal last-message (current-message)))) nil (message "Evil-Leader mode %sabled" (if evil-leader-mode "en" "dis"))))))
  evil-leader-mode()
  run-hooks(evil-local-mode-hook evil-local-mode-off-hook)
  (let ((last-message (current-message))) (setq evil-local-mode (if (eq arg (quote toggle)) (not evil-local-mode) (> (prefix-numeric-value arg) 0))) (cond ((evil-disabled-buffer-p)) (evil-local-mode (setq emulation-mode-map-alists (evil-concat-lists (quote (evil-mode-map-alist)) emulation-mode-map-alists)) (evil-initialize-local-keymaps) (if (eq major-mode (quote turn-on-evil-mode)) (progn (setq major-mode (quote fundamental-mode)))) (if evil-state nil (evil-initialize-state)) (add-hook (quote input-method-activate-hook) (quote evil-activate-input-method) t t) (add-hook (quote input-method-deactivate-hook) (quote evil-deactivate-input-method) t t) (add-hook (quote activate-mark-hook) (quote evil-visual-activate-hook) nil t) (add-hook (quote pre-command-hook) (quote evil-repeat-pre-hook)) (add-hook (quote pre-command-hook) (quote evil-jump-hook) nil t) (add-hook (quote post-command-hook) (quote evil-repeat-post-hook))) (t (evil-refresh-mode-line) (remove-hook (quote pre-command-hook) (quote evil-jump-hook) t) (remove-hook (quote activate-mark-hook) (quote evil-visual-activate-hook) t) (remove-hook (quote input-method-activate-hook) (quote evil-activate-input-method) t) (remove-hook (quote input-method-deactivate-hook) (quote evil-deactivate-input-method) t) (evil-change-state nil))) (run-hooks (quote evil-local-mode-hook) (if evil-local-mode (quote evil-local-mode-on-hook) (quote evil-local-mode-off-hook))) (if (called-interactively-p (quote any)) (progn nil (if (and (current-message) (not (equal last-message (current-message)))) nil (message "Evil-Local mode %sabled" (if evil-local-mode "en" "dis"))))))
  evil-local-mode(-1)
  (progn (evil-local-mode -1) (funcall (function evil-initialize)))
  (if evil-local-mode (progn (evil-local-mode -1) (funcall (function evil-initialize))) (funcall (function evil-initialize)))
  (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn (evil-local-mode -1) (funcall (function evil-initialize))) (funcall (function evil-initialize))))
  (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn (evil-local-mode -1) (funcall (function evil-initialize))) (funcall (function evil-initialize)))))
  (save-current-buffer (set-buffer buf) (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn (evil-local-mode -1) (funcall (function evil-initialize))) (funcall (function evil-initialize))))) (setq evil-local-mode-major-mode major-mode))
  (progn (save-current-buffer (set-buffer buf) (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn (evil-local-mode -1) (funcall (function evil-initialize))) (funcall (function evil-initialize))))) (setq evil-local-mode-major-mode major-mode)))
  (if (buffer-live-p buf) (progn (save-current-buffer (set-buffer buf) (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn (evil-local-mode -1) (funcall ...)) (funcall (function evil-initialize))))) (setq evil-local-mode-major-mode major-mode))))
  (while --dolist-tail-- (setq buf (car --dolist-tail--)) (if (buffer-live-p buf) (progn (save-current-buffer (set-buffer buf) (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode (progn ... ...) (funcall ...)))) (setq evil-local-mode-major-mode major-mode)))) (setq --dolist-tail-- (cdr --dolist-tail--)))
  (let ((--dolist-tail-- evil-mode-buffers) buf) (while --dolist-tail-- (setq buf (car --dolist-tail--)) (if (buffer-live-p buf) (progn (save-current-buffer (set-buffer buf) (if evil-local-mode-set-explicitly nil (if (eq evil-local-mode-major-mode major-mode) nil (if evil-local-mode ... ...))) (setq evil-local-mode-major-mode major-mode)))) (setq --dolist-tail-- (cdr --dolist-tail--))))
  evil-mode-enable-in-buffers()
  run-hooks(after-change-major-mode-hook)
  run-mode-hooks(yaml-mode-hook)
  yaml-mode()
  set-auto-mode-0(yaml-mode nil)
  set-auto-mode()
  normal-mode(t)
  after-find-file(nil t)
  find-file-noselect-1(#<buffer main.yml<skylake>> "~/b-box/ansible/roles/skylake/tasks/main.yml" nil nil "~/b-box/ansible/roles/skylake/tasks/main.yml" (10354841 2052))
  find-file-noselect("/home/zerodi/b-box/ansible/roles/skylake/tasks/main.yml" nil nil nil)
  find-file("/home/zerodi/b-box/ansible/roles/skylake/tasks/main.yml")
  mapc(find-file ("/home/zerodi/b-box/ansible/roles/skylake/tasks/main.yml"))
  (let ((helm--reading-passwd-or-string t)) (mapc (quote find-file) (helm-marked-candidates)))
  helm-find-many-files("/home/zerodi/b-box/ansible/roles/skylake/tasks/main.yml")
  funcall(helm-find-many-files "/home/zerodi/b-box/ansible/roles/skylake/tasks/main.yml")
  (progn (funcall action selection))
  (if (and selection action) (progn (funcall action selection)))
  (let ((source (or helm-saved-current-source (helm-get-current-source))) non-essential) (setq selection (helm-coerce-selection (or selection helm-saved-selection (helm-get-selection) (and (assoc (quote accept-empty) source) "")) source)) (if preserve-saved-action nil (setq helm-saved-action nil)) (if (and selection action) (progn (funcall action selection))))
  helm-execute-selection-action-1()
  (unwind-protect (helm-execute-selection-action-1) (let ((it (get-buffer helm-action-buffer))) (if it (kill-buffer it))) (helm-log-run-hook (quote helm-after-action-hook)))
  helm-execute-selection-action()
  (if helm-quit nil (helm-execute-selection-action))
  (prog1 (if helm-quit nil (helm-execute-selection-action)) (helm-log (concat "[End session] " (make-string 41 45))))
  (let (helm-source-name helm-current-source helm-in-persistent-action helm-quit (helm-buffer (or any-buffer helm-buffer))) (let ((orig-vars57806 (mapcar (function (lambda (v) (cons v ...))) helm-restored-variables))) (unwind-protect (progn (helm-initialize any-resume any-input any-default any-sources) (helm-display-buffer helm-buffer) (if helm-prevent-escaping-from-minibuffer (progn (helm--remap-mouse-mode 1))) (add-hook (quote post-command-hook) (quote helm--maybe-update-keymap)) (add-hook (quote post-command-hook) (quote helm--update-header-line)) (helm-log "show prompt") (unwind-protect (helm-read-pattern-maybe any-prompt any-input any-preselect any-resume any-keymap any-default any-history) (helm-cleanup))) (let* ((--cl-var-- orig-vars57806) (value nil) (var nil)) (while (consp --cl-var--) (setq value (car --cl-var--) var (car-safe (prog1 value ...))) (set var value) (setq --cl-var-- (cdr --cl-var--))) nil) (helm-log "restore variables"))) (prog1 (if helm-quit nil (helm-execute-selection-action)) (helm-log (concat "[End session] " (make-string 41 45)))))
  (condition-case _v (let (helm-source-name helm-current-source helm-in-persistent-action helm-quit (helm-buffer (or any-buffer helm-buffer))) (let ((orig-vars57806 (mapcar (function (lambda ... ...)) helm-restored-variables))) (unwind-protect (progn (helm-initialize any-resume any-input any-default any-sources) (helm-display-buffer helm-buffer) (if helm-prevent-escaping-from-minibuffer (progn (helm--remap-mouse-mode 1))) (add-hook (quote post-command-hook) (quote helm--maybe-update-keymap)) (add-hook (quote post-command-hook) (quote helm--update-header-line)) (helm-log "show prompt") (unwind-protect (helm-read-pattern-maybe any-prompt any-input any-preselect any-resume any-keymap any-default any-history) (helm-cleanup))) (let* ((--cl-var-- orig-vars57806) (value nil) (var nil)) (while (consp --cl-var--) (setq value (car --cl-var--) var (car-safe ...)) (set var value) (setq --cl-var-- (cdr --cl-var--))) nil) (helm-log "restore variables"))) (prog1 (if helm-quit nil (helm-execute-selection-action)) (helm-log (concat "[End session] " (make-string 41 45))))) ((debug quit) (helm-restore-position-on-quit) (helm-log (concat "[End session (quit)] " (make-string 34 45))) nil))
  (unwind-protect (condition-case _v (let (helm-source-name helm-current-source helm-in-persistent-action helm-quit (helm-buffer (or any-buffer helm-buffer))) (let ((orig-vars57806 (mapcar (function ...) helm-restored-variables))) (unwind-protect (progn (helm-initialize any-resume any-input any-default any-sources) (helm-display-buffer helm-buffer) (if helm-prevent-escaping-from-minibuffer (progn ...)) (add-hook (quote post-command-hook) (quote helm--maybe-update-keymap)) (add-hook (quote post-command-hook) (quote helm--update-header-line)) (helm-log "show prompt") (unwind-protect (helm-read-pattern-maybe any-prompt any-input any-preselect any-resume any-keymap any-default any-history) (helm-cleanup))) (let* ((--cl-var-- orig-vars57806) (value nil) (var nil)) (while (consp --cl-var--) (setq value ... var ...) (set var value) (setq --cl-var-- ...)) nil) (helm-log "restore variables"))) (prog1 (if helm-quit nil (helm-execute-selection-action)) (helm-log (concat "[End session] " (make-string 41 45))))) ((debug quit) (helm-restore-position-on-quit) (helm-log (concat "[End session (quit)] " (make-string 34 45))) nil)) (if (fboundp (quote advice-add)) (progn (advice-remove (quote tramp-read-passwd) (function helm--advice-tramp-read-passwd)) (advice-remove (quote ange-ftp-get-passwd) (function helm--advice-ange-ftp-get-passwd))) (ad-deactivate (quote tramp-read-passwd)) (ad-deactivate (quote ange-ftp-get-passwd))) (helm-log "helm-alive-p = %S" (setq helm-alive-p nil)) (helm--remap-mouse-mode -1) (setq helm-alive-p nil) (setq helm-pattern "") (and old--cua (cua-mode 1)) (helm-log-save-maybe))
  (let ((non-essential t) (input-method-verbose-flag helm-input-method-verbose-flag) (old--cua cua-mode) (helm--maybe-use-default-as-input (and (null any-input) (or helm--maybe-use-default-as-input (let* ((--cl-var-- ...) (s nil) (--cl-flag-- t) --cl-var--) (while (and ... ...) (setq --cl-var-- ...)) --cl-var--))))) (and cua-mode (cua-mode -1)) (unwind-protect (condition-case _v (let (helm-source-name helm-current-source helm-in-persistent-action helm-quit (helm-buffer (or any-buffer helm-buffer))) (let ((orig-vars57806 (mapcar ... helm-restored-variables))) (unwind-protect (progn (helm-initialize any-resume any-input any-default any-sources) (helm-display-buffer helm-buffer) (if helm-prevent-escaping-from-minibuffer ...) (add-hook ... ...) (add-hook ... ...) (helm-log "show prompt") (unwind-protect ... ...)) (let* (... ... ...) (while ... ... ... ...) nil) (helm-log "restore variables"))) (prog1 (if helm-quit nil (helm-execute-selection-action)) (helm-log (concat "[End session] " (make-string 41 45))))) ((debug quit) (helm-restore-position-on-quit) (helm-log (concat "[End session (quit)] " (make-string 34 45))) nil)) (if (fboundp (quote advice-add)) (progn (advice-remove (quote tramp-read-passwd) (function helm--advice-tramp-read-passwd)) (advice-remove (quote ange-ftp-get-passwd) (function helm--advice-ange-ftp-get-passwd))) (ad-deactivate (quote tramp-read-passwd)) (ad-deactivate (quote ange-ftp-get-passwd))) (helm-log "helm-alive-p = %S" (setq helm-alive-p nil)) (helm--remap-mouse-mode -1) (setq helm-alive-p nil) (setq helm-pattern "") (and old--cua (cua-mode 1)) (helm-log-save-maybe)))
  helm-internal((helm-source-buffers-list helm-source-recentf helm-source-buffer-not-found) nil nil nil nil "*helm mini*" nil nil nil)
  apply(helm-internal ((helm-source-buffers-list helm-source-recentf helm-source-buffer-not-found) nil nil nil nil "*helm mini*" nil nil nil))
  (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda (key) (plist-get plist key))) helm-argument-keys))) (apply fn plist))
  (if (and helm-alive-p (eq fn (function helm))) (if (helm-alive-p) (error "Error: Trying to run helm within a running helm session") (save-current-buffer (set-buffer (helm-buffer-get)) (prog1 (message "Aborting an helm session running in background") (helm-keyboard-quit)))) (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda (key) (plist-get plist key))) helm-argument-keys))) (apply fn plist)))
  (let ((fn (cond ((or (and helm-alive-p (plist-get plist :allow-nest)) (and helm-alive-p (memq ... plist))) (function helm-nest)) ((keywordp (car plist)) (function helm)) (t (function helm-internal))))) (if (and helm-alive-p (eq fn (function helm))) (if (helm-alive-p) (error "Error: Trying to run helm within a running helm session") (save-current-buffer (set-buffer (helm-buffer-get)) (prog1 (message "Aborting an helm session running in background") (helm-keyboard-quit)))) (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda ... ...)) helm-argument-keys))) (apply fn plist))))
  helm((helm-source-buffers-list helm-source-recentf helm-source-buffer-not-found) nil nil nil nil "*helm mini*" nil nil nil)
  apply(helm ((helm-source-buffers-list helm-source-recentf helm-source-buffer-not-found) nil nil nil nil "*helm mini*" nil nil nil))
  (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda (key) (plist-get plist key))) helm-argument-keys)))
  (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda (key) (plist-get plist key))) helm-argument-keys))) (apply fn plist))
  (if (and helm-alive-p (eq fn (function helm))) (if (helm-alive-p) (error "Error: Trying to run helm within a running helm session") (save-current-buffer (set-buffer (helm-buffer-get)) (prog1 (message "Aborting an helm session running in background") (helm-keyboard-quit)))) (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda (key) (plist-get plist key))) helm-argument-keys))) (apply fn plist)))
  (let ((fn (cond ((or (and helm-alive-p (plist-get plist :allow-nest)) (and helm-alive-p (memq ... plist))) (function helm-nest)) ((keywordp (car plist)) (function helm)) (t (function helm-internal))))) (if (and helm-alive-p (eq fn (function helm))) (if (helm-alive-p) (error "Error: Trying to run helm within a running helm session") (save-current-buffer (set-buffer (helm-buffer-get)) (prog1 (message "Aborting an helm session running in background") (helm-keyboard-quit)))) (if (keywordp (car plist)) (progn (setq helm--local-variables (append helm--local-variables (helm-parse-keys plist))) (apply fn (mapcar (function (lambda ... ...)) helm-argument-keys))) (apply fn plist))))
  helm(:sources (helm-source-buffers-list helm-source-recentf helm-source-buffer-not-found) :buffer "*helm mini*" :ff-transformer-show-only-basename nil :truncate-lines t)
  helm-mini()
  call-interactively(helm-mini nil nil)
  command-execute(helm-mini)

Strangely, if I try to open this file for a second time, it works as expected.

What would be the advised way of fixing this error and / or making leader work in *Messages* buffer?

Thanks!

@zeroDivisible
Copy link
Author

A possible workaround which removes the need for the change from above is to set the initial state for *Messages* buffer to i.e. motion with:

            (evil-set-initial-state 'messages-buffer-mode 'motion)

However, the error from above still happens for me.

@mclearc
Copy link

mclearc commented Jan 21, 2016

I'm seeing a similar problem, and just for yaml files. This error didn't appear before I installed the yaml-mode package.

@HenryMarshall
Copy link

HenryMarshall commented Jan 9, 2017

This also happens using sass-mode. I wonder if it is related to significant whitespace.

If you wind up here from google, I found that general behaves similarly to evil-leader, but does not have this issue (at least with sass).

@infinisil
Copy link

Fwiw the same problem happens with .cabal files and the haskell-mode package

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

4 participants