* using log directory 'd:/RCompile/CRANincoming/R-devel/metricminer.Rcheck' * using R Under development (unstable) (2024-01-23 r85822 ucrt) * using platform: x86_64-w64-mingw32 * R was compiled by gcc.exe (GCC) 12.3.0 GNU Fortran (GCC) 12.3.0 * running under: Windows Server 2022 x64 (build 20348) * using session charset: UTF-8 * checking for file 'metricminer/DESCRIPTION' ... OK * checking extension type ... Package * this is package 'metricminer' version '0.5.0' * package encoding: UTF-8 * checking CRAN incoming feasibility ... NOTE Maintainer: 'Candace Savonen ' New submission Possibly misspelled words in DESCRIPTION: APIs (13:82) metricminer (16:19) * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking whether package 'metricminer' can be installed ... OK * checking installed package size ... OK * checking package directory ... OK * checking for future file timestamps ... OK * checking 'build' directory ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking R files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... OK * checking whether the package can be loaded with stated dependencies ... OK * checking whether the package can be unloaded cleanly ... OK * checking whether the namespace can be loaded with stated dependencies ... OK * checking whether the namespace can be unloaded cleanly ... OK * checking loading without being on the library search path ... OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... OK * checking Rd files ... OK * checking Rd metadata ... OK * checking Rd line widths ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking installed files from 'inst/doc' ... OK * checking files in 'vignettes' ... OK * checking examples ... OK * checking for unstated dependencies in 'tests' ... OK * checking tests ... [14s] ERROR Running 'testthat.R' [14s] Running the tests in 'tests/testthat.R' failed. Complete output: > # This file is part of the standard setup for testthat. > # It is recommended that you do not modify it. > # > # Where should you do additional test configuration? > # Learn more about the roles of various files in: > # * https://r-pkgs.org/tests.html > # * https://testthat.r-lib.org/reference/test_package.html#special-files > > library(testthat) > library(metricminer) > > test_check("metricminer") Using user-supplied cached token using authorize("calendly") Using user-supplied cached token using authorize("github") Using user-supplied cached token using authorize("github") Using user-supplied cached token using authorize("github") Trying GET /repos/{owner}/{repo}/activity for fhdsl/metricminer i Running gh query i Running gh query, got 100 records i Running gh query, got 200 records i Running gh query, got 300 records Trying GET /repos/{owner}/{repo}/stargazers for fhdsl/metricminer Trying GET /repos/{owner}/{repo}/forks for fhdsl/metricminer Trying GET /repos/{owner}/{repo}/contributors for fhdsl/metricminer Trying GET /repos/{owner}/{repo}/community/profile for fhdsl/metricminer Using user-supplied cached token using authorize("github") Trying GET /repos/{owner}/{repo}/traffic/clones for fhdsl/metricminer Using user-supplied cached token using authorize("google") Auto-refreshing stale OAuth token. Using user-supplied cached token using authorize("google") Auto-refreshing stale OAuth token. Using user-supplied cached token using authorize("google") Retrieving all properties underneath this account Using user-supplied cached token using authorize("google") Auto-refreshing stale OAuth token. Using user-supplied cached token using authorize("google") Trying to grab form: 1Neyj7wwNpn8wC7NzQND8kQ30cnbbETSpT0lKhX7uaQY Auto-refreshing stale OAuth token. Using user-supplied cached token using authorize("google") Trying to grab form: 1Neyj7wwNpn8wC7NzQND8kQ30cnbbETSpT0lKhX7uaQY Auto-refreshing stale OAuth token. You chose to cache your credentials, if you change your mind, run metricminer::delete_creds(). Be careful not to push .httr-oauth or RDS files to GitHub or share it anywhere. Using user-supplied cached token using authorize("google") Trying to grab form: 1pbFfgUPYH2w9zEoCDjCa4HFOxzEhGOseufw28Xxmd-o Auto-refreshing stale OAuth token. Using user-supplied cached token using authorize("google") [ FAIL 9 | WARN 6 | SKIP 1 | PASS 3 ] ══ Skipped tests (1) ═══════════════════════════════════════════════════════════ • On CRAN (1): 'test-auth.R:1:1' ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test-calendly.R:6:3'): Calendly: Events ───────────────────────────── Error in `calendly_get(url = "https://api.calendly.com/users/me", token = token)`: Unauthorized (HTTP 401). Backtrace: ▆ 1. └─metricminer::get_calendly_user() at test-calendly.R:6:3 2. └─metricminer::calendly_get(...) 3. └─httr::stop_for_status(result) ── Error ('test-github.R:29:3'): GitHub: Repo metrics ────────────────────────── Error in `purrr::map(api_calls, gh_repo_wrapper_fn)`: i In index: 1. i With name: clones. Caused by error in `gh::gh()`: ! GitHub API error (403): Must have push access to repository i Read more at ── Error ('test-google-analytics.R:10:3'): Google Analytics: Properties ──────── Error in `request_ga(token = token, url = "https://analytics.googleapis.com/analytics/v3/management/accountSummaries", request_type = request_type)`: API request failed:{ "error": { "code": 401, "message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.", "errors": [ { "message": "Login Required.", "domain": "global", "reason": "required", "location": "Authorization", "locationType": "header" } ], "status": "UNAUTHENTICATED", "details": [ { "@type": "type.googleapis.com/google.rpc.ErrorInfo", "reason": "CREDENTIALS_MISSING", "domain": "googleapis.com", "metadata": { "method": "analytics.gaapi.v3.AnalyticsManagementAccountSummaries.List", "service": "analytics.googleapis.com" } } ] } } Backtrace: ▆ 1. └─metricminer::get_ga_user() at test-google-analytics.R:10:3 2. └─metricminer::request_ga(...) ── Error ('test-google-analytics.R:30:3'): Google Analytics: Stats ───────────── Error in `request_ga(token = token, url = "https://analyticsadmin.googleapis.com/v1alpha/properties", query = list(filter = paste0("parent:accounts/", account_id)), request_type = "GET")`: API request failed:{ "error": { "code": 401, "message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.", "status": "UNAUTHENTICATED", "details": [ { "@type": "type.googleapis.com/google.rpc.ErrorInfo", "reason": "CREDENTIALS_MISSING", "domain": "googleapis.com", "metadata": { "method": "google.analytics.admin.v1alpha.AnalyticsAdminService.ListProperties", "service": "analyticsadmin.googleapis.com" } } ] } } Backtrace: ▆ 1. └─metricminer::get_ga_properties(account_id = 209776907) at test-google-analytics.R:30:3 2. └─metricminer::request_ga(...) ── Error ('test-google-analytics.R:55:3'): Google Analytics: All Stats ───────── Error in `request_ga(token = token, url = "https://analyticsadmin.googleapis.com/v1alpha/properties", query = list(filter = paste0("parent:accounts/", account_id)), request_type = "GET")`: API request failed:{ "error": { "code": 401, "message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.", "status": "UNAUTHENTICATED", "details": [ { "@type": "type.googleapis.com/google.rpc.ErrorInfo", "reason": "CREDENTIALS_MISSING", "domain": "googleapis.com", "metadata": { "method": "google.analytics.admin.v1alpha.AnalyticsAdminService.ListProperties", "service": "analyticsadmin.googleapis.com" } } ] } } Backtrace: ▆ 1. └─metricminer::get_all_ga_metrics(account_id = 209776907) at test-google-analytics.R:55:3 2. └─metricminer::get_ga_properties(account_id = account_id) 3. └─metricminer::request_ga(...) ── Error ('test-google-forms.R:9:3'): Google Forms: Get form ─────────────────── Error in `request_google_forms(url = form_info_url, token = token)`: Unauthorized (HTTP 401). Backtrace: ▆ 1. └─metricminer:::get_google_form("https://docs.google.com/forms/d/1Neyj7wwNpn8wC7NzQND8kQ30cnbbETSpT0lKhX7uaQY/edit") at test-google-forms.R:9:3 2. └─metricminer::request_google_forms(url = form_info_url, token = token) 3. └─httr::stop_for_status(result) ── Error ('test-google-forms.R:28:3'): Google Forms: Get multiple forms ──────── Error in `request_google_forms(url = form_info_url, token = token)`: Unauthorized (HTTP 401). Backtrace: ▆ 1. └─metricminer:::get_multiple_forms(form_ids = form_ids) at test-google-forms.R:28:3 2. └─base::sapply(...) 3. └─base::lapply(X = X, FUN = FUN, ...) 4. └─metricminer (local) FUN(X[[i]], ...) 5. └─metricminer:::get_google_form(form_id = form_id, token = token) 6. └─metricminer::request_google_forms(url = form_info_url, token = token) 7. └─httr::stop_for_status(result) ── Error ('test-write_data.R:10:3'): Writing gsheets ─────────────────────────── Error in `request_google_forms(url = form_info_url, token = token)`: Unauthorized (HTTP 401). Backtrace: ▆ 1. └─metricminer:::get_google_form("https://docs.google.com/forms/d/1pbFfgUPYH2w9zEoCDjCa4HFOxzEhGOseufw28Xxmd-o/edit") at test-write_data.R:10:3 2. └─metricminer::request_google_forms(url = form_info_url, token = token) 3. └─httr::stop_for_status(result) ── Error ('test-youtube.R:10:3'): Youtube ────────────────────────────────────── Error in `get_youtube_channel_stats("UCr73I9ZEPbn-3_1CBM57QgQ")`: Forbidden (HTTP 403). Backtrace: ▆ 1. └─metricminer::get_youtube_channel_stats("UCr73I9ZEPbn-3_1CBM57QgQ") at test-youtube.R:10:3 2. └─httr::stop_for_status(result) [ FAIL 9 | WARN 6 | SKIP 1 | PASS 3 ] Error: Test failures Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes ... OK * checking re-building of vignette outputs ... OK * checking PDF version of manual ... [29s] OK * checking HTML version of manual ... OK * DONE Status: 1 ERROR, 1 NOTE