Comments (8)
@sunkaflek Yes You are right. I will look into changes on the master branch, and will do my best to make a patch release today with the fix.
from vies.
@sunkaflek i'm upgrading the code to support PHP 8.1. When this is done there will be a new 2.3.0 release - hopefully today
from vies.
It is probably the Vies::validateVatSum() method that return false negatives.
Either bypass DragonBe Vies for those numbers or just comment if (!$this->validateVatSum($countryCode, $vatNumber)) {.....} statement in the vendor ... Yes it's very ugly but this error is very annoying.
from vies.
@sunkaflek I can't reproduce this bug. What version of library are You using ?
<?php
require './vendor/autoload.php';
$vies = new \DragonBe\Vies\Vies();
$result = $vies->validateVat(
'NL',
'001439542B97',
'FR',
'45497709824'
);
Both VAT numbers pass checksum validation test and are valid in Vies.
print_r($result->toArray());
Response:
Array
(
[countryCode] => NL
[vatNumber] => 001439542B97
[requestDate] => 2021-12-21
[valid] => 1
[name] => HAMMINGA INSTALLATIESERVICE
[address] =>
WAGNERLAAN 00016
9603AT HOOGEZAND
[identifier] => WAPIAAAAX3cV7iHA
[nameMatch] =>
[companyTypeMatch] =>
[streetMatch] =>
[postcodeMatch] =>
[cityMatch] =>
)
returns true
from vies.
@krzaczek Ah ok, this seems to be the problem. I have now tested installing latest release using composer require dragonbe/vies (that installs 2.2.0). This version does have the bug I mentioned above.
But if I download the latest zipped code directly from github and use that way, the bug is gone. So I guess it has been fixed in some commit after 2.2.0 but has not been released as a new version yet?
In my opinion this is quite a serious bug, I'd say it's worth a release.
from vies.
@sunkaflek the only change I see is a fix for 32 bit architectures and this was done in a both NL and FR validator here. What platform are You having issues on ?
from vies.
@krzaczek It is 32bit PHP 7.4.4 so sounds like this could be it
from vies.
@sunkaflek sorry for the delay. This has been released in 2.3.0
from vies.
Related Issues (20)
- Validation of Irish VAT ID failed for valid VAT ID HOT 7
- Making VIES package more inclusive
- Missing BG checksum validation for foreign natual persons
- VIES_EU_COUNTRY_LIST Visibility HOT 1
- Package upgrade to composer 2.0
- Ensure this package can be installed with Composer 2.0
- Implementing a Symfony constraint based on this library HOT 2
- Remove support for the United Kingdom ("GB") HOT 16
- Add support for United Kingdom (Northern Ireland) ("GB-NIR") HOT 7
- Support php8
- 32 Bit Support HOT 1
- The service moved to SSL endpoint. HOT 1
- use of ::VIES_EXCLUDED_COUNTRY_CODES
- ValidatorLV results inconsistent with official EU validation
- heartbeat is not working anymore HOT 12
- Cannot populate CheckVatResponse after using `toArray`
- Optional Argument Validation Fails for ® HOT 2
- Heathbeat check always false HOT 1
- GetAddress non getting separated city, zip
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vies.