covid19datahub / COVID19

A worldwide epidemiological database for COVID-19 at fine-grained spatial resolution
https://covid19datahub.io
GNU General Public License v3.0
251 stars 93 forks source link

Error connecting with the Hub from Canada #194

Closed jfsavardenap closed 2 years ago

jfsavardenap commented 2 years ago

When I try to download data from Canada, I keep getting an error message that it is not possible to connect to the hub. When I use my VPN from an European country I do not get that error.

eguidotti commented 2 years ago

Wow, this is the most weird issue I've come across so far :) The data files are actually hosted in US, so it is strange it works from Europe and not from Canada.

Can you try to manually download some files from here, by clicking on the links? If it works, the issue is probably not due to this repo itself. Otherwise, can you please share a screenshot or something with the error you get?

Thanks!

jfsavardenap commented 2 years ago

Hello, I investigated the problem further. It seems that the problem is not link to the country, but to my internet service provider. Here is a reproducible example with my internet service provider:

library(dplyr) library(COVID19) library(ggplot2)

canada <- covid19(country = "CA", level=2, start = "2020-02-01")

trying URL 'https://storage.covid19datahub.io/country/index.csv.gz' Error in utils::download.file(url, destfile = tmp, mode = "wb", quiet = !verbose) : cannot open URL 'https://storage.covid19datahub.io/country/index.csv.gz' In addition: Warning message: In utils::download.file(url, destfile = tmp, mode = "wb", quiet = !verbose) : URL 'https://storage.covid19datahub.io/country/index.csv.gz': status was 'Couldn't connect to server'

Now, here is the same example with a different results when I connect with my VPN to a server in Canada:

canada <- covid19(country = "CA", level=2, start = "2020-02-01") trying URL 'https://storage.covid19datahub.io/country/index.csv.gz' Content type 'application/octet-stream' length 8115 bytes

downloaded 8115 bytes

trying URL 'https://storage.covid19datahub.io/country/CAN.csv.gz' Content type 'application/octet-stream' length 157116 bytes (153 KB)

downloaded 153 KB

We have invested a lot of time and effort in creating COVID-19 Data Hub, please cite the following when using it:

Guidotti, E., Ardia, D., (2020), "COVID-19 Data Hub", Journal of Open Source Software 5(51):2376, doi: 10.21105/joss.02376.

A BibTeX entry for LaTeX users is

@Article{, title = {COVID-19 Data Hub}, year = {2020}, doi = {10.21105/joss.02376}, author = {Emanuele Guidotti and David Ardia}, journal = {Journal of Open Source Software}, volume = {5}, number = {51}, pages = {2376}, }

To hide this message use 'verbose = FALSE'.

Additionally I get a data.frame called "canada as suppose to. Also note that I can access the link you provided when I am on my VPN, but not when I am not connected to the VPN. So something blocks the connection between your hub and my internet service provider, but I can't figure out what. Anybody else has a similar problem?

eguidotti commented 2 years ago

OK, I'll leave this issue open for a while in case someone else has a similar problem. However, I guess that this is not related to the hub itself and there is little I can do about it.

jfsavardenap commented 2 years ago

I will contact my internet provider to see if they have an answer and post it here.

jfsavardenap commented 2 years ago

Hello, As promised I contacted my internet service provider. So the problem comes from a feature called Advanced Security that blocks certain website. So, I simply have to ask my internet service provider to turn it off and the problems gets resolved. Thank you for your help and patience.

eguidotti commented 2 years ago

Great, thanks for the update. I'm closing the issue then