emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: imymorror wang <jagger.wangzg.2019@gmail.com>
To: Ihor Radchenko <yantar92@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: [BUG] when open a large org file, emacs get stuck and show a warning "org-element--cache: Unregistered buffer modifications detected"
Date: Thu, 19 May 2022 17:58:37 +0800	[thread overview]
Message-ID: <CAGVe7232mWLgpi8Ro3a_70xA5ru_Kusyf5PaHhLndZTeyROVJQ@mail.gmail.com> (raw)
In-Reply-To: <87k0ajxuj1.fsf@localhost>

[-- Attachment #1: Type: text/plain, Size: 11305 bytes --]

sorry. I sent a false message yesterday。I try again today. even upgrade to Org
mode version 9.5.3 (9.5.3-g277897), The problem still exists. But I find
out something new。you can see my *conclusion*. And I send all my emacs org
state.

 - desktop environment
   - GNU Emacs 29.0.50 (build 2, x86_64-apple-darwin20.4.0, NS
appkit-2022.44 Version 11.3.1 (Build 20E241)) of 2022-01-08
   - Org mode version 9.5.3 (9.5.3-g277897)
 - bug description
   - influence factor
     - a large org file : 11053 lines。1092 headlines。
     - (setq org-startup-folded t)
     - org-indent-mode : (add-hook 'org-mode-hook 'org-indent-mode)
   - My Observation
     - if setting org-startup-folded t , enable org-indent-mode, open the
large org file, emacs get stuck, the mouse can't move。
     - if keeping org-startup-folded defaul value(i.e  "showeverything") ,
enable org-indent-mode , open the large org file, get a warning, but not
get stuck:
       #+begin_quote
       Warning (org-element-cache): org-element--cache: Unregistered buffer
modifications detected. Resetting.
       If this warning appears regularly, please report it to Org mode
mailing list (M-x org-submit-bug-report).
       #+end_quote
     - if keeping org-startup-folded defaul value and disable
org-indent-mode , open the large org file, everything works fine.
     - if setting org-startup-folded t, disable org-indent-mode, everything
works fine.
 - conclusion
   - enalbe org-indent-mode cause the warning : "Warning
(org-element-cache): org-element--cache: Unregistered buffer modifications
detected."
   - setting org-startup-folded t, enable org-indent-mode. Having both
causes emacs get stuck.
   - In addition,it's not accurate to say that emacs get stuck. To be
precise, emacs get stuck, the mouse can't move for a few seconds and then
it works find.

----------------------------------------
----------------------------------------
----------------------------------------
----------------------------------------
-----------------------------------------------



Emacs  : GNU Emacs 29.0.50 (build 2, x86_64-apple-darwin20.4.0, NS
appkit-2022.44 Version 11.3.1 (Build 20E241))
 of 2022-01-08
Package: Org mode version 9.5.3 (9.5.3-g277897 @
/Users/fuhongxue/env/emacs/vanilla/straight/straight/build/org/)

current state:
==============
(setq
 org-roam-db-location
"~/central-management-system/zotero/roam-db/2022-03-13-daily-based.db"
 org-link-elisp-confirm-function 'yes-or-no-p
 org-hide-emphasis-markers t
 org-bibtex-headline-format-function #[257 "\300 \236A\207" [:title] 3
"\n\n(fn ENTRY)"]
 org-download-file-format-function 'org-download-file-format-default
 org-roam-dailies-capture-templates '(("d" "default" entry "* %<%Y-%m-%d
%H:%M> %?" :if-new
      (file+head "%<%Y-%m-%d>.org" "#+title: %<%Y-%m-%d>\n#+filetags:
:daily:\n"))
     )
 org-startup-folded t
 org-roam-node-display-template "${tags:35} ${title:80}"
 org-persist-after-read-hook '(org-element--cache-persist-after-read)
 org-export-before-parsing-hook '(org-attach-expand-links)
 org-cycle-tab-first-hook '(org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
 org-tag-alist '(("review" . 114) ("summary" . 115) ("case" . 99) ("book" .
98) ("economics" . 101) ("refile" . 114) ("twitter" . 116) ("youtube" . 121)
("emacs" . 101) ("weibo" . 119) ("how" . 104))
 org-roam-find-file-hook '(org-roam-buffer--setup-redisplay-h
org-roam--register-completion-functions-h
org-roam--replace-roam-links-on-save-h
  org-roam-db-autosync--setup-update-on-save-h)
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-footnote-auto-adjust t
 org-odt-format-inlinetask-function
'org-odt-format-inlinetask-default-function
 org-ascii-format-drawer-function #[771 " \207" [] 4 "\n\n(fn NAME CONTENTS
