I want tomake a command that basically takes an image that the user sent. I'm using the pillow library.
@bot.command(pass_context=True)
async def task(ctx):
userimg = attachment.url[0].url
print(userimg.size)
background = Image.open("task_failed.jpg")
print(background.size)
size = (640,2030)
background = background.resize(size,Image.ANTIALIAS)
background.paste(userimg, (0, 0), userimg)
background.save('memetask',"PNG")
How am I supposed to complete this?