AlfredGoogleTranslateWorkflow
AlfredGoogleTranslateWorkflow copied to clipboard
translate on Alfred 3
does this workflow work on Alfred 3? As is, it does not seem to work (on my machine), but I have not yet ruled out other options. Because the Packal workflow explicitly states 'Alfred 2' workflow, this seemed to me the obvious reason.
No it does not unfortunately. I don't have the Alfred 3 Powerpack so I can't port it.
Got a license... So I can check it. Thank you!
Okay, so I checked the workflow on Alfred 3 and it works for me so far. But that could be because I still have the Alfred 2 version around.
Can you please elaborate on what is not working in your setup?
Please check out pre-release 3.2.0 and let me know if that works for you: https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/releases/tag/3.2.0-pre1
It does work! Thanks a lot! Have a nice week!
Hello, there is no action triggered on my machine. Here is some logging:
#1 /Users/martin/Google Drive/exchange/osx/config/alfred/Alfred.alfredpreferences/workflows/user.workflow.6E397583-7A9F-4EBE-8219-E626BB8A9F3E/GoogleTranslateWorkflow.php(122): St in /Users/martin/Google Drive/exchange/osx/config/alfred/Alfred.alfredpreferences/workflows/user.workflow.6E397583-7A9F-4EBE-8219-E626BB8A9F3E/vendor/stichoza/google-translate-php/src/Stichoza/GoogleTranslate/TranslateClient.php on line 263
[2016-08-31 21:41:12][ERROR: input.scriptfilter] JSON error: JSON text did not start with array or object and option to allow fragments not set. in JSON:
Fatal error: Uncaught exception 'ErrorException' with message 'Server error: `POST http://translate.google.com/translate_a/t` resulted in a `503 Service Unavailable` response:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
Any idea how to fix it? I wish I could help you, but this workflow stuff is totally new to me.
same here. Yesterday suddenly it stopped providing results. (and I just checked; still no results). It did work until recently though, so probably something on Google's end.
On Wed, Aug 31, 2016 at 9:44 PM, Martin Pfeffer [email protected] wrote:
Hello, at my machine it doesn't translate anything, no action is triggered. Here is some logging:
#1 /Users/martin/Google Drive/exchange/osx/config/alfred/Alfred.alfredpreferences/workflows/user.workflow.6E397583-7A9F-4EBE-8219-E626BB8A9F3E/GoogleTranslateWorkflow.php(122): St in /Users/martin/Google Drive/exchange/osx/config/alfred/Alfred.alfredpreferences/workflows/user.workflow.6E397583-7A9F-4EBE-8219-E626BB8A9F3E/vendor/stichoza/google-translate-php/src/Stichoza/GoogleTranslate/TranslateClient.php on line 263 [2016-08-31 21:41:12][ERROR: input.scriptfilter] JSON error: JSON text did not start with array or object and option to allow fragments not set. in JSON: Fatal error: Uncaught exception 'ErrorException' with message 'Server error:
POST http://translate.google.com/translate_a/t
http://translate.google.com/translate_a/t resulted in a503 Service Unavailable
response:— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/issues/32#issuecomment-243878209, or mute the thread https://github.com/notifications/unsubscribe-auth/ACsPM096hY2q7-1quHHIsAR013vWpCE1ks5qldmjgaJpZM4Ji8B- .
Yes, they must have changed something:
PHP Fatal error: Uncaught exception 'ErrorException' with message 'Server error: `POST http://translate.google.com/translate_a/t` resulted in a `503 Service Unavailable` response:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head><meta http-equiv="content-type" content="te (truncated...)
' in /Users/nlo/Library/Application Support/Alfred 3/Alfred.alfredpreferences/workflows/user.workflow.484AF645-7BFD-4C98-978D-2580B0BD3F27/vendor/stichoza/google-translate-php/src/Stichoza/GoogleTranslate/TranslateClient.php:263
Stack trace:
#0 /Users/nlo/Library/Application Support/Alfred 3/Alfred.alfredpreferences/workflows/user.workflow.484AF645-7BFD-4C98-978D-2580B0BD3F27/vendor/stichoza/google-translate-php/src/Stichoza/GoogleTranslate/TranslateClient.php(186): Stichoza\GoogleTranslate\TranslateClient->getResponse('asd')
#1 /Users/nlo/Library/Application Support/Alfred 3/Alfred.alfredpreferences/workflows/user.workflow.484AF645-7BFD-4C98-978D-2580B0BD3F27/GoogleTranslateWorkflow.php(122): Stichoza\GoogleTransla in /Users/nlo/Library/Application Support/Alfred 3/Alfred.alfredpreferences/workflows/user.workflow.484AF645-7BFD-4C98-978D-2580B0BD3F27/vendor/
Anyone has found a way to correct this ? Or is it due to some policy change by Google that is not authorizing some API ?
Looks like Google closed the door on the API again. :-/
Sad news. I just bought a license for Alfred 3 just because of this workflow ;). Any ideas how to workaround this issue ?
I don't but Alfred is also useful without this workflow. But yes, this was my favourite as well!
hennis.nl // +31651855220 // Amsterdam, Delft
On Wed, Oct 19, 2016 at 11:25 AM, Eugene Gluhotorenko < [email protected]> wrote:
Sad news. I just buy a license for Alfred 3 just because of this workflow ;). Any ideas how to workaround this issue ?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/issues/32#issuecomment-254761098, or mute the thread https://github.com/notifications/unsubscribe-auth/ACsPM2o9BBnju99y0qrL-B_S9CDd_vQNks5q1eIbgaJpZM4Ji8B- .
Sorry, guys. But since Google is trying to earn money with the translation API, they regularly change the access and break these kind of clients. I'm not sure how to solve this and to be honest I'm not sure if can dedicate enough time to support this anytime soon.
Anyway thanks for the awesome try ;)
It has apparently been fixed upstream at https://github.com/Stichoza/google-translate-php/issues/62. Obviously, I'm not that familiar, but if so this package only needs to update the dependency. Worst case scenario a bit of tweaking in the results might be required, but I don't think that'd be the case at all. Sadly I don't speak PHP so I'm hoping the author or someone more experienced than me would jump in. Thanks.
I've created a pull request #34.
Don't know if the author will aprove it, but you can still do the changes yourself.
Run composer update stichoza/google-translate-php
on the workflow folder and replace the file attached.
@DONSA Hello, bro. I can't set the sourceLanguages and the targetLanguages with your approach. I also use Alfred 3.
I just create a blank workflow. Then I clone this repo and replace your GoogleTranslateWorkflow.php
file in its src
dir. I run the composer update stichoza/google-translate-php
command under src
working dir. Lastly, I copy all files in src
folder to my blank workflow finder's dir.
Did I missed any important thing? Thanks for reply. BTW Could you send me a worked workflow?
Hi, No need to create a new workflow. Just cd into workflow source folder and run composer on it. Then replace the attached file.
Thanks. Which release version did you use (3.2.0-pre1 or 3.1.2 in releases)?
V3.1.2
Thank you @DONSA
Does this still work for you all? The operations work but the translation invariably returns ARRAY
.
Am I doing something wrong or did Google just change their API again?
Works fine. I'm using stichoza/google-translate-php v3.2, make sure you use the same version. You can check it in composer.json.
so it works fine with the latest version? Or only with modifications? If it works, that's new to me, I thought it did not work anymore due to changes at Google's side.
-- hennis.nl // +31651855220 // Amsterdam, Delft
On Thu, Jan 19, 2017 at 8:58 AM, Nuno [email protected] wrote:
Works fine. I'm using stichoza/google-translate-php v3.2, make sure you use the same version. You can check it in composer.json.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/issues/32#issuecomment-273705733, or mute the thread https://github.com/notifications/unsubscribe-auth/ACsPM9djZqqzHpRA-nDI89wQub9BAL81ks5rTxeMgaJpZM4Ji8B- .
Only with the modifications I did in GoogleTranslateWorkflow.php file.
@DONSA thanks! I've found out what the problem was. The GoogleTranslateWorkflow.php
you linked to in https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/issues/32#issuecomment-263400058 points to the original one for some reason. Using the one from your Pull Request found here worked for me.
for non-programmers - what is the step by step procedure to get this workflow working? Do I download the 'latest' workflow? And then?
I will fork this project this weekend and create the workflow. I will post the link when it's finished.
thanks Nuno!
-- hennis.nl // +31651855220 // Amsterdam, Delft
On Fri, Jan 20, 2017 at 9:58 AM, Nuno [email protected] wrote:
I will fork this project this weekend and create the workflow. I will post the link when it's finished.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thomashempel/AlfredGoogleTranslateWorkflow/issues/32#issuecomment-274014854, or mute the thread https://github.com/notifications/unsubscribe-auth/ACsPMwQloLspUzCsyxkC1TrHIVrW_X47ks5rUHdDgaJpZM4Ji8B- .
Finally, I found the issue. My network is broken in fu*king China Mainland. :( I must use VPN get google translate working normally. @DONSA Thank for hard work again.