Skip to content

Commit

Permalink
fixed problem with get_gbifid
Browse files Browse the repository at this point in the history
  • Loading branch information
zachary-foster committed Feb 3, 2025
1 parent ff26475 commit 8700222
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 69 deletions.
6 changes: 3 additions & 3 deletions R/get_gbifid.R
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,6 @@ get_gbifid <- function(sci, ask = TRUE, messages = TRUE, rows = NA,
assert(method, "character")
assert_rows(rows)

# Escape problematic characters
sci <- gsub(sci, pattern = "[^\\]?'", replacement = "\\\\'")

if (!is.null(sciname)) {
lifecycle::deprecate_warn(when = "v0.9.97", what = "get_gbifid(sciname)", with = "get_gbifid(sci)")
sci <- sciname
Expand All @@ -159,6 +156,9 @@ get_gbifid <- function(sci, ask = TRUE, messages = TRUE, rows = NA,
items <- c(sci, tstate$taxa_completed())
}

# Escape problematic characters
sci <- gsub(sci, pattern = "[^\\]?'", replacement = "\\\\'")

prog <- progressor$new(items = items, suppress = !messages)
done <- tstate$get()
for (i in seq_along(done)) prog$completed(names(done)[i], done[[i]]$att)
Expand Down
70 changes: 4 additions & 66 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,76 +1,14 @@
I am taking over as maintainer from Scott Chamberlain.
Scott told me that there was an error on a CRAN check due to a down internet service.
The error no longer appears at https://cran.r-project.org/web/checks/check_results_taxize.html so I do not know what the problem was exactly.
However, I have checked all of the test code to make sure that tests requiring internet services will not be run on CRAN, so the problem is probably solved.

Update after first submission:

I have checked for invalid URLs using `urlchecker::url_check` and fixed all except for:

```
x Error: inst/CITATION:8:22 403: Forbidden
url = "https://f1000research.com/articles/2-191/v2",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
x Error: inst/CITATION:13:37 403: Forbidden
"F1000Research, 2:191. URL: https://f1000research.com/articles/2-191/v2")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```

I am not sure what the problem is here.
The link works fine in a browser and does not redirect to another URL.


## Test environments and check results

### Local computer: Pop!_OS 20.04 LTS, R version 4.0.3
### Local computer: Pop!_OS 22.04 LTS, R version 4.4.2

0 errors | 0 warnings | 0 notes

### win-builder (devel)

0 errors | 0 warnings | 1 notes

```
* checking CRAN incoming feasibility ... NOTE
Maintainer: 'Zachary Foster <[email protected]>'
### rhub

New maintainer:
Zachary Foster <[email protected]>
Old maintainer(s):
Scott Chamberlain <[email protected]>
linux, macos, windows (all R-devel)

Found the following (possibly) invalid URLs:
URL: https://codecov.io/gh/ropensci/taxize (moved to https://app.codecov.io/gh/ropensci/taxize)
From: README.md
Status: 200
Message: OK
URL: https://f1000research.com/articles/2-191/v2
From: inst/CITATION
Status: 403
Message: Forbidden
...
...
...
```

I am taking over as maintainer from Scott Chamberlain.

I got many notes about unconfirmed URLs like:

```
URL: https://github.com/JulietteLgls
From: README.md
Status: 429
Message: Too Many Requests
```

probably because there are so many to check.

### Rhub

0 errors | 0 warnings | 1 notes

Same as win-builder notes
0 errors | 0 warnings | 0 notes


## Reverse dependencies
Expand Down

0 comments on commit 8700222

Please sign in to comment.