changed from close to remove on the sqlalchemy session