ddbj / submission-excel2xml

Tools for XML submission
Apache License 2.0
5 stars 3 forks source link

Errors in the validation #1

Open tkasukawa opened 4 years ago

tkasukawa commented 4 years ago

When running validate_dra_meta.rb via docker, the following errors are shown:

== XML validation against SRA xsd ==
warning: failed to load external entity "SRA.submission.xsd"
Schemas parser error : Failed to locate the main schema resource at 'SRA.submission.xsd'.
WXS schema SRA.submission.xsd failed to compile
warning: failed to load external entity "SRA.experiment.xsd"
Schemas parser error : Failed to locate the main schema resource at 'SRA.experiment.xsd'.
WXS schema SRA.experiment.xsd failed to compile
warning: failed to load external entity "SRA.run.xsd"
Schemas parser error : Failed to locate the main schema resource at 'SRA.run.xsd'.
WXS schema SRA.run.xsd failed to compile

I'm afraid that the XSD files are not copied to a docker image.

komstat commented 4 years ago

It was not reproduced in my environment. Please enter full path in "/path_to_excel_directory" and try again. sudo docker run -v /path_to_excel_directory:/data -w /data excel2xml validate_dra_meta.rb -a example -i 0001

tkasukawa commented 3 years ago

It was reproduced in my environment. According to the code of validate_dra_meta.db,

result = system("xmllint --schema SRA.submission.xsd --noout #{submission_id}_Submission.xml")

xsd files should be located in the same directory of XML files. When I copied the XSD files to the directory with XML files, the validation can work.

I guess the the filenames of XSD files should be rewritten with a correct path.

komstat commented 3 years ago

Please git clone submission-excel2xml, set your XML and XSD files directly under the submission-excel2xml directory and run the command. The README was modified to emphasize these points.