PhilippN Posted March 5, 2016 Share Posted March 5, 2016 (edited) I coded a little workflow for translation that is powered by dict.cc. I saw this workflow over here http://www.alfredforum.com/topic/8286-dictcc-translate-english-to-german/ and there was some demand for another one that works offline. So here it is: Features: Offline translation with dictionaries powered by dict.cc Highly flexible, integrate as many language packs as you want Easy to setup A little bit hidden features: Copy the translated word to the clipboard by actioning it Copy the word in the origin language to the clipboard by actioning it with cmd as modifier I tried to make the setup progress as simple as possible. Unfortunately you are not allowed to distribute the offline files, which are provided by dict.cc. But some of them are also very huge, so it is unexpedient too. You can see here how to configure this workflow: https://github.com/Kavakuo/Dict.cc-Alfred-Workflow#installation You can download the workflow from the Github Releases page or from packal.org: http://www.packal.org/workflow/dictcc-alfred Here it is in action: Edited March 6, 2016 by PhilippN cands and arsenty 2 Link to comment
deanishe Posted March 5, 2016 Share Posted March 5, 2016 To get performance with that amount of data, you can't be loading them into memory each run. You should probably be using an sqlite database. You seem to be re-implementing a lot of Alfred-Workflow, too. Link to comment
PhilippN Posted March 6, 2016 Author Share Posted March 6, 2016 Ah yes, great idea. I hate databases, so they were out of my mind Anyway, I pushed a new release which uses a SQLite database. Depending on the query search is faster now. But even if it is slower sometimes, I think the database solution is much better. cands 1 Link to comment
deanishe Posted July 14, 2016 Share Posted July 14, 2016 Ah yes, great idea. I hate databases, so they were out of my mind Anyway, I pushed a new release which uses a SQLite database. Depending on the query search is faster now. But even if it is slower sometimes, I think the database solution is much better. I had a quick glance at the code. The slowness is mostly down to the use of sqlalchemy, which is big. It's an industrial strength library, not ideally suited to small scripts meant to run fast. I did a little bit of benchmarking, and it takes ~0.2s for sqlalchemy just to import on my machine (old but has an SSD). With Alfred-Workflow, you're looking at a minimum of ~0.1s before your code starts running (0.05s for Python to start up plus 0.05s till Workflow.run() calls your main() function). That means it takes over 0.3 seconds before workflowScript.py even does anything, which is a noticeable delay. To speed it up, I'd consider using peewee instead of sqlalchemy. It's much smaller, so will probably load noticeably faster. Link to comment
WalterBeiter Posted September 21, 2017 Share Posted September 21, 2017 Hey there, I am in urgent need of an alternative to the Leo dictionary workflow, so I found this. Wanted to do the last step and finally parse that stuff, but I got the following error: python "/Users/David/Dropbox/Alfred Sync Folder/Alfred.alfredpreferences/workflows/user.workflow.9B955379-60E9-4C05-A5BD-D89026DF606C/parseDictsData.py" "/Users/David/Library/Application Support/Alfred 3/Workflow Data/de.nieting.DictCC" Traceback (most recent call last): File "/Users/David/Dropbox/Alfred Sync Folder/Alfred.alfredpreferences/workflows/user.workflow.9B955379-60E9-4C05-A5BD-D89026DF606C/parseDictsData.py", line 299, in <module> main() File "/Users/David/Dropbox/Alfred Sync Folder/Alfred.alfredpreferences/workflows/user.workflow.9B955379-60E9-4C05-A5BD-D89026DF606C/parseDictsData.py", line 124, in main settings = ujson.loads(open(os.path.join(dirName, "dictccSettings.json")).read()) ValueError: Expected object or value Can you please update that workflow? I also had to run the fixum workflow to even start using the dict.cc workflow. Is there anything that can be done? I really need a reliable german-english translator workflow. I used Leo every day. Link to comment
deanishe Posted September 21, 2017 Share Posted September 21, 2017 1 hour ago, WalterBeiter said: but I got the following error Looks like you broke the JSON file. Link to comment
WalterBeiter Posted September 22, 2017 Share Posted September 22, 2017 14 hours ago, deanishe said: Looks like you broke the JSON file. my dictaSettings.json file looks like this: [{ "downloadedDictionaryFile": "/Users/David/Library/Application Support/Alfred 3/Workflow Data/de.nieting.DictCC/cmkdkkkgmm-8718512140-eiiiie.txt", "languageOrderInDictionaryFile": [{ "identifier":"de", "completeName":"German", "icon":"icons/icon.png" },{ "identifier":"en", "completeName":"English", "icon":"icons/icon.png" }], "supportedDirection":"both" },{ ** second translation configuration goes here (same keys as before) ** }] Link to comment
deanishe Posted September 22, 2017 Share Posted September 22, 2017 I can’t tell if the JSON is invalid if you only post part of it. Paste the whole file in here: https://jsonlint.com/ Link to comment
WalterBeiter Posted September 22, 2017 Share Posted September 22, 2017 40 minutes ago, deanishe said: Paste the whole file in here: https://jsonlint.com/ Thank you, I had to remove the following part: ,{ ** second translation configuration goes here (same keys as before) ** } Now, is there a way to use both directions in this workflow without having to choose the direction first? For instance I would like to type in "hello" and "Hallo" and the workflow would detect the language and translate it? Or it would simply display both translations? Link to comment
deanishe Posted September 22, 2017 Share Posted September 22, 2017 Oh, right. That was the whole file. I have no idea how the workflow works. I don’t have it. ”supportedDirection”: “both” would indicate it works in both directions. Link to comment
patowod Posted September 22, 2017 Share Posted September 22, 2017 Hi all, …since the Leo Workflow stopped working (due to timeout) and reading that they asked the workflow to not be published furthermore (see https://github.com/psistorm/alfredapp) I am also looking for an alternative and this works really good. I have a question though: Is there any way to reverse the display within the results list? Looking at the following screenshot, from a UX perspective, I find it irritating that the term I already know (water in this case) is shown large - since the translation "Nass" is really what I'm after. Does anyone have a hint how this would be possible, if at all? Any hint is highly appreciated. Link to comment
DJay Posted September 26, 2017 Share Posted September 26, 2017 Alfred DeepL Translation Workflow ⭐️⭐️⭐️⭐️⭐️ Diegobit and patowod 2 Link to comment
romebot Posted January 21, 2020 Share Posted January 21, 2020 Having trouble with this workflow. I'm on a mac, catalina, using Alfred 4. I used the en-de tab-delimited file and I tried to enter the name of the file both with and w/o the brackets in the original code. (see my code below) The first time I did this yesterday, terminal did open and I got a similar error as WalterBeiter above. But now when I do it, I just get "translate..." forever, like in the screenshot below. I also looked for a parseDictsData.py file on my computer and dont have it, so I'm not sure what's happening. thanks for the help. [{ "downloadedDictionaryFile": "cmnsmfsndf-1962405712-759768.txt", "languageOrderInDictionaryFile": [{ "identifier":"de", "completeName":"German", "icon":"icons/icon.png" },{ "identifier":"en", "completeName":"English", "icon":"icons/icon.png" }], "supportedDirection":"both" },{ ** second translation configuration goes here (same keys as before) ** }] Link to comment
deanishe Posted January 21, 2020 Share Posted January 21, 2020 @romebot When a workflow isn't working, please check Alfred's debugger and post the output. Screenshots are very little use in trying to diagnose issues. Link to comment
romebot Posted January 21, 2020 Share Posted January 21, 2020 thanks, I'm a bit new to this, but I clicked the debug icon and did the step that I'm stuck on: "Last but not least run the parseDictsData.py script. To do this type dictcc wf:executeParsing into Alfred. A new Terminal window opens and the necessary operations are performed." This is what gets returned (no terminal pops up): "[16:37:47.680] Logging Started... [16:37:50.915] Dict.cc[Script Filter] Queuing argument ' wf:executeParsing'" I'm not 100% sure I'm using the debugger utility right, but I inserted the debugger before every object and nothing happened below. then I tried to type in dictcc again in alfred and got a message I need to update, so I did. and then I typed in dictcc again. there was a message I needed to configure, which popped up the text file (however, it had the info from yesterday even though I deleted the workflow and started from scratch today). I corrected the text file name and saved. then I tried again to type:dictcc wf:executeParsing and the same thing happens as above w/ my screenshot. (I still never got the terminal window to come up again since my last time) I'm very confused. Here's the info from the debugger : [16:49:29.530] Dict.cc[Script Filter] Queuing argument '' [16:49:29.840] Dict.cc[Script Filter] Script with argv '(null)' finished [16:49:29.843] STDERR: Dict.cc[Script Filter] 16:49:29 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.0) ---------- 16:49:29 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:49:29 workflow.py:2531 DEBUG update check not due 16:49:29 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:49:29 workflow.py:2461 DEBUG update_data: {u'available': True, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:49:29 workflow.py:2411 DEBUG last run version: 1.3.0 16:49:29 workflow.py:2411 DEBUG last run version: 1.3.0 16:49:29 parseDictsData.py:52 DEBUG connectToDatabase: 0.00764417648315 16:49:29 workflow.py:2440 DEBUG set last run version: 1.3.0 16:49:29 workflow.py:2289 DEBUG ---------- finished in 0.028s ---------- [16:49:29.844] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:update" valid="no"><title>New version available</title><subtitle>Action this item to install the update</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items> [16:49:35.241] Dict.cc[Script Filter] Queuing argument ' wf:update' [16:49:36.158] Dict.cc[Script Filter] Script with argv '(null)' finished [16:49:36.165] STDERR: Dict.cc[Script Filter] 16:49:35 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.0) ---------- 16:49:35 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:49:35 workflow.py:2531 DEBUG update check not due 16:49:35 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:49:35 workflow.py:2461 DEBUG update_data: {u'available': True, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:49:35 workflow.py:2411 DEBUG last run version: 1.3.0 16:49:35 workflow.py:2411 DEBUG last run version: 1.3.0 16:49:35 parseDictsData.py:52 DEBUG connectToDatabase: 0.00489091873169 16:49:35 update.py:308 DEBUG retrieving releases list: https://api.github.com/repos/Kavakuo/Dict.cc-Alfred-Workflow/releases 16:49:35 update.py:312 INFO retrieving releases: Kavakuo/Dict.cc-Alfred-Workflow 16:49:35 workflow.py:1919 DEBUG cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/gh-releases-Kavakuo-Dict.cc-Alfred-Workflow.cpickle 16:49:35 update.py:280 DEBUG release v1.3.1: https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow 16:49:35 update.py:327 DEBUG release: {u'version': u'v1.3.1', u'prerelease': False, u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:49:35 update.py:280 DEBUG release v1.3: https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3/Dictcc.alfredworkflow 16:49:35 update.py:327 DEBUG release: {u'version': u'v1.3', u'prerelease': False, u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3/Dictcc.alfredworkflow'} 16:49:35 update.py:263 WARNING invalid release (no workflow file): v1.2 16:49:35 update.py:320 DEBUG invalid release: None 16:49:35 update.py:280 DEBUG release v1.1: https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.1/Dict.cc.alfredworkflow 16:49:35 update.py:327 DEBUG release: {u'version': u'v1.1', u'prerelease': False, u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.1/Dict.cc.alfredworkflow'} 16:49:35 update.py:280 DEBUG release v1.0: https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.0/Dictcc.alfredworkflow 16:49:35 update.py:327 DEBUG release: {u'version': u'v1.0', u'prerelease': False, u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.0/Dictcc.alfredworkflow'} 16:49:35 update.py:353 INFO 4 releases for Kavakuo/Dict.cc-Alfred-Workflow 16:49:35 update.py:361 DEBUG latest=Version('1.3.1'), installed=Version('1.3.0') 16:49:35 workflow.py:1919 DEBUG cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:49:35 workflow.py:2566 DEBUG downloading update ... 16:49:35 background.py:188 DEBUG [__workflow_update_install] command cached: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_install.argcache 16:49:35 background.py:192 DEBUG [__workflow_update_install] passing job to background runner: [u'/usr/bin/python', '/Users/fox/Library/Mobile Documents/com~apple~CloudDocs/Alfred.alfredpreferences/workflows/user.workflow.82405BDD-AE7F-4FD5-A8FF-F4D3227C9F90/workflow/background.pyc', u'__workflow_update_install'] 16:49:36 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.0) ---------- 16:49:36 background.py:197 DEBUG [__workflow_update_install] background job started 16:49:36 workflow.py:1414 DEBUG Downloading and installing update ... 16:49:36 workflow.py:2289 DEBUG ---------- finished in 0.685s ---------- [16:49:36.170] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:update" valid="no"><title>New version available</title><subtitle>Action this item to install the update</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items><?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:update" valid="no"><title>New version available</title><subtitle>Action this item to install the update</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item><item valid="no"><title>Downloading and installing update ...</title><subtitle /><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item></items> [16:49:36.172] WARNING: Dict.cc[Script Filter] XML Parse Error 'The operation couldn’t be completed. (NSXMLParserErrorDomain error 64.)'. Row 2, Col 531: 'XML declaration allowed only at the start of the document' in XML: <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:update" valid="no"><title>New version available</title><subtitle>Action this item to install the update</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items><?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:update" valid="no"><title>New version available</title><subtitle>Action this item to install the update</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item><item valid="no"><title>Downloading and installing update ...</title><subtitle /><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item></items> [16:51:05.560] Dict.cc[Script Filter] Queuing argument '' [16:51:06.791] Dict.cc[Script Filter] Script with argv '(null)' finished [16:51:06.798] STDERR: Dict.cc[Script Filter] 16:51:06 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.1) ---------- 16:51:06 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:51:06 workflow.py:2531 DEBUG update check not due 16:51:06 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:51:06 workflow.py:2461 DEBUG update_data: {u'available': False, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:51:06 workflow.py:2411 DEBUG last run version: 1.3.0 16:51:06 workflow.py:2411 DEBUG last run version: 1.3.0 16:51:06 parseDictsData.py:52 DEBUG connectToDatabase: 0.00526595115662 16:51:06 workflow.py:2440 DEBUG set last run version: 1.3.1 16:51:06 workflow.py:2289 DEBUG ---------- finished in 0.024s ---------- [16:51:06.799] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items> [16:51:11.741] Dict.cc[Script Filter] Queuing argument ' wf:openSettings' [16:51:48.500] Dict.cc[Script Filter] Queuing argument '' [16:51:48.767] Dict.cc[Script Filter] Script with argv '(null)' finished [16:51:48.778] STDERR: Dict.cc[Script Filter] 16:51:48 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.1) ---------- 16:51:48 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:51:48 workflow.py:2531 DEBUG update check not due 16:51:48 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:51:48 workflow.py:2461 DEBUG update_data: {u'available': False, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:51:48 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:48 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:48 parseDictsData.py:52 DEBUG connectToDatabase: 0.00530600547791 16:51:48 workflow.py:2440 DEBUG set last run version: 1.3.1 16:51:48 workflow.py:2289 DEBUG ---------- finished in 0.016s ---------- [16:51:48.779] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items> [16:51:49.148] Dict.cc[Script Filter] Queuing argument ' ' [16:51:49.391] Dict.cc[Script Filter] Script with argv '(null)' finished [16:51:49.405] STDERR: Dict.cc[Script Filter] 16:51:49 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.1) ---------- 16:51:49 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:51:49 workflow.py:2531 DEBUG update check not due 16:51:49 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:51:49 workflow.py:2461 DEBUG update_data: {u'available': False, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:51:49 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:49 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:49 parseDictsData.py:52 DEBUG connectToDatabase: 0.00472187995911 16:51:49 workflow.py:2440 DEBUG set last run version: 1.3.1 16:51:49 workflow.py:2289 DEBUG ---------- finished in 0.015s ---------- [16:51:49.406] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items> [16:51:52.023] Dict.cc[Script Filter] Queuing argument ' wf:openSettings' [16:51:52.333] Dict.cc[Script Filter] Script with argv '(null)' finished [16:51:52.351] STDERR: Dict.cc[Script Filter] 16:51:52 workflow.py:2247 DEBUG ---------- Dict.cc (1.3.1) ---------- 16:51:52 workflow.py:1657 DEBUG reading settings from /Users/fox/Library/Application Support/Alfred/Workflow Data/de.nieting.DictCC/settings.json 16:51:52 workflow.py:2531 DEBUG update check not due 16:51:52 workflow.py:1884 DEBUG loading cached data: /Users/fox/Library/Caches/com.runningwithcrayons.Alfred/Workflow Data/de.nieting.DictCC/__workflow_update_status.cpickle 16:51:52 workflow.py:2461 DEBUG update_data: {u'available': False, u'version': u'v1.3.1', u'download_url': u'https://github.com/Kavakuo/Dict.cc-Alfred-Workflow/releases/download/v1.3.1/Dictcc.alfredworkflow'} 16:51:52 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:52 workflow.py:2411 DEBUG last run version: 1.3.1 16:51:52 parseDictsData.py:52 DEBUG connectToDatabase: 0.00494694709778 16:51:52 workflow.py:1414 DEBUG Opening workflow settings... 16:51:52 workflow.py:2289 DEBUG ---------- finished in 0.076s ---------- [16:51:52.352] Dict.cc[Script Filter] <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items><?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item><item valid="no"><title>Opening workflow settings...</title><subtitle /><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item></items> [16:51:52.354] WARNING: Dict.cc[Script Filter] XML Parse Error 'The operation couldn’t be completed. (NSXMLParserErrorDomain error 64.)'. Row 2, Col 292: 'XML declaration allowed only at the start of the document' in XML: <?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item></items><?xml version="1.0" encoding="utf-8"?> <items><item autocomplete=" wf:openSettings" valid="no"><title>You need to configure this workflow.</title><subtitle>Action this item to start the configuration.</subtitle><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/AlertCautionIcon.icns</icon></item><item valid="no"><title>Opening workflow settings...</title><subtitle /><icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ToolbarInfo.icns</icon></item></items> [16:52:37.845] Dict.cc[Script Filter] Queuing argument ' wf:executeParsing' Link to comment
deanishe Posted January 21, 2020 Share Posted January 21, 2020 2 hours ago, romebot said: I needed to configure, which popped up the text file (however, it had the info from yesterday even though I deleted the workflow and started from scratch today). I corrected the text file name and saved. Judging by the log, you haven't configured it correctly, and I can't comment on what you might have done wrong without seeing your configuration. Also, deleting the workflow does not delete its settings because they're not stored in the workflow. If you really want to delete the settings, enter dictcc workflow:deldata. If your config is what you posted above, then it's invalid. You need to put the correct path to the downloaded dictionary in your config, and delete the extraneous part as WalterBeiter described above. Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now