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

Show historic timeouts and bans in usercard #4760

Merged
merged 9 commits into from
Aug 13, 2023

Conversation

Nerixyz
Copy link
Contributor

@Nerixyz Nerixyz commented Aug 10, 2023

Description

This PR fixes timeouts and bans of users not being shown in their usercard and timeouts not stacking. Previously, CLEARCHATs were converted to NOTICEs. This was removed and CLEARCHATs are handled.

The fix is a bit more involved, as the addOrReplaceMessage logic now adapts to any buffer. I wasn't very sure where to put the shared logic, so I chose ChannelHelpers (analogous to IrcHelpers).

Fixes #3030.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

clang-tidy made some suggestions

src/providers/twitch/IrcMessageHandler.cpp Show resolved Hide resolved
src/providers/twitch/IrcMessageHandler.cpp Show resolved Hide resolved
src/providers/twitch/IrcMessageHandler.cpp Show resolved Hide resolved
src/util/ChannelHelpers.hpp Outdated Show resolved Hide resolved
src/util/ChannelHelpers.hpp Outdated Show resolved Hide resolved
src/util/ChannelHelpers.hpp Show resolved Hide resolved
src/util/ChannelHelpers.hpp Show resolved Hide resolved
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

clang-tidy made some suggestions

src/util/ChannelHelpers.hpp Show resolved Hide resolved
src/util/ChannelHelpers.hpp Show resolved Hide resolved
src/util/ChannelHelpers.hpp Outdated Show resolved Hide resolved
src/util/ChannelHelpers.hpp Show resolved Hide resolved
Copy link
Member

@pajlada pajlada left a comment

Choose a reason for hiding this comment

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

This change is fine to me - it was not difficult to test.

One quirk it has that I documented in ChannelHelpers is that timeouts can be merged into historic message timeouts even though they technically wouldn't if that timeout was a normal message, since we rely on the parse time of a message to know if we should merge into it.

I'm OK with the implementation as-is since it would require a pretty heavy lift to fix this issue.

Let me know if you are comfortable having this PR merged in

@Felanbird Felanbird added this to the 2.4.5 milestone Aug 12, 2023
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

clang-tidy made some suggestions

src/util/ChannelHelpers.hpp Show resolved Hide resolved
@pajlada pajlada enabled auto-merge (squash) August 13, 2023 09:25
@pajlada pajlada merged commit e7281b0 into Chatterino:master Aug 13, 2023
15 of 16 checks passed
@Nerixyz Nerixyz deleted the fix/timeout-thingy branch August 13, 2023 11:19
Nerixyz added a commit to Nerixyz/chatterino2 that referenced this pull request Aug 19, 2023
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.

Usernames in historic bans / timeouts aren't clickable.
3 participants