Setting pricing attribute fields programmatically
I am importing a very large selection of products with option sets into Drupal 7. The import works fine with all custom fields, builds the option sets with prices added, and creates commerce_pricing_attribute fields on the content types. What I'm running into is that I can't seem to programmatically select the option sets on the products, if I add a commerce_attribute_pricing field the product has "none" selected once the import is completed.
I've tried adding "set_id" to match the appropriate option set, but as I look through the module code it seems that everything uses the form api, so I'm concerned the only way I'll be able to do this is to run the products submit handlers programmatically which I would very much like to avoid.