I had not pigtailed a neutral wire and attached it to the silver screw on the bottom outlet.
I had instructions with the outlet when I bought it but threw them away because I thought I had installed it correctly. Both did work but my wife discovered that when you turned on the disposal the lamp went out.
Now I undersand that the neutral sides of the outlet must be factory tabbed as well as the hot sides and I was probably breaking the neutral when I turned on the switch.
I had just never installed an outlet that had a switch on top and outlet below so I did not understand how they worked, I guess.