Closed jpuris closed 2 years ago
I suspect running this from cli is not valid use case, since in the py3.sh
the workding directory is passed in from alfred
WF_DATA_DIR=$alfred_workflow_data
...
#Cache file for python binary - Allowes for faster execution
PYALIAS="$WF_DATA_DIR/py3"
But then, I've got no clue how to troubleshoot the absence of any bookmarks :(
I'm trying to get this work with Brave (Dev) browser.
No errors displayed in Alfred
You cannot run sh and py from command line because workflow dir env variable will be set by Alfred.
when you run the WF what is written in the debugger ?
what you can try is to exchange ./py3.sh and run with /usr/bin/python3
@Acidham running /usr/bin/python3 chrom_bookmarks.py youtube
gets me
❯ /usr/bin/python3 chrom_bookmarks.py youtube
Traceback (most recent call last):
File "chrom_bookmarks.py", line 26, in <module>
show_favicon = Tools.getEnvBool("show_favicon")
File "/Users/jp/Library/Application Support/Alfred/Alfred.alfredpreferences/workflows/user.workflow.70A42591-FADF-4DCD-ACE0-279A5A3EF993/Alfred3.py", line 271, in getEnvBool
if os.getenv(var).isdigit():
AttributeError: 'NoneType' object has no attribute 'isdigit'
python version
❯ /usr/bin/python3 --version
Python 3.8.9
argh ...I thought i fixed that one but seems not.
can you please ensure to configure in workflow config to show fav icons?
Found the problem. The "Dev" should actually be "Beta".
From Alfred debugger
[21:46:03.623] Logging Started...
[21:46:07.651] Chromium Bookmarks and History Search[Script Filter] Queuing argument 'youtube'
[21:46:08.091] Chromium Bookmarks and History Search[Script Filter] Script with argv 'youtube' finished
[21:46:08.095] STDERR: Chromium Bookmarks and History Search[Script Filter] PYTHON VERSION: 3.8.9 (default, Apr 13 2022, 08:48:06)
[Clang 13.1.6 (clang-1316.0.21.2.5)]
/Users/jp/Library/Application Support/BraveSoftware/Brave-Browser-Dev/Default/Bookmarks → NOT found
[21:46:08.096] Chromium Bookmarks and History Search[Script Filter] {
"items": [
{
"title": "No Bookmark found!",
"subtitle": "Search \"youtube\" in Google...",
"arg": "https://www.google.com/search?q=youtube"
}
]
}
When I first install the workflow, I did not see "Beta", hence chose "Dev"
❯ ls -l ~/Library/Application\ Support/BraveSoftware/
drwx------ jp staff 1.3 KB Fri Aug 26 21:48:06 2022 Brave-Browser-Beta
yes never used beta. You can add URL in py file. you also need to change WF config to show properly in wF config.
I am on vacation without a computer otherwise I would change it.
Thank you for the assist @Acidham and have a great holiday!
Heya!
The workflow seems to not be able to find any bookmarks, so I pocked around and in the workflows working dir run a test
which throws following
with DEBUG=1
is this something on my end?