Hi @mikeudin, thanks for reaching out us.
With regard to your request, although it's not expected it to work inside the Cinema 4D Script Manager you can get it properly working using the c4dpy executable (here's the 20.059 compatible version[URL-REMOVED]) as much as you do on the Python Shell or on SublimeText console as you can see from the log below.
$ more test.py import inspect # Save this code as script py-file and start def main(): code = inspect.getsource(main_new) # place function code to str variable print code # print code text. Works on Python Shell, but not in C4D Scripts Manager def main_new(): # This is a comment # New comment string # Change this code, to check the console output pass if __name__ == '__main__': main() $ ./c4dpy.app/Contents/MacOS/c4dpy test.py def main_new(): # This is a comment # New comment string # Change this code, to check the console output pass $Best, Riccardo
[URL-REMOVED] @maxon: This section contained a non-resolving link which has been removed.