eval - How to pass a 'BeautifulSoup.Tag' object inside http post request in google app engine? -
i have beautifulsoup.tag
object want transfer in http post request. request task in google app engine perform.
this code:
taskqueue.add(url='/maintenance', method='post', params={'row': row})
when receive request on other end, parameter row unicode string. how original object back? undersand json eval won't work kind of object, there solution compelled pass simple objects only?
hmmm. beautiful soup kind of evaluator. can send object's html , reuse beautiful soup.
i did way:
taskqueue.add(url='/maintenance', params={'element': str(myobject)})
and reused soup inside task itself:
payload = self.request.get('element')
soup = beautifulsoup(payload)
Comments
Post a Comment