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

Refreshing home timeline sometimes duplicates newest post #928

Open
Jasdemi opened this issue Sep 4, 2024 · 3 comments
Open

Refreshing home timeline sometimes duplicates newest post #928

Jasdemi opened this issue Sep 4, 2024 · 3 comments

Comments

@Jasdemi
Copy link

Jasdemi commented Sep 4, 2024

Describe the bug
When refreshing the home timeline, it will sometimes duplicate the newest post. Refreshing it again might add another one, up to four.

To Reproduce
Steps to reproduce the behavior:

  1. Refresh your home timeline
  2. Repeat until it happens
    Not sure what is triggering it. Can't always reproduce it, but happens quite often.

Screenshots or video

document_5388970224491974811.1.mp4

photo_5388970224948208180_y

Versions
Pachli Current 2.8.0+c9044536
Device:
Google Pixel 6a
Android version: 14
SDK level: 34
Account:
@jasdemi@jasdemi.com
Version: 0.16.1-SNAPSHOT+git-6ee540a

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

@nikclayton
Copy link
Contributor

Can I get an account to test with on your server?

I've never seen this, or seen it reported with Pachli or Tusky (the refresh codebase is still quite similar between the two). So my immediate instinct is this is your server returning duplicate results, similar to a Friendica bug discovered in #338.

An account would let me send API requests at it, see exactly what's coming back, and see if I can reproduce this.

@Jasdemi
Copy link
Author

Jasdemi commented Sep 4, 2024

Login details sent via email.

@nikclayton
Copy link
Contributor

Thanks. I'll poke the endpoint periodically to see if I can reproduce.

nikclayton added a commit that referenced this issue Jan 23, 2025
The modifications to the Notifications* classes highlighted different
(and better) ways of writing the code that manages status timelines.
Follow those practices here.

Changes include:

- Move `pachliAccountId` in to `IStatusViewData` so the adapter does not
need to be initialised with the information. This allows the parameter
to be removed from functions that operate on `IStatusViewData`, and the
adapter does not need to be marked `lateinit`.

- Convert Fragment/ViewModel communication to use the `uiResult`
pattern instead of separate `uiSuccess` and `uiError`.

- Show a `LinearProgressIndicator` when refreshing the list.

- Restore the reading position more smoothly by responding when the
first page of results is loaded.

- Save the reading position to `RemoteKeyEntity` instead of a dedicated
property in `AccountEntity`.

- Fixed queries for returning the row number of a notification or
status in the database.

Fixes #238, #872, #928, #1190
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

2 participants