Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,556,626
Community Members
 
Community Events
184
Community Groups

JSONObject["name"] not found

When I try to get details about my Jira projects, in the class JsonParseUtil, parseBasicUser method, the code look for the field "name" in the "reporter" group.

But my Json delivered doesn't contains it:

{
"self":"",
"accountId":"",
"emailAddress":"",
"avatarUrls":{
},
"displayName":"",
"active":,
"timeZone":"America\/Sao_Paulo",
"accountType":"atlassian"
}

 There's some update that removed the field?

13 answers

1 accepted

2 votes
Answer accepted

For me issue got fixed by upgrading com.atlassian.jira:jira-rest-java-client-core to 5.2.0

Refer below link for details.

https://issues.jenkins-ci.org/browse/JENKINS-53794

Thanks @Venkata Bellamkonda for the info. So nice of you! We will also upgrade now. 

After upgrading to 5.2.0, the issue got fixed. Thanks!

Thanks for the answer!!

It looks like this fix is also needed for the Perforce P4DTG functionality (it looks like they repackage the above library so it cant just be dropped in).  Any chance Atlassian can contact them to get them to rebuild the tool (last build was in 2018)?

It fails now with a null pointer reference (probably to the missing Name field is my guess since it just started happening at the same time as this and the older P4DTG actually reports

Caused by: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at org.codehaus.jettison.json.JSONObject.get(JSONObject.java:360)

newer p4dtg event viewer output

Faulting application name: p4dtg-repl.exe, version: 2018.1.169.9871, time stamp: 0x5b989296
Faulting module name: p4dtg-repl.exe, version: 2018.1.169.9871, time stamp: 0x5b989296
Exception code: 0xc0000005
Fault offset: 0x00000000000146eb
Faulting process id: 0x19d0
Faulting application start time: 0x01d5ec13fac5a9fd
Faulting application path: C:\Program Files\Perforce\P4DTG 64-bit\p4dtg-repl.exe
Faulting module path: C:\Program Files\Perforce\P4DTG 64-bit\p4dtg-repl.exe
Report Id: 6a539496-b755-4383-9192-6be0d35e9d44
Faulting package full name:
Faulting package-relative application ID:

I am seeing a lot of people having issues with the name tag being removed from the JSON data and the only response from Atlassian being to upgrade to version 5.2. That doesn't help me or the other's using Eclipse and now being unable to use Jira in Eclipse anymore. We PAY for Jira and support of Eclipse seems pretty obvious to me. Can we please get some support for that?

The Atlassian Eclipse connector dates back to 2015 and does not officially support the latest Eclipse versions. I managed to get it to work anyway, only to have it break due to this change. I am not hopeful that Atlassian is going to help here.

They should TOTALLY support Eclipse as it is one of the most common tools used by software engineers. The fact that they don't gives me a very poor opinion of them as a provider of tools for engineers. How much work could it really take to avoid their clients being upset by this?

Same for us. Mylyn Jira connector from eclipse worked well last week. Since yesterday same problems as described above.

Can somebody from Atlassian JIRA development have a look in it and provide a fix (Atlassian cloud as well)?

And i get this: JSONObject["name"] not found from my JIRA connector for Eclipse which worked just fine until yesterday....

com.atlassian.connector.eclipse.internal.jira.core.service.JiraException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.


Atlassian Connector for Eclipse
3.2.5.v20150427

Eclipse
Version: Neon.3 Release (4.6.3)
Build id: 20170314-1500




eclipse.buildId=4.6.3.M20170301-0400
java.version=1.8.0_201
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_GB
Framework arguments: -product org.eclipse.epp.package.javascript.product -product org.eclipse.epp.package.javascript.product -product org.eclipse.epp.package.javascript.product
Command-line arguments: -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.javascript.product -product org.eclipse.epp.package.javascript.product -data file:/C:/Users/willem.mulder/workspace/ -product org.eclipse.epp.package.javascript.product

com.atlassian.connector.eclipse.internal.jira.core
Error
Thu Feb 20 13:46:15 GMT 2020
com.atlassian.connector.eclipse.internal.jira.core.service.JiraException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.

com.atlassian.connector.eclipse.internal.jira.core.service.JiraException: com.atlassian.connector.eclipse.internal.jira.core.service.JiraException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.call(JiraRestClientAdapter.java:790)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.getIssues(JiraRestClientAdapter.java:315)
at com.atlassian.connector.eclipse.internal.jira.core.service.JiraClient.findIssues(JiraClient.java:368)
at com.atlassian.connector.eclipse.internal.jira.core.service.JiraClient.search(JiraClient.java:757)
at com.atlassian.connector.eclipse.internal.jira.core.JiraRepositoryConnector.performQuery(JiraRepositoryConnector.java:140)
at org.eclipse.mylyn.internal.tasks.core.sync.SynchronizeQueriesJob.synchronizeQuery(SynchronizeQueriesJob.java:311)
at org.eclipse.mylyn.internal.tasks.core.sync.SynchronizeQueriesJob.synchronizeQueries(SynchronizeQueriesJob.java:268)
at org.eclipse.mylyn.internal.tasks.core.sync.SynchronizeQueriesJob.run(SynchronizeQueriesJob.java:199)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: com.atlassian.connector.eclipse.internal.jira.core.service.JiraException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.call(JiraRestClientAdapter.java:783)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.getIssue(JiraRestClientAdapter.java:248)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.access$3(JiraRestClientAdapter.java:247)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter$5.call(JiraRestClientAdapter.java:325)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter$5.call(JiraRestClientAdapter.java:1)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.call(JiraRestClientAdapter.java:746)
... 8 more
Caused by: com.atlassian.jira.rest.client.RestClientException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at com.atlassian.jira.rest.client.internal.jersey.AbstractJerseyRestClient.invoke(AbstractJerseyRestClient.java:89)
at com.atlassian.jira.rest.client.internal.jersey.AbstractJerseyRestClient.getAndParse(AbstractJerseyRestClient.java:106)
at com.atlassian.jira.rest.client.internal.jersey.JerseyIssueRestClient.getIssue(JerseyIssueRestClient.java:133)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter$3.call(JiraRestClientAdapter.java:250)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter$3.call(JiraRestClientAdapter.java:1)
at com.atlassian.connector.eclipse.internal.jira.core.service.rest.JiraRestClientAdapter.call(JiraRestClientAdapter.java:746)
... 13 more
Caused by: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at org.codehaus.jettison.json.JSONObject.get(JSONObject.java:360)
at org.codehaus.jettison.json.JSONObject.getString(JSONObject.java:487)
at com.atlassian.jira.rest.client.internal.json.JsonParseUtil.parseBasicUser(JsonParseUtil.java:169)
at com.atlassian.jira.rest.client.internal.json.BasicUserJsonParser.parse(BasicUserJsonParser.java:26)
at com.atlassian.jira.rest.client.internal.json.BasicUserJsonParser.parse(BasicUserJsonParser.java:23)
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.getOptionalField(IssueJsonParser.java:351)
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.parse(IssueJsonParser.java:266)
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.parse(IssueJsonParser.java:90)
at com.atlassian.jira.rest.client.internal.jersey.AbstractJerseyRestClient$1.call(AbstractJerseyRestClient.java:111)
at com.atlassian.jira.rest.client.internal.jersey.AbstractJerseyRestClient.invoke(AbstractJerseyRestClient.java:68)
... 18 more



Edit (duplicated message in topic)

So what is the plan for people who used the Java library published by Atlassian?

(https://mvnrepository.com/artifact/com.atlassian.jira/jira-rest-java-client-core)

Same here with access to cloud version.

Caused by: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at org.codehaus.jettison.json.JSONObject.get(JSONObject.java:405) ~[jettison-1.3.7.jar!/:1.3.7]
at org.codehaus.jettison.json.JSONObject.getString(JSONObject.java:541) ~[jettison-1.3.7.jar!/:1.3.7]
at com.atlassian.jira.rest.client.internal.json.JsonParseUtil.parseBasicUser(JsonParseUtil.java:192) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.UserJsonParser.parse(UserJsonParser.java:34) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.UserJsonParser.parse(UserJsonParser.java:31) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.getOptionalNestedField(IssueJsonParser.java:300) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.parse(IssueJsonParser.java:234) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.IssueJsonParser.parse(IssueJsonParser.java:88) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.GenericJsonArrayParser.parse(GenericJsonArrayParser.java:39) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.SearchResultJsonParser.parse(SearchResultJsonParser.java:40) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.json.SearchResultJsonParser.parse(SearchResultJsonParser.java:27) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.async.AbstractAsynchronousRestClient$1.handle(AbstractAsynchronousRestClient.java:148) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
at com.atlassian.jira.rest.client.internal.async.AbstractAsynchronousRestClient$3.apply(AbstractAsynchronousRestClient.java:189) ~[jira-rest-java-client-core-5.1.6.jar!/:na]
... 15 common frames omitted

I am experiencing the same issue with Smartsheets Jira Connector. Our Jira is cloud hosted. Do I need to ask Smartsheets to make changes to their API??

Hi, I have the same problem since this morning from my jira connector in java application:

com.atlassian.jira.rest.client.api.RestClientException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.
at com.atlassian.jira.rest.client.internal.async.DelegatingPromise.claim(DelegatingPromise.java:45) ~[jira-rest-java-client-core-5.1.6.jar:na]
at com.tims.jira.server.services.JiraServiceImpl.getJiraIssues(JiraServiceImpl.java:583) ~[classes/:na]
at com.tims.jira.server.subtasks.ScheduledConfiguration.lambda$job$0(ScheduledConfiguration.java:73) ~[classes/:na]
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54) ~[spring-context-5.0.10.RELEASE.jar:5.0.10.RELEASE]
at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:93) [spring-context-5.0.10.RELEASE.jar:5.0.10.RELEASE]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_211]

