Giter Site home page Giter Site logo

Duplicate categories are created if new members are assigned to channels and channels are assigned to categories about mattermost-plugin-welcomebot HOT 6 OPEN

christianhueserhzdr avatar christianhueserhzdr commented on June 20, 2024
Duplicate categories are created if new members are assigned to channels and channels are assigned to categories

from mattermost-plugin-welcomebot.

Comments (6)

christianhueserhzdr avatar christianhueserhzdr commented on June 20, 2024

Is there any update on this issue?

from mattermost-plugin-welcomebot.

christianhueserhzdr avatar christianhueserhzdr commented on June 20, 2024

Do you need any additional information about this issue from my side? Thanks for letting me know!

from mattermost-plugin-welcomebot.

mickmister avatar mickmister commented on June 20, 2024

HI @christianhueserhzdr, thank you for filing this issue. I'm thinking we can solve this in the welcomebot plugin, by debouncing the operations of adding the user to multiple channels.

We currently do not do any "waiting" in between adding the user to different channels. If we add some wait period (~3seconds) I think that would be enough to avoid this issue. What are your thoughts on this?

Here are the two places we are doing this operation in a loop:

for _, channelName := range configMessageAction.ChannelsAddedTo {
p.joinChannel(action, channelName)
}

for _, channelName := range configAction.ChannelsAddedTo {
p.joinChannel(action, channelName)
}

from mattermost-plugin-welcomebot.

mickmister avatar mickmister commented on June 20, 2024

@raghavaggarwal2308 For context, there is a feature called "Channel Actions" in the playbooks plugin https://github.com/mattermost/mattermost-plugin-playbooks, that allows an admin to configure the channel to make it so whenever a new user joins the channel, they will have that channel added to a specific channel category.

It seems there is a race condition happening with the welcomebot and playbooks plugins, where the welcomebot plugin is adding users to the channels too quickly, so the "channel category add" process can end up creating new categories instead of using existing ones, which results in duplicate channel categories. If we slow down the welcomebot's channel member modifications to avoid this race condition, I think the issue will be avoided.

from mattermost-plugin-welcomebot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.