Bake off your pie shell and let cool. In a heavy saucepan, combine your egg yolks, sugar, salt, flour and cocoa powder and beat until smooth.
Slowly whisk or stir in the milk and cook over medium heat, stirring constantly until the mixture thickens about 8-10 minutes.
Reduce your heat to very low and cook until quite thick, 3 or 4 minutes more. Remove from the heat, add butter and stir until the butter melts. Stir in the vanilla.
Transfer to a bowl, cover with plastic wrap laid directly on the surface of the custard, and let stand until slightly cool, about 10 minutes. Preheat oven to 350. Pour the filling into your cooled pie shell and top with small mounds of meringue and bake until meringue is lightly browned, 10-15 minutes. Cool on rack. I like to serve this slightly warm or room temperature.