What I can do?

Thanks!

The problem is the same with:

com.atlassian.jira:jira-rest-java-client-core:5.1.6

 Regards

Upgrade 

com.atlassian.jira:jira-rest-java-client-core to 5.2.0

 Refer https://issues.jenkins-ci.org/browse/JENKINS-53794

I have upgraded the version and works fine.

 

Thanks!! 

Our problem here is the Atlassian connector for Mylyn. The version here is "jira-rest-java-client-1.1-ide-m09.jar" - provided I've picked the correct one. Some of the file/class structure in there are similar to the contents of "jira-rest-java-client-core-5.2.0.jar".

In a fit of madness, I copied the core-5.2.0 classes into the 1.1-ide-m09.jar - replacing all classes with the same name. Result: the error "JSONObject["name"] not found" had gone, but the Mylyn connector still wasn't able to get the Jira issues as tasks.

So my question is: Where can we get a operational version of the Mylyn connector to Jira that is based on the JRJC core 5.2.0?

Editing code and fixing the code of the Mylyn connector is unfortunately no option for me.

Like Mike Fechner likes this

Hi, did anybody find a way forward - connecting Eclipse to Jira with task focus etc?

Atlassian provide a solution for their product to work with Eclipse, the most popular development tool? Surely you jest.

@Wayne_Baldwin Hi Wayne, wish I was jesting. A couple of months back the Atlassian Jira Connector for Eclipse stopped working due to this issue: com.atlassian.jira.rest.client.api.RestClientException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.

