[-- Attachment #1: Type: text/plain, Size: 334 bytes --] Hello, I would like to report a bug: during typing, all content below the current line disappeared. The content was unrecoverable with "undo". Have you seen this before? The .org file before content corruption was about 1.5MB. GNU Emacs 26.3 macOS 10.15.7 Please let me know if I can provide more info. Best regards, Dmitry [-- Attachment #2: Type: text/html, Size: 1933 bytes --]
On Tuesday, 9 Feb 2021 at 11:57, Dmitry Knyaginin wrote:
> during typing, all content below the current line disappeared.
> The content was unrecoverable with "undo".
:-(
You can type C-h l at any time to see all your recent keystrokes, in
case it was something you mis-typed to lead to this outcome.
Check to see if you have a backup of the file: Emacs, by default, will
copy the original contents to filename~, i.e. adding a ~ to the end of
the file name. Well, at least on Linux it does; not sure about macOS...
--
: Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-213-g49364f
[-- Attachment #1: Type: text/plain, Size: 1548 bytes --] Hi Eric, I have tried the regular means to recover the latest data, but eventually had to recover from the latest git commit. This incident sounds similar: https://emacs.stackexchange.com/questions/44659/help-emacs-empty-my-1-year-org-file I have some wild theories, including a gamma particle hitting my laptop ;) But: I do not know what emacs does under the hood in the org mode. For instance, the text below my cursor at the time of accident was about 1MB. As you type in org mode, the text below the cursor would have to be "shifted down". Maybe there is something in that operation, combined with the fact that the amount of text was relatively large... like I said, just some wild theories. Anyways, I hope that nobody else experiences this, and if they do, then we would be able to collect bug reports and figure out a fix. Best regards, Dmitry On Thu, Feb 11, 2021 at 5:24 PM Eric S Fraga <e.fraga@ucl.ac.uk> wrote: > On Tuesday, 9 Feb 2021 at 11:57, Dmitry Knyaginin wrote: > > during typing, all content below the current line disappeared. > > The content was unrecoverable with "undo". > > :-( > > You can type C-h l at any time to see all your recent keystrokes, in > case it was something you mis-typed to lead to this outcome. > > Check to see if you have a backup of the file: Emacs, by default, will > copy the original contents to filename~, i.e. adding a ~ to the end of > the file name. Well, at least on Linux it does; not sure about macOS... > > -- > : Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-213-g49364f > [-- Attachment #2: Type: text/html, Size: 2256 bytes --]
On Friday, 12 Feb 2021 at 11:29, Dmitry Knyaginin wrote:
> I have some wild theories, including a gamma particle hitting my laptop ;)
Something I saw on the emacs developer list: if you invoke a special
mode while visting a file not intended for that mode, it is possible for
contents to be deleted and no undo information kept. I don't have more
details than this unfortunately. Luckily, I've never run into this but,
then again, I don't usually invoke a mode switching command explicitly.
I'm glad you could get some (all?) of what you lost from git. Another
data point pushing everybody to use version control systems!
--
: Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-213-g49364f
[-- Attachment #1: Type: text/plain, Size: 1375 bytes --] > > if you invoke a special mode while visting a file not intended for that > mode sound interesting to test... in my case the file has been in org mode from the beginning, and to be honest I am unsure I understand "not intended for that mode". I mean, if I visit plain text files, I guess it does not matter which mode I invoke, right? About git -- totally. It's just that unexplained bugs add to the paranoia feeling. By the way, I have started to test my theory that the bug has to do with the file size, but so far I have not been able to reproduce the bug. / Dmitry On Mon, Feb 15, 2021 at 12:36 PM Eric S Fraga <e.fraga@ucl.ac.uk> wrote: > On Friday, 12 Feb 2021 at 11:29, Dmitry Knyaginin wrote: > > I have some wild theories, including a gamma particle hitting my laptop > ;) > > Something I saw on the emacs developer list: if you invoke a special > mode while visting a file not intended for that mode, it is possible for > contents to be deleted and no undo information kept. I don't have more > details than this unfortunately. Luckily, I've never run into this but, > then again, I don't usually invoke a mode switching command explicitly. > > I'm glad you could get some (all?) of what you lost from git. Another > data point pushing everybody to use version control systems! > > -- > : Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-213-g49364f > [-- Attachment #2: Type: text/html, Size: 2042 bytes --]
Dmitry Knyaginin <d.knyaginin@gmail.com> writes:
> By the way, I have started to test my theory that the bug has to do with
> the file size, but so far I have not been able to reproduce the bug.
Another guess about your case: I have experienced deleted parts of
buffer and lost history when using undo-tree. Do you happen to use it?
Best,
Ihor
On Monday, 15 Feb 2021 at 13:21, Dmitry Knyaginin wrote:
> the beginning, and to be honest I am unsure I understand "not intended for
> that mode". I mean, if I visit plain text files, I guess it does not matter
> which mode I invoke, right?
There are some modes that expect buffers to have specific content
(e.g. think dired-mode or gnus-summary-mode etc.) and it may be that
*some* may inadvertently throw away anything that doesn't fit their
world view... These are modes that will typically be invoked by another
command, not by the user directly. As I said, it was a throwaway
comment I saw on the Emacs developer list.
--
: Eric S Fraga via Emacs 28.0.50, Org release_9.4.4-213-g49364f
[-- Attachment #1: Type: text/plain, Size: 500 bytes --] Hi Ihor, No, I am not using undo-tree. Thanks, Dmitry On Mon, Feb 15, 2021 at 1:41 PM Ihor Radchenko <yantar92@gmail.com> wrote: > Dmitry Knyaginin <d.knyaginin@gmail.com> writes: > > > By the way, I have started to test my theory that the bug has to do with > > the file size, but so far I have not been able to reproduce the bug. > > Another guess about your case: I have experienced deleted parts of > buffer and lost history when using undo-tree. Do you happen to use it? > > Best, > Ihor > [-- Attachment #2: Type: text/html, Size: 998 bytes --]