Place butter and sugar in the bowl of a mixer fitted with a paddle and beat until smooth and creamy. Add the eggs and vanilla, one at a time, beating well between additions. Scrape down side of bowl. Place flour, cocoa powder, baking soda, baking powder and salt in a separate bowl and mix well. Gradually add to the butter mixture and beat until everything is well incorporated. Scrape down the side of the bowl and beat again. Add nuts.