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

fix: prevent forever chat loading animation #13929

Merged
merged 6 commits into from
Mar 12, 2024
Merged

Conversation

igor-sirotin
Copy link
Contributor

Fixes #13533

Description

  1. Prevent forever scrolling if loading new messages didn't start.
    (e.g. because all cursor is mostRecent or pending)

    if self.controller.loadMoreMessages():
    warn "failed to start loading more messages"
    return
    # If failed to `loadMoreMessages`, then the most recent message is already loaded.

  2. Prevent scrolling to messages that exist, but will never be loaded to the model, because they're not displayable.

    if message.contentType == ContentType.ContactIdentityVerification or
    message.contentType == ContentType.ContactRequest:
    warn "attempted to scroll to a non-displayed message", messageId, contentType = $message.contentType
    self.view.setMessageSearchOngoing(false)
    return

  3. Fixed behaviour when clicking on a AC contact request and verification request notifications.
    Instead of trying to scroll to message we now profile popup.

  4. Removed CURSOR_VALUE_IGNORE. It's just simpler.

  5. Added "Copy chat ID" action to chat context menu.
    Also moved all debug actions to a submenu.

Screenshot

Screen.Recording.2024-03-11.at.22.17.01.mov

@igor-sirotin igor-sirotin changed the title Fix/issue 13533 fix: prevent forever chat loading animation Mar 11, 2024
@status-im-auto
Copy link
Member

status-im-auto commented Mar 11, 2024

Jenkins Builds

Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ b84677c #1 2024-03-11 22:35:52 ~6 min macos/aarch64 🍎dmg
✔️ b84677c #1 2024-03-11 22:36:18 ~6 min tests/nim 📄log
b84677c #1 2024-03-11 22:40:04 ~10 min tests/ui 📄log
✔️ b84677c #1 2024-03-11 22:40:11 ~10 min macos/x86_64 🍎dmg
✔️ b84677c #1 2024-03-11 22:47:04 ~17 min linux/x86_64 📦tgz
✔️ b84677c #1 2024-03-11 22:53:55 ~24 min windows/x86_64 💿exe
✔️ b84677c #2 2024-03-12 12:21:20 ~10 min tests/ui 📄log

Copy link
Member

@caybro caybro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

>>> Error loading StoryBook page: QUrl("file:///home/jenkins/workspace/s_linux_x86_64_tests-ui_PR-13929/storybook/pages/EditPermissionViewPage.qml")

Looks like a legit UI-test failure but maybe you just have to rebase 🤔

Also the commit mess needs some squashing :)

Otherwise LGTM

@igor-sirotin
Copy link
Contributor Author

igor-sirotin commented Mar 12, 2024

Looks like a legit UI-test failure but maybe you just have to rebase 🤔

@caybro Don't worry, I'm keeping an eye on the tests result.
It won't let me merge it without passing 🙂

Also the commit mess needs some squashing :)

Sure. I usually use Squash and merge button on github.

@igor-sirotin
Copy link
Contributor Author

igor-sirotin commented Mar 12, 2024

@caybro FYI actually that was some kind of a glitch on CI.

https://ci.status.im/job/status-desktop/job/prs/job/linux/job/x86_64/job/tests-ui/job/PR-13929/

image

The page runs ok for me locally.
I just restarted the test on CI and it worked as well.

Copy link
Member

@jrainville jrainville left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice fixes

Copy link
Contributor

@MishkaRogachev MishkaRogachev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great!

@igor-sirotin igor-sirotin merged commit a6f5f0b into master Mar 12, 2024
8 checks passed
@igor-sirotin igor-sirotin deleted the fix/issue-13533 branch March 12, 2024 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clicking on ID verification notification in AC results in forever loading chat
5 participants