Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Change now" in settings doesn't work #85

Open
Vyachean opened this issue Mar 24, 2024 · 37 comments
Open

"Change now" in settings doesn't work #85

Vyachean opened this issue Mar 24, 2024 · 37 comments
Assignees
Labels
bug Something isn't working

Comments

@Vyachean
Copy link

Automatic wallpaper change does not work starting from version 2.4.0. Version 2.3.1 works fine.
Changing wallpaper only works from the wallpaper viewer. When you try to change the wallpaper from the settings menu or from the shortcut, the icon rotates and nothing changes.
Android 13, miui for pad 14.

@ammargitham
Copy link
Owner

Have you correctly configured the sources? Can you post screenshots of your sources screen?

@Vyachean
Copy link
Author

Screenshot of source settings

Screenshot_2024-03-25-07-36-11-729_com ammar wallflow

@Vyachean
Copy link
Author

Now I discovered that after a timeout of 4 hours the wallpaper changed. The problem with the "Change now" button remains.

@Vyachean Vyachean changed the title Automatic wallpaper change does not work "Change now" in settings doesn't work Mar 25, 2024
@ammargitham
Copy link
Owner

So does the 'change now' button keep on loading or does it stop with any info?

@Vyachean
Copy link
Author

Vyachean commented Mar 26, 2024

I haven't seen any messages, just doesn't work and nothing happens. Observed the behavior, I changed the time of changing the wallpaper, the wallpaper did not change anymore. There are no notifications either.
If i start changing the wallpaper through the shortcut, the indicator appears and it spins endlessly without messages.

@ammargitham
Copy link
Owner

To help debug this, create a backup and share the backup here.

@ammargitham
Copy link
Owner

Are you using Plus or Regular? If using plus, try disabling object detection.

@Vyachean
Copy link
Author

Vyachean commented Mar 26, 2024

wallflow_backup_20240326190253.json
I've tried both versions, now I use a regular

@ammargitham
Copy link
Owner

Hi. I tried your backup and the 'Change Now' button seems to be working correctly. As for the notification, did you give the app the notification permission? You can check that in App info -> Notifications.

@ammargitham
Copy link
Owner

It could be that the wallpaper sizes are large and it's taking time to download the wallpapers. If you enable notifications, you would be able to see the progress.

@Vyachean
Copy link
Author

Of course, I have notifications turned on, I enabled all the permissions that are in miui, and added to exceptions to optimize the battery. The peculiarity is that version 2.3.1 works without problems with similar settings.

@ammargitham
Copy link
Owner

ammargitham commented Mar 29, 2024

Okay. To further debug this, can you use LogFox or any Logcat app to see if there are any logs when you click 'Change Now'?

@Vyachean
Copy link
Author

30_03-07-17-36_873.zip

@ammargitham
Copy link
Owner

Nothing of use in the logs. Next what I can do is give you a debug build with various debug lines added. You can use the same method to give me back the logs.

@ammargitham
Copy link
Owner

Here is the debug apk. app-base-debug.zip

Note that it will be a bit laggy compared to release builds. Try it and send me the logs.

@ammargitham
Copy link
Owner

@Vyachean Were you able to check the debug build?

@gaabster
Copy link

gaabster commented May 4, 2024

It seems that the app (version 2.5.0) stopped working completely on my Tab s7 fe. I tried earlier versions and it doesn't change wallpapers automatically or manually. There is no notification. I'm not sure what to do, especially that the app works on my phone running lineageos 21 (android 14).

Edit:

OK, I just checked few things again and the only way to change wallpapers I by doing it through "Local Tab" menu. Other methods like "Auto Wallpaper" or "Change now" don't work. Oh and this is the regular, non Plus version.

@ammargitham
Copy link
Owner

@gaabster What toast message do you get when you click 'Change now'?

@gaabster
Copy link

gaabster commented May 4, 2024

@gaabster What toast message do you get when you click 'Change now'?

Nothing. It just keeps on spinning and spinning. The tablet is running official, non rooted android 14 OS. I had issus where it would not run some Google apps like Google Sounds.

Another edit:
Version 2.3.1 works great, just as op said.

@ammargitham
Copy link
Owner

Please try https://github.com/ammargitham/WallFlow/releases/tag/v2.6.0-alpha01 and let me know if this issue is fixed.

@gaabster
Copy link

gaabster commented May 6, 2024

Hello.
Sadly the issue is still present. There is no notification or any toast message.
The app also crashed few times when exiting settings.

