yonicd / carbonate

carbon.js for R
https://yonicd.github.io/carbonate/
Other
212 stars 5 forks source link

Selenium "unable to locate element" error, carbon page changed? #23

Closed dpprdan closed 4 years ago

dpprdan commented 4 years ago

Describe the bug

I am getting similar error messages as in #15. Has the carbon page changed again?

(Apparently you did not have problems today, though.)

To Reproduce

library(carbonate)
x <- carbon$new("x <- 1")
x$carbonate()
#> starting chrome session...
#> checking chromedriver versions:
#> BEGIN: PREDOWNLOAD
#> BEGIN: DOWNLOAD
#> BEGIN: POSTDOWNLOAD
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> 
#> 
#> Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="export-menu"]/div/button"}
#>   (Session info: chrome=83.0.4103.61)
#>   (Driver info: chromedriver=83.0.4103.39 (ccbf011cb2d2b19b506d844400483861342c20cd-refs/branch-heads/4103@{#416}),platform=Windows NT 10.0.18363 x86_64)
#> Error: attempt to fetch image from carbon servers failed, 
#>          please check network connectivity and try again
Session info ``` r devtools::session_info() #> - Session info --------------------------------------------------------------- #> setting value #> version R version 3.6.3 (2020-02-29) #> os Windows 10 x64 #> system x86_64, mingw32 #> ui RTerm #> language EN #> collate German_Germany.1252 #> ctype German_Germany.1252 #> tz Europe/Berlin #> date 2020-05-21 #> #> - Packages ------------------------------------------------------------------- #> package * version date lib source #> askpass 1.1 2019-01-13 [1] CRAN (R 3.6.2) #> assertthat 0.2.1 2019-03-21 [1] CRAN (R 3.6.2) #> backports 1.1.7 2020-05-13 [1] CRAN (R 3.6.3) #> binman 0.1.1 2018-07-18 [1] CRAN (R 3.6.2) #> bitops 1.0-6 2013-08-17 [1] CRAN (R 3.6.0) #> callr 3.4.3 2020-03-28 [1] CRAN (R 3.6.3) #> carbonate * 0.1.3 2020-05-21 [1] Github (yonicd/carbonate@9764c99) #> caTools 1.18.0 2020-01-17 [1] CRAN (R 3.6.2) #> cli 2.0.2 2020-02-28 [1] CRAN (R 3.6.3) #> clipr 0.7.0 2019-07-23 [1] CRAN (R 3.6.1) #> crayon 1.3.4 2017-09-16 [1] CRAN (R 3.6.2) #> curl 4.3 2019-12-02 [1] CRAN (R 3.6.2) #> desc 1.2.0 2018-05-01 [1] CRAN (R 3.6.2) #> devtools 2.3.0 2020-04-10 [1] CRAN (R 3.6.3) #> digest 0.6.25 2020-02-23 [1] CRAN (R 3.6.3) #> ellipsis 0.3.1 2020-05-15 [1] CRAN (R 3.6.3) #> evaluate 0.14 2019-05-28 [1] CRAN (R 3.6.2) #> fansi 0.4.1 2020-01-08 [1] CRAN (R 3.6.2) #> fs 1.4.1 2020-04-04 [1] CRAN (R 3.6.3) #> glue 1.4.1 2020-05-13 [1] CRAN (R 3.6.3) #> highr 0.8 2019-03-20 [1] CRAN (R 3.6.2) #> htmltools 0.4.0 2019-10-04 [1] CRAN (R 3.6.1) #> httr 1.4.1 2019-08-05 [1] CRAN (R 3.6.1) #> jsonlite 1.6.1 2020-02-02 [1] CRAN (R 3.6.2) #> knitr 1.28 2020-02-06 [1] CRAN (R 3.6.2) #> magick 2.3 2020-01-24 [1] CRAN (R 3.6.2) #> magrittr 1.5 2014-11-22 [1] CRAN (R 3.6.2) #> memoise 1.1.0 2017-04-21 [1] CRAN (R 3.6.1) #> openssl 1.4.1 2019-07-18 [1] CRAN (R 3.6.1) #> pkgbuild 1.0.8 2020-05-07 [1] CRAN (R 3.6.3) #> pkgload 1.0.2 2018-10-29 [1] CRAN (R 3.6.2) #> prettyunits 1.1.1 2020-01-24 [1] CRAN (R 3.6.2) #> processx 3.4.2 2020-02-09 [1] CRAN (R 3.6.2) #> ps 1.3.3 2020-05-08 [1] CRAN (R 3.6.3) #> R6 2.4.1 2019-11-12 [1] CRAN (R 3.6.1) #> rappdirs 0.3.1 2016-03-28 [1] CRAN (R 3.6.2) #> Rcpp 1.0.4.6 2020-04-09 [1] CRAN (R 3.6.3) #> remotes 2.1.1 2020-02-15 [1] CRAN (R 3.6.3) #> reprex 0.3.0 2019-05-16 [1] CRAN (R 3.6.2) #> rex 1.2.0 2020-04-21 [1] CRAN (R 3.6.3) #> rlang 0.4.6 2020-05-02 [1] CRAN (R 3.6.3) #> rmarkdown 2.1 2020-01-20 [1] CRAN (R 3.6.2) #> rprojroot 1.3-2 2018-01-03 [1] CRAN (R 3.6.2) #> RSelenium 1.7.7 2020-02-03 [1] CRAN (R 3.6.2) #> rstudioapi 0.11 2020-02-07 [1] CRAN (R 3.6.2) #> rtweet 0.7.0 2020-01-08 [1] CRAN (R 3.6.2) #> semver 0.2.0 2017-01-06 [1] CRAN (R 3.6.2) #> sessioninfo 1.1.1 2018-11-05 [1] CRAN (R 3.6.2) #> stringi 1.4.6 2020-02-17 [1] CRAN (R 3.6.2) #> stringr 1.4.0 2019-02-10 [1] CRAN (R 3.6.2) #> testthat 2.3.2 2020-03-02 [1] CRAN (R 3.6.3) #> todor 0.1.0 2020-03-04 [1] CRAN (R 3.6.2) #> usethis 1.6.1 2020-04-29 [1] CRAN (R 3.6.3) #> wdman 0.2.5 2020-01-31 [1] CRAN (R 3.6.2) #> withr 2.2.0 2020-04-20 [1] CRAN (R 3.6.3) #> xfun 0.14 2020-05-20 [1] CRAN (R 3.6.3) #> XML 3.99-0.3 2020-01-20 [1] CRAN (R 3.6.2) #> xml2 1.3.2 2020-04-23 [1] CRAN (R 3.6.3) #> yaml 2.2.1 2020-02-01 [1] CRAN (R 3.6.2) #> #> [1] D:/Users/Daniel/Documents/R/win-library/3.6 #> [2] C:/Program Files/R/R-3.6.3/library ```

{carbonate} is from current master, Chrome opens and shows carbon.now.sh correctly with the specified code.

yonicd commented 4 years ago

i didnt use this package for the twitter post. i used this one: https://github.com/yonicd/carbonace. it is going to replace {carbonate} because of such problems like in this issue. the carbonjs UI is too unstable.

dpprdan commented 4 years ago

Ha, I saw this and thought it was a typo 🤦‍♂️ 😂 grafik

dpprdan commented 4 years ago

Apparently no update on the "access to the raw [carbon.js] script" then?

yonicd commented 4 years ago

the JS that drives rselenium worked a month ago. /shrug

yonicd commented 4 years ago

Fixed: PR https://github.com/yonicd/carbonate/pull/22