danyspin97 / wpaperd

Modern wallpaper daemon for Wayland
GNU General Public License v3.0
332 stars 26 forks source link

fix an unsafe unwrap in animation transition #73

Closed antholeole closed 5 months ago

antholeole commented 5 months ago

this paniced every time previously

danyspin97 commented 5 months ago

My apologies, I might be breaking too much stuff in main branch. I will switch to a development branch. Also, how were you able to trigger a panic there? I am interested in reproducing it so that I can fix it, that value shouldn't be empty when a transition is running.

Btw, thank you for the fix and the PR @antholeole !

antholeole commented 5 months ago

No worries! thanks for making this package, seems to do exactly what I want. I'm unsure of exactly what triggered the case, but it panic'd immediately, so I'm assuming it had something to do with the base case (no image to some image).

wallpaper.toml:

[DP-2]
duration = "1h"
mode = "fit-border-color"
path = "~/backgrounds"
sorting = "random"

[HDMI-A-1]
duration = "1h"
mode = "fit-border-color"
path = "~/backgrounds"
sorting = "random"

[any]
duration = "1h"
mode = "fit-border-color"
path = "~/backgrounds"
sorting = "random"

[default]
duration = "1h"
mode = "fit-border-color"
path = "~/backgrounds"
sorting = "random"

[eDP-1]
duration = "1h"
mode = "fit-border-color"
path = "~/backgrounds"
sorting = "random"

btw, it doesn't seem like inheritance from default or any works on master currently. I had to duplicate path to all displays to get the toml to parse.

thx for the pkg!

danyspin97 commented 5 months ago

No worries! thanks for making this package, seems to do exactly what I want.

I am glad that is useful :) Also, I am really happy to see that "fit-border-color" is getting used, I added it on a whim xD

btw, it doesn't seem like inheritance from default or any works on master currently. I had to duplicate path to all displays to get the toml to parse.

Can you please share the configuration that doesn't work in another issue? I am currently trying both default and any, and they are working as I am expecting them to, so probably it's something I am not thinking of or the documentation doesn't explain it well.