Describe the bug
listCensusApis() returns error indicating the URL cannot be reached. However, getCensus() itself seems to work fine.
To Reproduce
> library("censusapi")
Attaching package: ‘censusapi’
The following object is masked from ‘package:methods’:
getFunction
> listCensusApis()
Error in open.connection(con, "rb") :
cannot open the connection to 'https://api.census.gov/data.json'
In addition: Warning message:
In open.connection(con, "rb") :
URL 'https://api.census.gov/data.json': status was 'Failure when receiving data from the peer'
(For what it's worth, that address doesn't seem to work directly entered in Firefox, either.
# using the example from the docs
> acs_simple <- getCensus(
+ name = "acs/acs5",
+ vintage = 2020,
+ vars = c("NAME", "B01001_001E", "B19013_001E"),
+ region = "place:*",
+ regionin = "state:01")
> head(acs_simple)
state place NAME B01001_001E B19013_001E
1 01 44536 Lowndesboro town, Alabama 75 41667
2 01 44608 Loxley town, Alabama 2767 62292
3 01 44728 Luverne city, Alabama 2742 48468
4 01 44800 Lynn town, Alabama 832 36115
5 01 45040 McCalla CDP, Alabama 12077 71061
6 01 45208 McDonald Chapel CDP, Alabama 662 49038
>
So, if I knew how to ask for what I want, it seems I could get it fine. But I don't seem to be able to use the method that's supposed to tell me how to ask...
Describe the bug listCensusApis() returns error indicating the URL cannot be reached. However, getCensus() itself seems to work fine.
To Reproduce
(For what it's worth, that address doesn't seem to work directly entered in Firefox, either.
So, if I knew how to ask for what I want, it seems I could get it fine. But I don't seem to be able to use the method that's supposed to tell me how to ask...
R session information: