I understood the problem as soon as I read your post. Gone through this myself. 3 months I was offroading in the club with the same problem wondering what happened to my car. I am really angry for garages doing this deliberately to make us spend more money culminating in replacing a busted engine. We pay the bills given to us by them promptly. The mechanic keep charging us for replacing the knock sensor, the cam shaft sensors, the crank shaft sensor finally replacing the throttle body. When we reach this stage the engine head gaskets will be already busted. No codes will appear for the spark plug, instead all other codes will appear. We will never doubt a spark plug mismatch as we trusted the mechanic to have put the right ones for which we paid. The moment you realize u have been cheated u will feel so angry with the garage for making us fool. All this happens because the garages know the owner of the car lacks technical knowledge. They think its very smart to fool us like this. The clue to your problem was in your write up itself at the last paragraph. Instantly I knew what was the problem. When you don't put the manufacturer specified spark plugs with a different one having a different heat range the ignition starts to behave strange when the engine gets hot. I know the sequence of repairs the garage will suggest to get rid of the issue. You already replaced the knock sensor. Next they will say crank shaft & cam sensor.
Anyways it your good luck I noticed the write up and reached out to you immediately.
Enjoy your drive today and post the results. If at all any further damage has happened it will be the throttle body sensor as you may have used the throttle too much and probably heated up the motor rendering it weak. I hope you didn't reach to that stage as this spark plug change happened recently. In my case I had to replace the throttle body as I ran the car like this for 3 months and pushed the throttle excessively while offroading. Even if the throttle body motor has become weak don't worry. U get a used throttle body for 150 AED.