There was a stinky brown liquid around input EMC filter and everithing was clear - capacitor in EMC filter goes to silicon heaven.
I think it is a very common failure that the old compact filtered power entry modules die on these power supplies. I had it happen on 3 of my devices. I have also seen the same happen in
this video. At this point I recommend just replacing these on sight (and labeling the new ones with when they were replaced). Note that the "FN282-6-06" modules can still be ordered, one example is
here, on TMEBut i have no idea what happened. Batteries have 4,02V so they are not shorted out. Why they went so hot ? Current limit was set to 4A and TP4056 for 1A.
I don't know why your batteries were hot, I don't think the PM281x can operate in current sink mode (according to the documentation only PM283x can sink current), and I just did a couple measurements with the power supply off, and I only see kilo-ohms resistance across the outputs, that wouldn't be enough to heat up the batteries.
I think the batteries being hot is most likely unrelated. Were the batteries of good quality, and internal resistance still low? Were the batteries hot and the TP4056 cold? Or could it have been the TP4056 hot? What voltage did you use to supply the TP4056? Remember that the TP4056 has to dissipate any voltage difference between the battery and its supply voltage. So while you can feed it 8V according to its datasheet, if your battery is at 4.02V, and you charge at 1A, it will have to dissipate (8V-4.02V)*1A=3.98W and that would be too much for the tiny SOP-8 package.
Have you fixed you PM2811? Did it accumulate any other faults, than the filtered power entry module exploding?