You guys are doing fine not much I can add
Lean code means computers air/fuel mix calculations are off by more than 15%, so it notifies driver with a CEL(check engine light) and code P0171
After engine warms up computer has feed back from upstream O2 sensor
So it can see if its air/fuel ratio calculations are correct
O2 sensors see OXYGEN in the exhaust, not fuel
After engine burns the air/fuel mix the O2 will show oxygen level in exhaust, low oxygen is Rich, high oxygen is Lean
If oxygen is high the computer adds MORE fuel to the calculated mix, then see what O2 shows
If still too much oxygen its adds more fuel, ect.............until oxygen level is "just right", this takes about 1 to 2 seconds, so engine was never "running lean"
If computer have to add more than 15% more fuel to get O2 in correct range then Lean Code
If an engine misfires, then no oxygen was burned up with the fuel, so that oxygen is dumped into the exhaust, higher oxygen in exhaust
If exhaust manifold has a leak oxygen is sucked in, higher oxygen in exhaust
If fuel pressure is low, then less fuel is flowing in to engine when injectors open, so calculations are off
If there are air leaks between MAF sensor and intake valves then calculations will be off
Exhaust blockage can also cause lean codes
So not sure I would go right to valve guide seals after getting a lean code
The oil causes incomplete combustion so less oxygen is used, so higher oxygen in exhaust