HELP TRAVELING AND FAR FROM HOME

1996 Pontiac Transport • 6 cylinder FWD Automatic •

1996 pontinac montana transport 3400. Just had engine rebuilt today sometimes it starts and runs just fine others it starts, pops like a back fire shakes a little when I put it in gear it stalls so if I shut it off and on until it strarts normal it runs great why is it doing this?