build but exception thrown when passing data from module to algorithm