Actual wait it isn't. We would still get a null pointer exception in the case of lookup rather than a helpful error message since lookup peeks at the partitioner before doing anything with the sparkcontext.