refactor: tests and recover from bad issue cache