-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
issues with validate_names #266
Comments
Please try updating to the most recent version?
On Thu, Jun 8, 2023 at 6:22 PM Dana I Grieco ***@***.***> wrote:
Hi rfishbase,
I'm having an issue with the validate_names, and I can't seem to figure it
out. I ran the code about two weeks ago, and was able to use validate_names
with my dataset, and it worked perfectly. Now, before even getting to my
dataset, I try to run the simple code, below, to make sure validate names
is working, and it produces the following error, below:
validate_names("Abramites ternetzi")
Error in purrr::map_chr():
i In index: 1.
Caused by error:
! Result must be length 1, not 2.
Run rlang::last_trace() to see where the error occurred.
rlang::last_trace()
<error/purrr_error_indexed>
------------------------------
Backtrace:
x
1. +-rfishbase::validate_names("Abramites ternetzi")
2. | +-... %>% dplyr::pull(Species)
3. | -rfishbase::synonyms(...)
4. | +-... %>% ...
5. | -rfishbase::fb_tbl("synonyms", server, version, db)
6. | -rfishbase::fb_import(server, version, db, tbl)
7. | +-rfishbase:::parse_prov(read_prov(server), version)
8. | | +-base::withVisible(eval(mc, parent.frame()))
9. | | -base::eval(mc, parent.frame())
10. | | -base::eval(mc, parent.frame())
11. | -rfishbase (local) <fn>(prov = read_prov(server), version =
version)
12. | -tibble::tibble(...)
13. | -tibble:::tibble_quos(xs, .rows, .name_repair)
14. | -rlang::eval_tidy(xs[[j]], mask)
15. +-dplyr::pull(., Species)
16. +-dplyr::left_join(x = tmp, y = ., by = "synonym")
17. +-dplyr:::left_join.data.frame(x = tmp, y = ., by = "synonym")
18. | -dplyr::auto_copy(x, y, copy = copy)
19. | +-dplyr::same_src(x, y)
20. | -dplyr:::same_src.data.frame(x, y)
21. | -base::is.data.frame(y)
22. +-dplyr::distinct(.)
23. +-dplyr::select(., synonym, Species)
24. +-dplyr::ungroup(.)
25. +-dplyr::filter(., !is.na(Species))
26. +-dplyr::group_by(., synonym)
27. +-dplyr::mutate(...)
28. +-dplyr::collect(.)
29. +-dplyr::select(...)
30. +-dplyr::mutate(., synonym = paste(SynGenus, SynSpecies))
31. +-purrr::map_chr(meta, "encodingFormat", .default = NA)
32. | -purrr:::map_("character", .x, .f, ..., .progress = .progress)
33. | +-purrr:::with_indexed_errors(...)
34. | | -base::withCallingHandlers(...)
35. | -purrr:::call_with_cleanup(...)
36. -base::.handleSimpleError(...)
37. -purrr (local) h(simpleError(msg, call))
38.
\-cli::cli_abort(...)
39.
\-rlang::abort(...)>
—
Reply to this email directly, view it on GitHub
<#266>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABWK6S6K35A4BUAU73VPMTXKJGBFANCNFSM6AAAAAAY734HYM>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
--
---
Carl Boettiger
http://carlboettiger.info/
|
Hi, I'm also having a problem with validate_names as well. I've updated both the package and R today - I'd last run the code in May and it had worked then. Any advice on the following error appreciated:
Error in (function (cond) : |
@sollucas sorry but I'm unable to reproduce the behavior you're seeing. Can you try first purging the cache: rfishbase::db_dir() |> unlink() Can you please provide more information, including please ensure related dependencies are up-to-date -- eg. consider using |
Thanks for the response - I've tried the suggestions and unfortunately still getting the same error:
|
note taht you will need to restart R after installing/upgrade packages. I'm very confused why certain packages are not being listed in your sessionInfo() : in particular, can you try installing and loading duckdb manually first? |
(aside, but is your RStudio version up-to-date as well?) |
Updated R Studio today (version 2023.06.0)
|
Hi again - I copied my files to a different drive and am no longer getting the error. Apologies, think this was an issue with the original drive I was using. Thanks very much for your help! |
Hi rfishbase,
I'm having an issue with the validate_names, and I can't seem to figure it out. I ran the code about two weeks ago, and was able to use validate_names with my dataset, and it worked perfectly. Now, before even getting to my dataset, I try to run the simple code, below, to make sure validate names is working, and it produces the following error, below:
validate_names("Abramites ternetzi")
Error in
purrr::map_chr()
:i In index: 1.
Caused by error:
! Result must be length 1, not 2.
Run
rlang::last_trace()
to see where the error occurred.Backtrace:
x
<fn>
(prov = read_prov(server), version = version)The text was updated successfully, but these errors were encountered: