Somewhat scary fix for dependency caching problems