In scripts, when importing a project with a JSON data file asset, , AE throws a modal warning dialog with the following message:
After Effects warning: The structure of the data file for the layer "scores.json" has changed
The dialog triggers regardless of the file not having changed since saving and furthermore it halts all scripting as the dialog does not respect app.suppressDialogs(), even from aerender.exe.
jenkmeister • Adobe Employee, Jun 05, 2024Jun 05, 2024
Thanks for reporting this and linking over to the other bug. I've created a bug internally to further discuss why we have this dialog and if we can get rid of it.
Thanks for reporting this and linking over to the other bug. I've created a bug internally to further discuss why we have this dialog and if we can get rid of it.
For anyone concerned - the workaround for this is to _only_ have the json as footage in your project, and _not_ add it as a layer anywhere. This avoids triggering the parsing for the properties tree that show up when JSON is presented as a layer. However this means that you have to reference your JSON from footage rather than pickwhipping from the properties tree of a JSON layer.
var brands = footage("brands.json").sourceData;
brands[whatBrand+1].name;
If you want to export as a mogrt or reduce your project, you will need to include the layer in your comp, or the json file will be omitted from the mogrt.