title: How to identify the type of an variable?
body: <p>I'm creating an clear command for discord, I'd like to make it so whenever you put an string instead of an int, it sends an message in the chat "Please use numbers."</p>
  
  <p>I have tried <code>if isinstance(amount, int):</code> But that dose not seem to work.</p>
  
  <p><strong>Script V</strong></p>
  
  <pre class="lang-py prettyprint-override"><code>@client.command()
  async def clear(ctx, amount=1):
      role = discord.utils.get(ctx.guild.roles, name="[+] Admin")
      if role in ctx.author.roles:
          if isinstance(amount, int):
              print('int')
          else:
              print('str')
  
      else:
          await ctx.send(f'You lack the permissions.', delete_after=3)```
  
  &gt; It can identiy if it is an int value
  
  ``` Bot is ready. int```
  
  &gt; But not strings.
  
  ```Bot is ready.
  Ignoring exception in command clear:
  Traceback (most recent call last):
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 367, in _actual_conversion
      return converter(argument)
  ValueError: invalid literal for int() with base 10: 'Hello'
  
  The above exception was the direct cause of the following exception:
  
  Traceback (most recent call last):
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\bot.py", line 859, in invoke
      await ctx.command.invoke(ctx)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 718, in invoke
      await self.prepare(ctx)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 682, in prepare
      await self._parse_arguments(ctx)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 596, in _parse_arguments
      transformed = await self.transform(ctx, param)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 452, in transform
      return await self.do_conversion(ctx, converter, argument, param)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 405, in do_conversion
      return await self._actual_conversion(ctx, converter, argument, param)
    File "C:\Users\User\AppData\Local\Programs\Python\Python36\lib\site-packages\discord\ext\commands\core.py", line 376, in _actual_conversion
      raise BadArgument('Converting to "{}" failed for parameter "{}".'.format(name, param.name)) from exc
  discord.ext.commands.errors.BadArgument: Converting to "int" failed for parameter "amount".
  </code></pre>