Unable to activate visual mode (document contains example lists which are not currently supported)

Warning message at the top:
Unable to activate visual mode (document contains example lists which are not currently supported)

rmd script is quite large and not suitable to copy and paste here. Any ideas or suggestions are more than welcome.

You can try a bisection search. Make a copy of the document and cut out about half the content. If the reduced document works, the problem is in the half you cut out, so switch to that. Cut the reduced document in half again and repeat until you've narrowed down the location of the problem to something that you either recognize as buggered or is brief enough (and sufficiently devoid of state secrets) that you can publish it here.

2 Likes

I got in the last few months several time the same error message. As a result, I could not use visual mode. Finally, with the procedure proposed by @prubin I found the problem.

The issue arises whenever I use a cross-reference in a bullet list. I believe it has to do with one of the Known Limitations of the visual markdown editor.

Example lists (@) First example Read/written as ordinary numbered lists.

How to test? Write the text in source mode of RStudio and then switch to visual mode.

Here is a Reprex of a minimal example:

---
title: "Test"
---

# My Header {#sec-my-header}

-   This is my first bullet.
-   This is my second bullet, this time with a cross-reference
    @sec-my-header.
-   This is my third bullet.
#> Error: <text>:7:10: unexpected symbol
#> 6: 
#> 7: -   This is
#>             ^

Created on 2024-07-29 with reprex v2.1.1

Session info

sessioninfo::session_info()
#> ─ Session info ───────────────────────────────────────────────────────────────
#>  setting  value
#>  version  R version 4.4.1 (2024-06-14)
#>  os       macOS Sonoma 14.5
#>  system   x86_64, darwin20
#>  ui       X11
#>  language (EN)
#>  collate  en_US.UTF-8
#>  ctype    en_US.UTF-8
#>  tz       Europe/Vienna
#>  date     2024-07-29
#>  pandoc   3.2.1 @ /usr/local/bin/ (via rmarkdown)
#> 
#> ─ Packages ───────────────────────────────────────────────────────────────────
#>  package     * version date (UTC) lib source
#>  cli           3.6.3   2024-06-21 [1] CRAN (R 4.4.1)
#>  digest        0.6.36  2024-06-23 [1] CRAN (R 4.4.0)
#>  evaluate      0.24.0  2024-06-10 [1] CRAN (R 4.4.0)
#>  fastmap       1.2.0   2024-05-15 [1] CRAN (R 4.4.0)
#>  fs            1.6.4   2024-04-25 [1] CRAN (R 4.4.0)
#>  glue          1.7.0   2024-01-09 [1] CRAN (R 4.4.0)
#>  htmltools     0.5.8.1 2024-04-04 [1] CRAN (R 4.4.0)
#>  knitr         1.48    2024-07-07 [1] CRAN (R 4.4.0)
#>  lifecycle     1.0.4   2023-11-07 [1] CRAN (R 4.4.0)
#>  reprex        2.1.1   2024-07-06 [1] CRAN (R 4.4.0)
#>  rlang         1.1.4   2024-06-04 [1] CRAN (R 4.4.0)
#>  rmarkdown     2.27    2024-05-17 [1] CRAN (R 4.4.0)
#>  rstudioapi    0.16.0  2024-03-24 [1] CRAN (R 4.4.0)
#>  sessioninfo   1.2.2   2021-12-06 [1] CRAN (R 4.4.0)
#>  withr         3.0.0   2024-01-16 [1] CRAN (R 4.4.0)
#>  xfun          0.46    2024-07-18 [1] CRAN (R 4.4.0)
#>  yaml          2.3.10  2024-07-26 [1] CRAN (R 4.4.0)
#> 
#>  [1] /Library/Frameworks/R.framework/Versions/4.4-x86_64/Resources/library
#> 
#> ──────────────────────────────────────────────────────────────────────────────
2 Likes

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.