switching to spawn to avoid buffer issues