Skip to content

Conversation

@egeulgen
Copy link
Owner

@egeulgen egeulgen commented Sep 18, 2025

some tests unexpectedly failed on CRAN checks:

══ Failed tests ════════════════════════════════════════════════════════════════
    ── Error ('test-data_generation.R:49:3'): `get_biogrid_pin()` -- determines and downloads the latest version ──
    <curl_error_operation_timedout/curl_error/error/condition>
    Error in `curl::curl_fetch_memory(url, handle = handle)`: Timeout was reached [downloads.thebiogrid.org]:
    Connection timed out after 10001 milliseconds
    Backtrace:1. ├─pathfindR:::get_biogrid_pin() at test-data_generation.R:49:3
     2. │ └─httr::GET("https://downloads.thebiogrid.org/BioGRID/Latest-Release/")
     3. │   └─httr:::request_perform(req, hu$handle$handle)
     4. │     ├─httr:::request_fetch(req$output, req$url, handle)
     5. │     └─httr:::request_fetch.write_memory(req$output, req$url, handle)
     6. │       └─curl::curl_fetch_memory(url, handle = handle)
     7. └─curl:::raise_libcurl_error(...)

CRAN policy:

'Packages which use Internet resources should fail gracefully with an informative message
if the resource is not available or has changed (and not give a check warning nor error).'

Updates have been implemented so that:

  • the new safe_get_content function is utilised so that GET and content call failures are handled more gracefully
  • tests updated so that there is no direct access to actual URLs (instead these are mocked)

@egeulgen egeulgen merged commit 17abdf1 into master Sep 18, 2025
7 of 8 checks passed
@egeulgen egeulgen deleted the fix/update-get-method-to-fail-gracefully branch September 18, 2025 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants