Can someone find the error?
I recently bought the book "Text Mining with R".
In chapter 1, I tried to download some novels of H.G. Wells.
I get the first error message, and then I try to change mirrors and get the same error message again.
And, I used replex package (first time) to report this error message.
library(gutenbergr)
library(dplyr)
#>
#> Attaching package: 'dplyr'
#> The following objects are masked from 'package:stats':
#>
#> filter, lag
#> The following objects are masked from 'package:base':
#>
#> intersect, setdiff, setequal, union
hgwells <- gutenberg_download(c(35, 36, 5230,159))
#> Determining mirror for Project Gutenberg from http://www.gutenberg.org/robot/harvest
#> Using mirror http://aleph.gutenberg.org
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/3/35/35.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/3/36/36.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/5/2/3/5230/5230.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/1/5/159/159.zip
#> Error in `mutate()`:
#> ! Problem while computing `gutenberg_id = as.integer(gutenberg_id)`.
#> ✖ `gutenberg_id` must be size 0 or 1, not 4.
my_mirror <- "http://mirrors.xmission.com/gutenberg/"
hgwells <- gutenberg_download(c(35, 36, 5230,159))#second time
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/3/35/35.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/3/36/36.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/5/2/3/5230/5230.zip
#> Warning in .f(.x[[i]], ...): Could not download a book at http://
#> aleph.gutenberg.org/1/5/159/159.zip
#> Error in `mutate()`:
#> ! Problem while computing `gutenberg_id = as.integer(gutenberg_id)`.
#> ✖ `gutenberg_id` must be size 0 or 1, not 4.
Created on 2022-07-31 by the reprex package (v2.0.1)