I am attempting to strip an incoming message of all punctuation in order to run an accurate moderation system. However, when I use string.strip(), it only pulls off the ending character of the string, and leaves the rest of the same character in the remainder of the string. What am I misunderstanding? Every resource I can find says that string.strip() is sufficient.
Relevant code:
async def on_message(message):
stripString = ".!?,'@#$%^&*()"
if message.author == bot.user:
return
message.content = message.content.strip(variables.stripString)
input: This. Is. A. Test.
output: This. Is. A. Test