WIDTH)"]
 org-cycle-hook '(org-cycle-hide-archived-subtrees
org-cycle-show-empty-lines
org-cycle-optimize-window-after-visibility-change)
 org-persist-before-read-hook '(org-element--cache-persist-before-read)
 org-font-lock-set-keywords-hook '(doom-themes-enable-org-fontification)
 org-image-actual-width nil
 org-mode-hook '(rasmus/org-prettify-symbols org-fragtog-mode
org-indent-mode valign-mode
#[0 "\300\301\302\303\304$\207" [add-hook change-major-mode-hook
org-fold-show-all append local] 5]
#[0 "\300\301\302\303\304$\207" [add-hook change-major-mode-hook
org-babel-show-result-all append local] 5] org-babel-result-hide-spec
org-babel-hide-all-hashes)
 org-roam-ref-annotation-function 'org-roam-ref-read--annotation
 org-roam-directory
"~/central-management-system/zotero/notes/2022-03-13-daily-based"
 org-latex-format-drawer-function #[514 "\207" [] 3 "\n\n(fn _ CONTENTS)"]
 org-download-timestamp "%Y%m%d-%H%M%S_"
 org-roam-db-node-include-function #[0 "\300\207" [t] 1]
 org-download-abbreviate-filename-function 'file-relative-name
 org-latex-format-headline-function
'org-latex-format-headline-default-function
 org-confirm-shell-link-function 'yes-or-no-p
 org-download-annotate-function '(closure (t) (_link) "")
 org-html-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
 outline-isearch-open-invisible-function 'outline-isearch-open-invisible
 org-roam-dailies-directory
"~/central-management-system/zotero/notes/2022-05-10-theme/daily"
 org-latex-classes '(("org-plain-latex"
"\\documentclass{article}[102pt,letterpaper]\n    \\tolerance=1000\n
 [NO-DEFAULT-PACKAGES]\n    [EXTRA]"
     ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" .
"\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}")
     ("\\paragraph{%s}" . "\\paragraph*{%s}") ("\\subparagraph{%s}" .
"\\subparagraph*{%s}"))
    ("article" "\\documentclass[11pt]{article}" ("\\section{%s}" .
"\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}")
     ("\\subsubsection{%s}" . "\\subsubsection*{%s}") ("\\paragraph{%s}" .
"\\paragraph*{%s}")
     ("\\subparagraph{%s}" . "\\subparagraph*{%s}"))
    ("report" "\\documentclass[11pt]{report}" ("\\part{%s}" .
"\\part*{%s}") ("\\chapter{%s}" . "\\chapter*{%s}")
     ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" .
"\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))
    ("book" "\\documentclass[11pt]{book}" ("\\part{%s}" . "\\part*{%s}")
("\\chapter{%s}" . "\\chapter*{%s}")
     ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" .
"\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))
    )
 org-odt-format-headline-function 'org-odt-format-headline-default-function
 org-roam-capture-preface-hook '(org-roam-dailies--override-capture-time-h
org-roam-capture--try-capture-to-ref-h)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-capture-prepare-finalize-hook '(org-roam-capture--install-finalize-h)
 org-roam-preview-function 'org-roam-preview-default-function
 org-src-mode-hook '(doom-modeline-set-org-src-modeline
org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer)
 org-confirm-elisp-link-function 'yes-or-no-p
 org-latex-src-block-backend t
 org-log-buffer-setup-hook '(org-roam-log--setup)
 org-roam-capture-new-node-hook '(org-roam-capture--insert-captured-ref-h)
 org-preview-latex-image-directory "/Users/fuhongxue/env/emacs/cache/"
 org-speed-command-hook '(org-speed-command-activate
org-babel-speed-command-activate)
 org-html-format-inlinetask-function
'org-html-format-inlinetask-default-function
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-odt-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
 org-fold-core-isearch-open-function 'org-fold--isearch-reveal
 org-preview-latex-default-process 'dvisvgm
 org-latex-format-inlinetask-function
'org-latex-format-inlinetask-default-function
 org-persist-before-write-hook '(org-element--cache-persist-before-write)
 org-tab-first-hook '(org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
 org-link-shell-confirm-function 'yes-or-no-p
 org-babel-pre-tangle-hook '(save-buffer)
 org-agenda-loop-over-headlines-in-active-region nil
 org-cycle-include-plain-lists 'integrate
 org-occur-hook '(org-first-headline-recenter)
 org-roam-log-setup-hook '(org-roam--register-completion-functions-h)
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-roam-node-annotation-function 'org-roam-node-read--annotation
 org-link-parameters '(("eww" :follow org-eww-open :store
