PDA

View Full Version : Solved Translator not working with Microsoft and Apertium



bathy
14-01-12, 09:16
As titled. Running vbulletin 4.1.9 with vBet 4.4.6.

r.dziadusz
14-01-12, 12:04
Hi
Could you please tell me which translation API's you use?(Microsft/Microsoft Azure)
For these - used by you - please run test from here (http://www.vbenterprisetranslator.com/forum/troubleshooting/6-faq-2.html#post1728)
You can find all of them already created in you do-not-upload/tools folder, just upload to your forum root directory, and share results here

bathy
15-01-12, 10:51
This is the result:


Starting test for Microsft Translation API by Azure


Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 29

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 15
Full token:
{"error":"invalid_grant","error_description":"ACS50012: Authentication failed. ACS50026: Principal with name \u0027KHMFBu8/XCgswVqDjzD8pmWaubgZ3qjf3YYIU6HjieY=\u0027 is not a known principal. \r\nTrace ID: 3242b52c-d413-4d4d-aa8f-96a24ddddb4e\r\nTimestamp: 2012-01-15 09:50:46Z"}

Test result: "ArgumentException: No bearer information found in the token : ID=3835.V2_Json.Translate.2272B74F"
Test error:
Connection time (ms): 238.76171875

r.dziadusz
16-01-12, 21:50
Please try to use this solution at first: http://www.vbenterprisetranslator.com/forum/vbet4-troubleshooting/413-faq.html#post1543

Also did you use proper valuse from your Microsoft by Azure aplication:
Microsoft Comercial Translation API key by Azure: your Client ID,
Microsoft Comercial Translation API secret by Azure: your Client secret

bathy
17-01-12, 16:10
safe_mode is already off.

Updated the keys and this is what I get now:

Starting test for Microsft Translation API by Azure


Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 29

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 15
Full token:
{"access_token":"http%3a%2f%2fschemas.xmlsoap.org%2fws%2f2005%2f05%2fidentity%2fclaims%2fnameidentifier=2e31cdf8-0c3d-4ce3-908a-703056eb00f3&http%3a%2f%2fschemas.microsoft.com%2faccesscontrolservice%2f2010%2f07%2fclaims%2fidentityprovider=https%3a%2f%2fdatamarket.accesscontrol.windows.net%2f&Audience=http%3a%2f%2fapi.microsofttranslator.com&ExpiresOn=1326813620&Issuer=https%3a%2f%2fdatamarket.accesscontrol.windows.net%2f&HMACSHA256=CREJfZgnv5j8Nq6V46uCP7gqQVM9iwy4irpW4okXSBU%3d","token_type":"http://schemas.xmlsoap.org/ws/2009/11/swt-token-profile-1.0","expires_in":"600","scope":"http://api.microsofttranslator.com"}

Test result: "Hello!"
Test error:
Connection time (ms): 244.588867188

r.dziadusz
18-01-12, 16:42
As you see translation request is fine.
Also safe_mode is on:

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 29

Could you please confirm if you have set all vbet opions correctly ?
Also are you using database cache and guest cache?

It sems that you reach your limits very quickly. If your databse is on and guest cache is on, and all options are set ok, I will have to check it in you admincp

bathy
20-01-12, 13:08
safe mode is off:
http://www.schmike.net/pics/safe.jpg

Everything was working fine initially with google.

r.dziadusz
20-01-12, 14:23
So is the problem still exist? If yes please answer my previous questions.
Also you set safe_mode off but clearly is still on. This warning:

Warning: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in [path]/microsoftbyazuretest.php on line 29 - if still exist, it's warning from your server, so your server "says" that this mode is on

bathy
26-01-12, 13:54
Any other ways to check on the safe_mode instead of phpinfo?

r.dziadusz
26-01-12, 21:05
You can try to edit file: php.ini. Find line: safe_mode and set it off: safe_mode = Off (or "on" if you want to activate it again) and then restart server

bathy
28-01-12, 12:39
I'm on a shared hosting now. I don't think I'm able to do that.

r.dziadusz
01-02-12, 11:31
You can ask your provider to do that:)

AfrikaansAlbanianArabicBelarusianBulgarianCatalanChineseCroatianCzechDanishDutchEnglishEstonianFilipinoFinnishFrenchGalicianGermanGreekHaitian CreoleHebrewHindiHungarianIcelandicIndonesianIrishItalianJapaneseKoreanLatvianLithuanianMacedonianMalayMalteseNorwegianPersianPolishPortugueseRomanianRussianSerbianSlovakSlovenianSpanishSwahiliSwedishTaiwaneseThaiTurkishUkrainianVietnameseWelshYiddish
Translations supported by vBET PRODUCER_PRODUCT_VERSION