Animation and Rigging Tools: FAQ, Known Issues and Feature Roadmap

Not sure which post this was pulled from, but as the error states, newName is never defined anywhere. It’s likely the script had something beforehand that defined newName. maybe try adding this to the beginning:

newName = cmds.file(q = True, sceneName = True)