alfred-raindrop-search: Workflow not working-- returning no results (Alfred 5 / WF 2.0.7)

Hello

Has the workflow stopped working recently? It was working up until yesterday (2023-05-07).

I receive this error in debugging:

[11:36:14.364] ERROR: Search Raindrop.io[Script Filter] JSON error: JSON text did not start with array or object and option to allow fragments not set. around line 1, column 0. in JSON:
/**** Unexpected response from server ****
{"result":true,"items":[],"count":0,"collectionId":0}
***********************************/


/**** Unexpected response from server ****
{"result":true,"items":[],"count":0,"collectionId":0}
***********************************/

I have tried everything I can think of, similar to troubleshooting steps listed in #14 and #19.

Removal and cleansing

  • removed your workflow from Alfred
  • uninstalled macOS Raindrop.app
  • removed all caches for Raindrop and all the directories and files for raindrop and your workflow under: ~/Library/Caches/com.runningwithcrayons.Alfred
  • removed ~/Library/Application Support/Alfred/Workflow Data/me.westerlind.alfred.raindrop-search
  • removed all profiles, caches and browser caches for Raindrop
  • search the entire filesystem for any other references to raindrop or raindropio - none!
  • deleted me.westerlind.alfred.raindrop-search in Keychain Access
  • restarted mac

No errors or issues above so now re-install

  • signed back in to Raindrop.io account in Firefox 112.02 (latest version)
  • re-added 2.0.7 of your workflow
  • tried re-authenticating following these steps with 2 different Raindrop accounts. Same error shown above.
  • tried authenticating using a different browser, Safari, same error.
  • tried installing/authenticating everything on a different computer for the first time (no cache), and received the same error.

Not sure if the folders are supposed to be like this, but I notice that no files populate in: ~/Library/Application Support/Alfred/Workflow Data/me.westerlind.alfred.raindrop-search but show up in: ~/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/me.westerlind.alfred.raindrop-search instead.

  • json files in this folder:
    • collections.json
    • collections_sublevel.json
    • tags.json are not empty, and seem to have all the appropriate key/value pairs.

Since I received the same error on a different computer using a completely fresh install/authentication, and I’ve tried with 2 different Raindrop accounts, that tells me that it’s probably not an issue on my end (?).

Running macOS Ventura 13.3.1, M1 Thank you

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Reactions: 3
  • Comments: 15 (4 by maintainers)

Most upvoted comments

Version 2.0.8 is now finally out, and fixes this problem.

Sorry that it has taken a while to get this solved.

Sorry guys (I’m creator of Raindrop). Recently I removed support for old deprecated format of search field value. This old format have looked like this search=[{"key":"word", "val": "some text"] Now instead you need just send your search value as plain text like search=some text This should be an easy fix for maintainer

Thank you I have replaced all and compiled. But I can’t install the compiled file

@KodaCHC The raindrop_alfred file is designed for use within an Alfred workflow. Although generating a new alfredworkflow file and installing it is possible, a simpler alternative, if you’ve already installed the Search Raindrop.io workflow, is to replace the existing raindrop_alfred file in the workflow folder. These are the steps I followed:

  1. Open Alfred Preferences.
  2. Select Workflows.
  3. Right-click on the Search Raindrop.io workflow and choose either “Open in Finder” or “Open in Terminal”.
  4. Copy the compiled raindrop_alfred file to this directory, overwriting the existing file.

Now the workflow can be run from Alfred.

may I ask If you already received an update @westerlind ?

I still get the same error with 2.0.8. Any ideas?

[12:13:50.484] Logging Started...
[12:13:53.985] Search Raindrop.io[Script Filter] Queuing argument '(null)'
[12:13:54.829] Search Raindrop.io[Script Filter] Queuing argument 'test'
[12:13:55.798] Search Raindrop.io[Script Filter] Script with argv '(null)' finished
[12:13:55.805] STDERR: Search Raindrop.io[Script Filter] 🍺
12:13:54 workflow.go:328: ----- Search Raindrop.io/2.0.8 (AwGo/0.27.1) -----
12:13:55 feedback.go:509: Sent 0 result(s) to Alfred
12:13:55 workflow.go:405: ------------------- 863.587ms --------------------
[12:13:55.807] Search Raindrop.io[Script Filter] /**** Unexpected response from server ****
Bad Request
***********************************/


/**** Unexpected response from server ****
Bad Request
***********************************/

{
  "variables": {
    "AW_SESSION_ID": "*********************"
  },
  "items": null
}
[12:13:55.808] ERROR: Search Raindrop.io[Script Filter] JSON error: JSON text did not start with array or object and option to allow fragments not set. around line 1, column 0. in JSON:
/**** Unexpected response from server ****
Bad Request
***********************************/


/**** Unexpected response from server ****
Bad Request
***********************************/

{
  "variables": {
    "AW_SESSION_ID": "*********************"
  },
  "items": null
}

You can probablt get it to work right now by applying the fix from the pull request, add in your own api key (which you can get form Raindrop.io), and compile it yourself, but that might require a bit of effort if you are not normally doing these sorts of things.

For anyone compiling this, here’s a few points that I found helpful:

  1. In addition to updating the client_id and client_secret in the client_code.go file with your Raindrop.io app’s values, update the client_id in the raindrop_common.go file:

    https://github.com/westerlind/alfred-raindrop-search/blob/d95dbbc197ee711cab1aa872bd65dc834b0c6119/raindrop_common.go#L42

    The following replaces the hardcoded value with the value from the client_code.go file:

    Arg("https://raindrop.io/oauth/authorize?redirect_uri=" + url.QueryEscape("http://127.0.0.1:11038") + "&client_id=" + client_id).
    
  2. In your Raindrop.io app, set the Redirect URI to http://127.0.0.1:11038.

  3. As a troubleshooting step for authentication issues, it may be helpful to delete the me.westerlind.alfred.raindrop-search application password in the Mac’s Keychain Access app.

@westerlind thank you Andreas, I thought it might be an issue with the API as well, given how often Raindrop is updated.

Hi

This does look like an issue with Raindrop’s API rather than the workflow. The same thing happens for me too, and I think it’s likely that it happens for many or all users of this workflow and other software that uses Raindrop’s API.

I have sent a mail to Raindrop to see if they know anything about this, and I will report back here when I know more.