Welcome to the Pentax Forums!
Originally posted by JT322 when I use an aperture between f/8 - f/22 I get two small black spots in my images, everything from f/1.4 - f/8 is perfect
What you describe is typical for dust or similar on the sensor. Does your camera have a dust detection feature? If so, what does it report? For peace of mind, you might want to physically inspect your lens for dirt using a small flashlight in a dim room. Shine the light at an oblique angle into the front of the lens while looking through the lens from the rear. Repeat from the other direction. Any dust, dirt, fungus, or scratches should be readily visible.
Steve