The Pentax K sensor to lens flange distance is 45.46mm.
The distance needed is 54.80mm.
You need to space an extra 9.34mm but you also have a t-ring in there too.
So, subtract the thickness of the t-ring from 9.34mm and that is the thickness of the spacer(s) you require. I thought most t-rings were at 9.8mm so, if so, you are already too long before adding spacers. If I remember correctly, Pentax K has a sensor to lens flange distance that is the largest of all of today's APS-C cameras and this may be the issue. You'll have to measure the thickness of your particular t-ring. Hopefully, it is thinner than 9.8mm and at around 9.3mm instead.
It is also possible that you are not square with the image plane. I didn't look at your image all that closely because I'm not on my desktop computer but it appeared that the problem was mostly on one side. That probably indicates that you are not square for one or more reasons. If the elongated stars are the same in all four corners, then you should be square. This, of course, isn't taking into account a not-so-great field flattener or even your scopes optics not be the same on both side. For instance, if the corners are different without the field flattener, how would the field flattener know which corners to apply more/less correction to? This could also be caused by an out-of-square focuser (which can be corrected in most cases).
Finding the exactly correct spacing is always a frustrating pain in the butt. I hope you figure this out.
Edited by PatrickVt, 25 July 2020 - 10:50 AM.