How to play action actuator logic brick via python
You can use python to activate the Action actuator with this script. You will need three logic bricks: A sensor (to trigger it all), the python controller, and the action actuator.


cont = bge.logic.getCurrentController()

act = cont.actuators["Action"] # the name of the Action actuator

if cont.sensors["Keyboard"].positive: # trigger when buton pressed

    #Set all the properties you want
    act.action = "CubeAction"
    act.frameStart = 1
    act.frameEnd = 30
    act.priority = 0

    cont.activate(act) # start the actuator


You can set as many or as few of the settings that you need with python or in the logic brick, however the python will overrule any duplicate settings. Here is a list of all the settings for the Action actuator.
Do note the the two minimum setting you need are the action name, and frame end.