Jump to content

WordReference - A multilingual translation dictionary


Recommended Posts

Sorry, I can't help if you don't already have access to an API key. My only suggestion would be to email them to gently express your disappointment and your desire to be notified if they should ever change their new policy.

RIght.. Actually I do have an API key somewhere, inside a time machine backup, I believe. I had to reinstall mavericks and when I took back the alfred backup from dropbox it asked me again for it. Is there a particular location where your extension put this API? It is possible to retrieve it from a backup?

Thanks anyway for the tip, I'll ask them as well! 

Link to comment

RIght.. Actually I do have an API key somewhere, inside a time machine backup, I believe. I had to reinstall mavericks and when I took back the alfred backup from dropbox it asked me again for it. Is there a particular location where your extension put this API? It is possible to retrieve it from a backup?

Thanks anyway for the tip, I'll ask them as well! 

 

Wordreference should have emailed you the API key originally, no? If you can't find the email they sent you, you need to go to ~/Library/Application Support/Alfred 2/Workflow Data/wordreference, open settings.plist, and then copy the numbers at the end of that line. That's your API. 

Link to comment

Wordreference should have emailed you the API key originally, no? If you can't find the email they sent you, you need to go to ~/Library/Application Support/Alfred 2/Workflow Data/wordreference, open settings.plist, and then copy the numbers at the end of that line. That's your API. 

 

Got it. Thanks!

Link to comment
  • 1 year later...

Did anyone else have this workflow break recently? I believe it may have been an OSX 10.10 update but I'm unsure. I've verified my API key is valid and no traffic is being sent out from the script. Any ideas on a fix? I'll dig into the code but am not too familiar with it.

 

Cheers,

Sky

Link to comment

There was an update for OS X that broke the PHP cli, which means that all of your php workflows and scripts will have broken. (To fix this, you just need to symlink a dylib).

 

But, if you head to the GH repo for this workflow, you'll also see this:

 

 

 

Note: as of 23/06/15 the workflow has stopped functioning. Wordreference.com stopped giving out APIs awhile back, and my guess is that the problem is related to that. I'll take a look in July to see if something else might be the problem though.
Link to comment
  • 2 months later...

I've poked and prodded at this script without success so far. The API is still returning valid results in my browser when I build the request URL as is done in translate.php, but the somewhere along the line I'm receiving errors such as:

 

 

Starting debug for 'WordReference'

 

[ERROR: alfred.workflow.input.scriptfilter] XML Parse Error 'The operation couldn’t be completed. (NSXMLParserErrorDomain error 4.)'. Row 1, Col 1: 'Document is empty' in XML:

array(3) {

  [19913]=>

  bool(true)

  [10002]=>

  string(54) "http://api.wordreference.com/0.8/MY_API_KEY/json/enfr/hello"

  [74]=>

  bool(true)

}

 

 

I'll update here when I get deeper into this. Might just rebuild with Ruby or Javascript.

Link to comment

I've poked and prodded at this script without success so far. The API is still returning valid results in my browser when I build the request URL as is done in translate.php, but the somewhere along the line I'm receiving errors such as:

 

 

 

I'll update here when I get deeper into this. Might just rebuild with Ruby or Javascript.

 

That'd be great! Unfortunately I'm really in over my head with the debugging.

Link to comment
  • 4 months later...
  • 2 years later...

Hey there, @avk_tp

I'm one of the lucky few who had a API key before WR closed it.

So until recently it worked perfectly, but today I have a weird issue.
First I had an error saying it could mkdir inside…

/Library/Caches/com.runningwithcrayons.Alfred-2/Workflow Data/

…that this folder didn't exist.
So I made the missing folder "Workflow Data" myself and then the workflow was able to write a "wordreference" folder inside but now, it's still not working.
In the debugging console I have

[2018-12-18 16:10:32][input.scriptfilter] Queuing argument 'house'
[2018-12-18 16:10:32][input.scriptfilter] Script with argument '(null)' finished

Don't know what's going on but I tested the API and it's manually responding so it's not that.

If you have any clue, it would very much appreciated. :)
 

Link to comment

Hey @GoOz,

 

