melpa / package-build

Tools for assembling a package archive
https://github.com/melpa/melpa
25 stars 34 forks source link

package-build-current-recipe error #14

Closed stardiviner closed 6 years ago

stardiviner commented 6 years ago

I try to build a create recipe. but got error: Here is the steps:

M-x package-build-create-recipe

(ob-clojure-literate-programming
  :fetcher github
  :repo "stardiviner/ob-clojure-literate-programming")

M-x package-build-cuurrent-recipe

The recipe build result:

;; Please check the following package descriptor.
;; If the correct package description or dependencies are missing,
;; then the source .el file is likely malformed, and should be fixed.
(ob-clojure-literate-programming .
                                 [(20171222 1037)
                                  ((emacs
                                    (24 4))
                                   (org
                                    (9))
                                   (cider
                                    (0 16 0 -4)))
                                  "Clojure's Org-mode Literate Programming." single
                                  ((:commit . "d62c09f2b7837a6ac6022db37b95a21566aaaaa8")
                                   (:keywords "tools")
                                   (:url . "https://github.com/stardiviner/ob-clojure-literate-programming"))])

And the error backtrace:

Debugger entered--Lisp error: (wrong-type-argument arrayp nil)
  package-build--archive-file-name(nil)
  package-build--find-package-file("ob-clojure-literate-programming")
  package-build-current-recipe()
  funcall-interactively(package-build-current-recipe)
  call-interactively(package-build-current-recipe nil nil)
  #f(compiled-function (cmd &optional record-flag keys special) "Execute CMD as an editor command.\nCMD must be a symbol that satisfies the `commandp' predicate.\nOptional second arg RECORD-FLAG non-nil\nmeans unconditionally put this command in the variable `command-history'.\nOtherwise, that is done only if an arg is read using the minibuffer.\nThe argument KEYS specifies the value to use instead of (this-command-keys)\nwhen reading the arguments; if it is nil, (this-command-keys) is used.\nThe argument SPECIAL, if non-nil, means that this command is executing\na special event, so ignore the prefix argument and don't clear it." #<bytecode 0x24db8b>)(package-build-current-recipe nil nil nil)
  ad-Advice-command-execute(#f(compiled-function (cmd &optional record-flag keys special) "Execute CMD as an editor command.\nCMD must be a symbol that satisfies the `commandp' predicate.\nOptional second arg RECORD-FLAG non-nil\nmeans unconditionally put this command in the variable `command-history'.\nOtherwise, that is done only if an arg is read using the minibuffer.\nThe argument KEYS specifies the value to use instead of (this-command-keys)\nwhen reading the arguments; if it is nil, (this-command-keys) is used.\nThe argument SPECIAL, if non-nil, means that this command is executing\na special event, so ignore the prefix argument and don't clear it." #<bytecode 0x24db8b>) package-build-current-recipe)
  apply(ad-Advice-command-execute #f(compiled-function (cmd &optional record-flag keys special) "Execute CMD as an editor command.\nCMD must be a symbol that satisfies the `commandp' predicate.\nOptional second arg RECORD-FLAG non-nil\nmeans unconditionally put this command in the variable `command-history'.\nOtherwise, that is done only if an arg is read using the minibuffer.\nThe argument KEYS specifies the value to use instead of (this-command-keys)\nwhen reading the arguments; if it is nil, (this-command-keys) is used.\nThe argument SPECIAL, if non-nil, means that this command is executing\na special event, so ignore the prefix argument and don't clear it." #<bytecode 0x24db8b>) package-build-current-recipe)
  command-execute(package-build-current-recipe)

Then I did edebug on some functions, belowing are steps:

tarsius commented 6 years ago

Should be fixed by ef1d1e1b7401895cbd2ca555d228a8febb91de03.

If you still get that error, then that's because archive-contents is not recreated everytime a package archive is created. Call package-build-dump-archive-contents to update that file. M-x package-build-current-recipe will do it too.