Question: why are stormtroopers so weak?
Answer: Stormtroopers are weak on purpose, because there are too many of them for palpatine to personally ensure his control over, so they can be countered as necessary by assets he did have personal control over.