update cache version right after clearing it
check cache version before attempting cd