1

I'm using an App Engine Task Queue to query AlchemyAPI. I send a text string to the task queue. Each task queue worker queries the AlchemyAPI and processes the results.

After working for ~1500 results, I've started getting endless errors that look like:

InvalidURLError: Invalid request URL: http://access.alchemyapi.com/calls/text/TextGetRankedNamedEntities?outputMode=json&apikey=xxxx&text=myverylongtexthere

Why I'm confused is that if I copy/paste the URL that is supposedly invalid into my browser directly it works fine!

What could possibly cause this kind of error?

Jed Christiansen
  • 659
  • 10
  • 21

1 Answers1

2

I guess that your URL is more than 2048 characters because of myverylongtexthere.

google.appengine.api.urlfetch_errors.InvalidURLError
Raised when the URL given is empty or invalid.

Only http: and https: URLs are allowed. The maximum URL length
allowed is 2048 characters. The login/pass portion is not
allowed. In deployed applications, only ports 80 and 443 for http
and https respectively are allowed.
Dmytro Sadovnychyi
  • 6,171
  • 5
  • 33
  • 60