Closed Asa-Nisi-Masa closed 3 years ago
Hello friend, whats up?
Sorry, this time I cant accept your pull request.
ICAO specifications are clear:
4.2.2.1 Data structure of the upper machine readable line
[...]
Document Code Two characters, the first of which shall be A, C or I, shall be used to designate the particular type of document. The second character shall be as specified in Note k.
[...]
k) The first character shall be A, C or I. Historically these three characters were chosen for their ease of recognition in the OCR-B character set. The second character shall be at the discretion of the issuing State or organization except that V shall not be used, and C shall not be used after A except in the crew member certificate.
Therefore the Estonian case is outside the norm.
I can think of two possible solutions:
1.- If you use mrz.generator
you can set kwarg force=True
(there are a lot of similar cases)
force (bool): Disables checks for country, nationality and document_type fields.
Allows to use 3-letter-codes not included in the countries dictionary
and to use document_type codes without restrictions.
For mrz.checker there is still no solution
2.- Create a special case for Estonia that overrides document_type
property
Best regards
PS: reading strictly note k
there may be a case in which exists a document type"AC"
, so could be deleted and s != "AC"
of the line code:
and C shall not be used after A except in the crew member certificate.
Hello. I see, Estonian document does not comply with the standard. I will see what I can do about the special case.
Ok. As always.. thank you very much!
BR