egh / zotxt-emacs

142 stars 11 forks source link

Markdown completion-at-point 'peculiar error' #65

Open steveb-123 opened 2 years ago

steveb-123 commented 2 years ago

Attempting to set up zotxt and zotxt-emacs for the first time I am having trouble getting completion-at-point working. I don't know if this is a zotxt or zotxt-emacs or just a setup problem of my own, unfortunately.

In a markdown file with zotxt-citekey-mode enabled, if I type @doe then M-x completion-at-point I get an error message peculiar error, and, sadly, no citation completion options appear.

If in zotero I enable debugging and repeat this, I get the following messages, which appear to relate to easykeys somehow.

version => 6.0.8, platform => Linux x86_64, oscpu => Linux x86_64, locale => en-US, appName => Zotero, appVersion => 6.0.8, extensions => ZotFile (5.1.1, extension), DOI Manager (1.4.2, extension), Zotero PMCID fetcher (0.0.13, extension), Better BibTex for Zotero (6.7.13, extension), zotxt (6.0.2, extension), Zotero LibreOffice Integration (6.0.0.SA.6.0.8, extension)

(5)(+0032019): GET /zotxt/complete?citekey=Bar HTTP/1.1 Host: 127.0.0.1:23119 User-Agent: curl/7.83.1 Accept: */* Accept-Encoding: deflate, gzip, br, zstd

(5)(+0000004): HTTP/1.0 400 Bad Request X-Zotero-Version: 6.0.8 X-Zotero-Connector-API-Version: 2 Content-Type: application/json; charset=UTF-8 "Option easykey is required."

(5)(+0000019): GET /zotxt/version HTTP/1.1 Host: 127.0.0.1:23119 User-Agent: curl/7.83.1 Accept: */* Accept-Encoding: deflate, gzip, br, zstd

(5)(+0000002): HTTP/1.0 200 OK X-Zotero-Version: 6.0.8 X-Zotero-Connector-API-Version: 2 Content-Type: application/json; charset=UTF-8 { "version": "6.0.2" }

My *Messages* buffer in emacs logs basically the above message.

Curiously, zotxt-citekey-insert and zotxt-citekey-select-item-at-point function as expected.

pkg-info-version for zotxt returns 5.0.5. I installed it using doom emacs (/straight) with

(package! zotxt :recipe (:host github :repo "egh/zotxt-emacs"))

which I think should be getting the latest version. I have also tried the default package! approach which I think pulls from MELPA.

If it is of interest, in addition to markdown-mode major mode I have a plethora of minor modes in action (output of describe-mode):

 +Popup +Word-Wrap Adaptive-Wrap-Prefix
All-The-Icons-Completion Auto-Composition Auto-Compression Auto-Encryption
Better-Jumper Better-Jumper-Local Buffer-Face Column-Number Company Company-Tng
Display-Line-Numbers Doom-Modeline Dtrt-Indent Eldoc Electric-Indent Eros Evil
Evil-Escape Evil-Goggles Evil-Local Evil-Markdown Evil-Snipe Evil-Snipe-Local
Evil-Snipe-Override Evil-Snipe-Override-Local Evil-Surround File-Name-Shadow
Flycheck Flycheck-Popup-Tip Flyspell Flyspell-Lazy Font-Lock Format-All Gcmh
General-Override Global-Company Global-Eldoc Global-Evil-Surround
Global-Flycheck Global-Font-Lock Global-Git-Commit Global-Hl-Line Global-So-Long
Global-Undo-Fu-Session Line-Number Marginalia Mouse-Wheel Olivetti
Override-Global Pandoc Persp Poly-Markdown Projectile Recentf Save-Place
Savehist Shell-Dirtrack Show-Paren Size-Indication Smartparens
Smartparens-Global Solaire-Global Transient-Mark Undo-Fu Undo-Fu-Session Vertico
Vi-Tilde-Fringe Visual-Line Which-Key Whitespace Windmove Window-Divider Winner
Ws-Butler-Global Yas Yas-Global Zotxt-Citekey