chrisgrieser / shimmering-obsidian

Alfred Workflow with dozens of features for controlling your Obsidian vault.
https://alfred.app/workflows/chrisgrieser/shimmering-obsidian/
MIT License
830 stars 41 forks source link

[Bug]: Unable to switch vault #101

Closed feliao closed 1 year ago

feliao commented 1 year ago

Bug Description

Everything works fine. I can see both vaults (personal, Denodo) and can even switch into their finder location. But when I try to switch the workflow ("ov") from Personal to Denodo (Shift-enter), it just stays within Personal. The ticket symbol stays with personal and all the interactions stays with the Personal Vault.

Just to add, if I switch the sequence of which vault to initialise first, then I get the reverse problem, ie I can interact with the Denodo vault but can't switch into the Personal vault so the vault setup themselves seems to be fine.

Relevant Screenshot

No response

To Reproduce

No response

Debugging Log

[10:14:00.302] Shimmering Obsidian[Script Filter] {"items":[{"title":"✅ Personal","subtitle":"/Documents/Obsidian Personal","arg":"obsidian://open?vault=Personal","mods":{"alt":{"arg":"/Users/felixliao/Documents/Obsidian Personal/Personal"},"cmd":{"arg":"/Users/felixliao/Documents/Obsidian Personal/Personal"},"ctrl":{"arg":"/Users/felixliao/Documents/Obsidian Personal/Personal"},"shift":{"arg":"/Users/felixliao/Documents/Obsidian Personal/Personal"},"fn":{"arg":"/Users/felixliao/Documents/Obsidian Personal/Personal"}}},{"title":"Denodo","subtitle":"/Documents/Obsidian Denodo","arg":"obsidian://open?vault=Denodo","mods":{"alt":{"arg":"/Users/felixliao/Documents/Obsidian Denodo/Denodo"},"cmd":{"arg":"/Users/felixliao/Documents/Obsidian Denodo/Denodo"},"ctrl":{"arg":"/Users/felixliao/Documents/Obsidian Denodo/Denodo"},"shift":{"arg":"/Users/felixliao/Documents/Obsidian Denodo/Denodo"},"fn":{"arg":"/Users/felixliao/Documents/Obsidian Denodo/Denodo"}}},{"title":"Vault Menu","subtitle":"Create or delete vaults","arg":"obsidian://advanced-uri?commandid=app%253Aopen-vault","icon":{"path":"icons/settings.png"},"mods":{"alt":{"valid":false,"subtitle":"⛔️"},"cmd":{"valid":false,"subtitle":"⛔️"},"ctrl":{"valid":false,"subtitle":"⛔️"},"shift":{"valid":false,"subtitle":"⛔️"}}}]}
[10:14:08.992] Shimmering Obsidian[Script Filter] Processing complete
[10:14:08.994] Shimmering Obsidian[Script Filter] Passing output '/Users/felixliao/Documents/Obsidian Denodo/Denodo' to Run Script
[10:14:09.196] Shimmering Obsidian[Run Script] Processing complete
[10:14:09.198] Shimmering Obsidian[Run Script] Passing output '
' to Arg and Vars
[10:14:09.199] Shimmering Obsidian[Arg and Vars] Processing complete
[10:14:09.199] Shimmering Obsidian[Arg and Vars] Passing output '/Documents/Obsidian Personal/Personal' to Post Notification
[10:14:09.200] Shimmering Obsidian[Post Notification] Processing complete
[10:14:09.201] Shimmering Obsidian[Post Notification] Passing output '/Documents/Obsidian Personal/Personal' to Play Sound
[10:14:09.246] Shimmering Obsidian[Play Sound] Processing complete
[10:14:09.248] Shimmering Obsidian[Play Sound] Passing output '/Documents/Obsidian Personal/Personal' to Call External Trigger
[10:14:09.249] Shimmering Obsidian[External] Processing complete
[10:14:09.250] Shimmering Obsidian[External] Passing output '/Documents/Obsidian Personal/Personal' to Conditional
[10:14:09.250] Shimmering Obsidian[Conditional] Processing complete
[10:14:09.251] Shimmering Obsidian[Conditional] Passing output '/Documents/Obsidian Personal/Personal' to Conditional
[10:14:09.252] Shimmering Obsidian[Conditional] Processing complete
[10:14:09.252] Shimmering Obsidian[Conditional] Passing output '/Documents/Obsidian Personal/Personal' to Run Script

Workflow Configuration 1

info.plist.zip

Workflow Configuration 2

CleanShot 2022-10-24 at 11 12 50

Version & System Information

-------------------------------
Metadata JSONs: 3/3
Metadata String Length: 1120333
-------------------------------
WORKSPACE DATA
'workspace' exists
'workspace.json' exists
-------------------------------
INSTALLED VERSION
macOS: 12.6
Alfred: 5.0.3
---
Obsidian: 1.0.2
This Workflow: 3.1.2
Advanced URI Plugin: 1.28.2
Metadata Extractor: 1.0.2
-------------------------------
LATEST VERSION
Obsidian: 1.0.0 (Insider: 1.0.2)
This Workflow: 3.1.3
Advanced URI Plugin: 1.28.2
Metadata Extractor: 1.0.2
-------------------------------
INTERNAL WORKFLOW CONFIGURATION
Vault Path: /Users/felixliao/Documents/Obsidian Personal/Personal
Vault Name (encoded): Personal
-------------------------------

Make sure you have done the following

chrisgrieser commented 1 year ago

so I looked into this, and it looks like these are 2 issues introduced by Alfred 5: 1) The notification fetches the wrong vault name, but the vault is correctly switched. 2) The vault sometimes isn't properly switched.

In case you are experiencing problem 1, I have added a fix for that in the latest release. However, in case you are experiencing problem 2, that would require a fix on Alfred 5's end, unfortunately 🙁

feliao commented 1 year ago

Thanks for looking into this Chris as I am starting to rely on your workflow more and more!

Just installed 3.2.3 and the problem still exists ☹️.

So you believe it is due to a bug in Alfred itself? does it happen to everyone?

chrisgrieser commented 1 year ago

okay, I have rewritten large parts of the workflow for #108, and as a side effect, this issue should also be solved now.

feliao commented 1 year ago

Thanks Chris!

It has definitely fixed my problem!

BTW have just bought you a cup of coffee (from Felix) for your amazing work and dedication!

Here is a related follow-up feature request (let me know if you want me to log this as a separate ticket) :+)

chrisgrieser commented 1 year ago

thank you!

regarding the feature request, the problem is that some people use the workflow to regularly open the workflow and switching shift+enter and enter would be unnecessary and off-trowing for them in turn. So I don't think i'm gonna implement that, sorry!