Field 'Environment' cannot be set. It is not on the appropriate screen, or unknown.

Family Organizer April 27, 2015

I've been trying this . Please help.

I'm able to see this field in my 'Create issue' Screen . 

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

Do you have more than one "environment" field?  

Go into the list of custom fields and see if you have "environment" listed there.  If you do, rename it slightly so you can tell it apart from the system one - then you'll be able to see which field is required and which you have on screen.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

What's this "issueBuilder"? I can't help you without the context you're trying to do this in.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

That's not a call I recognise in the API - again, could you explain the context in which you are coding?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

I'm afraid I am not being clear. IssueBuilder is not a JIRA API call. You have not given us the context where you are running this. I have no idea what you think you are doing because the code is nonsense, it's not JIRA code.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

Ok, crossed over comments there. Which JIRA REST Client are you using?

Family Organizer April 27, 2015

jira-rest-java-client-2.0.0-m2

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

There are lots of clients out there that use REST, I'm still not sure which one it is.

Family Organizer April 27, 2015

ira-rest-java-client-2.0.0-m2.. Sorry what do you mean by clients. can you please elaborate. ?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 27, 2015

A REST Client could be any program that interacts with JIRA via REST. I've got three on this laptop, two written by colleagues and a third myself (although mine is a really simple bash script). I don't know what client you are talking about here.

Family Organizer April 27, 2015

atlassian.jira.rest.client

Family Organizer April 28, 2015

Hi Nic, can you help on this ?

Family Organizer April 28, 2015

1.I'm using jira-rest-java-client-2.0.0-m2.jar 2.I'm not using any http get/post. I'm connecting to the Jira like below. JiraRestClient restClient = factory.createWithBasicHttpAuthentication(jiraServerUri, Username,Password()); private IssueRestClient issueClient =restClient.getIssueClient(); IssueInputBuilder issueBuilder = new IssueInputBuilder(ProjectKey, TargetType,Summary ); issueBuilder.setDescription(sourceIssue.getDescription()); IssueInput issueInput = issueBuilder.build(); BasicIssue basic = issueClient.createIssue(issueInput).claim(); newIssue = issueClient.getIssue(basic.getKey()).claim(); This above code in Java is successful when I'm creating issue of type 'Story' as it is not having the Environment field. With above code, I am trying to create a issue of type 'Bug' which needs 'Environment' as a mandatory field. So I'm not seeing any system defined method for Environment like we've for Description SetDescription("Descvalue"); 3. 'Environment' is a system field and as per our Jira requirement it is made as mandatory field. 4. Error message : 'Environment is required to create issue' --- meaning is it is mandatory field.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 29, 2015

Ah, ok. I don't know the JRJC well enough to be sure - I've avoided it because all it seems to do is add an extra layer of unnecessary complexity on top of the plain REST calls which work fine. My understanding is that the JRJC doesn't support get/set of Environment yet.

TAGS
AUG Leaders

Atlassian Community Events