The problem with the ClassicCommerce implementation is that if you have implemented your own product (as a subclass of WC_Product) with its own datastore (as a subclass of WC_Product_Data_Store_CPT) wc_update_product_stock() will not call the update_product_stock() of your datastore.
https://github.com/ClassicPress-plugins/classic-commerce/blob/10650f8347d4307b8b02ccdc76195e544cb50e51/includes/wc-stock-functions.php#L36
I think that line should be:
$data_store = WC_Data_Store::load( 'product-' . $product->get_type() );
The problem with the ClassicCommerce implementation is that if you have implemented your own product (as a subclass of WC_Product) with its own datastore (as a subclass of WC_Product_Data_Store_CPT) wc_update_product_stock() will not call the update_product_stock() of your datastore.