Declaring a new woo commerce product type i get this error

According to the class definition the constructor expects to receive either a product ID (integer) or a product instance (object). This leads me to believe WooCommerce expects the product to already exist.

https://docs.woothemes.com/wc-apidocs/class-WC_Product.html

Despite expecting an integer or object it appears that you can still create a new instance by simply passing null.

<?php $pjb = new WC_Product_PJB(null); ?>

Obviously you’d have to have a very specific reason to pursue that approach as it clearly deviates from the documented behavior.