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

Avoid killed-buffer reference on restart #1450

Merged
merged 1 commit into from
Dec 4, 2015

Conversation

rfkm
Copy link
Contributor

@rfkm rfkm commented Dec 4, 2015

Current version of cider-restart seems to cause (wrong-type-argument stringp nil) error by trying to get name of killed buffer.

Stacktrace:

Debugger entered--Lisp error: (wrong-type-argument stringp nil)
  propertize(nil face bold)
  cider-propertize-bold(nil)
  (message "Waiting for CIDER connection %s to quit..." (cider-propertize-bold (buffer-name conn)))
  (let ((project-dir (save-current-buffer (set-buffer conn) nrepl-project-dir))) (cider--quit-connection conn) (message "Waiting for CIDER connection %s to quit..." (cider-propertize-bold (buffer-name conn))) (sleep-for 2) (if project-dir (let ((default-directory project-dir)) (cider-jack-in)) (error "Can't restart CIDER connection for unknown project")))
  cider--restart-connection(#<killed buffer>)
  (if restart-all (let ((--dolist-tail-- cider-connections)) (while --dolist-tail-- (let ((conn (car --dolist-tail--))) (cider--restart-connection conn) (setq --dolist-tail-- (cdr --dolist-tail--))))) (cider--restart-connection (cider-current-connection)))
  cider-restart(nil)
  call-interactively(cider-restart record nil)
  command-execute(cider-restart record)
  helm-M-x(nil "cider-restart")
  call-interactively(helm-M-x nil nil)
  command-execute(helm-M-x)

@bbatsov
Copy link
Member

bbatsov commented Dec 4, 2015

Nice catch. Please, add a changelog entry in the "Bugs fixed" section.

@rfkm
Copy link
Contributor Author

rfkm commented Dec 4, 2015

Done.

bbatsov added a commit that referenced this pull request Dec 4, 2015
Avoid killed-buffer reference on restart
@bbatsov bbatsov merged commit fccde9b into clojure-emacs:master Dec 4, 2015
@bbatsov
Copy link
Member

bbatsov commented Dec 4, 2015

👍 Thanks!

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

Successfully merging this pull request may close these issues.

2 participants