[PR #5422] [core]: Improve GitHub release fetch robustness with split timeouts and retry logic #5788

Closed
opened 2025-11-20 07:07:36 -05:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/community-scripts/ProxmoxVE/pull/5422

State: closed
Merged: Yes


✍️ Description

This PR improves the robustness of the fetch_and_deploy_gh_release function by:

  • Splitting curl timeout handling:
    • API fetch now uses --connect-timeout 5 --max-time 30
    • Asset downloads use --connect-timeout 15 --max-time 900
  • Adding retry logic for GitHub API metadata fetch (3 attempts with 2s delay)
  • Preventing unnecessary download aborts for large prebuilds (e.g. Immich tarballs >150MB)
  • No functional changes to the function signature or behavior

These improvements make the function more resilient in environments with slow or unstable networks.

#5387

Prerequisites (X in brackets)

  • Self-review completed – Code follows project standards.
  • Tested thoroughly – Changes work as expected.
  • No security risks – No hardcoded secrets, unnecessary privilege escalations, or permission issues.

🛠️ Type of Change (X in brackets)

  • 🐞 Bug fix
  • New feature (non-breaking robustness enhancement)
  • 💥 Breaking change
  • 🆕 New script
  • 🌍 Website update
  • 🔧 Refactoring / Code Cleanup
**Original Pull Request:** https://github.com/community-scripts/ProxmoxVE/pull/5422 **State:** closed **Merged:** Yes --- ## ✍️ Description This PR improves the robustness of the `fetch_and_deploy_gh_release` function by: - Splitting `curl` timeout handling: - API fetch now uses `--connect-timeout 5 --max-time 30` - Asset downloads use `--connect-timeout 15 --max-time 900` - Adding retry logic for GitHub API metadata fetch (3 attempts with 2s delay) - Preventing unnecessary download aborts for large prebuilds (e.g. Immich tarballs >150MB) - No functional changes to the function signature or behavior These improvements make the function more resilient in environments with slow or unstable networks. ## 🔗 Related PR / Issue #5387 ## ✅ Prerequisites (**X** in brackets) - [x] **Self-review completed** – Code follows project standards. - [x] **Tested thoroughly** – Changes work as expected. - [x] **No security risks** – No hardcoded secrets, unnecessary privilege escalations, or permission issues. --- ## 🛠️ Type of Change (**X** in brackets) - [ ] 🐞 **Bug fix** - [x] ✨ **New feature** (non-breaking robustness enhancement) - [ ] 💥 **Breaking change** - [ ] 🆕 **New script** - [ ] 🌍 **Website update** - [ ] 🔧 **Refactoring / Code Cleanup**
saavagebueno added the pull-request label 2025-11-20 07:07:36 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SVI/ProxmoxVE#5788