Not being a developer, I have limited uderstanding of PATs and global
git options, but here is what I was able to cobble together to start
looking at my situation:
> Sys.getenv("GITHUB_PAT")
[1] ""
> Sys.unsetenv("GITHUB_PAT")
> Sys.getenv("GITHUB_PAT")
[1] ""
> devtools::install_github("DillonHammill/CytoExploreRData")
Using GitHub PAT from the git credential store.
Error: Failed to install 'CytoExploreRData' from GitHub:
HTTP error 401.
Bad credentials
Rate limit remaining: 59/60
Rate limit reset at: 2024-06-21 00:17:47 UTC
> usethis::git_sitrep()
── Git global (user)
• Name: 'Rob Baer'
• Email: 'rwb...@gmail.com'
• Global (user-level) gitignore file: 'C:/Users/rbaer/.gitignore'
• Vaccinated: TRUE
ℹ Defaulting to 'https' Git protocol
• Default Git protocol: 'https'
• Default initial branch name: 'master'
── GitHub user
• Default GitHub host: 'https://github.com'
• Personal access token for 'https://github.com': '<discovered>'
✖ Can't get user information for this token.
The token may no longer be valid or perhaps it lacks the 'user' scope.
Error in `gh()`:
! GitHub API error (401): Bad credentials
ℹ Read more at <https://docs.github.com/rest>
ℹ No active usethis project
I'm not sure where I go from here. Any hints on what other diagnostics
are useful?
On 6/20/2024 5:41 PM, Jeff Newmiller wrote:
My guess is that this is related to you saving an expired Personal Access Token
in your global git options or credentials store? Git is perfectly capable of
using per-repo credentials... don't configure a credential in your global
configuration and it won't fall back on using it to access random new
repositories.
On June 20, 2024 3:16:55 PM PDT, Robert Baer <rb...@atsu.edu> wrote:
I am trying to install a package from github which has worked fine in the past,
but now seems to be stuck on some new authentication issues. Does anyone know
how I can straighten myself out? In theory, this is a public repository so I'm
not sure why I even need authenticating for installation.
Thanks,
Rob
The code:
devtools::install_github("DillonHammill/CytoExploreR")
Using GitHub PAT from the git credential store.
Error: Failed to install 'unknown package' from GitHub:
HTTP error 401.
Bad credentials
Rate limit remaining: 50/60
Rate limit reset at: 2024-06-20 22:19:33 UTC
Using GitHub PAT from the git credential store.
Error: unexpected symbol in "Using GitHub"
Error: Failed to install 'unknown package' from GitHub:
Error: unexpected symbol in "Error: Failed to"
HTTP error 401.
Error: unexpected symbol in " HTTP error"
Bad credentials
Error: unexpected symbol in " Bad credentials"
Rate limit remaining: 55/60
Error: unexpected symbol in " Rate limit"
Rate limit reset at: 2024-06-20 21:12:27 UTC```
Error: unexpected symbol in " Rate limit"
**Include any associated screenshots or images here:**
SESSIONINFO
sessionInfo()
R version 4.4.1 (2024-06-14 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 11 x64 (build 26120)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.utf8
[2] LC_CTYPE=English_United States.utf8
[3] LC_MONETARY=English_United States.utf8
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.utf8
time zone: America/Chicago
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] vctrs_0.6.5 cli_3.6.2 rlang_1.1.4 stringi_1.8.4
[5] purrr_1.0.2 pkgload_1.3.4 promises_1.3.0 shiny_1.8.1.1
[9] xtable_1.8-4 glue_1.7.0 htmltools_0.5.8.1 httpuv_1.6.15
[13] pkgbuild_1.4.4 ellipsis_0.3.2 fastmap_1.2.0 lifecycle_1.0.4
[17] memoise_2.0.1 stringr_1.5.1 compiler_4.4.1 miniUI_0.1.1.1
[21] sessioninfo_1.2.2 fs_1.6.4 htmlwidgets_1.6.4 Rcpp_1.0.12
[25] urlchecker_1.0.1 later_1.3.2 digest_0.6.35 R6_2.5.1
[29] curl_5.2.1 usethis_2.2.3 magrittr_2.0.3 tools_4.4.1
[33] mime_0.12 devtools_2.4.5 profvis_0.3.8 remotes_2.5.0
[37] cachem_1.1.0
______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.