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

ess layer breaks org-mode keybindings #7890

Closed
leezu opened this issue Dec 1, 2016 · 6 comments
Closed

ess layer breaks org-mode keybindings #7890

leezu opened this issue Dec 1, 2016 · 6 comments

Comments

@leezu
Copy link
Contributor

leezu commented Dec 1, 2016

Description :octocat:

Enabling the ess layer breaks org-mode keybindings, such as t for org-todo (which changes the TODO state of an item).

I have verified this issue with a fresh spacemacs install containing only the org and ess layers.

Reproduction guide 🪲

  • Start Emacs
  • Enable org layer and reload config
  • Restart
  • Make sure t works for org-todo
  • Enable ess layer and reload config
  • Restart
  • t will not work anymore and is instead bound to evil-find-char-to

Observed behaviour: 👀 💔

  • t will not work anymore and is instead bound to evil-find-char-to

Expected behaviour: ❤️ 😄

  • t continues to work

System Info 💻

  • OS: gnu/linux
  • Emacs: 24.5.1
  • Spacemacs: 0.200.5
  • Spacemacs branch: master (rev. 664ba6a)
  • Graphic display: t
  • Distribution: spacemacs
  • Editing style: vim
  • Completion: helm
  • Layers:
(helm emacs-lisp org ess)
@izahn
Copy link
Contributor

izahn commented Dec 2, 2016

Pretty sure this is a symptom of a busted org loading process as reported in several other issues. It usually works for me to

  1. remove org if installed
  2. remove org-plus-contrib
  3. reinstall org-plus-contrib

@bmag
Copy link
Collaborator

bmag commented Dec 10, 2016

This bug report is missing some information:

Make sure t works for org-todo

How do you make sure? How do you determine if it works? What are the exact steps?

@leezu
Copy link
Contributor Author

leezu commented Dec 10, 2016

I mean make sure org-todo is bound to t and not any other function. You may test this by either pressing t and see if it changes the TODO state of an org item or by calling describe-key, asking which function is bound to the key t.

@bmag
Copy link
Collaborator

bmag commented Dec 10, 2016

I managed to repro this behavior, and indeed it is weird. For those wondering, here are the repro steps:

  • have org and ess layers enabled and installed
  • start Emacs
  • open an Org file
  • press SPC h d k t

Observed behavior: help buffer opens saying that "t runs the command evil-find-char-to".
Expected behavior: help buffer opens saying that "t runs the command org-todo".

Edit: forgot to add:

System Info 💻

  • OS: gnu/linux
  • Emacs: 25.1.1
  • Spacemacs: 0.200.5
  • Spacemacs branch: develop (rev. afa2226)
  • Graphic display: t
  • Distribution: spacemacs
  • Editing style: hybrid
  • Completion: helm
  • Layers:
(helm
 (auto-completion :variables auto-completion-enable-snippets-in-popup nil auto-completion-enable-help-tooltip 'manual company-tooltip-align-annotations t)
 command-log dash evil-cleverparens
 (git :variables git-magit-status-fullscreen t)
 ibuffer imenu-list nlinum org pdf-tools ranger
 (shell :variables shell-default-shell 'shell shell-default-height 30 shell-default-position 'bottom :packages
        (not company))
 smex syntax-checking version-control yaml c-c++
 (clojure :variables clojure-enable-fancify-symbols nil)
 emacs-lisp
 (latex :variables latex-enable-auto-fill t latex-enable-folding t)
 markdown octave python ruby rust common-lisp org-tweaks spaceline-tweaks verilog window-tweaks themes-megapack
 (theming :variables theming-modifications
          '((spacemacs-dark
             (aw-leading-char-face :foreground "red" :height 3.0))
            (spacemacs-light
             (aw-leading-char-face :foreground "red" :height 3.0))
            (monokai
             (aw-leading-char-face :foreground "red" :height 3.0))
            (flatland
             (aw-leading-char-face :foreground "red" :height 3.0)))))
  • System configuration features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GCONF GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11

@bmag
Copy link
Collaborator

bmag commented Dec 10, 2016

There is also an error in the echo-area when opening the org file (at first it was hidden from me by a later unrelated message). I turned on debug-on-error (before opening a new org file) and got this backtrace:

Debugger entered--Lisp error: (invalid-function org-babel-header-args-safe-fn)
  org-babel-header-args-safe-fn((:cache :colnames :comments :exports :epilogue :hlines :noeval :noweb :noweb-ref :noweb-sep :padline :prologue :rownames :sep :session :tangle :wrap (:eval "never" "query") (:results lambda (str) (not (string-match "file" str))) :width :height :bg :units :pointsize :antialias :quality :compression :res :type :family :title :fonts :version :paper :encoding :pagecentre :colormodel :useDingbats :horizontal))
  byte-code("\301\302\303\304�!#\210\305\306\307\310\311DD\312\313\314\315\316\317\320&	\207" [ob-R-safe-header-args put org-babel-default-header-args:R safe-local-variable org-babel-header-args-safe-fn custom-declare-variable org-babel-R-command funcall function #[0 "\300\207" ["R --slave --no-save"] 1 "R --slave --no-save"] "Name of command to use for executing R code." :group org-babel :version "24.1" :type string] 10)
  require(ob-R)
  org-babel-do-load-languages(org-babel-load-languages ((python . t) (R . t) (clojure . t) (shell . t) (emacs-lisp . t)))
  spacemacs//org-babel-do-load-languages()
  run-hooks(change-major-mode-after-body-hook text-mode-hook outline-mode-hook org-mode-hook)
  apply(run-hooks (change-major-mode-after-body-hook text-mode-hook outline-mode-hook org-mode-hook))
  run-mode-hooks(org-mode-hook)
  org-mode()
  set-auto-mode-0(org-mode nil)
  set-auto-mode()
  normal-mode(t)
  after-find-file(nil nil t nil nil)
  revert-buffer--default(nil nil)
  revert-buffer(nil nil)
  spacemacs/safe-revert-buffer()
  funcall-interactively(spacemacs/safe-revert-buffer)
  call-interactively(spacemacs/safe-revert-buffer nil nil)
  command-execute(spacemacs/safe-revert-buffer)

I've managed to solve the problem by recompiling ob-R.el: I opened directory elpa/org-plus-contrib-* with M-x dired, went to ob-R.el and then pressed B to byte-compile the file. I agree with @izahn that it's "a symptom of a busted org loading process" or a symptom of a busted installation and compilation process.

@bmag
Copy link
Collaborator

bmag commented Dec 10, 2016

@leezu I'm assuming recompiling ob-R.el will fix your issue, so I'm closing this issue in favor of #4618. If recompiling doesn't help, feel free to go over the discussion in that PR to see what else you can try to fix the issue, and if you have new input you can post comments there.

@bmag bmag closed this as completed Dec 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants