without the model Im not sure but these machines have a water tray underneeth and it could be detecting water there and the float could be stuck telling the machine it still needs to drain...
check for leaks underneath make sure the flood tray is dry
and check the float in the dish washer make sure no food is lodged under it
keeping it from going all the way down
this is general to most diswashers