Hi, the Project Specific Select Field REST API uses access URL as in example http://localhost:2990/rest/projectspecificselectfield/1.0/customfield/FCTA/customfield_10400
But the jira-phyton function find() to "Find Resource object for any addressable resource on the server" extends path to
http://localhost:2990/rest/api/2/projectspecificselectfield/1.0/customfield/FCTA/customfield_10400
(/api/2/ inserted) which does not match the required URL. Any hint to resolve this ? Many thanks, Jens-Uwe
Looking at the source code for the jira-python library (link), it looks like the url path for api calls is constructed using some default values for rest_path and rest_api_version provided by the JIRA class.
From the code:
class JIRA(object):
...
DEFAULT_OPTIONS = {
"server": "http://localhost:2990/jira",
"auth_url": '/rest/auth/1/session',
"context_path": "/",
"rest_path": "api",
"rest_api_version": "2",
"agile_rest_path": GreenHopperResource.GREENHOPPER_REST_PATH,
"agile_rest_api_version": "1.0",
"verify": True,
"resilient": True,
"async": False,
"client_cert": None,
"check_update": False,
Without modifying the codebase the only workaround I can think of would be to provide values for those two options so that the URL is constructed properly.
Example:
import jira.client
from jira.client import JIRA
jira_options={'server': 'http://localhost:2990/jira','rest_path': 'projectspecificselectfield','rest_api_version':'1.0'}
jira=JIRA(options=jira_options,basic_auth=('admin','password'))
* Remainder of your code*
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.