fixes to cache key generation
merge