codemodsquad / asyncify

Don't keep your promises 😉
MIT License
13 stars 6 forks source link

Error: You must pass a scope and parentPath unless traversing a Program/File. Instead of that you tried to traverse a undefined node without passing scope and parentPath. #31

Closed coderaiser closed 3 years ago

coderaiser commented 3 years ago

Got an error using noRecastWorkaround:

Error: You must pass a scope and parentPath unless traversing a Program/File. Instead of that you tried to traverse a undefined node without passing scope and parentPath.
    at traverse (/Users/coderaiser/putout/node_modules/@codemodsquad/asyncify/node_modules/@babel/traverse/lib/index.js:53:13)
    at index (/Users/coderaiser/putout/node_modules/@codemodsquad/asyncify/index.js:24:28)
    at module.exports (/Users/coderaiser/putout/node_modules/@codemodsquad/asyncify/noRecastWorkaround.js:13:28)

The thing is AST located in api.jscodeshift(fileInfo.source).get().value

jedwards1211 commented 3 years ago

whoops, sorry about that

jedwards1211 commented 3 years ago

gahh

jedwards1211 commented 3 years ago

:tada: This PR is included in version 2.2.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket: