Lets see if I can make sense of what I am thinking:
P0170 is the Fuel Trim Bank 1, ie. O2 sensor is not manageing the STFT- short term fuel trim, or LTFT- long term fuel trim.
The MAS is the primary sensor used in the calculation of the initial injection pulse width. When the sensor becomes open or shorted, the control module sets the code along with the operating conditions in which the fault occured. This would typically cause an intermintent hesitation upon acceleration.
Since this is not what is happening we look at what other sensors communicate with the ECM in conjunction with the MAS , which is the O2, the P0130 that is pending is... O2 sensor circuit problem bank 1 sensor 1, which makes perfect sense. Since the O2 manages fuel trim, and there is a code for fuel trim, what I think... is that the O2 had/has an intermintent short/open that effected STFT,LTFT that in turn set the code.
Diagnosis: Scope the O2 for function, check connections