bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#27789: 26.0.50; grep-apply-setting: wrong-type-argument consp nil


From: Kaushal Modi
Subject: bug#27789: 26.0.50; grep-apply-setting: wrong-type-argument consp nil
Date: Sat, 22 Jul 2017 04:03:59 +0000

Hello,

I believe I started seeing this error after this commit[1].

I get the error when attempting to use ag search from ag.el[2].

=====
Debugger entered--Lisp error: (wrong-type-argument consp nil)
  grep-apply-setting(grep-use-null-filename-separator t)
  custom-initialize-reset(grep-use-null-filename-separator (funcall (function #f(compiled-function () #<bytecode>))))
  custom-declare-variable(grep-use-null-filename-separator (funcall (function #f(compiled-function () #<bytecode>))) "If non-nil, use `grep's `--null' option.\nThis is done to disambiguate file names in `grep's output." :type (choice (const :tag "Do Not Use `--null'" nil) (const :tag "Use `--null'" t) (other :tag "Not Set" auto-detect)) :set grep-apply-setting :group grep)
  byte-code("\300\301\302\303\304DD\305\306\307\310\311\312\313&\011\210\300\314\302\303\315DD\316\306\317\320\321\310\311\312\313&\013\210\300\322\302\303\323DD\324\306\325\310\311\312\313&\011\210\300\326\302\303\327DD\330\306\331\320\321\312\313&\011\210\300\332\302\303\333DD\334\306\335\320\321\310\311\312\313&\013\210\300\336\302\303\337DD\340\306\341\320\321\312\313&\011\210\300\342\302\303\343DD\344\306\345\320\321\312\313&\011\210\300\346\302\303\347DD\350\306\351\320\321\312\313&\011\210\300\352\302\303\353DD\354\306\355\320\321\310\311\312\313&\013\210\300\356\302\303\357DD\360\306\361\312\313&\007\210\300\362\302\303\363DD\364\306\365\312\313&\007\210\300\366\302\303\367DD\370\306\371\312\313&\007\210\300\372\302\303\373DD\374\310\375\306\376\312\313&\011\210\300\377\302\303\201@\0\ DD\201A\0\306\201B\0\310\311\312\313&\011\210\300\201C\0\302\303\201D\0\ DD\201E\0\306\201F\0\312\313&\007\207" [custom-declare-variable grep-window-height funcall function #f(compiled-function () #<bytecode>) "Number of lines in a grep window.  If nil, use `compilation-window-height'." :type (choice (const :tag "Default" nil) integer) :version "22.1" :group grep grep-highlight-matches #f(compiled-function () #<bytecode>) "Use special markers to highlight grep matches.\n\nSome grep programs are able to surround matches with special\nmarkers in grep output.  Such markers can be used to highlight\nmatches in grep mode.  This requires `font-lock-mode' to be active\nin grep buffers, so if you have globally disabled font-lock-mode,\nyou will not get highlighting.\n\nThis option sets the environment variable GREP_COLORS to specify\nmarkers for highlighting and adds the --color option in front of\nany explicit grep options before starting the grep.\n\nWhen this option is `auto', grep uses `--color' to highlight\nmatches only when it outputs to a terminal (when `grep' is the last\ncommand in the pipe), thus avoiding the use of any potentially-harmful\nescape sequences when standard output goes to a file or pipe.\n\nTo make grep highlight matches even into a pipe, you need the option\n`always' that forces grep to use `--color=always' to unconditionally\noutput escape sequences.\n\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults' when the default value is `auto-detect'.\nTo change the default value, use Customize or call the function\n`grep-apply-setting'." (choice (const :tag "Do not highlight matches with grep markers" nil) (const :tag "Highlight matches with grep markers" t) (const :tag "Use --color=always" always) (const :tag "Use --color" auto) (other :tag "Not Set" auto-detect)) :set grep-apply-setting grep-scroll-output #f(compiled-function () #<bytecode>) "Non-nil to scroll the *grep* buffer window as output appears.\n\nSetting it causes the grep commands to put point at the end of their\noutput window so that the end of the output is always visible rather\nthan the beginning." boolean grep-command #f(compiled-function () #<bytecode>) "The default grep command for \\[grep].\nIf the grep program used supports an option to always include file names\nin its output (such as the `-H' option to GNU grep), it's a good idea to\ninclude it when specifying `grep-command'.\n\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults'; to change the default value, use\nCustomize or call the function `grep-apply-setting'." (choice string (const :tag "Not Set" nil)) grep-template #f(compiled-function () #<bytecode>) "The default command to run for \\[lgrep].\nThe following place holders should be present in the string:\n <C> - place to put the options like -i and --color.\n <F> - file names and wildcards to search.\n <X> - file names and wildcards to exclude.\n <R> - the regular _expression_ searched for.\n <N> - place to insert null-device.\n\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults'; to change the default value, use\nCustomize or call the function `grep-apply-setting'." (choice string (const :tag "Not Set" nil)) grep-use-null-device #f(compiled-function () #<bytecode>) "If t, append the value of `null-device' to `grep' commands.\nThis is done to ensure that the output of grep includes the filename of\nany match in the case where only a single file is searched, and is not\nnecessary if the grep program used supports the `-H' option.\n\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults'; to change the default value, use\nCustomize or call the function `grep-apply-setting'." (choice (const :tag "Do Not Append Null Device" nil) (const :tag "Append Null Device" t) (other :tag "Not Set" auto-detect)) grep-use-null-filename-separator #f(compiled-function () #<bytecode>) "If non-nil, use `grep's `--null' option.\nThis is done to disambiguate file names in `grep's output." (choice (const :tag "Do Not Use `--null'" nil) (const :tag "Use `--null'" t) (other :tag "Not Set" auto-detect)) grep-find-command #f(compiled-function () #<bytecode>) "The default find command for \\[grep-find].\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults'; to change the default value, use\nCustomize or call the function `grep-apply-setting'." (choice string (const :tag "Not Set" nil)) grep-find-template #f(compiled-function () #<bytecode>) "The default command to run for \\[rgrep].\nThe following place holders should be present in the string:\n <D> - base directory for find\n <X> - find options to restrict or expand the directory list\n <F> - find options to limit the files matched\n <C> - place to put the grep options like -i and --color\n <R> - the regular _expression_ searched for.\nIn interactive usage, the actual value of this variable is set up\nby `grep-compute-defaults'; to change the default value, use\nCustomize or call the function `grep-apply-setting'." (choice string (const :tag "Not Set" nil)) grep-files-aliases #f(compiled-function () #<bytecode>) "Alist of aliases for the FILES argument to `lgrep' and `rgrep'." alist grep-find-ignored-directories #f(compiled-function () #<bytecode>) "List of names of sub-directories which `rgrep' shall not recurse into.\nIf an element is a cons cell, the car is called on the search directory\nto determine whether cdr should not be recursed into." (choice (repeat :tag "Ignored directories" string) (const :tag "No ignored directories" nil)) grep-find-ignored-files #f(compiled-function () #<bytecode>) "List of file names which `rgrep' and `lgrep' shall exclude.\nIf an element is a cons cell, the car is called on the search directory\nto determine whether cdr should not be excluded." (choice (repeat :tag "Ignored file" string) (const :tag "No ignored files" nil)) grep-save-buffers #f(compiled-function () #<bytecode>) "If non-nil, save buffers before running the grep commands.\nIf `ask', ask before saving.  If a function, call it with no arguments\nwith each buffer current, as a predicate to determine whether that\nbuffer should be saved or not.  E.g., one can set this to\n  (lambda ()\n    (string-prefix-p my-grep-root (file-truename (buffer-file-name))))\nto limit saving to files located under `my-grep-root'." "26.1" (choice (const :tag "Ask before saving" ask) (const :tag "Don't save buffers" nil) function (other :tag "Save all buffers" t)) grep-error-screen-columns #f(compiled-function () #<bytecode>) "If non-nil, column numbers in grep hits are screen columns.\nSee `compilation-error-screen-columns'" (choice (const :tag "Default" nil) integer) grep-setup-hook #f(compiled-function () #<bytecode>) "List of hook functions run by `grep-process-setup' (see `run-hooks')." hook] 12)
  #<subr require>(grep nil nil)
  ad-Advice-require(#<subr require> grep)
  apply(ad-Advice-require #<subr require> grep)
  require(grep)
  byte-code("\300\301!\210\302\303\304\305\306\307\310\301&\007\210\311\312\304\313\310\303\314\315&\007\210\311\316\317\320\310\303\314\321&\007\210\311\322\304\323\310\303\314\315&\007\207" [require grep custom-declare-group wgrep nil "Customize wgrep" :prefix "wgrep-" :group custom-declare-variable wgrep-change-readonly-file "Non-nil means to enable change read-only files." :type boolean wgrep-enable-key "\003\020" "This variable will be obsoleted in the future release.\nKey to enable `wgrep-mode'." string wgrep-auto-save-buffer "Non-nil means do `save-buffer' automatically while `wgrep-finish-edit'."] 8)
  #<subr require>(wgrep nil nil)
  ad-Advice-require(#<subr require> wgrep)
  apply(ad-Advice-require #<subr require> wgrep)
  require(wgrep)
  byte-code("\300\301!\210\300\302!\207" [require wgrep cl-lib] 2)
  wgrep-ag-setup()
  run-hooks(change-major-mode-after-body-hook compilation-mode-hook ag-mode-hook)
  apply(run-hooks (change-major-mode-after-body-hook compilation-mode-hook ag-mode-hook))
  run-mode-hooks(ag-mode-hook)
  ag-mode()
  compilation-start("ag --nogroup --line-number --column --color --color-match 30\\;43 --color-path 1\\;32 --nogroup --skip-vcs-ignores --numbers --smart-case --follow --ignore \\#\\*\\# --stats -- preserve-breaks ." ag-mode (lambda (mode-name) "*ag search regexp:preserve-breaks dir:~/stow/pub_dotfiles/emacs/dot-emacs.d/elisp/org-mode/*"))
  ag/search("preserve-breaks" "~/stow/pub_dotfiles/emacs/dot-emacs.d/elisp/org-mode/" :regexp t)
  ag-project-regexp("preserve-breaks")
  funcall-interactively(ag-project-regexp "preserve-breaks")
  call-interactively(ag-project-regexp nil nil)
  command-execute(ag-project-regexp)
=====

PS: @Noam: Thanks for making the elisp backtrace copyable :)

[1]: http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=644cdd1aa0a10dbfffa3b9b4c7a97f8cddded0b8
[2]: https://github.com/Wilfred/ag.el
--

Kaushal Modi


reply via email to

[Prev in Thread] Current Thread [Next in Thread]