Here is work around ,
In stripe plugin file line no 597 on version 1.0.8 within catch exception block change following code
catch (Exception $e)
{
$body = $e->getJsonBody();
$error = $body['error']['message'];
$wc_order->add_order_note( __( 'Stripe Error.'.$error, 'woocommerce' ) );
wc_add_notice($error, $notice_type = 'error' );
}
to
catch (Exception $e)
{
$body = $e->getJsonBody();
$error = $body['error']['message'];
$wc_order->add_order_note( __( 'Stripe Error.'.$error, 'woocommerce' ) );
$error = apply_filters( 'woocommerce_stripe_woocommerce_addon_error', $body );
wc_add_notice($error, $notice_type = 'error' );
}
and in functions.php add following block of code
add_filter('woocommerce_stripe_woocommerce_addon_error','woocommerce_stripe_woocommerce_addon_error_overide',$error) ;
function woocommerce_stripe_woocommerce_addon_error_overide($body){
if($body['error']['type'] == 'invalid_request_error' ){
$error = 'Please make sure you have entered the credit card number';
}
if($body['error']['type'] == 'incorrect_number' ){
$error = 'The card number is incorrect.';
}
return $error ;
}
And you will get desired output like https://imgur.com/a/PEaCd