AceBot icon indicating copy to clipboard operation
AceBot copied to clipboard

Help channels cause channel list bounce on AHK Discord

Open onerandomusername opened this issue 3 years ago • 2 comments

I'm not sure if there's a good way to describe the title, but its when a channel is claimed the entire channel list will bounce around. Its annoying since it happens quite often, however there's an easy solution to the problem.

As proven on the Python Discord, if a channel position is not provided in the edit when switching categories, they will not bounce around. This does mean that when channels are moved they will always default to the bottom of the category. This should cause less channel bounce.

Affected Lines: https://github.com/Run1e/AceBot/blob/80db24da579eca6ff87eff11b52ee8f8175d3088/cogs/ahk/help.py#L206-L213 https://github.com/Run1e/AceBot/blob/80db24da579eca6ff87eff11b52ee8f8175d3088/cogs/ahk/help.py#L249-L256

If this is approved I can make a fix and submit a pull request myself.

onerandomusername avatar Mar 10 '21 20:03 onerandomusername

pydis sets the channel position of the channel they're moving to max(channel.pos for channel in category.text_channels) + 1 which moves it to the bottom. In the AHK discord the newly claimed channels are moved to the top of the claimed category, and since channel positions can't be negative as far as I know, we need to do a normal channel "move" which will cause the channel bouncing because of an implementation detail on discords side where all channels have globally unique positions.

As far as I can tell we can either move newly claimed channels to the bottom, or live with the channel bounce. I prefer the latter.

Run1e avatar Mar 18 '21 19:03 Run1e

Moving newly claimed channels to the bottom would also mean that those that are open for longer would be more of the focus. This may help sometimes when a channel gets no response and is left forgotten for the ones above it.

onerandomusername avatar Mar 27 '21 00:03 onerandomusername

Obsolete because of moving to help forums.

Run1e avatar Dec 25 '22 20:12 Run1e