Sounds like you had an air pocket in the block. When refilling the coolant system, you should make several checks after start up if you lost a lot of coolant when you removed the engine block plug to install the block heater.
When the block heater, warmed up the coolant, the air pocket expanded and became pressurized. Hence the coolant that vented when you opened the cap. Sounds like you have things good to go now.