da-rth / yasb

A highly configurable cross-platform (Windows) status bar written in Python.
MIT License
1.29k stars 78 forks source link

Updated Tauri to 1.5.x #117

Open isaacgale opened 7 months ago

isaacgale commented 7 months ago

Hi All, firstly I am a total rust newbie so please go easy on me.

I have updated the tauri-port to the latest 1.5.x version so I could build the application on my personal computer (MacOS) for my work Windows 11 machine.... corporate policy issues don't ask. see this for more information https://tauri.app/v1/guides/building/cross-platform/#experimental-build-windows-apps-on-linux-and-macos

It all compiled and the exe launches. However is looks like there is an issue parsing the Komorebi (v0.1.19) events. The log contains entries like this:

04:38:37 [INFO] Initialising yasb v0.1.0 04:38:37 [INFO] Logging to: C:\Users\IG4361.config\yasb\yasb.log 04:38:37 [INFO] Found config at: C:\Users\redacted.config\yasb\config.yaml 04:38:37 [INFO] Found stylesheet at: C:\Users\redacted.config\yasb\styles.scss 04:38:38 [INFO] Created yasb_bar_c2a9c7adcba64d54 on "\.\DISPLAY5" [ Pos: 0,0 | Edge: Top | AppBar: true ] 04:38:38 [INFO] Initialising background listeners. 04:38:38 [INFO] Always on top detected. Window(s) will be automatically hidden when fullscreen is detected. 04:38:38 [INFO] Watching files for changes. 04:38:38 [INFO] Initialisation complete. 04:38:39 [INFO] KomorebiEventListener: Initialisng Event Listener. 04:38:39 [INFO] KomorebiEventListener: creating named pipe: \.\pipe\yasb-komorebi. 04:38:39 [INFO] KomorebiEventListener: Connecting named pipe. 04:38:39 [INFO] Win32EventHookListener: Initialisng. 04:38:39 [INFO] Initialised Webview: yasb_bar_c2a9c7adcba64d54 has successfully mounted. 04:38:39 [INFO] KomorebiEventListener: waiting to subscribe to named pipe. 04:38:40 [INFO] KomorebiEventListener: pipe connected. Listening for komorebi events. 04:38:40 [INFO] KomorebiEventListener: successfully subscribed to named pipe. 04:38:40 [ERROR] Event[FloatRule]: invalid type: map, expected a string 04:38:40 [INFO] KomorebiEventListener: added ignore rule for process yasb.exe. 04:39:07 [WARN] NewEvents emitted without explicit RedrawEventsCleared 04:39:07 [WARN] RedrawEventsCleared emitted without explicit MainEventsCleared 04:39:07 [ERROR] Event[FocusWorkspaceNumber]: invalid type: map, expected a string 04:39:39 [ERROR] Event[FocusWorkspaceNumber]: invalid type: map, expected a string 04:58:27 [ERROR] Event[FocusWorkspaceNumber]: invalid type: map, expected a string

Any help would be greatly appreciated. My fork is here: https://github.com/isaacgale/yasb/tree/tauri-port

isaacgale commented 7 months ago

I managed to figure it out the 'identifiers' in Komorebi JSON have changed at some point from plain Strings to Objects. So that was causing the serde parsing issue. I have pushed a fix for this on my fork.

isaacgale commented 7 months ago

Re-opened this issue so I can link my PR to it