- What exactly does this error mean? Is it related to StoreKit 1 parsing or a misconfigured product?
missingValue(for: [StoreKit.ProductResponse.Key.price], expected: StoreKit.BackingValue)
"BackingValue" is a relatively new concept in StoreKit 2 per these wwdc notes (see Products & Purchases). I run into this issue when I have a local StoreKit configuration file while running on a physical device. If I change the identifier I provide to a bogus one, then I simply don't get any errors and my identifiers are considered "invalid". The fact that I only get this error when providing a legitimate identifier is a clue that it's kind of working (e.g. sees the product, but can't read it). Of course, with a local Storekit configuration, switching to a simulator without any other code changes works correctly.
So I have to switch to sandbox (i.e. change "StoreKit Configuration" under "Options" of the "Scheme" to "None") to get proper testing on a physical device.
How can I confirm if my project is actually using StoreKit 1 or StoreKit 2?
If you're using deprecated methods/classes, like SKProductsRequest, then you are using StoreKit 1.
To migrate fully to StoreKit 2 in Xcode 16.4, do I need any special setup beyond importing StoreKit and using Product.products(for:)?
No, although I live in an Objective C world and have not yet been able to bridge in StoreKit 2.
RevenueCat has a wonderful, step-by-step tutorial for getting started with StoreKit 2 and provides a sample app with multiple project "steps" to walk you through it. It's a good way to jump in and figure out the ropes of configuring a project to work with StoreKit 2 and might shine a light on any missteps you've had in your own project. Here it is: https://www.revenuecat.com/blog/engineering/ios-in-app-subscription-tutorial-with-storekit-2-and-swift/
Why would the .storekit file (both GUI and JSON edits) sometimes remove the error, but still not show products?
There's a lot of potential reasons. I mentioned one above when changing between legitimate and bogus product identifiers and getting different results. Unfortunately, we don't get a lot of feedback to inform us so we end up going through a lot of trial and error, and, due to the nature of sandbox testing and delays, patience!
Summary
My recommendation to get started:
Experiment with the RevenueCat tutorial I linked above when first starting. Start with a fresh project!
Get local Storekit testing working on a simulator.
Work towards Sandbox testing on a physical device. You'll have to setup Banking info, Taxes, Localizations on App Store Connect. And if you have different bundle ID's per environment, like I do, you'll need to do several steps per bundle id! And then wait a while before those changes work!
Good luck!