Skip to content

Single backslash rstripped in input #54

@YumYummity

Description

@YumYummity

Describe the bug
A single backslash can be placed at the end of an integer.
EG. -slots 200000\ results in the same thing as -slots 200000

To Reproduce

# using guilded.ext.commands.Bot
@bot.command(name='slots')
async def testcode(ctx, amount:int):
    await ctx.reply(str(amount), private=ctx.message.private)

Afterwards, just run -slots 200000\

Expected behavior
Raise an error: Converting to "int" failed for parameter "amount".

Actual behavior
Command runs as if the backslash isn't there.

Screenshots
image

Environment

  • OS: Windows 10 Microsoft Windows [Version 10.0.19044.2728] (testing) and Ubuntu 22.04.1 LTS x86-64 VM (hosting)
  • Python version (make sure you're using >=3.8): 3.10.6
  • Library version: 1.7.0 (March 4 release on PyPi.org)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions