You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Remove unused forward reference
* Registration: Use channel names instead of IDs
* Registration: Use role names instead of IDs
* Refactor config and cog setup
General
* User __name__ as logger name everywhere
'$participants' command:
* Move from extension module to simple cog
* Use dynamic role list instead of hard-coded role names
* Add channel visibility check
bot.py
* Simplify and refactor
program notifications
* Use channel names in config, not IDs
* Simplify notification logic
* Make Config non-Singleton
* Streamline configuration
* Config: Require file path explicitly
* run-bot: Expect config file path as --config-file or CONFIG_FILE
* README: Update
* uv: Remove python-dotenv and certifi dependencies
* Move config files to repo root
* Docker: Expect CONFIG_FILE
* Compose: Specify config file and .secrets
* Streamline configuration
Model all configuration as cog-specific pydantic.BaseModels.
* Remove unused dependencies
Remove certifi, yarl and arrow
* Remove ansible
* Docker: Use bind instead of COPY for prod-config.toml
* Require --config-file, drop CONFIG_FILE
* Dockerfile: Drop $PATH overwrite
* Update livestreams and schedule-cache file paths
* Registration: Improve accessibility
Use plain messages instead of embeds, use ASCII codes instead of unicode emojis
* fix formatting
* Fix emoji insertion on button label
* Update README and screenshots
*[scripts/configure-guild.py](./scripts/configure-guild.py): Configure channels and roles of a Discord server
7
+
*[scripts/export-members.py](./scripts/export-members.py): Export a list of all server members and their roles
8
8
9
-
## Overview
9
+
The scripts work standalone and only require an Auth token. Please find more documentation in the respective files.
10
10
11
-
The `main` method in `src/europython_discord/bot.py` is the entry point for the bot.
12
-
I't a good starting point to start browsing the codebase.
13
-
It requires a `.secrets` file in the root of the repository with `DISCORD_BOT_TOKEN` and `PRETIX_TOKEN` environment variables.
11
+
The bot has the following extensions ("Cogs"):
14
12
15
-
### Registration
13
+
* Ping: To check if the bot is running, write `$ping` in any channel. The bot will respond with `Pong!`.
14
+
* Guild Statistics: As an organizer, write `$participants` in an organizer-only channel. The bot will respond with a list of roles, and the number of members per role.
15
+
* Registration: On startup, the bot posts a registration form. New users must register using their Pretix ticket data. On success, the bot assigns the appropriate roles.
16
+
* Programme Notifications: Before each session, the bot posts a session summary and updates the livestream URLs.
16
17
17
-
At EuroPython, we use [pretix](https://pretix.eu/about/en/) as our ticketing system.
The bot utilizes the Pretix API to fetch ticket information and creates an in-memory key-value store to retrieve the ticket type for a given Discord user. The mapping between ticket types and Discord roles is defined in a JSON file, such as ticket_to_roles_prod.json, and is used by the bot to assign roles to users.
22
+
### Registration Form:
23
+

20
24
21
-
There are safeguard methods in place to prevent users from registering multiple times and to make a direct Pretix API call in case the user information is not available in the in-memory store.
All configuration is server-agnostic. You can set up your own Discord server and use the included configuration.
25
31
26
-
Is a service to push the programme notification to Discord. Pretalx API is used to fetch the programme information, and `config.toml` holds information about livestream URLs.
32
+
Arguments and environment variables:
27
33
28
-
### Organizers extension
34
+
* Argument `--config-file`: Path to .toml configuration file
0 commit comments