WooCommerce breadcrumb display custom posts instead of product data

The solution is quite simple. I copied single-product.php from woocommerce/templates and modified it so loop starts before before_main_content hook:

get_header( 'shop' ); ?>
    <?php while ( have_posts() ) : the_post(); ?>
    <?php   
        /**
        * woocommerce_before_main_content hook.
        *
         * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
         * @hooked woocommerce_breadcrumb - 20
         */
        do_action( 'woocommerce_before_main_content' );
    ?>

That way it works fine, all functionalities are maintained.

error code: 523