Skip to content
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

Unable to access the USPTO PBD system #5

Closed
mohamedasni opened this issue Oct 2, 2018 · 9 comments
Closed

Unable to access the USPTO PBD system #5

mohamedasni opened this issue Oct 2, 2018 · 9 comments

Comments

@mohamedasni
Copy link

screenshot from 2018-10-02 17-07-51

amotl added a commit that referenced this issue Oct 3, 2018
…ce Unavailable: Back-end server is at capacity, see #5
@amotl
Copy link
Member

amotl commented Oct 3, 2018

Dear Mohamed,

thanks for writing in and reporting this problem. We just released uspto-opendata-python 0.8.0 which improves the error handling at the place you referenced. The software will now raise a more appropriate exception when running into this error condition.

Unfortunately, when running e.g.

$ uspto-pbd get "2017/0293197" --type=publication --format=xml

the USPTO API currently responds with

503 Service Unavailable: Back-end server is at capacity

Bummer.

We hope this upstream issue will get fixed and we will be happy to hear about it. You might want to report the issue to them in the meanwhile to let them know there are actually people using the service.

With kind regards,
Andreas.


You can also observe the behavior by just requesting the base url:

$ http https://pairbulkdata.uspto.gov/

HTTP/1.1 503 Service Unavailable: Back-end server is at capacity
Connection: keep-alive
Content-Length: 0
Date: Wed, 03 Oct 2018 20:16:52 GMT
Via: 1.1 9f37c8b999ae2d6018396fda48773445.cloudfront.net (CloudFront)
X-Amz-Cf-Id: jo9nFTewqkX-fc5X8cPnXJKsyy6DdrFfumGapHBmYGIdIdc65eYrJg==
X-Cache: Error from cloudfront

@amotl
Copy link
Member

amotl commented Oct 4, 2018

As the API still responds with the same HTTP Status, i assume something is broken there. Can someone open a ticket at the USPTO?

@amotl
Copy link
Member

amotl commented Oct 4, 2018

Can someone open a ticket at the USPTO?

I just submitted an issue using their feedback form behind image on https://developer.uspto.gov/. Let's see whether there will be any answer.

@andyhegedus
Copy link

I am having similar issues. I have 0.8.0 version installed and trying the command line operation. Any tips on how to get this working?

uspto-pbd save "7654321" --type=patent --format=xml

2018-10-23 16:26:06,143 [uspto.util.client ] INFO : Querying for expression=patentNumber:(7654321), filter=[], sort=applId asc

Traceback (most recent call last):
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connection.py", line 141, in _new_conn
(self.host, self.port), self.timeout, **extra_kw)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/util/connection.py", line 83, in create_connection
raise err
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/util/connection.py", line 73, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 61] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 601, in urlopen
chunked=chunked)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 346, in _make_request
self._validate_conn(conn)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 850, in _validate_conn
conn.connect()
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connection.py", line 284, in connect
conn = self._new_conn()
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connection.py", line 150, in _new_conn
self, "Failed to establish a new connection: %s" % e)
urllib3.exceptions.NewConnectionError: <urllib3.connection.VerifiedHTTPSConnection object at 0x10e4bfd68>: Failed to establish a new connection: [Errno 61] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/requests/adapters.py", line 440, in send
timeout=timeout
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 639, in urlopen
_stacktrace=sys.exc_info()[2])
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/urllib3/util/retry.py", line 388, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='pairbulkdata.uspto.gov', port=443): Max retries exceeded with url: /api/queries (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x10e4bfd68>: Failed to establish a new connection: [Errno 61] Connection refused',))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/andreashegedus/anaconda3/bin/uspto-pbd", line 11, in
sys.exit(run())
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/pbd/command.py", line 78, in run
run_command(client, options)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/util/command.py", line 127, in run_command
result = acquire_single_document(client, options)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/util/command.py", line 156, in acquire_single_document
result = client.download_document(**query)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/util/client.py", line 250, in download_document
response = self.query_patent(query['number'])
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/util/client.py", line 277, in query_patent
return self.query(expression)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/uspto/util/client.py", line 59, in query
response = self.session.post(self.QUERY_URL, json=solr_query)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/requests/sessions.py", line 555, in post
return self.request('POST', url, data=data, json=json, **kwargs)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/Users/andreashegedus/anaconda3/lib/python3.6/site-packages/requests/adapters.py", line 508, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='pairbulkdata.uspto.gov', port=443): Max retries exceeded with url: /api/queries (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x10e4bfd68>: Failed to establish a new connection: [Errno 61] Connection refused',))

@amotl
Copy link
Member

amotl commented Oct 24, 2018

Dear Andy,

thanks for writing in. The exception you are getting makes sense as https://pairbulkdata.uspto.gov currently does not respond to any requests. According to Russ Allen of http://pairbulk.historicip.com/, the service has been decommissioned:

Note that the uspto shutdown https://pairbulkdata.uspto.gov/ use https://ped.uspto.gov/peds

Bummer! On top of that, i didn't receive any answer on reporting the issue to the USPTO. Maybe someone coming here knows something about the background of this and would be so kind to share any insights?

With kind regards,
Andreas.

@amotl
Copy link
Member

amotl commented Oct 24, 2018

Dear Mohamed (@mohamedasni) and Andy (@andyhegedus),

according to the recent observations, i just disabled the PBD subsystem and released version 0.8.2 of this package which will yield an appropriate error message when trying to use it and also reflects the decommissioning of the USPTO PBD system in its documentation.

Following the advice of Russ Allen, i checked whether the PEDS system still works. It does, so you might want to use the uspto-peds utility instead for acquiring respective data from the USPTO, e.g.

uspto-peds get "7654321" --type=patent --format=xml

Russ is also investigating the API, you might enjoy reading http://peds.historicip.com/.
Please let me know if you need further assistance. I will be happy to hear back from you.

With kind regards,
Andreas.

@andyhegedus
Copy link

andyhegedus commented Oct 24, 2018 via email

@amotl
Copy link
Member

amotl commented Oct 24, 2018

Dear Andy,

i believe the BDSS API is suitable for downloading gazettes only and not for acquiring information about individual patent applications or issued patents.

However, i am definitively looking forward to add further capabilities to the uspto-opendata-python package, for example to unlock access to these services:


[...] the PEDS database does not have the patent text I am interested in

Unfortunately no. May i point you to the Open Patent Services (OPS) offered by the European Patent Office? It offers an extensive API for accessing patent information from many offices. However, i don't know whether it also contains fulltext information from documents issued by the USPTO.

Cheers,
Andreas.

This was referenced Mar 11, 2019
@amotl amotl changed the title Unable to make any queries Unable to access USPTO PBD API Mar 13, 2019
@amotl amotl changed the title Unable to access USPTO PBD API Unable to access the USPTO PBD system Mar 13, 2019
@amotl
Copy link
Member

amotl commented Mar 13, 2019

The USPTO PBD system has been decommissioned, we are tracking the support for further data sources at #8.

Thanks again for your comments and your interest, @mohamedasni and @andyhegedus. I'm closing this now.

@amotl amotl closed this as completed Mar 13, 2019
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

No branches or pull requests

3 participants