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

404 error when import a junit xml test report to JIRA - Xray

Ami Gao
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 16, 2024

Hi guys,

I am trying to import/upload junit xml test report and want it is attached to a XRAY JIRA ticket. However, I am getting error:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<status>
<status-code>404</status-code>
</status>

my curl is :

--header 'Authorization: Basic [xxxxxxxxx]'
--form 'file=@"/automation_test.xml"'

Does anyone met the same issue?

Thanks,
Ami Gao

3 answers

Suggest an answer

Log in or Sign up to answer
0 votes
Francisco Fonseca _Xray_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 26, 2024

Hi @Ami Gao ,

Welcome to the community!

I'm from Xray and to be able to assist you with it, I would recommend you to contact our support here.

They can help you evaluate the request as it seems the XML format might a a character before the opening tag "<".

Best, Francisco

0 votes
Nicolas Grossi
Banned
June 16, 2024

@Ami Gao Welcome! The uri appears to be wrong try another one for example up to import section https://xxxxx.atlassian.net/rest/raven/1.0/import

 

HTH

Nicolas

Ami Gao
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 17, 2024

Hi Nicolas,

Thanks for the assistance. Since our company use XRAY DC, I was using wrong api to send the request. But now I get another problem 

{
"error": "Invalid xml file: Non-whitespace before first tag. Line: 0 Column: 1 Char: -"
}
Do you have any thought about what should I do?

Thanks,
Ami 
Like Nicolas Grossi likes this
Stefan Salzl
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 2, 2024

@Ami Gao 

could you check file encoding of your xml file? see the following community post dealing with a similar behaviour:

https://community.atlassian.com/t5/Jira-questions/cURL-returns-quot-error-quot-quot-Invalid-xml-file-Non/qaq-p/2225118

Best
Stefan

DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events