Forbid using protocol module before app is ready, fixes #661