progfolio / elpaca

An elisp package manager
GNU General Public License v3.0
657 stars 33 forks source link

[Support]: Debugging Failed Package Installation (chatgpt) #199

Closed ddoherty03 closed 1 year ago

ddoherty03 commented 1 year ago

Confirmation

Elpaca Version

Elpaca 86d995a HEAD -> master, origin/master, origin/HEAD installer: 0.6 emacs-version: GNU Emacs 29.1.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.33, cairo version 1.16.0) of 2023-08-08 git --version: git version 2.34.1

Operating System

Linux saturn 6.2.0-36-generic #37~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon Oct 9 15:34:04 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

Ubuntu 22.04

Description

I am trying to figure out why one of my installs failed. When I go to elpaca-log, the failed install doesn't show up. For what it's worth, I am trying to install "chatgpt" with this, but I want to know how I go about diagnosing a failed install with elpaca.

  (use-package chatgpt
    :elpaca (:host github :repo "emacs-openai/chatgpt"))
progfolio commented 1 year ago

Thanks for taking the time to fill out a support ticket.

When I go to elpaca-log, the failed install doesn't show up.

The version of Elpaca you're on (86d995a) introduced a bug in the logging. The next commit, e60ab3c fixed it. I would first try updating Elpaca to see if that fixes the logging issue. If not, you'll want to make sure the search query is not excluding the log information you're looking for. See the manual section on searching for the basics of how the search facility works. You should be able to see all of the information about the chatgtp package by using the query "chatgpt|", which will match the name of the package in the first column of the table.

Here's what I get in a test environment:

Log @2023-11-12 10:03:48 -0500 search query: "#unique | !finished"
PackageStatusInfoTime
openaifailedUnable to determine repo dir: (error "Cannot determine URL from recipe: (:protocol https :inherit t :depth 1 :package \"openai\")")531.140635
chatgptfailedFailed dependencies: (openai)531.466335

The problem is that chatgtp declares a dependency on the "openai" package. That package is not published in any ELPA which Elpaca currently supports. I've opened a ticket upstream to mention this to the maintainer of the "chatgpt" package.

You'll have to install it with a custom recipe as well. See the following test case:

