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

Allow support channel settings to be either channel name OR channel ID #613

Merged
merged 4 commits into from
Oct 17, 2024

Commits on Oct 10, 2024

  1. Refactor support channel config

    This gets rid of some duplicate code and makes it simpler to add
    additional support channels in future.
    rebkwok committed Oct 10, 2024
    Configuration menu
    Copy the full SHA
    85bce9a View commit details
    Browse the repository at this point in the history
  2. Allow support channel settings to be either channel name OR channel ID

    Most slack functions will accept either a channel name or a channel
    ID. We always use a channel ID for support channels for the few that
    require it. For readability, our settings have used channel names, but the
    disadvantage is that if a channel name changes, bennettbot will no
    longer be able to post to it.
    
    This allows settings to be either channel name or channel ID. If we
    decide to change them to channel IDs in prod, this means channel names
    can be changed with no interruption to how the support keywords work.
    rebkwok committed Oct 10, 2024
    Configuration menu
    Copy the full SHA
    0b93bdf View commit details
    Browse the repository at this point in the history

Commits on Oct 15, 2024

  1. Move support config to a shared module

    Both the bot and the message checker in the dispatcher use elements
    of the support config, so move it out into a shared module.
    
    I'm not greatly happy about having a config.py that this lives in,
    but I don't want to pollute settings.py with functions that build
    config, and I don't want dispatcher.py to be dependent on bot.py
    
    Also fixes a bug with the reaction emoji config, and uses
    "support_channel" as the key in the support config to be more
    explicit about which channel we're referring to in functions that
    use this config.
    rebkwok committed Oct 15, 2024
    Configuration menu
    Copy the full SHA
    966056b View commit details
    Browse the repository at this point in the history

Commits on Oct 16, 2024

  1. Update comments

    rebkwok committed Oct 16, 2024
    Configuration menu
    Copy the full SHA
    0950ef7 View commit details
    Browse the repository at this point in the history