Python 模块运行但在 aptana 中显示 "Syntax error while detecting tuple"

Python module runs but shows "Syntax error while detecting tuple" in aptana

我正在学习 python,当我 运行 下面的代码时

print("X",end='awesome')

代码运行但显示以下语法错误

"Syntax error while detecting tuple"

我该如何解决?

A​​ptana 设置为对 Python 2.x 使用语法检查,其中 print 是一个语句。它识别这个语句就好像你正在尝试打印一个元组,这就是 Python 2.x 中的内容,并正确地指出你不能有一个 = 符号在元组里面。但是代码是为 Python 3.x 编写的,其中 print 是函数调用并且此语法有效。

您需要设置 Aptana 以使用 Python3 语法。我发现 this page 向您展示了如何设置 Aptana 以使用 Python 3.x 解释器(自脚本运行以来您可能已经有了)和语法。