keyboard input problem with python

hey everyone, so when I do this in UPBGE:

import bge


cont = bge.logic.getCurrentController()
own = cont.owner


keyboard = bge.logic.keyboard
ACTIVE = bge.logic.KX_INPUT_ACTIVE


w = keyboard.events[bge.events.WKEY] == ACTIVE


if w:
    own.applyMovement((0, .1, 0), True)

I get a warning saying keyboard.events is deprecated please use keyboard.inputs instead. so I did this:

w = keyboard.inputs[bge.events.WKEY] == ACTIVE


if w:
    own.applyMovement((0, .1, 0), True)

and I don’t get any Warning, but nothing happens, it does not move.

any help would be greatly appreciated

If I remember correctly you have to do
w = keyboard.inputs[bge.events.WKEY][0] == ACTIVE

that gives the error: ‘SCA_InputEvent’ object is not subscriptable

Almost XD
After checking the API: https://pythonapi.upbge.org/bge.types.SCA_InputEvent.html#bge.types.SCA_InputEvent

It should be w = keyboard.inputs[bge.events.WKEY].status[0] == ACTIVE

that works thanks!