Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update batch.R - Sets the maximum time (in seconds) to wait while try… #95

Closed
wants to merge 1 commit into from

Conversation

wangzhao0217
Copy link
Contributor

Sets the maximum time (in seconds) to wait while trying to connect to the server. This only limits the connection phase, not the entire request.

By adding httr::config(connecttimeout = 60 * 60 * 5), allowing the connection phase to take up to 5 hours, matching overall timeout.

@wangzhao0217
Copy link
Contributor Author

@Robinlovelace

@Robinlovelace
Copy link
Collaborator

Let's see if the tests pass, will merge if so!

@Robinlovelace Robinlovelace self-requested a review December 3, 2024 10:30
Copy link
Collaborator

@Robinlovelace Robinlovelace left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests not passing:

 ** using staged installation
** R
Error in parse(...) : 
  /home/runner/work/cyclestreets-r/cyclestreets-r/check/cyclestreets.Rcheck/00_pkg_src/cyclestreets/R/batch.R:310:3: unexpected symbol
309:   res = httr::POST(url = batch_url, body = body, httr::timeout(60*60*5), httr::config(connecttimeout = 60 * 60 * 5) # Connection timeout (5 hours))
310:   res_json
       ^
ERROR: unable to collate and parse R files for package ‘cyclestreets’
* removing ‘/home/runner/work/cyclestreets-r/cyclestreets-r/check/cyclestreets.Rcheck/cyclestreets’

Source: https://github.com/cyclestreets/cyclestreets-r/actions/runs/12128460223/job/33841523400?pr=95#step:6:92

Have you tried devtools::check() @wangzhao0217 ?

@wangzhao0217
Copy link
Contributor Author

close with a new PR

@wangzhao0217 wangzhao0217 deleted the patch-1 branch December 4, 2024 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants