✊🏿 Black Lives Matter. Please consider donating to Black Girls Code today.
🐇 Announcing Dash VTK for 3d simulation graphics. Check out the March webinar.

Can't change value of an argument

Dear Dash community,

I’m using the option to put inputs and states into *args. Working with pandas DataFrame works quite good but I can’t write a simple value to one of the args.

INPUTS = [Input(some inputs), ...]
INPUTS.extend([Input(more inputs)])
STATES = [State('xy', 'value')]
STATES.extend([State(more States)])

    [Output('xy', 'value'), more outputs...],
def test(*args)

    convert and write something to args[0], e.g.
    xx = args[0]
    xy = xx
    if xy == '' or xy is None or xy == []:
        xy = 0
        xy = xy + 1

    return something, ..., xy

    [Output(outputs), ...],
    [Inputs(inputs), ... ]
    [States('xy', 'value'), ...]
def printing(some inputs, xy_after, some states)

So, here is my problem. Getting args[0], assigning a value and returning it works since I see the value 0 here

def printing(inputs, xy_after, more states)

But when I call def test(*args) again and get args[0] it is an empty tuple again and I see value 0 over and over again. The type of xy is everywhere an int. Do you have any advice for me?

Thanks in advance!