Skip to content

Crawlee—A web scraping and browser automation library for Node.js to build reliable crawlers. In JavaScript and TypeScript. Extract data for AI, LLMs, RAG, or GPTs. Download HTML, PDF, JPG, PNG, and other files from websites. Works with Puppeteer, Playwright, Cheerio, JSDOM, and raw HTTP. Both headful and headless mode. With proxy rotation.

ci: Retry NPM publishing attempts (#3231)

Jan Buchar0529e95cb0b1
diff --git a/.github/workflows/publish-to-npm.yml b/.github/workflows/publish-to-npm.yml
index a9373fa30..6badd8517 100644
--- a/.github/workflows/publish-to-npm.yml
+++ b/.github/workflows/publish-to-npm.yml
@@ -24,6 +24,10 @@ on:
type: string
default: 'prod'
+concurrency:
+ group: publish-to-npm
+ cancel-in-progress: false
+
permissions:
id-token: write # Required for OIDC
contents: write # Required to push updates
@@ -87,12 +91,22 @@ jobs:
- name: Publish to NPM (@latest)
if: inputs.dist-tag == 'prod'
- run: yarn publish:prod --yes --no-verify-access
+ uses: nick-fields/retry@v3
+ with:
+ timeout_minutes: 10
+ max_attempts: 5
+ retry_wait_seconds: 30
+ command: yarn publish:prod --yes --no-verify-access
env:
GH_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
- name: Publish to NPM (@next)
if: inputs.dist-tag == 'next'
- run: yarn publish:next --yes --no-verify-access
+ uses: nick-fields/retry@v3
+ with:
+ timeout_minutes: 10
+ max_attempts: 5
+ retry_wait_seconds: 30
+ command: yarn publish:next --yes --no-verify-access
env:
GH_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}