:(

I was being sarcastic. Read up above back on March 4th or so. Atlassian SHOULD provide a plugin for Eclipse and keep it supported as they keep changing their servers like they just did breaking the only functioning option left.

Like Mike Fechner likes this

@Wayne_Baldwin Sorry, missed that .... So we soldier on and no amount of complaining will get them to do anything right...?

Hello All,

there are any chance to have Eclipse MyLyn working connector?

Like # people like this

+1 for fixing Eclipse Mylyn JIRA connector

Like Mike Fechner likes this

@JIRA Team : Could you please provide the ETA to fix this issue? Our Integrations got broken with JIRA. Any help would be greatly appreciated. Thanks in advance! 

we are using 

com.atlassian.jira:jira-rest-java-client-core:5.1.6

Hi folks,

Our integration functionality also broke yesterday with the same exception -

com.atlassian.jira.rest.client.api.RestClientException: org.codehaus.jettison.json.JSONException: JSONObject["name"] not found.

Can someone from the Atlassian JIRA dev team please fix this at the earliest... Thanks in advance!

Hi,

We make use of the following as well and it is a breaking change for our internal tool.

com.atlassian.jira:jira-rest-java-client-core:5.1.6

We would much rather not have to build our own custom api client for this.

Is there a possible simple fix or workaround for this?

Hi,

I believe this is related to the deprecation of the field name and id - have a look at the below article: 

https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/

We ran into this issue yesterday and have adjusted to use accountId going forward.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events