Copy link to clipboard
Copied
I'm guessing the only way to really do this is to turn off Auto Recover in Preferences. But is there a way to launch Animate so it won't try and use recovery files? This is for an automated tool.
Note if I have to disable auto recovery, I will. Just trying to understand what the options are.
Hi,
There is no JSFL command to avoid/ignore the file recovery dialog when Animate is launched.
However, this is the file that keeps track of autorecovery files:
C:\Users\<username>\AppData\Local\Adobe\Animate CC 2018\en_US\Configuration\AutoRecoverFilenames
Modifying/deleting this through your script should help.
Copy link to clipboard
Copied
The recovery file should only appear as an option if you have opened an FLA, made changes, then a crash happens before the file is saved. Is your automated tool able to continue running during an application or machine crash?
You could turn off auto recovery, or just set the time to something that is longer than the time your automated routines need to do their thing.
Copy link to clipboard
Copied
Colin, thanks for the reply.
As you probably know, Animate can be a bit unstable. I'd say any given day, it crashes on my 10+ times daily. And that is being conservative.
My automated tool can continue as it is a combination of python and jsfl. All it will know really is that the jsfl "job" never finished. I have a sanity timer which waits for a known output file to be written. The problem is it will try and queue the next "job". And when Animate re-opens, a dialog box regarding recovery files will show up, stopping any further processing.
One of the problems with the way flash works is that it can mark files as dirty even though you haven't touched them. For example, we use AuthortimeSharedAssets files. So those almost always mark the file as dirty. Even though the AST file has not been saved and the FLA in question has been saved at a later date that the AST (so you'd think it would be up to date).
The automated tools run both remotely (where it is fine to set the auto recovery off) and on local machines for validating files.
Copy link to clipboard
Copied
Hi,
There is no JSFL command to avoid/ignore the file recovery dialog when Animate is launched.
However, this is the file that keeps track of autorecovery files:
C:\Users\<username>\AppData\Local\Adobe\Animate CC 2018\en_US\Configuration\AutoRecoverFilenames
Modifying/deleting this through your script should help.
Copy link to clipboard
Copied
Thanks so much. This will do the trick. I'm actually on a Mac, but for references for others:
Copy link to clipboard
Copied
As I mostly launch my JSFL from Python, I was able to have a reasonable work around.
ANIMATE_APP_RECOVER_FILENAME_LIST = "~/Library/Application Support/Adobe/Animate CC 2018/en_US/Configuration/AutoRecoverFilenames.txt"
def full_pa(dir):
return path.abspath(path.expanduser(dir))
def walk_directory_for_recovery_fla_files(dir):
if path.exists(dir):
for f in listdir(full_path(dir)):
full = path.join(dir, f)
if path.isdir(full):
walk_directory_for_recovery_fla_files(full)
elif f.startswith('RECOVER_') and f.endswith('.fla'):
logger.info("Removing recovery file {}".format(full))
os.remove(full)
def remove_animate_recovery_files(root):
with open(full_path(ANIMATE_APP_RECOVER_FILENAME_LIST), 'w'):
logger.info("Clearing Animate's auto recovery filename list...")
walk_directory_for_recovery_fla_files(root)
You can replace logger.info with print. root is the directory which will contain your recovery files. I use this to also clean out the recovery files.
I updated the link above. On the Mac, there is an auto recovery file that keeps a list of the recovery files.
RECOVER_* files are actually not cleaned up by Animate (regardless if you use or "discard" using the recovery file when you start the app)