I don’t know.
In order for this template to show the product
wc_get_template_part('content', 'product');
it needs to know what post is being shown. WC does this by looking at the global $post, and the code I’ve given you set up the post as the global post.