Fix file filter and add more verbose logging.