r-lib / httr

httr: a friendly http package for R
https://httr.r-lib.org
Other
985 stars 1.99k forks source link

progress bar immediately shows 100% #683

Closed rafapereirabr closed 10 months ago

rafapereirabr commented 3 years ago

Hi all. I use httr to download files in the geobr package. The issue I'm facing is that the progress bar immediately shows 100%, but the file is not downloaded yet.

Reprex.

library(httr)

# one of the files we use in our package
file_url <- "http://www.ipea.gov.br/geobr/data_gpkg/census_tract/2010/33_simplified.gpkg"

httr::GET(url=file_url, httr::progress(type = "down") )

ps. Thanks for an amazing package.

hadley commented 10 months ago

Unfortunately not every server sends the correct headers to allow progress bars to work.