atykhonov / google-translate

Emacs interface to Google Translate
370 stars 48 forks source link

google-translate-backend--emacs: Search failed #94

Closed aadcg closed 4 years ago

aadcg commented 5 years ago

Hi,

I've been using this package for a while and I remember it was working. However, I'm getting the following error now (copied from *Messages*):

Contacting host: translate.google.com:80
google-translate-backend--emacs: Search failed: "

"

In *google-translate-backend-debug* I get:

Sun Aug 25 11:08:37 2019
("http://translate.google.com/" emacs)
-- begin --

-- end --

Do you have any ideas on this error?

Versions: Ubuntu 19.04 Emacs 26.1

ag91 commented 5 years ago

I have got the same issue. Essentially

(url-retrieve-synchronously "http://translate.google.com/")

is not creating a buffer and the search for '"tkk':" is failing. This is breaking the call:

(google-translate-backend-retrieve google-translate--tkk-url) in google-translate-tk.el.

(Strangely enough the asynchronous version works: (url-retrieve "http://translate.google.com/" (lambda (x) (message "Buffer: %s" (buffer-substring-no-properties (point-min) (point-max))))) - maybe a problem of the latest version of Emacs itself?)

@aadcg can you confirm that if you change the backend method you get a new error: for instance I get the error, condition-case: JSON readtable error: 60 if I set: (setq google-translate-backend-method 'curl)

aadcg commented 5 years ago

Well, things started to work for me again... not sure why. And for you, @ag91 ?

ag91 commented 5 years ago

Lol, it seems same for me... Maybe something wrong on google side? And we disturb these nice folks of google-translate.el ;)

aadcg commented 5 years ago

Yes, maybe google... At least we saw it together so none of us hallucinated! I'm closing this issue.

Sbozzolo commented 5 years ago

I am re-opening this since I am still experiencing the problem with the same error.

aadcg commented 5 years ago

That makes two of us. Any ideas?

ag91 commented 5 years ago

what is your value of google-translate-backend-method?

aadcg commented 5 years ago

emacs. I changed to curl and it works for me. What about you?

ag91 commented 5 years ago

I moved to curl as well for safety, because on another machine I could still observe the error.

Sbozzolo commented 5 years ago

Same here, with emacs fails, but with curl it works.

stardiviner commented 4 years ago

I can't reproduce this problem on my machine, can somebody provide some detailed info like Edebug. You can check out following link to learn it if you don't know how to use Edebug.

aadcg commented 4 years ago

Everything's working for me. I'm closing this.

tlkahn commented 4 years ago

(setq google-translate-backend-method 'curl)