-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Closed
Labels
Description
Feature Request
Output of python -c "import pydantic.utils; print(pydantic.utils.version_info())":
pydantic version: 1.5
pydantic compiled: True
install path: /Users/<hidden>/.pyenv/versions/3.7.2/envs/common-utils/lib/python3.7/site-packages/pydantic
python version: 3.7.2 (default, Jan 22 2020, 18:22:02) [Clang 10.0.1 (clang-1001.0.46.4)]
platform: Darwin-18.7.0-x86_64-i386-64bit
optional deps. installed: ['typing-extensions']
Currently PaymentCardNumber type does support 16-digits VISA only:
However as described on wiki page https://en.wikipedia.org/wiki/Payment_card_number:
While the vast majority of Visa's account ranges describe 16 digit card numbers there are still a few account ranges (forty as of 11 December 2013) dedicated to 13 digit PANs and several (439 as of 11 Dec. 2013) account ranges where the issuer can mix 13 and 16 digit card numbers. Visa's VPay brand can specify PAN lengths from 13 to 19 digits and so card numbers of more than 16 digits are now being seen.
This fact is handler properly in faker library:
But not handled in pydantic.
sudoguy