arthurdejong / python-stdnum

A Python library to provide functions to handle, parse and validate standard numbers.
https://arthurdejong.org/python-stdnum/
GNU Lesser General Public License v2.1
495 stars 205 forks source link

Connection Missing with server #252

Closed jeffryjdelarosa closed 3 years ago

jeffryjdelarosa commented 3 years ago

@arthurdejong

https://github.com/arthurdejong/python-stdnum/blob/407a02f98c8c8dd911e040eb6f8a784a57f40af6/stdnum/do/rnc.py#L57

This server all the time has issue and losing connection, there's a new one is the link below

https://www.dgii.gov.do/app/WebApps/ConsultasWeb/consultas/rnc.aspx

This has two way to get by rnc and name.

I thinks this has a better result and connection.

arthurdejong commented 3 years ago

Hi @jeffryjdelarosa

The link directs to the same site so I would expect the timeout issues to be similar.

The biggest problem is that the link you provided is that it does not provide a usable API but would require parsing the returned HTML. That is generally very fragile and breaks every time a site changes some styling or layout. I have that kind of scraping for a few of the update scripts that are run on release and they require regular changes.

jeffryjdelarosa commented 3 years ago

Okey, Thanks.