Malabarba / spinner.el

Emacs mode-line spinner for operations in progress
104 stars 21 forks source link

Assumes mode-line-format is a list. #1

Closed jordonbiondo closed 5 years ago

jordonbiondo commented 9 years ago

The package assumes that mode-line-format is a list and tries modify it, however the mode line format is not always a list. Fromt the docs:

The value may be nil, a string, a symbol or a list.

The package errors when it is not a list. If it is not a list you could simply take the current symbol or string and set the mode-line-format to a list where the existing value is the car.

Malabarba commented 8 years ago

Sorry for not replying to this earlier. Github didn't notify me for some reason. the implementation changed quite a bit and we no longer edit this variable directly.

However, we still edit the mode-line-process, so I'm leaving this open as a reminder.

yyoncho commented 5 years ago

I hit this when working in sh file.

Debugger entered--Lisp error: (wrong-type-argument listp "[bin]")
  spinner-start(progress-bar-filled)
  (condition-case err (spinner-start 'progress-bar-filled) ((debug error) (message "Unable to start spinner. Error: %s" err) nil))
  lsp--spinner-start()
  eval((lsp--spinner-start) nil)
  eval-expression((lsp--spinner-start) nil nil 127)
  funcall-interactively(eval-expression (lsp--spinner-start) nil nil 127)
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)
Malabarba commented 5 years ago

I've added a check for that, let me know if it solves the problem.

yyoncho commented 5 years ago

@Malabarba thanks for the fix! It seems to work. Is it possible to roll out a release?