I have a dictionary initialized into a dataframe that has values inside a @client.command function for discord.py. I want to use this dataframe in the next function that I have written. I am unsure of how to do this.
>Solution :
suppose you have a command like this
@client.command()
async def test(ctx, arg)
await ctx.send("the variable is " + arg)
you can share it by using global variable
argument = ""
@client.command()
async def test(ctx, arg)
global argument
argument = arg
await ctx.send("the variable is " + arg)
@client.command()
async def anothertest(ctx)
global argument
await ctx.send("the previous arg is " + argument)