alphapapa / plz.el

An HTTP library for Emacs
GNU General Public License v3.0
201 stars 11 forks source link

Exit code 92 is not handled #70

Closed akirak closed 4 days ago

akirak commented 6 days ago

While I was using plz.el in my library, I got the following error:

plz: plz: Curl error: "Curl error", #s(plz-error nil nil "Unexpected curl process status:\"exited abnormally with code 92 \" code:92. Please report this bug to the `plz' maintainer.")

According to curl(1), the exit code is defined as follows:

92 Stream error in HTTP/2 framing layer.

The error was from API requests to https://www.google.com/transliterate. Google might have changed the API, and now curl returns the error related to HTTP/2.

The versions are as follows:

plz.el 0.9.1 from Git curl 8.9.1 GNU Emacs 31.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.43, cairo version 1.18.0)

alphapapa commented 5 days ago

Hi Akira,

Well, I don't know what kind of special handling we should do for that error. I guess we could prevent that code from causing it to ask that the error be reported to me, but other than that, I think there's nothing else to be done.

BTW, I guess you could try using the --http1.1 argument to Curl, to prevent it from using HTTP/2, but I don't know if that would help.

akirak commented 5 days ago

I guess you could try using the --http1.1 argument to Curl, to prevent it from using HTTP/2

Indeed, this has resolved the error. I will add this option to plz-curl-default-args custom variable in my config. For most Emacs applications, HTTP/2 features wouldn't be necessary.

I guess we could prevent that code from causing it to ask that the error be reported to me

It might be helpful if plz displayed error messages from curl. Aside from that, I agree that there is nothing plz can do to prevent this kind of error.

alphapapa commented 4 days ago

Given the uncertainty here, I think I'll not make any changes to the code about this. But if we get more information about this error code, maybe it would be worthwhile. Thanks.

akirak commented 4 days ago

I think I'll not make any changes to the code about this.

I think that's fine. Thank you.