Make the Cake: Preheat the oven to 350°F. Grease and flour two 9-inch cake pans, and line them with parchment paper circles.
Place the stout and butter in a large, heavy saucepan, and heat until the butter melts. Remove the pan from the heat, and add the cocoa powder. Whisk until the mixture is smooth. Set aside to cool to room temperature.
Whisk together the flour, sugar, baking powder, and salt in a large bowl; set aside.
In a large mixing bowl, beat together the eggs and sour cream. Add the stout-cocoa mixture, mixing to combine. Add the flour mixture and mix together at slow speed. Scrape the sides and bottom of the bowl, and mix again for 1 minute.
Divide the batter equally among the prepared pans. Bake the layers for 35 minutes, until a cake tester inserted into the center comes out clean. Remove the cakes from the oven and cool on a rack for 10 minutes before turning the cakes out of their pans and returning to the rack to finish cooling completely before frosting.
Make the Frosting: In a mixing bowl, beat the butter on medium-high speed until super light and fluffy, 3 to 5 minutes, scraping the sides and bottom of the bowl as needed. Reduce the speed to medium-low and gradually add the powdered sugar, then the Baileys Irish cream and salt until combined. Increase the speed to medium and beat for an additional 3 minutes, until light and fluffy. If the frosting feels too stiff to spread, beat in 1 tablespoon of cream at a time; if it feels too soft, beat in extra powdered sugar, 1 tablespoon at a time.
Assemble the Cake: Place one of the cake layers on a serving platter or cake stand and spread 1½ cups of the frosting over the top in an even layer. Place the second cake layer on top of the frosting upside-down, then frost the top and sides of the cake and decorate as desired.
Storing: Keep this cake stored in an airtight container at cool room temperature or in the refrigerator for 4 days.
Freezing Instructions: The cake layers can be baked, cooled, wrapped in plastic wrap, and placed into a freezer zip-top resealable bag, and frozen for up to 3 months before thawing in the refrigerator overnight and proceeding with the frosting. You can wrap the entire cake in plastic wrap, then in aluminum foil, and freeze for up to 1 month. Thaw in the refrigerator before serving.
Make-Ahead: For the best taste, you can make the cake up to 2 days in advance and keep it in an airtight container in a cool place. Or freeze the layers and thaw overnight in the refrigerator. Frost before serving.