egh / zotxt

zotxt: a Zotero extension for text
http://gitlab.com/egh/zotxt
GNU General Public License v3.0
326 stars 16 forks source link

version endpoint not found (zotxt 5.1.4) #29

Open mmacpherson opened 3 years ago

mmacpherson commented 3 years ago

Have seen a few of these among the recent issues, but I seem to encounter it with zotxt 5.1.4.

I see two mentions of zotxt in my zotero logs;

once at the very start:

version => 5.0.96.2, platform => MacIntel, oscpu => Intel Mac OS X 10.15, locale => en-US, appName => Zotero, appVersion => 5.0.96.2, extensions => Zotero Word for Mac Integration (5.0.36.SA.5.0.96.2, extension), Zotero LibreOffice Integration (5.0.25.SA.5.0.96.2, extension), zotxt (5.1.4, extension), Better BibTex for Zotero (5.4.10, extension, disabled)

and once at the end, when I'd curl'ed the version endpoint, as curl http://127.0.0.1:23119/zotxt/version:

(5)(+0173681): GET /zotxt/version HTTP/1.1 Host: 127.0.0.1:23119 User-Agent: curl/7.64.1 Accept: */* 
(5)(+0000014): HTTP/1.0 404 Not Found X-Zotero-Version: 5.0.96.2 X-Zotero-Connector-API-Version: 2 Content-Type: text/plain No endpoint found

and where "No endpoint found" was the response I saw at the CLI.

I'll note, I'm running the same versions of Zotero and zotxt on a linux box, and there they work fine.

Any ideas to try? Thank you.

egh commented 3 years ago

H @mmacpherson - If it can't find the version endpoint, it means that zotxt did not load properly. If you enable zotero debugging and search the logs for zotxt that might give you an idea. I'm not sure what the issue is, though - I don't have a mac to test on.

mmacpherson commented 3 years ago

Thanks kindly for the quick reply, @egh.

In the message posted above, the messages I had pasted in came from the Zotero debugging logs. There are only two mentions, neither particularly telling.

It sounds like my options are (1) just to use the linux box where zotxt works great, or (2) to dig into the source and see if I can figure out what's going on. If I go down route 2 and find something of use, I'd be sure to share in a PR.

Thanks again for your time, cheers.

egh commented 3 years ago

Thanks @mmacpherson Yes, those sound like your best options. In my experience if there is a problem with loading zotxt, it happens early on in the logs, so you might see something at the beginning of the logs that gives you a clue. Thanks for reporting, and good luck!

myildi commented 3 years ago

Hello, I meet the same problem here with OSC Big Sur and Zotero 5.0.96.2. When I execute http://127.0.0.1:23119/zotxt/items in Firefox, I get "Request not allowed"

That also seems to impede Hook working because it relies on zotxt.

egh commented 3 years ago

@myildi Unfortunately, because of the way Zotero works, requests made directly are returned as "Request not allowed". So in this case, I think zotxt has been installed correctly. If you have curl or something similar you should be able to try it from the command line:

$ curl http://localhost:23119/zotxt/version
{
  "version": "5.1.4"
}
myildi commented 3 years ago

Yes, I get this indeed. So Zotxt seems to be working in my case, but please see my other post about getting the id field of the selected reference. Thank you again!

danieltomasz commented 2 years ago

On MacOS Monterey on M1 mac I am getting No endpoint found after running curl http://localhost:23119/zotxt/version

khinsen commented 2 years ago

Same problem here, after updating to Zotero 6 (and zotxt as well). From the Zotero debug log:

version => 6.0.4, platform => MacIntel, oscpu => Intel Mac OS X 10.16, locale => en-US, appName => Zotero, appVersion => 6.0.4, extensions => Zotero Word for Mac Integration (6.0.0.SA.6.0.4, extension), Zotero LibreOffice Integration (6.0.0.SA.6.0.4, extension), ZotFile (5.1.1, extension), zotxt (6.0.0, extension), Better BibTex for Zotero (6.4.3, extension)

and later, when I do a request from Emacs:

(5)(+0073701): GET /zotxt/items?selected=selected&format=key HTTP/1.1 Host: 127.0.0.1:23119 User-Agent: curl/7.80.0 Accept: */* Accept-Encoding: deflate, gzip, zstd

(5)(+0000002): HTTP/1.0 404 Not Found X-Zotero-Version: 6.0.4 X-Zotero-Connector-API-Version: 2 Content-Type: text/plain No endpoint found

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

(5)(+0000001): HTTP/1.0 404 Not Found X-Zotero-Version: 6.0.4 X-Zotero-Connector-API-Version: 2 Content-Type: text/plain No endpoint found

I am a bit surprised to see the zotxt version reported as 6.0.0, since the file I downloaded and installed is zotxt-6.0.1.xpi. Could that be (or point to) the cause of the problem?

egh commented 2 years ago

@khinsen

Thanks for the information! There was a problem with the reported version in 6.0.1 - I have released a new version to fix this.

Does it work if you stop & restart zotero?

khinsen commented 2 years ago

In the meantime I went back to Zotero 5, so I can't say. Now I am back on Zotero 6, with zotxt installed and working just fine. Thanks!