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

Pachli doesn't stop creating UP topics #934

Closed
nichu42 opened this issue Sep 9, 2024 · 13 comments
Closed

Pachli doesn't stop creating UP topics #934

nichu42 opened this issue Sep 9, 2024 · 13 comments
Assignees

Comments

@nichu42
Copy link
Contributor

nichu42 commented Sep 9, 2024

Describe the bug
After reworking the notification system, Pachli creates new UnifiedPush topics in ntfy every other day. See screenshot. It happens only on my tablet, my phone works fine.

Expected behavior
Only one UP topic per account in Pachli.

Screenshots or video
Screenshot_20240909_175837_ntfy_1.jpg

Versions
Pachli 2.8.1
ntfy 1.16.0 (fdroid)
samsung SM-P613
Android-Version: 14
SDK-Level: 34

Affirmation
I have checked other issues for this project (open and closed) and I cannot find one that matches the problem I am reporting.

@JakubIwanowski
Copy link

Same thing happens, if you're logged in with multiple accounta, and you switch between them. Each switch of an account = one UP topic created

Pachli 2.8.0 from fdroid
OnePlus IN2013
Android version: 14
SDK level: 34

@nichu42
Copy link
Contributor Author

nichu42 commented Sep 10, 2024

Ah, yes! That's when it happens. The same on my other device (Fairphone 5).

@nikclayton
Copy link
Contributor

Thanks for the report, sorry about that.

Note to self: Check the code that works around the store bugs in UnifiedPush isn't wiping out the per-UnifiedPush-instance token in UnifiedPush.registerApp

@nikclayton nikclayton self-assigned this Sep 13, 2024
@nikclayton
Copy link
Contributor

@JakubIwanowski @nichu42 Do you still see this behaviour?

When I checked two weeks ago I could reproduce just by switching accounts, as you report.

Now I can't. I'm logged in with two accounts, and see two topics in ntfy.

When I switch accounts (or swipe/dismiss Pachli and re-open it), then check ntfy, I still see two topics in ntfy.

The endpoint (the ntfy.sh/... bit) shown in ntfy changes every time, but that's expected, as Pachli resubscribes on launch and when accounts are switched, in case there was a problem subscribing to notifications on the last attempt.

I see the same behaviour if I install https://unifiedpush.org/users/distributors/fcm/ and switch to that (in Pachli this is "Preferences > Change Unified Push distributor"). Pachli registers once per account, so for me it shows up twice.

Or is this behaviour you only see once per day?

@nichu42
Copy link
Contributor Author

nichu42 commented Sep 25, 2024

@nikclayton I just checked. On my smartphone, I'm connected with three Mastodon accounts. I had > 20 UP entries for Pachli.
I have now deleted them all, opened up Pachli again and switched back and forth between the accounts. I now have 5 entries, but that's it for now.

Edit: On my tablet I had 43 entries (5 accounts), now 6 entries.

I will try again tomorrow.

@JakubIwanowski
Copy link

@nikclayton

I've reinstalled Pachli. When I added two Mastodon accounts, everything seemed to be working fine, but when I added a GoToSocial account, the app started adding topics every time I switch an account. Maybe it has to something to do with GTS account?

@JakubIwanowski
Copy link

One more thing, GTS doesn't have push notifications implemented, yet:

superseriousbusiness/gotosocial#2797
superseriousbusiness/gotosocial#1350

Maybe that's what's registering extra topics?

@nichu42
Copy link
Contributor Author

nichu42 commented Sep 25, 2024

@nikclayton

Maybe it has to something to do with GTS account?

It's only Mastodon here, so I doubt it is (only) GTS related.

@nikclayton
Copy link
Contributor

Thanks for the additional details. I'm rolling out a new version of Pachli Current which might resolve this. It's difficult to tell, since I still can't reproduce the problem, and I have five accounts logged in.

This is currently stuck in Google Play because of a bug there (I've escalated that separately).

If you'd like to check sooner, and you're comfortable installing a downloaded APK file, the most recent release build for Google Play is at https://github.com/pachli/pachli-android/actions/runs/11036688928 (the "app-release.apk" link at the bottom of the page). If you can try that and let me know if it resolves the issue for you that would be great.

@JakubIwanowski
Copy link

@nikclayton

Looks like it working, now! Thanks! :)

@nikclayton
Copy link
Contributor

@JakubIwanowski Thanks for the feedback. @nichu42 Pachli Current has been updated with this change, if you're able to try that.

@nichu42
Copy link
Contributor Author

nichu42 commented Sep 27, 2024

@nikclayton I do not have Pachli Current installed. Does ist always have the latest version or is it sometimes behind the release?

@nichu42
Copy link
Contributor Author

nichu42 commented Oct 1, 2024

I have switched to Pachli Current 2.8.2+f9ca3cd7 and can confirm that the issue is gone. Thank you!

@nichu42 nichu42 closed this as completed Oct 1, 2024
@github-project-automation github-project-automation bot moved this from Todo to Done in Pachli roadmap Oct 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

No branches or pull requests

3 participants