如何获取 discord.py 中用户的标签?

How to get tag of user in discord.py?

如果我有用户对象,我如何获取用户的标签?例如,如果我想打印类似 CircuitSacul#1111 的内容,我会使用类似

的内容
print(f"{owner.name}:#{owner.tag}")

但是,我收到“用户对象没有属性 'tag'”的错误。

这是user's discriminator:

@bot.command()
async def tag(ctx):
    await ctx.send(ctx.author.discriminator)