Yes for short trips, but extended lean operation can damage internal engine parts.
What P0171 Means
P0171 means the computer is adding extra fuel to compensate for what it sees as a lean condition on engine bank 1. The root cause is almost always unmetered air entering the engine, a fuel delivery problem, or a faulty sensor.