Skip to content

Make member role application command a hybrid slash command#40

Merged
johnvictorfs merged 1 commit into
masterfrom
codex/add-hybrid-command-support-for-aplicar-and-ranks
Feb 8, 2026
Merged

Make member role application command a hybrid slash command#40
johnvictorfs merged 1 commit into
masterfrom
codex/add-hybrid-command-support-for-aplicar-and-ranks

Conversation

@johnvictorfs

Copy link
Copy Markdown
Owner

Motivation

  • Only the member-role apply flow should be exposed as the slash aplicar command while PvM apply flows (Raids/AoD) must remain prefix-only to avoid changing unrelated behaviors.
  • Preserve the ranks hybrid behavior and keep a helpful suggestion when invoked via prefix for a better UX.
  • Update tests and stubs so the authentication cog can be validated in isolation.

Description

  • Converted the member-role apply command to a hybrid command by changing the decorator to @commands.hybrid_command(name="aplicar", aliases=["role", "membro", "aplicar_role"]) in bot/cogs/authentication.py.
  • Reverted the raids apply command to a normal prefix command with @commands.command("raids", aliases=["aplicar_raids"]) in bot/cogs/chat.py so PvM apply commands remain unchanged.
  • Kept ranks as a hybrid command and preserved the prefix-tip by checking if getattr(ctx, "interaction", None) is None: await ctx.send("Dica: use o comando de barra /ranks ...") in bot/cogs/clan.py.
  • Extended tests/helpers.py with additional lightweight stubs and a make_authentication() helper, replaced the aplicar test to assert authentication.aplicar_role is a HybridCommand, and kept/added tests/test_ranks_command.py to validate ranks hybrid behavior and the prefix suggestion.

Testing

  • Ran the full test suite with pytest -q, which completed successfully with 5 passed.

Codex Task

@johnvictorfs johnvictorfs changed the title Limit hybrid aplicar to member-role flow and keep ranks behavior Make member role application command a hybrid slash command Feb 8, 2026
@johnvictorfs
johnvictorfs merged commit 49dec37 into master Feb 8, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant