Page MenuHome

Autosave is postponed by 10 seconds when a modal operator is running
Closed, ResolvedPublicDESIGN

Description

System Information
Operating system: Windows-10-10.0.18362-SP0 64 Bits
Graphics card: AMD Radeon RX 5700 XT ATI Technologies Inc. 4.5.13596 Core Profile Context 20.5.1 27.20.1017.1011

Blender Version
Broken: version: 2.83.0, branch: master, commit date: 2020-06-03 14:38, hash: rB211b6c29f771
Worked: (newest version of Blender that worked as expected)

Short description of error
Blender does not auto save every minute as directed..
From the user's point of view this appears to be a random interval.


Exact steps for others to reproduce the error

  1. change preference of time interval of save to 1 minute.
  2. save preferences
  3. close blender
  4. reload blender
  5. delete scene
  6. add cube
  7. save file as save test.blend
  8. enter sculpt mode on cube
  9. enable dyno topo
  10. sculpt on cube for 10 minutes
  11. notice that there are not 10 auto saves in the specified directory.
  12. notice that there is only one.

Related Objects

Event Timeline

The blender interface needs to update. If blender is minimized, for example, it does not automatically save.
This report does not contain all the requested information, which is required for us to investigate the issue.
It's missing:

  • Steps to reproduce the bug.

A guideline for making a good bug report can be found at https://wiki.blender.org/wiki/Process/Bug_Reports

Why would you just assume the bug report is invalid. Rude. I'ts not invalid and now blender is going to be stuck with this bug because someone wanted to get some quick forum points or something.. this place is worse then stack exchange for people who are not part of the "system"

Tasha Upchurch (TashaSkyUp) changed the task status from Invalid to Resolved.Tue, Jun 16, 7:46 PM

Steps to reproduce:

  1. change preference of time interval of save to 1 minute.
  2. save preferences
  3. close blender
  4. reload blender
  5. delete scene
  6. add cube
  7. save file as save test.blend
  8. enter sculpt mode on cube
  9. enable dyno topo
  10. sculpt on cube for 10 minutes
  11. notice that there are not 10 auto saves in the specified directory.
  12. notice that there is only one.
  13. take a chance and report bug
  14. be rejected

And this system we are on has no way for me to contact you directly so I have no idea if you will notice the changes to the report in order to set it to valid or whatever. Meaning I will have to go through the entire process of reporting the bug again.. This is a bad system.

@Tasha Upchurch (TashaSkyUp) Closing the bug report as invalid doesn't mean that we don't believe that there is an issue. It was closed because the report was missing steps to reproduce the problem. Without these steps it can be very difficult to identify the source of the issue and develop a patch. Therefore, it is in your own interest to provide all information that are requested in the submission template. Developers only have a limited time to deal with all reports, which is why incomplete ones will be closed.

Robert Guetzkow (rjg) reopened this task as Needs Triage.Tue, Jun 16, 7:59 PM
Robert Guetzkow (rjg) removed Tasha Upchurch (TashaSkyUp) as the assignee of this task.

Why would you just assume the bug report is invalid. Rude. I'ts not invalid and now blender is going to be stuck with this bug because someone wanted to get some quick forum points or something.. this place is worse then stack exchange for people who are not part of the "system"

Sorry for the inconvenience, there are dozens of reports open every day and this one was closed for two reasons:

  • At first glance it doesn't seem to be a bug (it's normal not to save in exactly 1 minute. And it wouldn't be efficient to autosave without need)
  • Fits the "Should Close Task Scenarios:" of the Triaging_Playbook

I forgot to add this text in the comment:

Please submit a new report and carefully follow the instructions. Be sure to provide system information, Blender version, the last Blender version which worked, and a .blend file with exact steps to reproduce the problem.

Now looking at the image, I could see that the autosave intervals are less than 1 minute. I'll have a look to see what happens.

Now looking at the image, I could see that the autosave intervals are less than 1 minute. I'll have a look to see what happens.

I mistook hours for minutes. Autosave never runs before a minute apart.

Looking at the code I found this comment:

/* if a modal operator is running, don't autosave, but try again in 10 seconds */

It seems that this decision to wait 10 seconds if a modal operator is being executed, (as when using a brush), is a bad decision.
I'll see if I can improve this, but I still have doubts if this report should be confirmed as a bug.

https://developer.blender.org/diffusion/B/browse/master/source/blender/windowmanager/intern/wm_files.c$1606

You know what. Your right, saving while sculpting may create a hiccup on most systems and would be an undesirable behavior. I suppose "Auto save while sculpting" could be a feature request.. we can spend hours in sculpt mode... and crash while in it and loose the work.

Germano Cavalcante (mano-wii) renamed this task from Blender does not auto save using the correct interval to Autosave is postponed by 10 seconds when a modal operator is running.Tue, Jun 16, 9:14 PM
Germano Cavalcante (mano-wii) changed the task status from Needs Triage to Confirmed.
Germano Cavalcante (mano-wii) updated the task description. (Show Details)
Germano Cavalcante (mano-wii) changed the subtype of this task from "Report" to "Design".Tue, Jun 16, 9:16 PM

This behavior was implemented more than 10 years ago in rBcb8f7fd3

  • Autosave is postponed by 10 seconds when a modal operator is running, e.g. transform or file browsing.

@Brecht Van Lommel (brecht), sorry back to this, I can imagine what led to that decision, but in my opinion the ideal thing would be to run the autosave the moment the modal operator concludes.
I investigated the code, maybe we can add a global flag to run the autosave in wm_handler_operator_call, but I don’t know if it’s that so simple.

I think it's quite possible for someone to work on sculpt for an hour in a row to miss all 10 second intervals between modal operators in the meantime.
We could skip the navigation modal at least.

@Germano Cavalcante (mano-wii), yes, it would make sense to run auto save right after the last modal operator ends. Or maybe simpler is to temporarily set the timer interval to 10ms or so.

I think it's rather unlikely that you would sculpt an hour and miss all 10s intervals, but we should do better here..

@Germano Cavalcante (mano-wii) & @Brecht Van Lommel (brecht) Don't know if this is relevant here, but I remember there was a bug or discussion about never ending modal operators and autosave a while back (I think the blenderkit addon uses one).