我有jira,我尝试在工作流jython脚本上执行。 我已成功将它们添加到步骤(在我的情况下为“开始”)并保存。 但是之后我在jira点击了这个按钮时出现了错误:
root cause: Traceback (most recent call last):
File "/var/atlassian/application-data/jira/jss/jython/__init_interpreter__.py", line 6, in <module> codecs.setDefaultEncoding('utf-8')
LookupError: no codec search functions registered: can't find encoding 'utf-8'
It seems that you have tried to perform an illegal workflow operation. If you think this message is wrong, please contact your JIRA administrators.
请帮助:有init_interpreter.py:
# -*- coding: UTF-8 -*-
import sys
if sys.getdefaultencoding() != 'utf-8':
from org.python.core import codecs
codecs.setDefaultEncoding('utf-8')
from com.quisapps.jira.plugin.workflow import JythonFileUtil
path = JythonFileUtil.getInstance().getJythonPath()
if path not in sys.path:
sys.path.append(path)
from com.quisapps.jira.jss.jython import JythonUtil
path = JythonUtil.getJythonPath()
if path not in sys.path:
sys.path.append(path)
并且我尝试执行我的新脚本:
summary = parameters['summary'][0]
if summary.find('OMG')=>0:
result=False
description = u'Ururu'
invaild_fields['summary'] = description
我在插件 - 脚本套件部分尝试了“重新安装所有内容”,但它没有帮助。
如果需要,catalina.out
中也有错误答案 0 :(得分:2)
尝试重新安装jython。从官方网站获取.jar
文件:http://www.jython.org/downloads.html
答案 1 :(得分:0)
尝试重新安装 Jira脚本套件:
如果无法解决,请重新安装 JIRA脚本套件插件