-
-
Notifications
You must be signed in to change notification settings - Fork 89
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
[infra] A função get_table_description()
não está funcionando – pacote basedosdados para a linguagem R
#1307
Comments
get_table_description()
não está funcionando – pacote basedosdados para a linguagem R
O resultado veio nulo da API, interessante. Isso acontece com outras bases ou só nessa tabela? |
Testei com outras tabelas e datasets, também sem sucesso. Testei para:
|
Pode rodar |
Criei um novo projeto no Rstudio e fiz um reprex. Os erros do "Teste 01" e do "Teste 02" são ligeiramente diferentes. O session info está logo depois. # Configuração ----
basedosdados::set_billing_id("meu-billing-id")
#>
#> ── Base dos Dados ──────────────────────────────────────────────────────────────
#> • Website: https://basedosdados.org/
#> • Docs: https://basedosdados.github.io/mais/
#>
#> ── Contatos ──
#>
#> • Discord: discord.gg/tuaFbAPeq5
#> • Twitter: @basedosdados
#> • Email: [email protected]
#> • Telegram: t.me/joinchat/OKWc3RnClXnq2hq-8o0h_w
#> • Github: github.com/basedosdados
#> • LinkedIn: linkedin.com/company/base-dos-dados
#> • Newsletter:
#> https://basedosdados.hubspotpagebuilder.com/assine-a-newsletter-da-base-dos-dados
#> • WhatsApp: https://chat.whatsapp.com/HXWgdFc1RmwCoblly5KPBZ
#> • YouTube: https://www.youtube.com/c/BasedosDados
#>
#> ── Somos um projeto open-source e gratuito. Para nos mantermos e crescermos precisamos do seu apoio. Quanto valem as horas do seu trabalho que poupamos?
#>
#> Nos apoie em https://apoia.se/basedosdados.
#>
#> ── Usando o pacote para produzir um trabalho? Para nos citar basta rodar citation('basedosdados').
#> Project keys set successfully
# Teste 01 ----
basedosdados::get_table_description(
dataset_id = "br_me_rais",
table_id = "microdados_vinculos"
)
#> Error:
#> ! Tibble columns must have compatible sizes.
#> • Size 0: Column `temporal_coverage`.
#> • Size 3: Column `directory_column`.
#> ℹ Only values of size one are recycled.
#> Backtrace:
#> ▆
#> 1. ├─basedosdados::get_table_description(...)
#> 2. │ └─tibble::tibble(...)
#> 3. │ └─tibble:::tibble_quos(xs, .rows, .name_repair)
#> 4. │ └─rlang::eval_tidy(xs[[j]], mask)
#> 5. ├─... %>% list()
#> 6. ├─purrr::reduce(., dplyr::bind_rows)
#> 7. │ └─purrr:::reduce_impl(.x, .f, ..., .init = .init, .dir = .dir)
#> 8. │ └─purrr:::reduce_init(.x, .init, left = left)
#> 9. │ └─rlang::is_empty(x)
#> 10. └─purrr::map(., tibble::as_tibble)
#> 11. ├─tibble (local) .f(.x[[i]], ...)
#> 12. └─tibble:::as_tibble.list(.x[[i]], ...)
#> 13. └─tibble:::lst_to_tibble(x, .rows, .name_repair, col_lengths(x))
#> 14. └─tibble:::recycle_columns(x, .rows, lengths)
#> 15. └─rlang::cnd_signal(...)
# Teste 02 ----
basedosdados::get_table_description(
dataset_id = "br_ibge_pib",
table_id = "municipio"
)
#> Error:
#> ! All columns in a tibble must be vectors.
#> ✖ Column `measurement_unit` is NULL.
#> Backtrace:
#> ▆
#> 1. ├─basedosdados::get_table_description(...)
#> 2. │ └─tibble::tibble(...)
#> 3. │ └─tibble:::tibble_quos(xs, .rows, .name_repair)
#> 4. │ └─rlang::eval_tidy(xs[[j]], mask)
#> 5. ├─... %>% list()
#> 6. ├─purrr::reduce(., dplyr::bind_rows)
#> 7. │ └─purrr:::reduce_impl(.x, .f, ..., .init = .init, .dir = .dir)
#> 8. │ └─purrr:::reduce_init(.x, .init, left = left)
#> 9. │ └─rlang::is_empty(x)
#> 10. └─purrr::map(., tibble::as_tibble)
#> 11. ├─tibble (local) .f(.x[[i]], ...)
#> 12. └─tibble:::as_tibble.list(.x[[i]], ...)
#> 13. └─tibble:::lst_to_tibble(x, .rows, .name_repair, col_lengths(x))
#> 14. └─tibble:::check_valid_cols(x)
#> 15. └─rlang::cnd_signal(...)
# Session Info ----
sessioninfo::session_info()
#> ─ Session info ───────────────────────────────────────────────────────────────
#> setting value
#> version R version 4.2.1 (2022-06-23 ucrt)
#> os Windows 10 x64 (build 19044)
#> system x86_64, mingw32
#> ui RTerm
#> language (EN)
#> collate Portuguese_Brazil.utf8
#> ctype Portuguese_Brazil.utf8
#> tz America/Bahia
#> date 2022-09-04
#> pandoc 2.18 @ C:/Program Files/RStudio/bin/quarto/bin/tools/ (via rmarkdown)
#>
#> ─ Packages ───────────────────────────────────────────────────────────────────
#> package * version date (UTC) lib source
#> assertthat 0.2.1 2019-03-21 [1] CRAN (R 4.2.0)
#> basedosdados 0.2.1 2022-03-15 [1] CRAN (R 4.2.0)
#> bigrquery 1.4.0 2021-08-05 [1] CRAN (R 4.2.1)
#> bit 4.0.4 2020-08-04 [1] CRAN (R 4.2.0)
#> bit64 4.0.5 2020-08-30 [1] CRAN (R 4.2.0)
#> cli 3.3.0 2022-04-25 [1] CRAN (R 4.2.0)
#> colorspace 2.0-3 2022-02-21 [1] CRAN (R 4.2.0)
#> curl 4.3.2 2021-06-23 [1] CRAN (R 4.2.0)
#> DBI 1.1.3 2022-06-18 [1] CRAN (R 4.2.0)
#> dbplyr 2.2.1 2022-06-27 [1] CRAN (R 4.2.1)
#> digest 0.6.29 2021-12-01 [1] CRAN (R 4.2.0)
#> dplyr 1.0.10 2022-09-01 [1] CRAN (R 4.2.1)
#> ellipsis 0.3.2 2021-04-29 [1] CRAN (R 4.2.0)
#> evaluate 0.16 2022-08-09 [1] CRAN (R 4.2.1)
#> fansi 1.0.3 2022-03-24 [1] CRAN (R 4.2.0)
#> fastmap 1.1.0 2021-01-25 [1] CRAN (R 4.2.0)
#> fs 1.5.2 2021-12-08 [1] CRAN (R 4.2.0)
#> gargle 1.2.0 2021-07-02 [1] CRAN (R 4.2.0)
#> generics 0.1.3 2022-07-05 [1] CRAN (R 4.2.0)
#> glue 1.6.2 2022-02-24 [1] CRAN (R 4.2.0)
#> highr 0.9 2021-04-16 [1] CRAN (R 4.2.0)
#> hms 1.1.2 2022-08-19 [1] CRAN (R 4.2.1)
#> htmltools 0.5.3 2022-07-18 [1] CRAN (R 4.2.1)
#> httr 1.4.4 2022-08-17 [1] CRAN (R 4.2.1)
#> jsonlite 1.8.0 2022-02-22 [1] CRAN (R 4.2.0)
#> knitr 1.40 2022-08-24 [1] CRAN (R 4.2.1)
#> lifecycle 1.0.1 2021-09-24 [1] CRAN (R 4.2.0)
#> magrittr 2.0.3 2022-03-30 [1] CRAN (R 4.2.0)
#> munsell 0.5.0 2018-06-12 [1] CRAN (R 4.2.0)
#> pillar 1.8.1 2022-08-19 [1] CRAN (R 4.2.1)
#> pkgconfig 2.0.3 2019-09-22 [1] CRAN (R 4.2.0)
#> purrr 0.3.4 2020-04-17 [1] CRAN (R 4.2.0)
#> R.cache 0.16.0 2022-07-21 [1] CRAN (R 4.2.0)
#> R.methodsS3 1.8.2 2022-06-13 [1] CRAN (R 4.2.0)
#> R.oo 1.25.0 2022-06-12 [1] CRAN (R 4.2.0)
#> R.utils 2.12.0 2022-06-28 [1] CRAN (R 4.2.0)
#> R6 2.5.1 2021-08-19 [1] CRAN (R 4.2.0)
#> Rcpp 1.0.9 2022-07-08 [1] CRAN (R 4.2.0)
#> readr 2.1.2 2022-01-30 [1] CRAN (R 4.2.0)
#> reprex 2.0.2 2022-08-17 [1] CRAN (R 4.2.1)
#> rlang 1.0.5 2022-08-31 [1] CRAN (R 4.2.1)
#> rmarkdown 2.16 2022-08-24 [1] CRAN (R 4.2.1)
#> rstudioapi 0.14 2022-08-22 [1] CRAN (R 4.2.1)
#> scales 1.2.1 2022-08-20 [1] CRAN (R 4.2.1)
#> sessioninfo 1.2.2 2021-12-06 [1] CRAN (R 4.2.0)
#> stringi 1.7.8 2022-07-11 [1] CRAN (R 4.2.0)
#> stringr 1.4.1 2022-08-20 [1] CRAN (R 4.2.1)
#> styler 1.7.0 2022-03-13 [1] CRAN (R 4.2.0)
#> tibble 3.1.8 2022-07-22 [1] CRAN (R 4.2.0)
#> tidyselect 1.1.2 2022-02-21 [1] CRAN (R 4.2.0)
#> typed 0.0.1 2021-03-19 [1] CRAN (R 4.2.0)
#> tzdb 0.3.0 2022-03-28 [1] CRAN (R 4.2.0)
#> utf8 1.2.2 2021-07-24 [1] CRAN (R 4.2.0)
#> vctrs 0.4.1 2022-04-13 [1] CRAN (R 4.2.0)
#> withr 2.5.0 2022-03-03 [1] CRAN (R 4.2.0)
#> xfun 0.32 2022-08-10 [1] CRAN (R 4.2.1)
#> yaml 2.3.5 2022-02-21 [1] CRAN (R 4.2.0)
#>
#> [1] C:/Users/enoch/AppData/Local/R/win-library/4.2
#> [2] C:/Program Files/R/R-4.2.1/library
#>
#> ────────────────────────────────────────────────────────────────────────────── Created on 2022-09-04 with reprex v2.0.2 |
Um pequeno esclarecimento: no exemplo que dei na mensagem inicial houve um erro de grafia – eu não deveria ter colocado o acento agudo no nome da tabela (município versus municipio). Consertei no reprex acima mas ainda assim a função |
Descrição
A função
get_table_description()
não estárodando.Cheguei a testar fazendo o downgrade do dbplyr para a versão 2.1.1 mas sem sucesso.
get_table_description()
Mensagens de erro
Trechos do Session Info
The text was updated successfully, but these errors were encountered: