gautamkrishnar / blog-post-workflow

Show your latest blog posts from any sources or StackOverflow activity or Youtube Videos on your GitHub profile/project readme automatically using the RSS feed
https://github.com/marketplace/actions/blog-post-workflow
GNU Affero General Public License v3.0
3.03k stars 271 forks source link

[Bug]: Unable to fetch RSS feed | Error with status code: 503 #179

Closed soumendrak closed 2 years ago

soumendrak commented 2 years ago

Describe the bug

Run gautamkrishnar/blog-post-workflow@master
  with:
    feed_list: https://blog.soumendrak.com/rss.xml
    gh_token: ***
    readme_path: ./README.md
    max_post_count: 5
    disable_sort: false
    filter_comments: medium,stackoverflow/Comment by $author/,stackexchange/Comment by $author/
    template: default
    date_format: UTC:ddd mmm dd yyyy h:MM TT
    user_agent: rss-parser
    accept_header: application/rss+xml
    commit_message: Updated with the latest blog posts
    committer_username: blog-post-bot
    committer_email: blog-post-bot@example.com
    output_only: false
    enable_keepalive: true
    retry_count: 0
    retry_wait_time: [1](https://github.com/soumendrak/soumendrak/actions/runs/3355743277/jobs/5560245386#step:3:1)
    disable_html_encoding: false
    categories_template: default
    disable_item_validation: false
Error: https://blog.soumendrak.com/rss.xml runner failed, please verify the configuration. Error:
Error: Error: Status code 50[3](https://github.com/soumendrak/soumendrak/actions/runs/3355743277/jobs/5560245386#step:3:3)

It was working perfectly till 25 September.

Expected behavior There should not be any errors and blog posts should be updated.

Screenshots image

Workflow Yml Used

# reference: https://iamdarshshah.hashnode.dev/how-to-add-your-recently-published-articles-to-your-github-profile-readme-using-github-actions
name: Latest blog post workflow
on:
 schedule: # Run workflow automatically
   # This will make it run every hour
   - cron: '0 * * * *' 
  # Run workflow manually (without waiting for the cron to be called), through the Github Actions Workflow page directly
 workflow_dispatch: 
jobs:
 update-readme-with-blog:
   name: Update this repo's README with latest blog posts
   runs-on: ubuntu-latest
   steps:
     - uses: actions/checkout@v2
     - uses: gautamkrishnar/blog-post-workflow@master
       with:
         # Replace this URL with your rss feed URL/s
         feed_list: "https://blog.soumendrak.com/rss.xml"

Additional context N/A

gautamkrishnar commented 2 years ago

@soumendrak as the message says this is a problem with your website itself, it is returning 503. There is nothing i can do to fix this. Since you are using Hashnode, please report it to their support. If you are using Cloudflare you may need to whitelist the GitHub IPs. Explaining how to do it is beyond the scope of this repo.

soumendrak commented 2 years ago

Thanks, @gautamkrishnar for the hint. For future visitors, I temporarily resolved this issue by disabling "Bot Fight Mode" and then running the GitHub Action manually. Path in Cloudflare: Security --> Bots --> Bot Fight Mode

gautamkrishnar commented 2 years ago

@soumendrak you can also whitelist the user agent rss-parser in Cloudflare and still keep the bot protection running. You can also add your own custom user agent via user_agent option of the workflow.

soumendrak commented 2 years ago

Thanks, @gautamkrishnar , unable to whitelist User-Agent to bypass bot fight mode. Maybe in Paid versions, the options are there. Thank you.

gautamkrishnar commented 2 years ago

@soumendrak it is possible, you can do it via a custom WAF rule:

Screenshot 2022-10-31 at 1 37 08 PM

Screenshot 2022-10-31 at 1 38 05 PM

Screenshot 2022-10-31 at 1 40 09 PM

soumendrak commented 2 years ago

@gautamkrishnar the last screenshot shows it does not prevent "Bot Fight Mode" (on your screenshot above too). image

I wonder how is it working for you. 🤔

gautamkrishnar commented 2 years ago

@soumendrak lol sorry my bad. I have the bot protection turned off. Then ya, turning it off is the only option.