Test Case [How to run this test?](https://github.com/progfolio/elpaca/wiki/Troubleshooting#the-elpaca-test-macro) ```emacs-lisp (elpaca-test :init (elpaca (openai :host github :repo "emacs-openai/openai")) (elpaca (chatgpt :host github :repo "emacs-openai/chatgpt")) (elpaca-wait) (elpaca-test-log "openai\\|chatgpt|")) ```
Host Env
elpaca039ae35 HEAD -> master, origin/master, origin/HEAD
isntaller0.6
emacsGNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.18.0) of 2023-11-02
gitgit version 2.42.0
Output ```emacs-lisp INFO Scraping files for loaddefs... INFO Scraping files for loaddefs...done GEN ../elpaca-autoloads.el Cloning into '/tmp/elpaca.D72jrf/elpaca/repos/elpaca'... Your branch is up to date with 'origin/master'. Checking /tmp/elpaca.D72jrf/elpaca/repos/elpaca... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-info.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-log.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-manager.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-menu-elpa.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-menu-melpa.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-menu-org.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-process.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-test.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca-ui.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/elpaca.el... Checking /tmp/elpaca.D72jrf/elpaca/repos/elpaca/doc... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/doc/early-init.el... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/doc/init.el... Checking /tmp/elpaca.D72jrf/elpaca/repos/elpaca/extensions... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/extensions/elpaca-use-package.el... Checking /tmp/elpaca.D72jrf/elpaca/repos/elpaca/images... Checking /tmp/elpaca.D72jrf/elpaca/repos/elpaca/test... Compiling /tmp/elpaca.D72jrf/elpaca/repos/elpaca/test/elpaca-test.el... Done (Total of 11 files compiled, 3 skipped in 4 directories) Downloading MELPA recipes... Downloading MELPA recipes...100% Downloading NonGNU-devel ELPA... Downloading GNU-devel ELPA... Downloading NonGNU ELPA... Downloading GNU ELPA... elpaca-log: "openai\\|chatgpt|" " openai cloning Cloning 05.953216 chatgpt cloning Cloning 05.953839 openai cloning Cloning into '/tmp/elpaca.D72jrf/elpaca/repos/openai'... 05.954409 chatgpt cloning Receiving objects: 100% (14/14), 2.39 MiB | 11.43 MiB/s, done. 06.483705 openai cloning Resolving deltas: 100% (9/9), done. 06.493614 chatgpt blocked Blocked by: (spinner markdown-mode ht lv openai) 06.810203 openai blocked Blocked by: (tblui request) 06.856913 chatgpt blocked Blocked by: (spinner markdown-mode ht lv openai) 06.884357 openai blocked Blocked by: (tblui request) 06.921440 chatgpt blocked Blocked by: (spinner markdown-mode ht lv openai) 07.011647 chatgpt blocked Blocked by: (spinner markdown-mode ht lv openai) 07.031980 chatgpt blocked Blocked by: (spinner markdown-mode ht openai) 07.083151 chatgpt blocked Blocked by: (markdown-mode ht openai) 07.279724 openai blocked Blocked by: (tblui) 07.320351 chatgpt blocked Blocked by: (ht openai) 07.442031 chatgpt blocked Blocked by: (openai) 08.478133 openai unblocked Unblocked by: tblui 08.878843 openai linking Linking build files 08.879636 openai linking Build files linked 08.881259 openai autoloads Generating autoloads: /tmp/elpaca.D72jrf/elpaca/builds/openai 08.882339 openai autoloads INFO Scraping files for loaddefs... 08.977459 openai autoloads INFO Scraping files for loaddefs...done 08.984968 openai autoloads GEN openai-autoloads.el 08.985964 openai autoloads Autoloads Generated 08.986846 openai byte-compilation Byte compiling 08.987611 openai byte-compilation Checking /tmp/elpaca.D72jrf/elpaca/builds/openai... 09.042483 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-audio.el... 09.047919 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-autoloads.el... 09.104163 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-chat.el... 09.109048 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-completion.el... 09.109981 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-edit.el... 09.119254 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-embedding.el... 09.129419 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-engine.el... 09.130384 openai byte-compilation In toplevel form: 09.131232 openai byte-compilation openai-engine.el:91:2: Warning: Use of deprecated ((lambda nil ...) ...) form 09.132068 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-file.el... 09.132976 openai byte-compilation In toplevel form: 09.139580 openai byte-compilation openai-file.el:216:2: Warning: Use of deprecated ((lambda nil ...) ...) form 09.140480 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-fine-tune.el... 09.141330 openai byte-compilation In toplevel form: 09.142199 openai byte-compilation openai-fine-tune.el:217:2: Warning: Use of deprecated ((lambda nil ...) ...) form 09.143089 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-image.el... 09.143916 openai byte-compilation In toplevel form: 09.149785 openai byte-compilation openai-image.el:184:2: Warning: Use of deprecated ((lambda nil ...) ...) form 09.150752 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-model.el... 09.151604 openai byte-compilation In toplevel form: 09.159893 openai byte-compilation openai-model.el:97:2: Warning: Use of deprecated ((lambda nil ...) ...) form 09.160851 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai-moderation.el... 09.161705 openai byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/openai/openai.el... 09.162702 openai byte-compilation In toplevel form: 09.163592 openai byte-compilation openai.el:93:10: Warning: in defcustom for ‘openai-parameters’: ‘list’ without arguments 09.164353 openai byte-compilation Done (Total of 12 files compiled, 1 skipped) 09.165151 openai byte-compilation Byte compilation complete 09.165930 openai info Compiling Info files 09.166721 openai info Info source files not found 09.167498 openai activation Activating package 09.168257 openai activation Package build dir added to load-path 09.169048 openai activation Caching autoloads 09.169851 openai activation Autoloads cached 09.170832 chatgpt unblocked Unblocked by: openai 09.171623 chatgpt linking Linking build files 09.172516 chatgpt linking Build files linked 09.173686 chatgpt autoloads Generating autoloads: /tmp/elpaca.D72jrf/elpaca/builds/chatgpt 09.175014 openai finished ✓ 3.233 secs 09.192101 chatgpt autoloads INFO Scraping files for loaddefs... 09.266953 chatgpt autoloads INFO Scraping files for loaddefs...done 09.269458 chatgpt autoloads GEN chatgpt-autoloads.el 09.270434 chatgpt autoloads Autoloads Generated 09.271380 chatgpt byte-compilation Byte compiling 09.272266 chatgpt byte-compilation Checking /tmp/elpaca.D72jrf/elpaca/builds/chatgpt... 09.323845 chatgpt byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/chatgpt/chatgpt-autoloads.el... 09.332290 chatgpt byte-compilation Compiling /tmp/elpaca.D72jrf/elpaca/builds/chatgpt/chatgpt.el... 09.333296 chatgpt byte-compilation In chatgpt-current-chat-point: 09.409030 chatgpt byte-compilation chatgpt.el:244:6: Warning: value from call to ‘cl-some’ is unused 09.410606 chatgpt byte-compilation In chatgpt--new-index: 09.412977 chatgpt byte-compilation chatgpt.el:314:6: Warning: value from call to ‘cl-some’ is unused 09.413986 chatgpt byte-compilation In chatgpt-mode-insert-tip: 09.423194 chatgpt byte-compilation chatgpt.el:816:8: Warning: ‘add-face-text-property’ on constant string (arg 5) 09.424140 chatgpt byte-compilation In end of data: 09.425000 chatgpt byte-compilation chatgpt.el:547:6: Warning: the function ‘openai-chat’ is not known to be defined. 09.425807 chatgpt byte-compilation Done (Total of 1 file compiled, 1 skipped) 09.426665 chatgpt byte-compilation Byte compilation complete 09.427489 chatgpt info Compiling Info files 09.428293 chatgpt info Info source files not found 09.429097 chatgpt activation Activating package 09.430038 chatgpt activation Package build dir added to load-path 09.430877 chatgpt activation Caching autoloads 09.431692 chatgpt activation Autoloads cached 09.432609 chatgpt finished ✓ 3.495 secs 09.433489 " Test Env Elpaca 039ae35 HEAD -> master, origin/master, origin/HEAD installer: 0.6 emacs-version: GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.18.0) of 2023-11-02 git --version: git version 2.42.0 ```

Does that help?

ddoherty03 commented 1 year ago

@progfolio, yes that helps a lot. Is there a way to upgrade elpaca itself?

progfolio commented 1 year ago

@progfolio, yes that helps a lot. Is there a way to upgrade elpaca itself?

Glad to hear it helps. To update the version of Elpaca you're on:

  1. M-x elpaca-update elpaca
  2. M-x restart-emacs

Note that after updating, there has been a slight API change: https://github.com/progfolio/elpaca/commit/039ae35a573af904e425b95e1cf0401e3f43537b

The new command after the update is:

  1. C-u M-x elpaca-merge elpaca
  2. M-x restart-emacs

I'll consider this closed for now. Feel free to comment if the original issue persists or open a new ticket if you run into any other issues. Thanks.