pipe2py icon indicating copy to clipboard operation
pipe2py copied to clipboard

Problem with xpathfetchpage

Open Saboti opened this issue 10 years ago • 6 comments

Hello,

I Have a Problem with the pipeurlbuilder and pipexpathfetchpage Module.

I Use my following Pipe which gets converted without errors: http://pipes.yahoo.com/pipes/pipe.info?_id=9ac44b79ddd8b30ae42a1a9e31cb6e03

But If I run the Python Script it throws me an error:

Season and Episode (default=Game of Thrones S04E07) Seriennamen (default=Game of Thrones S04E07) Traceback (most recent call last): File "pipe_9ac44b79ddd8b30ae42a1a9e31cb6e03.py", line 32, in for i in p: File "/usr/local/lib/python2.7/dist-packages/pipe2py/modules/pipeoutput.py", line 18, in pipe_output for item in _INPUT: File "/usr/local/lib/python2.7/dist-packages/pipe2py/modules/pipecreaterss.py", line 45, in pipe_createrss for item in _INPUT: File "/usr/local/lib/python2.7/dist-packages/pipe2py/modules/piperegex.py", line 40, in pipe_regex for item in _INPUT: File "/usr/local/lib/python2.7/dist-packages/pipe2py/modules/pipefilter.py", line 39, in pipe_filter for item in _INPUT: File "/usr/local/lib/python2.7/dist-packages/pipe2py/modules/pipexpathfetchpage.py", line 39, in pipe_xpathfetchpage request = urllib2.build_opener().open(request) File "/usr/lib/python2.7/urllib2.py", line 410, in open response = meth(req, response) File "/usr/lib/python2.7/urllib2.py", line 523, in http_response 'http', request, response, code, msg, hdrs) File "/usr/lib/python2.7/urllib2.py", line 448, in error return self._call_chain(_args) File "/usr/lib/python2.7/urllib2.py", line 382, in _call_chain result = func(_args) File "/usr/lib/python2.7/urllib2.py", line 531, in http_error_default raise HTTPError(req.get_full_url(), code, msg, hdrs, fp) urllib2.HTTPError: HTTP Error 404: Not Found

In the Pipe i Use a Regex to change Spaces from a User input to "-". Seems like this is not working correctly. I changed the Pipe by Hand to get the pipeurlbuilder output and it showed me %20 in the URL instead of %2D according to this Website: http://www.w3schools.com/tags/ref_urlencode.asp

Hope you understand my Problem and Someone can help me !

Greetings Saboti

Saboti avatar Sep 05 '14 11:09 Saboti

I just made a bunch of updates, can you check and see if the issue is still there?

reubano avatar Nov 09 '14 11:11 reubano

Hi and thank you, now I get an error if i convert the Pipe:

Traceback (most recent call last): File "pipe2py/compile.py", line 379, in pipe = '%2Fpipes%2Fpipe.info%3F_out=json%26_id=%s' % options.pipeid TypeError: a float is required

Regards Saboti

Saboti avatar Nov 11 '14 13:11 Saboti

I'm running into the same error Saboti hit on Nov 11, when attempting to run compile.py:

python pipe2py/compile.py -p 9bd04bf4ff4c064f3287401418248c95
Traceback (most recent call last):
  File "pipe2py/compile.py", line 379, in <module>
    pipe = '%2Fpipes%2Fpipe.info%3F_out=json%26_id=%s' % options.pipeid
TypeError: a float is required

Any thoughts?

Thanks!

alexj avatar Feb 18 '15 00:02 alexj

Unfortunately i havent used that module yet so not exactly sure how it works. Does that id work on yahoo?

reubano avatar Feb 18 '15 03:02 reubano

Thanks for the quick reply. Yes, that's a valid ID for a published pipe. I tried a couple of others and hit the same issue.

alexj avatar Feb 18 '15 16:02 alexj

Sorry for the late reply... I know yahoo pipes has since shut down, but if you saved the json you can try converting again. The last update in this repo is Nov 2015 so the issue may have been fixed. You can also try out my new repo. While it won't convert yahoo pipes for you, it does allow to recreate your yahoo pipe using pure python.

reubano avatar Aug 05 '16 14:08 reubano