Thorw exception if no context has been defined