Add close to generic typeahead, fixes leaks in CI environments