it would be complete luck.
you could go to a passport office and try to get a last minute appointment. you might be lucky and get a cancelation.
or you can try your luck with changing the booking and swapping to a later flight.
or you could try your luck with trying to go with the passport as it is.
whatever you do luck isn't really on your side.
I've been in this situation, last year, first work trip since covid, got through security, and only when boarding the plane did someone realise my colleagues passport expired in just over a month, she was refused boarding.
It was a few years ago now but similar happened to another colleague, but he got out of the uk fine, it was only when we were flying home it was flagged, fortunately they let him board anyway, but he was told he could be refused boarding.
I also know someone who last year realised a few days before leaving for their holiday that their youngest passport expired in 2020, there was no way they could get a new one so decided to just try it, they strategically held the passport to hide it, and kept it in the middle of the stack of 6 passports,
I tried to talk them out of it, it seemed so stupid, but they had borrowed the money for the holiday and couldn't afford to loose it, so they did it.
They got through Manchester airport fine, I was gobsmacked when they texted me from the plane, they got into Lanzarote fine too.
The problems came when they were due to come home, I'm not sure where it happened but someone spotted the date, they pretended they had no idea and that it was a complete mistake, they spent 9 hours in a little room, being questioned about it, they missed their flight and had to wait to see if they would be allowed to fly home, in the end they were allowed and were booked onto a later flight, but they had to pay for the rebooking I think.
They treated the whole thing as a win, but they didn't seem to consider that had they been refused they would have had to have traveled to the British consulate to apply for a temporary 'return home' passport, which trust me is a bloody nightmare, I've had to do it when my passport was stolen and I wouldn't wish it on my worst enemy.
Really I think it was incredibly stupid to even try.
You will probably just be refused at the airport though.