check required options.Fixes #44