Skip to content

Add 2020 decade Albania TIN #402

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

Conversation

Dj0ulo
Copy link

@Dj0ulo Dj0ulo commented Mar 1, 2023

The first letter of Albania TIN corresponds to the decade it was issued. (Source: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf)

This commit adds 'M' to the regex in order to match TIN from this decade.

The first letter of Albania TIN corresponds to the decade it was issued.
(Source: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf)

This commit adds 'M' to the regex in order to match TIN from this decade.
Dj0ulo added a commit to odoo-dev/odoo that referenced this pull request Mar 1, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114006

Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
fw-bot pushed a commit to odoo-dev/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

X-original-commit: f0b6e4c
fw-bot pushed a commit to odoo-dev/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

X-original-commit: f0b6e4c
fw-bot pushed a commit to odoo-dev/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

X-original-commit: f0b6e4c
fw-bot pushed a commit to odoo-dev/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

X-original-commit: f0b6e4c
fw-bot pushed a commit to odoo-dev/odoo that referenced this pull request Mar 6, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

X-original-commit: f0b6e4c
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 7, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114488

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 7, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114479

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 7, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114454

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 7, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114438

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
robodoo pushed a commit to odoo/odoo that referenced this pull request Mar 7, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes #114463

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
StevenSermeus pushed a commit to acsone/odoo that referenced this pull request Mar 9, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes odoo#114463

X-original-commit: f0b6e4c
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
@arthurdejong
Copy link
Owner

Hi @Dj0ulo,

Thanks for pointing this out and providing the PR. I took this a little further and fixed it as a09a7ce. It turns out that the scope of the original implementation had some problems and the range we should accept is actually larger than the previous range implied.

jdoutreloux pushed a commit to acsone/odoo that referenced this pull request Jul 5, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes odoo#114006

Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
jdoutreloux pushed a commit to acsone/odoo that referenced this pull request Aug 10, 2023
__Description of the issue this PR addresses:__
The first character of a Tax ID from Albania is a letter representing the decade in which it has been issued. The letter M represents the current decade. (This pdf explains in details how it is formated: https://www.oecd.org/tax/automatic-exchange/crs-implementation-and-assistance/tax-identification-numbers/Albania-TIN.pdf).

Currently the way Albanian Tax IDs are validated is through the python library [`python-stdnum`](https://pypi.org/project/python-stdnum/).
However, the regex that is used to validate them has not been updated since 2017. (I made a PR in its repo arthurdejong/python-stdnum#402 to fix that).

The code from this commit is inspired by the one from that library, but the regex includes the letter M.

__Current behavior before PR:__
(`base_vat` must be installed)
By going to Settings > Users & Companies > [A company]:
- Set the country to Albania
- Set VAT/Tax ID to “M12345678T”.

=> Error message

closes odoo#114006

Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants