# Allowing tax identifier non validated by python-stdnum

**URL:** <https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590>\
**Category:** Ideas\
**Created:** [October 10, 2022, 7:33am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590 "2022-10-10T07:33:47Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 7:33am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/1 "2022-10-10T07:33:48Z")

</div>

One of our customers is selling goods to IRAN. He has the IRANI fiscal number but this is not available as Tryton tax identifier (neither it is available on python-stdnum).

Altought this can be entered as other type on the party form, this has the drawback that the tax identifier is not automatically selected when issuing the invoice so the user needs to manually check that the field is filled before posting the invoice, causing some problems as they sometimes forget about it.

I’m wondering if it will be a good idea to have a “Other tax identifier” selection option in the types of identifiers which is not validated by python-stdnum but is considered a tax identifier.

Tougths?

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [October 10, 2022, 7:43am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/2 "2022-10-10T07:43:19Z")

</div>

I do not see the point. You can add any extra type on identifier (as long as it does not contain `_` it will not be tested with python-stdnum). And you can add this identifier to the tax identifier types list.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 7:46am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/3 "2022-10-10T07:46:33Z")

</div>

Well the point is basically that:

- A developer (like me) can add the extra type on the identifier without any issue
- But a user can not add the type by himself.

So having a extra type will allow the user to add the tax identifier by himself without requesting developer help.

P.S: Is also a little bit anoying to add the tax identifier one by one each time the company is issuing a new invoice to a diferent country.

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [October 10, 2022, 8:03am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/4 "2022-10-10T08:03:13Z")

</div>

> [@pokoli](#):
>
> So having a extra type will allow the user to add the tax identifier by himself without requesting developer help.

But it will not help python-stdnum to grow.

> [@pokoli](#):
>
> P.S: Is also a little bit anoying to add the tax identifier one by one each time the company is issuing a new invoice to a diferent country.

Just add all of them.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 8:26am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/5 "2022-10-10T08:26:03Z")

</div>

> [@ced](#):
>
> Just add all of them.

Then why not adding all of them in Tryton?

> [@ced](#):
>
> But it will not help python-stdnum to grow.

Of course, the library will grow just when somebody wants to validate the identifier of such country.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 9:03am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/6 "2022-10-10T09:03:53Z")

</div>

I’ve digging a little bit and I just found that there is [VATIN](https://en.wikipedia.org/wiki/VAT_identification_number) which is supported by [python-stdnum](https://github.com/arthurdejong/python-stdnum/blob/master/stdnum/vatin.py) which may be a good addition to Tryton.

However, that does not fix the case of _Iran_. I also found that _United Arab Emirates_ and _Saudi Arabia_ are also missing.

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [October 10, 2022, 9:08am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/7 "2022-10-10T09:08:46Z")

</div>

> [@pokoli](#):
>
> I’ve digging a little bit and I just found that there is [VATIN](https://en.wikipedia.org/wiki/VAT_identification_number) which is supported by [python-stdnum](https://github.com/arthurdejong/python-stdnum/blob/master/stdnum/vatin.py) which may be a good addition to Tryton.

Indeed it is a new feature.

> [@pokoli](#):
>
> However, that does not fix the case of _Iran_. I also found that _United Arab Emirates_ and _Saudi Arabia_ are also missing.

Better to add them to python-stdnum, for me it is a small cost for those countries to use Tryton.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 9:13am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/8 "2022-10-10T09:13:58Z")

</div>

> [@ced](#):
>
> for me it is a small cost for those countries to use Tryton.

The main point is not for such countries to use Tryton but for companies currently using Tryton that are selling goods/services to such countries.

So in such case, we need to wait for a new python-stdnum release and then wait for a Tryton relase which is a minimum of 6 month timeframe just for issuing an invoice.

---

<div class="post-metadata">

**Author:** ![pokoli](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/pokoli/32/22_2.png) [@pokoli](https://discuss.tryton.org/u/pokoli)\
**Post date:** [October 10, 2022, 9:16am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/9 "2022-10-10T09:16:26Z")

</div>

> [@ced](#):
>
> > [@pokoli](#):
> >
> > I’ve digging a little bit and I just found that there is [VATIN](https://en.wikipedia.org/wiki/VAT_identification_number) which is supported by [python-stdnum](https://github.com/arthurdejong/python-stdnum/blob/master/stdnum/vatin.py) which may be a good addition to Tryton.
> 
> Indeed it is a new feature.

I’ve filled [Add VATIN tax identifier (#11784) · Issues · Tryton / Tryton · GitLab](https://bugs.tryton.org/issue11784) to implement such feature.

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [October 10, 2022, 9:24am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/10 "2022-10-10T09:24:22Z")

</div>

> [@pokoli](#):
>
> The main point is not for such countries to use Tryton but for companies currently using Tryton that are selling goods/services to such countries.

That the same.

> [@pokoli](#):
>
> So in such case, we need to wait for a new python-stdnum release and then wait for a Tryton relase which is a minimum of 6 month timeframe just for issuing an invoice.

Well the tax identifier is not very important when doing international trading because there is no taxes to deduce.  
Also user can fill the number in the description for example and if they want to be rid of this they will just add it to python-stdnum.

Globally I dislike the idea of adding a carryall tax identifier because it will be misused (for example to skip validation).

---

<div class="post-metadata">

**Author:** ![ced](https://discuss-cdn.tryton.org/user_avatar/discuss.tryton.org/ced/32/1237_2.png) [@ced](https://discuss.tryton.org/u/ced)\
**Post date:** [October 10, 2022, 9:57am UTC](https://discuss.tryton.org/t/allowing-tax-identifier-non-validated-by-python-stdnum/5590/11 "2022-10-10T09:57:29Z")

</div>

> [@ced](#):
>
> Globally I dislike the idea of adding a carryall tax identifier because it will be misused (for example to skip validation).

Maybe if we make filling such non-validated tax identifier hard enough it will not be misused. For example we could raise a warning when created or modified. Also we could check that it is not a valid VATIN and so we reject it.
