Report this

What is the reason for this report?

RSS with Nodejs problem

Posted on January 19, 2022

I recently added a nodejs project to my droplet. I installed all the necessary modules. It should do one simple thing for now; watch a RSS feed. Though it is not working. It works on my local machine just fine but not when I deploy it to the DO droplet.

Error: Bad status code
at Request.<anonymous> (/root/node_modules/parse-rss/lib/parse-rss.js:31:37)
at Request.onRequestResponse (/root/node_modules/request/request.js:1059:10

The error comes from parse-rss module, which is a requirement for feed-watcher module. It basically can not connect to any RSS feed. Could there be something on the droplet blocking it from connecting to a RSS?



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi there,

I recently had a similar problem with an RSS feed parser written in PHP.

The problem was that the RSS feed I was connecting to was returning 403 forbidden status.

My fix was to pass a user agent in the request so that I would not get a 403 forbidden.

Feel free to share the code snippet that you are using and I could try and advise you on how to patch it.

Best,

Bobby

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.