Discord bot · 2026

FanClub

Discord bot that turns Codeforces solves into levels, ranks, and a shared leaderboard for the UB community.

FanClub logo: a cat-eared A beside rising bars, crossed by a graph edge

Overview

FanClub runs the competitive programming community at Universitas Brawijaya on Discord. It links each member to a Codeforces handle and turns solved problems into levels, eight rank roles from Rookie to Legendary Master, and a shared leaderboard.

It also keeps the community practising: three personal daily problems, custom practice sets by rating and tag, contest announcements for Codeforces, CodeChef, and AtCoder, and a reminder every morning at 09:00 Jakarta time.

How it works

  1. Prove you own the handle

    To register, a member submits a compilation error on a random problem within five minutes. The bot checks the submission on Codeforces, so nobody can claim someone else’s account.

  2. Turn solves into progress

    The bot syncs accepted submissions, awards EXP and levels, keeps daily streaks in Asia/Jakarta time, and updates rank roles and nicknames in the form 【level】handle.

  3. Show it as images

    Profile cards, leaderboards, daily problems, and accepted-solve announcements are drawn onto card templates with Pillow and posted to the right channel.

Highlights

  • Registration that cannot be faked

    Ownership is proven with a submission on Codeforces itself, not a typed handle.

  • Contest calendar

    Codeforces, CodeChef, and AtCoder contests are announced up to a week ahead, with a reminder an hour before they start.

  • Survives rebuilds

    Data lives in a PostgreSQL volume and migrations run on start, so redeploying the bot loses nothing.

Tech stack

Bot
  • Python 3.12
  • discord.py
  • httpx
  • Pillow
Data
  • PostgreSQL
  • SQLAlchemy
  • Alembic
Infra
  • Docker Compose