I created a simple bot that responds to messages by adding or removing roles appropriately. It is adding roles, but not removing them. Here is the removal part (I just copied the add part, which is working correctly, and changed to remove role and added a check for the resign command:
if str(message.channel) == "private" and message.content.startswith('!resign'):
role = get(message.author.guild.roles, name="In Group")
await message.author.remove_roles(role)
return