Hmmm, I'm not sure... I can't recreate the issue, as my WR workflow continues to work fine (though I'm on Alfred 3, not 2). Given that the missing Workflow Data folder that initially caused the error message is not unique to this workflow, however, I think my inclination would be to first try a reinstall and see if things get sorted that way. 

Link to comment
11 hours ago, avk_tp said:

Hey @GoOz,

 

Hmmm, I'm not sure... I can't recreate the issue, as my WR workflow continues to work fine (though I'm on Alfred 3, not 2). Given that the missing Workflow Data folder that initially caused the error message is not unique to this workflow, however, I think my inclination would be to first try a reinstall and see if things get sorted that way. 


Oddly, I'm on Alfred 3 as well (3.7.1 to be exact) 😐

I tried to reinstall on top of it but It wouldn't fix the issue. I just tried to remove the workflow and reinstall it again and… now it works! ☜(゚ヮ゚☜)

Don't know why I didn't think of that before. Sorry for the bother.

Link to comment
On 12/19/2018 at 9:37 AM, GoOz said:


Oddly, I'm on Alfred 3 as well (3.7.1 to be exact) 😐

I tried to reinstall on top of it but It wouldn't fix the issue. I just tried to remove the workflow and reinstall it again and… now it works! ☜(゚ヮ゚☜)

Don't know why I didn't think of that before. Sorry for the bother.

 

Ah, I'd assumed you were on an older version because I think

/Library/Caches/com.runningwithcrayons.Alfred-2/Workflow Data/

is for Alfred 2, not 3 - so it may be that there was some sort of issue tied to updates or something. In any event, glad it's sorted!

 

Link to comment
  • 5 months later...

Hey @avk_tp

 

It's me again :D

 

I have the same issue, again.

As Alfred 4 came out,  I decided to clean a little bit, uninstalled Alfred and installed the new version. It turns out I still get the same error for the missing "Alfred 2" folder. I took a look in your code and found this line. I'm starting to think that this is the issue. I also get the `Script with argument '(null)' finished` but one thing at a time. :)

What do you think?

Link to comment
On 6/3/2019 at 11:58 AM, GoOz said:

Hey @avk_tp

 

It's me again :D

 

I have the same issue, again.

As Alfred 4 came out,  I decided to clean a little bit, uninstalled Alfred and installed the new version. It turns out I still get the same error for the missing "Alfred 2" folder. I took a look in your code and found this line. I'm starting to think that this is the issue. I also get the `Script with argument '(null)' finished` but one thing at a time. :)

 What do you think?

 

Hey hey!

 

Good eye on the Alfred 2 folder issue - I've now updated the relevant lines to use the Alfred 3+ naming conventions. But I think the real problem may actually lie elsewhere, as now I'm getting the same issue you originally had (i.e. with the null return). Not sure what has changed... don't suppose you have any other ideas? :) 

Link to comment
1 hour ago, avk_tp said:

 

Hey hey!

 

Good eye on the Alfred 2 folder issue - I've now updated the relevant lines to use the Alfred 3+ naming conventions. But I think the real problem may actually lie elsewhere, as now I'm getting the same issue you originally had (i.e. with the null return). Not sure what has changed... don't suppose you have any other ideas? :) 


Sorry I have no clue either. Last time it was "fixed" when I uninstalled and reinstalled the workflow. Didn't try it yet.
But I'm pretty sure it's not related to the request or the WordReference's API itself.

EDIT: I just uninstalled/reinstalled it and the path is now fixed but I still get `Script with argument '(null)' finished` 😢

Edited by GoOz
Link to comment
2 minutes ago, deanishe said:

 

That’s not an error message, just normal status feedback.

 

Is the workflow not working?


No, it doesn't work anymore. And when it worked, it didn't output this feedback that's why I thought it was an error.

Link to comment
9 minutes ago, GoOz said:

that's why I thought it was an error.

 

It might well be an error, but the message itself doesn’t automatically mean error.

 

If something went badly wrong, Alfred should prefix the message with a large ERROR. Unfortunately, some versions of Alfred always show ERROR, even if nothing went wrong.

Link to comment
  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...