Impossible to import issues in a JSON file from Github API

Marion Carré February 5, 2021

I exported issues from a Github repository as a JSON file to import them on Jira with the JSON import assistant but

 

first I had the following error : 

 

"There was a problem validating the json file. The fields [] are not valid." 

 

Then I removed the [] at the beginning and the end of the file, the import worked successfully but nothing was imported : 

 

2021-02-05 15:46:25,022 INFO - Import started by ug:0d45aec9-ede5-4b07-866c-586152ee3536 using com.atlassian.jira.plugins.importer.sample.SampleDataBean
2021-02-05 15:46:25,062 INFO - ------------------------------
2021-02-05 15:46:25,063 INFO - Importing: Users
2021-02-05 15:46:25,063 INFO - ------------------------------
2021-02-05 15:46:25,063 INFO - Only new items will be imported
2021-02-05 15:46:25,069 INFO - 0 users associated with import. All of them imported as inactive, this can be changed after import in User Access step.
2021-02-05 15:46:25,069 INFO - ------------------------------
2021-02-05 15:46:25,069 INFO - Finished Importing : Users
2021-02-05 15:46:25,069 INFO - ------------------------------
2021-02-05 15:46:25,070 INFO - 0 users successfully created.
2021-02-05 15:46:25,073 INFO - Retrieving projects...
2021-02-05 15:46:25,091 INFO - ------------------------------
2021-02-05 15:46:25,091 INFO - Importing: Issues
2021-02-05 15:46:25,091 INFO - ------------------------------
2021-02-05 15:46:25,091 INFO - Only new items will be imported
2021-02-05 15:46:25,099 INFO - 0 issues successfully created
2021-02-05 15:46:25,102 INFO - ------------------------------
2021-02-05 15:46:25,102 INFO - Finished Importing : Issues
2021-02-05 15:46:25,102 INFO - ------------------------------
2021-02-05 15:46:25,112 INFO - ------------------------------
2021-02-05 15:46:25,112 INFO - Importing: Issue Links & Subtasks
2021-02-05 15:46:25,112 INFO - ------------------------------
2021-02-05 15:46:25,112 INFO - Only new items will be imported
2021-02-05 15:46:25,116 INFO - ------------------------------
2021-02-05 15:46:25,116 INFO - Finished Importing : Issue Links & Subtasks
2021-02-05 15:46:25,116 INFO - ------------------------------
2021-02-05 15:46:25,117 INFO - ------------------------------
2021-02-05 15:46:25,117 INFO - Importing: Issue remote links
2021-02-05 15:46:25,117 INFO - ------------------------------
2021-02-05 15:46:25,117 INFO - Only new items will be imported
2021-02-05 15:46:25,121 INFO - ------------------------------
2021-02-05 15:46:25,121 INFO - Finished Importing : Issue remote links
2021-02-05 15:46:25,121 INFO - ------------------------------

 

Can you help me ?  

2 answers

0 votes
Marion Carré February 8, 2021

Thanks ! Do you think this could also work to import issues and not users ? 

Mahad Uddin December 13, 2023

@Marion Carré Did you ever figure this out? I would really like some assistance on this!!

0 votes
Rami February 5, 2021

We had a similar issue.

We had to create an JSON object to feed it to the importer... It just didn't work with simple json data.

We fixed it by :

 

List<Users> list = getUsers();
String inputUserList = new ObjectMapper().writerWithDefaultPrettyPrinter().writeValueAsString(list);
Mahad Uddin December 13, 2023

How do I go about doing this @Rami ?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events