pylint and pep8 not work with emacs24.2? - emacs

i try to intergrate pylint and pep8 into my emacs24.2, via some code like (require 'python-pep8) and (require 'python-pylint) in my .emacs.But i got the error as shown below:
Debugger entered--Lisp error: (void-function define-compilation-mode)
(define-compilation-mode python-pep8-mode "PEP8" (setq python-pep8-last-buffer (current-buffer)) (set (make-local-variable (quote compilation-error-regexp-alist)) python-pep8-regexp-alist) (set (make-local-variable (quote compilation-disable-input)) t))
eval-buffer(#<buffer *load*<3>> nil "/home/zhkzyth/.emacs.d/non_forked/python-pep8.el" nil t) ; Reading at buffer position 2399
load-with-code-conversion("/home/zhkzyth/.emacs.d/non_forked/python-pep8.el" "/home/zhkzyth/.emacs.d/non_forked/python-pep8.el" nil nil)
load("non_forked/python-pep8")
eval-buffer(#<buffer *load*<2>> nil "/home/zhkzyth/.emacs.d/zhkzyth.el" nil t) ; Reading at buffer position 1353
load-with-code-conversion("/home/zhkzyth/.emacs.d/zhkzyth.el" "/home/zhkzyth/.emacs.d/zhkzyth.el" nil nil)
load("zhkzyth")
eval-buffer(#<buffer *load*> nil "/home/zhkzyth/.emacs" nil t) ; Reading at buffer position 56
load-with-code-conversion("/home/zhkzyth/.emacs" "/home/zhkzyth/.emacs" t t)
load("~/.emacs" t t)
#[0 "\205\262
It seems like the define-compilation-mode is not defined.Any idea ?

Looks like python-pep8.el is missing a
(require 'compile)
at the top.

I had the same problem, in my case pep8 was commented out in .emacs
;;(require 'python-pep8)
(require 'python-pylint)
When I remove the comment out the problem has been fixed, seems pylint requires pep8.
(require 'python-pep8)
(require 'python-pylint)

Related

EIN on Aquamacs 3.0 not working

After starting my iPython Notebook server in Terminal, I try:
M-x ein:notebooklist-open RET
this gives following error:
defvar: Symbol's value as variable is void: c-mode-syntax-table
(source: ein documentation )
I'm at a loss how to debug/fix this.
I just got the newly released Aquamacs 3.0, and installed the required packages (websocket, request, auto-complete) before installing the ein package.
Preferences.el include (probably redundant with Aquamacs 3.0):
(require 'cl)
(require 'websocket)
(require 'request)
(require 'ein)
I am on Mavericks, have been using emacs for ~2 yrs.
EDIT
for completeness sake, at request of lunaryorn:
Debugger entered--Lisp error: (void-variable c-mode-syntax-table)
byte-code("\302!\303\304\305 #\210\303\306\305 #\210 )\207" [c-mode-syntax-table table make-syntax-table modify-syntax-entry 46 "w" 95] 4)
(defvar ein:dotty-syntax-table (byte-code "\302!\303\304\305 #\210\303\306\305 #\210 )\207" [c-mode-syntax-table table make-syntax-table modify-syntax-entry 46 "w" 95] 4) ("/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-utils.elc" . 2990))
require(ein-utils)
eval-buffer(#<buffer *load*-545884> nil "/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-core.el" nil t) ; Reading at buffer position 1143
load-with-code-conversion("/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-core.el" "/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-core.el" nil t)
require(ein-core)
eval-buffer(#<buffer *load*> nil "/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-notebooklist.el" nil t) ; Reading at buffer position 952
load-with-code-conversion("/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-notebooklist.el" "/Users/pavo/Library/Application Support/Aquamacs Emacs/elpa/ein-20130711.104/ein-notebooklist.el" nil t)
autoload-do-load((autoload "ein-notebooklist" "Open notebook list buffer.\n\n(fn &optional URL-OR-PORT NO-POPUP)" t nil) ein:notebooklist-open)
command-execute(ein:notebooklist-open record)
execute-extended-command(nil "ein:notebooklist-open")
call-interactively(execute-extended-command nil nil)
command-execute(execute-extended-command)
This is a guess, c-mode-syntax-table is defined in cc-mode.el, it seems ein uses this somewhere in its code, can you do M-: (require 'cc-mode) RET and try again.

dbus error in emacs

I am trying to use notify.el on OS X, but every time get next error:
Symbol's value as variable is void: dbus-message-type-method-call
emacs --debug-init gives next output:
Debugger entered--Lisp error: (void-variable dbus-message-type-method-call)
dbus-call-method(:session "org.freedesktop.Notifications" "/org/freedesktop/DBus" "org.freedesktop.DBus.Peer" "Ping")
byte-code("\305^H!\203^S^#\306 \n^K\f\307\310^H&^G\202^Z^#\306 \n^K\f\307%?\207" [timeout bus service dbus-path-dbus dbus-interface-peer natnump dbus-call-method "Ping" :timeout] 8)
dbus-ping(:session "org.freedesktop.Notifications")
(and (require (quote dbus) nil t) (dbus-ping :session "org.freedesktop.Notifications"))
(cond ((executable-find "growlnotify") (quote notify-via-growl)) ((and (require (quote dbus) nil t) (dbus-ping :session "org.freedesktop.Notifications")) (defvar notify-id 0 "Current D-Bus notification$
(setq notify-method (cond ((executable-find "growlnotify") (quote notify-via-growl)) ((and (require (quote dbus) nil t) (dbus-ping :session "org.freedesktop.Notifications")) (defvar notify-id 0 "Curren$
(cond ((null notify-method) (setq notify-method (cond ((executable-find "growlnotify") (quote notify-via-growl)) ((and (require (quote dbus) nil t) (dbus-ping :session "org.freedesktop.Notifications"))$
eval-buffer(#<buffer *load*-569235> nil "/Users/araeris/.emacs.d/packages/notify/notify.el" nil t) ; Reading at buffer position 3614
load-with-code-conversion("/Users/araeris/.emacs.d/packages/notify/notify.el" "/Users/araeris/.emacs.d/packages/notify/notify.el" nil t)
require(notify)
(if (fboundp name) nil (add-to-list (quote load-path) (concat (file-name-directory (or load-file-name (buffer-file-name))) "packages/" (symbol-name name))) (require name))
(progn (if (fboundp name) nil (add-to-list (quote load-path) (concat (file-name-directory (or load-file-name (buffer-file-name))) "packages/" (symbol-name name))) (require name)))
(while (consp --cl-var--) (setq name (car --cl-var--)) (progn (if (fboundp name) nil (add-to-list (quote load-path) (concat (file-name-directory (or load-file-name (buffer-file-name))) "packages/" (sym$
(let* ((--cl-var-- packages) (name nil)) (while (consp --cl-var--) (setq name (car --cl-var--)) (progn (if (fboundp name) nil (add-to-list (quote load-path) (concat (file-name-directory (or load-file-n$
(progn (let* ((--cl-var-- packages) (name nil)) (while (consp --cl-var--) (setq name (car --cl-var--)) (progn (if (fboundp name) nil (add-to-list (quote load-path) (concat (file-name-directory ...) "pa$
eval-buffer(#<buffer *load*> nil "/Users/araeris/.emacs.d/init.el" nil t) ; Reading at buffer position 1796
load-with-code-conversion("/Users/araeris/.emacs.d/init.el" "/Users/araeris/.emacs.d/init.el" t t)
load("/Users/araeris/.emacs.d/init" t t)
#[0 "^H\205\262^# \306=\203^Q^#\307^H\310Q\202;^# \311=\204^^^#\307^H\312Q\202;^#\313\307\314\315#\203*^#\316\202;^#\313\307\314\317#\203:^#\320\nB^R\321\202;^#\316\322^S\323^A\322\211#\210^K\322=\$
command-line()
normal-top-level()
Does anyone knows how to handle it?
P. S. I already installed dbus via homebrew.
You'll need to build Emacs with DBus support to actually use DBus. On OS X, that's rather unusual, and I can't see what you'd want to use DBus support in Emacs for, given that nothing else uses DBus on OS X.
If you're just after notifications, though, you don't need DBus. In fact, DBus won't give you notifications on OS X.
For notifications on OS X with notify.el, you need Growl. Namely, you must purchase Growl in the AppStore, or build it yourself, and additionally install Growlnotifier from http://growl.info/downloads.

(error "Buffer *scratch* was not set up for parsing")

I'm struggling to enable CEDET on Emacs (so I can get intellisense through auto-complete and such) and I came across this weird error:
Debugger entered--Lisp error: (error "Buffer *scratch* was not set up for parsing")
signal(error ("Buffer *scratch* was not set up for parsing"))
error("Buffer %s was not set up for parsing" "*scratch*")
semantic-idle-summary-mode()
eval-buffer(#<buffer *load*-660706> nil "/home/jorge/.emacs.d/conf-modes/cedet.el" nil t) ; Reading at buffer position 991
load-with-code-conversion("/home/jorge/.emacs.d/conf-modes/cedet.el" "/home/jorge/.emacs.d/conf-modes/cedet.el" nil nil)
load("/home/jorge/.emacs.d/conf-modes/cedet.el" nil nil t)
load-file("~/.emacs.d/conf-modes/cedet.el")
eval-buffer(#<buffer *load*-280517> nil "/home/jorge/.emacs.d/varl.el" nil t) ; Reading at buffer position 615
load-with-code-conversion("/home/jorge/.emacs.d/varl.el" "/home/jorge/.emacs.d/varl.el" nil nil)
load("/home/jorge/.emacs.d/varl.el" nil nil t)
load-file("~/.emacs.d/varl.el")
eval-buffer(#<buffer *load*> nil "/home/jorge/.emacs" nil t) ; Reading at buffer position 373
load-with-code-conversion("/home/jorge/.emacs" "/home/jorge/.emacs" t t)
load("~/.emacs" t t)
#[0 "\205\262 [...]
command-line()
normal-top-level()
Here is my CEDET configuration, written after painful experimentation and reading many posts on the Internet:
;;
;; configuraciĆ³n de CEDET
;;incia CEDET
(semantic-mode 1)
(global-ede-mode 1)
(ede-enable-generic-projects)
(add-to-list 'semantic-default-submodes 'global-semantic-decoration-mode)
(add-to-list 'semantic-default-submodes 'global-semantic-idle-local-symbol-highlight-mode)
(add-to-list 'semantic-default-submodes 'global-semantic-idle-scheduler-mode)
(add-to-list 'semantic-default-submodes 'global-semantic-idle-completions-mode)
(add-to-list 'semantic-default-submodes 'global-semanticdb-minor-mode)
(add-to-list 'semantic-default-submodes 'global-semantic-mru-bookmark-mode)
(add-to-list 'semantic-default-submodes 'global-cedet-m3-minor-mode)
(add-to-list 'semantic-default-submodes 'global-semantic-highlight-func-mode)
(semanticdb-enable-gnu-global-databases 'c-mode t)
(semanticdb-enable-gnu-global-databases 'c++-mode t)
;(semantic-load-enable-minimum-features) ;;Debugger entered--Lisp error: (void-function semantic-load-enable-minimum-features)
(semantic-idle-summary-mode)
(semantic-idle-completions-mode)
(when (cedet-ectag-version-check t) ;; Debugger entered--Lisp error: (void-function cedet-ectag-version-check)
(semantic-load-enable-primary-ectags-support))
This is what I'm requireing at startup:
(require 'semantic/bovine/gcc)
(require 'semantic/ia)
(require 'ecb)
and finally, my emacs version: GNU Emacs 24.3.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.8.2) of 2013-08-06 on -mnt-storage-buildroots-staging-x86_64-eric
What I'm doing wrong and how can I fix this? Thanks!

[emacs][Tuareg-mode] Symbol's function definition is void: dolist

I tried to install Tuareg-mode for Ocaml as advice on the Inria website.
Any time I try to launch it I have this error :
Symbol's function definition is void: dolist
With edebug-defun
Debugger entered--Lisp error: (void-function dolist)
apply(debug error (void-function dolist))
edebug(error (void-function dolist))
(dolist (buf (buffer-list)) (save-current-buffer (set-buffer buf) (if (derived-mode-p (quote tuareg-mode)) (progn (abbrev-mode (if val 1 -1))))))
(lambda (var val) (set-default var val) (dolist (buf (buffer-list)) (save-current-buffer (set-buffer buf) (if (derived-mode-p (quote tuareg-mode)) (progn (abbrev-mode (if val 1 -$
custom-initialize-reset(tuareg-use-abbrev-mode t)
custom-declare-variable(tuareg-use-abbrev-mode t "*Non-nil means electrically indent lines starting with leading keywords.\nLeading keywords are such as `end', `done', `else' etc$
eval-buffer(#<buffer *load*> nil "/nfs/ring/users/2013/phibonacci/.emacs.d/tuareg-mode/tuareg.el" nil t) ; Reading at buffer position 13589
load-with-code-conversion("/nfs/ring/users/2013/phibonacci/.emacs.d/tuareg-mode/tuareg.el" "/nfs/ring/users/2013/phibonacci/.emacs.d/tuareg-mode/tuareg.el" nil t)
command-execute(tuareg-mode record)
execute-extended-command(nil "tuareg-mode")
call-interactively(execute-extended-command nil nil)
recursive-edit()
edebug--recursive-edit(before)
edebug--display(nil 0 before)
edebug-debugger(0 before nil)
edebug-before(0)
(edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml code" t))
(lambda nil (edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml code" t)))()
edebug-enter(edebug-anon0 nil (lambda nil (edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml code" t))))
edebug-enter(edebug-anon0 nil (lambda nil (edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml code" t))))
eval((edebug-enter (quote edebug-anon0) nil (function (lambda nil (edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml code" t)))$
eval-expression((edebug-enter (quote edebug-anon0) nil (function (lambda nil (edebug-after (edebug-before 0) 1 (autoload (quote tuareg-mode) "tuareg" "Major mode for editing Caml$
edebug-defun()
call-interactively(edebug-defun record nil)
command-execute(edebug-defun record)
execute-extended-command(nil "edebug-defun")
call-interactively(execute-extended-command nil nil)
"/nfs/ring/users/2013/phibonacci" is my home directory.
I followed this : http://www.emacswiki.org/emacs/TuaregMode (only replaced ~/.elisp/tuareg-mode by my own path ~/.emacs.d/tuareg-mode)
emacs 24.3.1 (2013) /
tuareg 2.0.6 (2012)
dolist is from the common lisp Emacs library. If tuareg uses dolist without an (eval-when-compile ...(require 'cl)...) it's a bug. As a workaround you can do (require 'cl) in your .emacs. This is not recommended by the purist Emacs community, but it's fairly common.
IIRC dolist was added to standard Elisp sometimes around Emacs-21, so there's something really wrong with your setup.

Symbol's function definition is void: declare-function

New to emacs. GNU Emacs 22.1.1 on OSX.
Installed evil as per instructions. I get:
Symbol's function definition is void: declare-function
emacs --debug-init gives:
Debugger entered--Lisp error: (void-function declare-function)
(declare-function evil-visual-state-p "evil-visual")
eval-buffer(#<buffer *load*<3>> nil "/Users/rahul/.emacs.d /evil/evil-repeat.el" nil t) ; Reading at buffer pos$
load-with-code-conversion("/Users/rahul/.emacs.d/evil/evil- repeat.el" "/Users/rahul/.emacs.d/evil/evil-repeat.el$
require(evil-repeat)
eval-buffer(#<buffer *load*<2>> nil "/Users/rahul/.emacs.d /evil/evil.el" nil t) ; Reading at buffer position 1$
load-with-code-conversion("/Users/rahul/.emacs.d/evil/evil.el" "/Users/rahul/.emacs.d/evil/evil.el" nil t)
require(evil)
eval-buffer(#<buffer *load*> nil "/Users/rahul/.emacs" nil t) ; Reading at buffer position 122
load-with-code-conversion("/Users/rahul/.emacs"
"/Users/rahul/.emacs" t t)
load("~/.emacs" t t)
#[nil "^H\205\276^# \306=\203^Q^#\307^H\310Q\202A^# \311=\2033^#\312\307\313\314#\203#^#\315\202A^#\312\307\31$
command-line()
normal-top-level()
My .emacs has:
;;; Emacs Load Path
(setq load-path (cons "~/bin" load-path))
(add-to-list 'load-path "~/.emacs.d/evil")
(require 'evil)
(evil-mode 1)
(require 'undo-tree)
Emacs 22.1 is now old (mid-2007). You want either the latest 23.x or the latest 24.x pre-test from http://emacsformacosx.com/