Python 解释器 Jython - 模块的执行

Python Interpreter Jython - execution of modules

这是问题的 link:

以下是一个可能的解决方案:

    interp.exec("import os.path.abspath(__file__)/printTwice.py)");
    interp.exec("printTwice.print_twice('Adam')");

但是返回错误:

这返回了以下错误:线程异常 "main" SyntaxError: ("mismatched input '(' expecting NEWLINE", ('', 1, 22, 'import os.path.abspath(file)/printTwice.py)\n'))

interp.exec("import printTwice");
interp.exec("printTwice.print_twice('Adam')");

这应该有效。