org-eww-store-link) ("rmail" :follow org-rmail-open :store
org-rmail-store-link)
      ("mhe" :follow org-mhe-open :store org-mhe-store-link)
      ("irc" :follow org-irc-visit :store org-irc-store-link :export
org-irc-export)
      ("info" :follow org-info-open :export org-info-export :store
org-info-store-link)
      ("gnus" :follow org-gnus-open :store org-gnus-store-link)
      ("docview" :follow org-docview-open :export org-docview-export :store
org-docview-store-link)
      ("bibtex" :follow org-bibtex-open :store org-bibtex-store-link)
      ("bbdb" :follow org-bbdb-open :export org-bbdb-export :complete
org-bbdb-complete-link :store org-bbdb-store-link)
      ("w3m" :store org-w3m-store-link) ("doi" :follow org-link-doi-open
:export org-link-doi-export)
      ("roam" :follow org-roam-link-follow-link) ("attachment" :follow
org-attach-follow :complete org-attach-complete-link)
      ("id" :follow org-roam-id-open) ("file+sys") ("file+emacs") ("shell"
:follow org-link--open-shell)
      ("news" :follow #[514 "\301\300\302 Q \"\207" ["news" browse-url ":"]
6 "\n\n(fn URL ARG)"])
      ("mailto" :follow #[514 "\301\300\302 Q \"\207" ["mailto" browse-url
":"] 6 "\n\n(fn URL ARG)"])
      ("https" :follow #[514 "\301\300\302 Q \"\207" ["https" browse-url
":"] 6 "\n\n(fn URL ARG)"])
      ("http" :follow #[514 "\301\300\302 Q \"\207" ["http" browse-url ":"]
6 "\n\n(fn URL ARG)"])
      ("ftp" :follow #[514 "\301\300\302 Q \"\207" ["ftp" browse-url ":"] 6
"\n\n(fn URL ARG)"])
      ("help" :follow org-link--open-help :store org-link--store-help)
("file" :complete org-link-complete-file)
      ("elisp" :follow org-link--open-elisp))
 org-roam-ui-browser-function 'browse-url
 org-html-format-headline-function
'org-html-format-headline-default-function
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-download-heading-lvl nil
 org-download-link-format-function
'org-download-link-format-function-default
 org-link-frame-setup '((file . find-file))
 org-download-image-dir "images/"
 org-roam-indirect-buffer-hook '(org-roam--register-completion-functions-h)
 )

Ihor Radchenko <yantar92@gmail.com> 于2022年5月18日周三 13:45写道:

> imymorror wang <jagger.wangzg.2019@gmail.com> writes:
>
> >> *Can you please share the exact output of M-x org-version?If you really
> >> see 9.5.1, then you likely have a "mixed" Org installationwith some
> code in
> >> your init file first loading built-in Org mode andthen loading the newer
> >> version. Such state can cause all kinds of bugs.*
> >
> >
> > You are right. When I  Update Org to the latest version *Org mode version
> > 9.5.3 (9.5.3-g277897)* .  The bug is gone。
>
> Sharing this to the mailing list (it was not in CC).
>
> Best,
> Ihor
>

[-- Attachment #2: Type: text/html, Size: 15382 bytes --]

  reply	other threads:[~2022-05-21  6:18 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-16 22:59 [BUG] when open a large org file, emacs get stuck and show a warning "org-element--cache: Unregistered buffer modifications detected" imymorror wang
2022-05-17 16:38 ` William Denton
2022-05-18  3:14   ` Ihor Radchenko
2022-05-18  3:10 ` Ihor Radchenko
     [not found]   ` <CAGVe721ckg9U=NSy87TigYQ6SQcKd6zwg4h30LgmqDb6m-uWog@mail.gmail.com>
2022-05-18  5:46     ` Ihor Radchenko
2022-05-19  9:58       ` imymorror wang [this message]
2022-05-20  7:55         ` Ihor Radchenko
     [not found]           ` <CAGVe723h4bBCZsH95=JpQ3gjxGKfT8R0whU6=QvBGybR+Bb7Hw@mail.gmail.com>
     [not found]             ` <87leuv3bzt.fsf@localhost>
2022-05-21  3:58               ` Fwd: " imymorror wang
2022-05-21  4:11                 ` imymorror wang
2022-05-21  4:38                 ` Fwd: " Ihor Radchenko
2022-05-21  7:09                   ` imymorror wang
2022-05-21  7:26                   ` imymorror wang
2022-05-21  7:49                     ` Ihor Radchenko
2022-07-18  0:20                       ` Ihor Radchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAGVe7232mWLgpi8Ro3a_70xA5ru_Kusyf5PaHhLndZTeyROVJQ@mail.gmail.com \
    --to=jagger.wangzg.2019@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=yantar92@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).