Experience-Monks / ae-to-json

will export an After Effects project as a JSON object
MIT License
237 stars 26 forks source link

Script execution error inside of After Effects: self is undefined #17

Open DavidQL opened 6 years ago

DavidQL commented 6 years ago

I am running the example from the Readme:

var aeToJSON = require('ae-to-json/after-effects');
var ae = require('after-effects');

ae.default.execute(aeToJSON)
.then(function(json) {
  // do something with the json outout
})
.catch(function(e) {
  throw e;
});

And this is the output:

(node:36935) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): AfterEffectsScriptError: Script execution error inside of After Effects: self is undefined
(node:36935) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Any ideas on this?

tinogithub commented 2 years ago

I am getting the same error. However it worked the first time but then just got continuesly errors. I read in another post that it might have something to do with waiting for the response of After Effects. However, isn't this already a asynchronous function and should work? I am on Windows, After Effects 2020 and 2021.

Any new solutions?