APP_VERSION_CODE = 2204
APP_VERSION_NAME = 2.6.0-alpha01
PACKAGE_NAME = com.ammar.wallflow
PHONE_MODEL = SM-T733
ANDROID_VERSION = 14
BRAND = samsung
PRODUCT = gts7fewifieea

Stacktrace: 
java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 1
	at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
	at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70)
	at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266)
	at java.util.Objects.checkIndex(Objects.java:359)
	at java.util.ArrayList.get(ArrayList.java:434)
	at androidx.navigation.compose.NavHostKt$NavHost$28$1.invokeSuspend(SourceFile:47)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(SourceFile:9)
	at kotlinx.coroutines.DispatchedTask.run(SourceFile:113)
	at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(SourceFile:24)
	at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.run(SourceFile:3)
	at android.os.Handler.handleCallback(Handler.java:958)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:230)
	at android.os.Looper.loop(Looper.java:319)
	at android.app.ActivityThread.main(ActivityThread.java:8913)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:608)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)
	Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [androidx.compose.ui.platform.MotionDurationScaleImpl@65763dc, androidx.compose.runtime.BroadcastFrameClock@bcabce5, DeferredCoroutine{Cancelling}@8fe63ba, AndroidUiDispatcher@28f526b]

@ammargitham ammargitham reopened this May 6, 2024
@ammargitham
Copy link
Owner

ammargitham commented May 6, 2024

ok. I will check this further. Will try to provide a debug build later this week for you.

For the crash, I have already reported to Google. Which they have not acknowledged yet.

@ammargitham ammargitham self-assigned this May 7, 2024
@ammargitham ammargitham added the bug Something isn't working label May 7, 2024
@ammargitham
Copy link
Owner

ammargitham commented May 7, 2024

@gaabster Can you share me your backup file? Also, is your tablet rooted by any chance?

@gaabster
Copy link

gaabster commented May 7, 2024

@gaabster Can you share me your backup file? Also, is your tablet rooted by any chance?

No problem.
wallflow_tablet_backup.json
As for the tablet, it's not rooted. My phone is running a custom rom, crdroid android 14, but I don't use root. I also tried restoring backup from my phone but it did not help.

@ammargitham
Copy link
Owner

@gaabster Can you share your local folders too? Since you have configured only local wallpapers in your settings.

@gaabster
Copy link

gaabster commented May 9, 2024 via email

@ammargitham
Copy link
Owner

Mail me a drive link if possible ([email protected]).

@hirnsushi
Copy link

hirnsushi commented May 10, 2024

I have the same problem, I do however get a toast on the bottom with the text "Wallpaper not changed: No wallpaper found".

Might be related to the Light/Dark feature, if I switch sources to "Use local directories" everything works fine 🤔
Also using local wallpapers, but that wasn't a problem in previous versions, even the Light/Dark feature used to work. I sadly can't pinpoint exactly when that regression happened.

Edit: Nope, spoke too soon, managed to break "Use local directories" as well by deleting a picture in the wallpaper folder that was set as the current wallpaper.
Resetting app data got it going again including Light/Dark. Maybe the last picture sticks around somewhere and doesn't get cleared even if the wallpaper has been set to something else in the meantime, and if it doesn't exist it breaks the source? 🤔

@gaabster
Copy link

OK I got some logs for you. App version 2.5.0. Hope it helps.
11_05-10-50-21_436.log
logcat--pid=29583.txt

@ammargitham
Copy link
Owner

@hirnsushi Thanks for the info. Maybe it is an issue with the missing file. I will try to reproduce that particular issue locally.
@gaabster I checked the logs, nothing of value there. It will be helpful if you could also try to give me the same with the 2.6.0-alpha01 version. I am also preparing a debug build for you to gather more logs.

@gaabster
Copy link

OK new log
11_05-12-57-26_636.log

@ammargitham
Copy link
Owner

@gaabster Thanks for that. Found the issue.

AutoWallpaperWorker: doWork: AutoWallpaper failed since not in default orientation

Are you holding your tablet vertically or horizontally?

@gaabster
Copy link

Horizontally. So you suggest I should try holding it vertically and try to change wallpaper then?

@ammargitham
Copy link
Owner

@gaabster Try it. It should work. I think this is a Samsung tablet problem. I added that check due to this issue.

To workaround this, I will add a setting for you to set your default orientation.

@gaabster
Copy link

@ammargitham And it works! Thank you. I always had screen Auto rotate off.
I agree that an option to set default orientation would probably be best for now.

ammargitham added a commit that referenced this issue May 12, 2024
@ammargitham
Copy link
Owner

@hirnsushi Have you tried 2.6.0-alpha01?

@hirnsushi
Copy link

That works! Thank you so much for fixing this ☺️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants