bastibe / org-journal

A simple org-mode based journaling mode
BSD 3-Clause "New" or "Revised" License
1.24k stars 124 forks source link

"error: Invalid version syntax" thrown after loading org-journal #325

Closed markbil closed 3 years ago

markbil commented 3 years ago

I just installed org-journal (20210119.2137) through melpa, and added (require 'org-journal) to my init.el.

when I (re-)start emacs I receive the following error, which points back to the (require 'org-journal) line in init.el:

Warning (initialization): An error occurred while loading ‘/home/marjan/.emacs.d/init.el’:
error: Invalid version syntax: ‘’ (must start with a number)

Is this a bug? If it's not, any ideas what I am doing wrong?

emacs --debug-init throws the following details:

Debugger entered--Lisp error: (error "Invalid version syntax: ‘’ (must start with a number)")
  signal(error ("Invalid version syntax: ‘’ (must start with a number)"))
  error("Invalid version syntax: `%s' (must start with a number)" "")
  version-to-list("")
  version<("" "9.2")
  byte-code("\301\302!\210\301\303!\210\301\304!\210\301\305!\210\301\306!\210\301\307!\210\310\10\311\"\203$\0\312\313\314\"\210\315\316!\2044\0\312\317\320\"\210\312\316\317..." [org-version require cal-iso epa org org-crypt seq subr-x version< "9.2" defalias org-set-tags-to org-set-tags fboundp org--tag-add-to-alist org-tag-add-to-alist #f(compiled-function (alist1 alist2) "Append ALIST1 elements to ALIST2 if they are not there yet.\n\nFrom branch \"emacs-26\", added for compatibility." #<bytecode 0x1570dbdb2e31>) custom-declare-group org-journal nil "Settings for the personal journal" :group custom-declare-face org-journal-highlight ((t (:foreground "#ff1493"))) "Face for highlighting org-journal buffers."] 8)
  require(org-journal)
  eval-buffer(#<buffer  *load*> nil "/home/marjan/.emacs.d/init.el" nil t)  ; Reading at buffer position 11151
  load-with-code-conversion("/home/marjan/.emacs.d/init.el" "/home/marjan/.emacs.d/init.el" t t)
  load("/home/marjan/.emacs.d/init" noerror nomessage)
  startup--load-user-init-file(#f(compiled-function () #<bytecode 0x1570db6deedd>) #f(compiled-function () #<bytecode 0x1570db6deef1>) t)
  command-line()
  normal-top-level()
markbil commented 3 years ago

I just tried installing and loading v2.1.1 through melpa-stable - getting same error.

markbil commented 3 years ago

alright, I realised this has nothing to do with org-journal, but is rather a problem due to a mixed installation of the built-in version of org that is bundled into emacs and a newer, manually updated version of org. more specifically, the variable org-version somehow ended up being an empty string, which caused the issue described above. I deleted the newer (manually installed) version of org-mode, and installed a fresh one through Org Elpa archive which solved the issue. (to double-check run C-h v org-version - which after the re-installation showed that the variable is not an empty string any more, but actually contains org's version number)