eva-sub-cli 0.5.1__tar.gz → 0.5.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. {eva_sub_cli-0.5.1/eva_sub_cli.egg-info → eva_sub_cli-0.5.3}/PKG-INFO +1 -1
  2. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docker/Dockerfile +3 -1
  3. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docs/how_to_submit.md +5 -13
  4. eva_sub_cli-0.5.3/docs/input_file_overview.md +115 -0
  5. eva_sub_cli-0.5.3/docs/validation_overview.md +103 -0
  6. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/_version.py +3 -3
  7. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/eva_schema.json +4 -1
  8. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/check_fasta_insdc.py +15 -5
  9. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/cli.py +0 -22
  10. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/fasta_check.html +8 -2
  11. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/report.html +2 -0
  12. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/fasta_check.txt +5 -1
  13. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/nextflow/validation.nf +2 -1
  14. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/orchestrator.py +82 -60
  15. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/validators/docker_validator.py +18 -21
  16. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/validators/native_validator.py +3 -8
  17. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/validators/validator.py +38 -10
  18. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3/eva_sub_cli.egg-info}/PKG-INFO +1 -1
  19. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli.egg-info/SOURCES.txt +9 -4
  20. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test.json +2 -1
  21. eva_sub_cli-0.5.3/tests/resources/EVA_Submission_test_with_non_vcf_files.json +152 -0
  22. eva_sub_cli-0.5.3/tests/resources/EVA_Submission_test_with_non_vcf_files.xlsx +0 -0
  23. eva_sub_cli-0.5.1/tests/resources/validation_reports/expected_report_metadata_json.html → eva_sub_cli-0.5.3/tests/resources/validation_reports/expected_metadata_json_report.html +29 -1
  24. eva_sub_cli-0.5.1/tests/resources/validation_reports/expected_report_metadata_json.txt → eva_sub_cli-0.5.3/tests/resources/validation_reports/expected_metadata_json_report.txt +9 -1
  25. eva_sub_cli-0.5.1/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.html → eva_sub_cli-0.5.3/tests/resources/validation_reports/expected_metadata_xlsx_report.html +29 -25
  26. eva_sub_cli-0.5.1/tests/resources/validation_reports/expected_report_metadata_xlsx.txt → eva_sub_cli-0.5.3/tests/resources/validation_reports/expected_metadata_xlsx_report.txt +9 -1
  27. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/expected_report_metadata_json_process_not_run.html +2 -0
  28. eva_sub_cli-0.5.1/tests/resources/validation_reports/expected_report_metadata_xlsx.html → eva_sub_cli-0.5.3/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.html +53 -1
  29. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.txt +9 -1
  30. eva_sub_cli-0.5.3/tests/resources/validation_reports/validation_output/metadata.json +1 -0
  31. eva_sub_cli-0.5.3/tests/resources/validation_reports/validation_output/other_validations/file_info.txt +0 -0
  32. eva_sub_cli-0.5.3/tests/resources/vcf_files/example2.vcf.gz.tbi +0 -0
  33. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_check_fasta_insdc.py +16 -0
  34. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_cli.py +1 -8
  35. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_orchestrator.py +76 -67
  36. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_report.py +43 -187
  37. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_validator.py +5 -2
  38. eva_sub_cli-0.5.1/docs/input_file_overview.md +0 -45
  39. eva_sub_cli-0.5.1/docs/validation_overview.md +0 -79
  40. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/.github/workflows/publish.yml +0 -0
  41. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/.github/workflows/publish_docs.yml +0 -0
  42. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/.github/workflows/tests.yml +0 -0
  43. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/.github/workflows/trigger-eva-sub-cli-integration-tests.yml +0 -0
  44. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/.gitignore +0 -0
  45. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/LICENSE +0 -0
  46. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/README.md +0 -0
  47. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/conda/build.sh +0 -0
  48. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/conda/meta.yaml +0 -0
  49. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docs/README.md +0 -0
  50. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docs/_config.yml +0 -0
  51. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docs/installation.md +0 -0
  52. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/docs/using_nextflow.md +0 -0
  53. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/__init__.py +0 -0
  54. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/auth.py +0 -0
  55. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/date_utils.py +0 -0
  56. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/EVA_Submission_Example.xlsx +0 -0
  57. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/EVA_Submission_template.xlsx +0 -0
  58. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/eva-biosamples.json +0 -0
  59. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/eva_logo.png +0 -0
  60. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/spreadsheet2json_conf.yaml +0 -0
  61. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/etc/spreadsheet2json_conf_V2.yaml +0 -0
  62. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/__init__.py +0 -0
  63. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/invalid_file_type_exception.py +0 -0
  64. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/metadata_template_version_exception.py +0 -0
  65. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/submission_not_found_exception.py +0 -0
  66. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/submission_status_exception.py +0 -0
  67. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/exceptions/submission_upload_exception.py +0 -0
  68. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/__init__.py +0 -0
  69. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/check_metadata_semantics.py +0 -0
  70. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/evidence_type_checker.py +0 -0
  71. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/samples_checker.py +0 -0
  72. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/trim_down.py +0 -0
  73. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/executables/xlsx2json.py +0 -0
  74. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/file_utils.py +0 -0
  75. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/file_validation.html +0 -0
  76. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/metadata_validation.html +0 -0
  77. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/project_details.html +0 -0
  78. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/sample_name_check.html +0 -0
  79. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/html/shallow_validation.html +0 -0
  80. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/file_validation.txt +0 -0
  81. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/metadata_validation.txt +0 -0
  82. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/project_details.txt +0 -0
  83. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/report.txt +0 -0
  84. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/sample_name_check.txt +0 -0
  85. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/jinja_templates/text/shallow_validation.txt +0 -0
  86. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/metadata.py +0 -0
  87. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/report.py +0 -0
  88. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/semantic_metadata.py +0 -0
  89. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/submission_ws.py +0 -0
  90. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/submit.py +0 -0
  91. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/utils.py +0 -0
  92. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/validators/__init__.py +0 -0
  93. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli/validators/validation_results_parsers.py +0 -0
  94. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli.egg-info/dependency_links.txt +0 -0
  95. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli.egg-info/entry_points.txt +0 -0
  96. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli.egg-info/requires.txt +0 -0
  97. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/eva_sub_cli.egg-info/top_level.txt +0 -0
  98. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/pyproject.toml +0 -0
  99. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/pytest.ini +0 -0
  100. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/requirements.txt +0 -0
  101. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/setup.cfg +0 -0
  102. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/setup.py +0 -0
  103. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/build_and_test_docker_locally.py +0 -0
  104. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/ignore_test_nextflow_validation.yml +0 -0
  105. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_Docker_Test.xlsx +0 -0
  106. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test.xlsx +0 -0
  107. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_V2.xlsx +0 -0
  108. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_fails.xlsx +0 -0
  109. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_version_missing.xlsx +0 -0
  110. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_with_asm_report.json +0 -0
  111. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_with_project_accession.json +0 -0
  112. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/EVA_Submission_test_with_project_accession.xlsx +0 -0
  113. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/assembly_check/invalid.vcf.assembly_check.log +0 -0
  114. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/assembly_check/invalid.vcf.text_assembly_report.txt +0 -0
  115. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/assembly_reports/input_passed.txt +0 -0
  116. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/fasta_files/Saccharomyces_cerevisiae_I.fa +0 -0
  117. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/fasta_files/input_passed.fa +0 -0
  118. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/fasta_files/multi_seq.fa +0 -0
  119. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/metadata_with_filename.json +0 -0
  120. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/sample_checker/example1.vcf.gz +0 -0
  121. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/sample_checker/example2.vcf +0 -0
  122. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/sample_checker/example3.vcf +0 -0
  123. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/sample_checker/metadata.json +0 -0
  124. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/expected_report_metadata_json_process_not_run.txt +0 -0
  125. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.assembly_check.log +0 -0
  126. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.text_assembly_report.1680102476700.txt +0 -0
  127. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.valid_assembly_report.1680102476700.txt +0 -0
  128. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/evidence_type_checker.yml +0 -0
  129. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/input_passed.fa_check.yml +0 -0
  130. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/input_passed_trim_down.yml +0 -0
  131. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/metadata_conversion_errors.yml +0 -0
  132. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/metadata_semantic_check.yml +0 -0
  133. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/metadata_validation.txt +0 -0
  134. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/other_validations/sample_checker.yml +0 -0
  135. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.errors.1680102476854.db +0 -0
  136. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.errors.1680102476854.txt +0 -0
  137. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.vcf_format.log +0 -0
  138. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/vcf_files/example2.vcf.gz +0 -0
  139. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/resources/vcf_files/input_passed.vcf +0 -0
  140. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_auth.py +0 -0
  141. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_docker_validator.py +0 -0
  142. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_evidence_type_checker.py +0 -0
  143. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_file_utils.py +0 -0
  144. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_metadata.py +0 -0
  145. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_samples_checker.py +0 -0
  146. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_semantic_metadata.py +0 -0
  147. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_submit.py +0 -0
  148. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_trim_down.py +0 -0
  149. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_utils.py +0 -0
  150. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_validaton_results_parsers.py +0 -0
  151. {eva_sub_cli-0.5.1 → eva_sub_cli-0.5.3}/tests/test_xlsx2json.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eva_sub_cli
3
- Version: 0.5.1
3
+ Version: 0.5.3
4
4
  Summary: EBI EVA - validation and submission command line tool
5
5
  Classifier: Development Status :: 5 - Production/Stable
6
6
  Classifier: Environment :: Console
@@ -6,7 +6,9 @@ ENV NXF_VER=23.10.0
6
6
  WORKDIR /opt
7
7
 
8
8
  # Install JAVA and Node
9
- RUN apt update && apt install -y default-jdk nodejs npm
9
+ RUN apt update && apt install -y default-jdk build-essential \
10
+ && curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
11
+ && apt install -y nodejs
10
12
 
11
13
  # Install VCF validator
12
14
  RUN curl -LJo /usr/local/bin/vcf_validator https://github.com/EBIvariation/vcf-validator/releases/download/v${vcf_validator_version}/vcf_validator_linux \
@@ -70,25 +70,17 @@ To run only a subset of the validation steps, you can use the `--validation_task
70
70
  This can be useful if you want to avoid re-running long-running validations that have already passed.
71
71
  Note that all validation tasks must pass in order to submit. The report will aggregate the results of previous runs and new ones.
72
72
  The possible tasks are:
73
- * `vcf_check` - includes syntax validation and other checks on VCF files
74
- * `assembly_check` - includes all checks involving the FASTA file
75
- * `metadata_check` - includes syntactic and semantic checks on metadata
76
- * `sample_check` - includes sample coherence checks between VCF files and metadata
73
+ * [`vcf_check`](validation_overview.md#vcf-checks) - includes syntax validation and other checks on VCF files
74
+ ${CODE_ROOT}/env/bin/upload_to_gcloud.py --input-file evidence.json.gz --destination-folder pharmacogenomics
75
+ * [`assembly_check`](validation_overview.md#assembly-checks) - includes all checks involving the FASTA file
76
+ * [`metadata_check`](validation_overview.md#metadata-check) - includes syntactic and semantic checks on metadata
77
+ * [`sample_check`](validation_overview.md#sample-name-concordance-check) - includes sample coherence checks between VCF files and metadata
77
78
 
78
79
  For example, to run only `vcf_check` and `sample_check`:
79
80
  ```shell
80
81
  eva-sub-cli.py --metadata_xlsx <metadata file> --submission_dir <submission directory> --validation_tasks vcf_check sample_check
81
82
  ```
82
83
 
83
- ### VCF files and reference FASTA
84
- These can be provided either in the metadata file directly, or on the command line using the `--vcf_files` and
85
- `--reference_fasta` options. Note that if you are using more than one reference FASTA, you **cannot** use the command
86
- line options; you must specify which VCF files use which FASTA files in the metadata.
87
-
88
- VCF files can be either uncompressed or compressed using bgzip.
89
- Other types of compression are not allowed and will result in errors during validation.
90
- FASTA files must be uncompressed.
91
-
92
84
  ### Metadata JSON
93
85
  Frequent submitters may be interested in using our [metadata JSON schema](https://github.com/EBIvariation/eva-sub-cli/blob/main/eva_sub_cli/etc/eva_schema.json)
94
86
  instead of our spreadsheet template. The metadata requirements are the same regardless of which format you use, you will
@@ -0,0 +1,115 @@
1
+ # Overview of Input Files
2
+
3
+ View our [video tutorial on input files](https://embl-ebi.cloud.panopto.eu/Panopto/Pages/Viewer.aspx?id=9284869a-9f57-43c6-8222-b3aa0158941e).
4
+
5
+ The eva-sub-cli tool requires the following inputs:
6
+
7
+ - One or several valid VCF files
8
+ - Reference genome in FASTA format
9
+ - Completed metadata spreadsheet
10
+
11
+ Only the metadata file is passed directly to the CLI tool. The VCF and FASTA files should be referenced from the
12
+ metadata file.
13
+
14
+ In the following sections, we will examine each of these inputs in detail.
15
+
16
+ ## VCF File
17
+
18
+ A VCF (Variant Call Format) file is a type of file used in bioinformatics to store information about genetic variants.
19
+ The EVA requires data files to conform to the official VCF specifications, so that the data can be interpreted
20
+ consistently by other databases and researchers looking to reuse the data. Many tools can be used to generate VCF files,
21
+ including [BCFtools](https://samtools.github.io/bcftools/), [PLINK](https://www.cog-genomics.org/plink/2.0/), and
22
+ [GATK](https://gatk.broadinstitute.org).
23
+
24
+ Besides being compliant with the VCF specification, we also require that each VCF file contains the necessary
25
+ evidence linking the variant to its biological source. This evidence can be in the form of sample genotypes or allele frequencies.
26
+
27
+ Here is an example of how sample genotypes might look like in a VCF file:
28
+ ```
29
+ ##fileformat=VCFv4.2
30
+ ##FORMAT=<ID=GT,Number=1,Type=String,Description="Genotype">
31
+ #CHROM POS ID REF ALT QUAL FILTER INFO FORMAT SAMPLE1 SAMPLE2
32
+ 1 10583 rs58108140 G A 100 PASS . GT 0/1 1/1
33
+ ```
34
+
35
+ And here is how allele frequencies would look:
36
+ ```
37
+ ##fileformat=VCFv4.2
38
+ ##INFO=<ID=AF,Number=A,Type=Float,Description="Allele Frequency">
39
+ #CHROM POS ID REF ALT QUAL FILTER INFO
40
+ 1 10583 rs58108140 G A 100 PASS AF=0.25
41
+ ```
42
+
43
+ When using the eva-sub-cli tool, VCF files can be either uncompressed or compressed using bgzip or gzip.
44
+
45
+ ## FASTA File
46
+
47
+ This is the reference genome that your variants were called against, in uncompressed FASTA format. The EVA uses this to
48
+ check that the reference alleles are set correctly in the VCF files.
49
+
50
+ The sequences of the reference genome must be INSDC-registered, which means they are publicly available in one of the archives within the
51
+ INSDC consortium: [Genbank](https://www.ncbi.nlm.nih.gov/genbank/), [ENA](https://www.ebi.ac.uk/ena/browser/home), or
52
+ [DDBJ](https://www.ddbj.nig.ac.jp/index-e.html). This ensures the long-term availability of the genome and the
53
+ reusability of your variation data.
54
+
55
+ ## Metadata Spreadsheet
56
+
57
+ The metadata spreadsheet provides comprehensive contextual information about the dataset, ensuring that each submission
58
+ is accompanied by detailed descriptions that facilitate proper understanding and use of the data. Key elements included
59
+ in the metadata spreadsheet are analysis and project information, sample information, sequencing methodologies, and
60
+ experimental details. While not all fields are required, users are strongly encouraged to provide as much information
61
+ as possible to enhance the completeness and usefulness of the metadata.
62
+
63
+ The spreadsheet is organized into editable tabs, designed for metadata entry, and non-editable helper tabs, which offer
64
+ detailed explanations and guidance for each column. Users are required to complete all relevant sections within the
65
+ editable tabs. Mandatory fields in each section are indicated in bold to highlight essential information that must be
66
+ provided for a valid submission. Fields highlighted in green indicate an either/or choice. This means you should fill
67
+ in the choice most relevant for your submission, but not both.
68
+
69
+ Below we go through some important details for each of the tabs.
70
+
71
+ ### Submitter Details
72
+
73
+ This sheet captures basic information about the person or team submitting the data. This includes the lab name and
74
+ center, which is the name of the submitting institution or organization and is the name that will be visible once the
75
+ project is live on the EVA website.
76
+
77
+ ### Project
78
+
79
+ The objective of this sheet is to gather general information about the Project. If you are submitting to an existing
80
+ project, you can skip the other details and just provide the project accession; the data in this submission will be
81
+ added as analyses linked to that project. In case of a new project, please provide the relevant details including
82
+ submitter, submitting center, collaborators, project title, description and publications.
83
+
84
+ One important column to note is the Hold Date, which is the date until which the data should be kept private. EVA will
85
+ release the data automatically after this date. If it is missing, the default value is three days after the date of
86
+ submission.
87
+
88
+ ### Analysis
89
+
90
+ For EVA, an analysis is a grouping of samples and data files. This sheet allows us to link VCF files to a project and
91
+ to other EVA analyses. Additionally, this worksheet contains experimental metadata detailing the methodology of each
92
+ analysis. This includes a local path to your reference FASTA file, as described [above](#FASTA-file).
93
+
94
+ One project can have multiple associated analyses. EVA links analyses to samples and VCF files through the analysis
95
+ alias, which is a shortened identifier you must provide for each analysis.
96
+
97
+ ### Sample
98
+
99
+ This is where you describe the biological samples used for your analyses. Each row describes one sample and must include
100
+ the Analysis Alias to indicate which analysis it belongs to, and "Sample Name in VCF" which is the exact name of the
101
+ sample as it appears in the VCF file.
102
+
103
+ We accept preregistered samples, which should be provided using BioSamples sample or sampleset accessions. Please
104
+ ensure these are publicly accessible, as otherwise EVA will not be able to validate them.
105
+
106
+ If your samples are not yet accessioned, and are therefore novel, please use the "Novel sample(s)" sections of the
107
+ Sample worksheet to have them registered at BioSamples. Make sure to fill in the required fields in bold, including the
108
+ BioSample name, title, taxonomy ID, geographic location (chosen from the controlled vocabulary in the drop-down menu),
109
+ and collection date (in YYYY-MM-DD format).
110
+
111
+ ### Files
112
+
113
+ This sheet lists the VCF files in your submission. These should be provided as local paths within your system, so that
114
+ the CLI tool can locate them, along with the Analysis Alias which should be associated with each file. Each file should
115
+ be linked to exactly one analysis.
@@ -0,0 +1,103 @@
1
+ # Overview of Validation Checks
2
+
3
+ The CLI tool performs the following validation checks and generates corresponding reports:
4
+
5
+ - Metadata check to ensure that the metadata fields have been correctly filled in
6
+ - VCF check to ensure that the VCF file follows the VCF format specification
7
+ - Assembly check to ensure that the genome and the VCF match
8
+ - Sample name check to ensure that the samples in the metadata can be associated with the samples in the VCF
9
+
10
+ In the following sections, we will examine each of these checks in detail.
11
+
12
+ ## Metadata Check
13
+
14
+ Once the user passes the metadata spreadsheet for validation checks, the eva-sub-cli tool verifies that all mandatory columns, marked in bold in the spreadsheet, are filled in.
15
+ This data is crucial for further validation processes, such as retrieving the INDSC accession of the reference genome used to call the variants, and for sample and project metadata.
16
+
17
+ Each tab in the spreadsheet has an associated help tab, which provides detailed instructions on how to fill in your metadata correctly.
18
+ If any mandatory columns or sheets are missing, the CLI tool will raise errors.
19
+
20
+ Key points to note before validating your metadata spreadsheet with the eva-sub-cli tool:
21
+
22
+ - Please do not change the existing structure of the spreadsheet.
23
+ - Ensure all mandatory columns (marked in bold) are filled.
24
+ - Columns marked in green indicate an either/or requirement, so only one of the sections should be filled in.
25
+ - Any pre-registered projects and samples must be released and not kept in private status.
26
+ - Sample names in the spreadsheet must match those in the VCF file.
27
+ - Analysis aliases must match across the sheets (Analysis, Sample, and File sheets).
28
+ - Use the Hold Date field in the Project sheet for data that needs to be kept under embargo.
29
+
30
+ Common errors seen with metadata checks:
31
+
32
+ - Analysis alias is not filled in for the respective samples in the Sample tab.
33
+ - Reference field in the Analysis tab is not filled with an INSDC accession. Submitters should not use a non-GCA accession or generic assembly name as their reference genome.
34
+ - Taxonomy ID and the scientific name of the organism do not match for novel samples.
35
+ - Collection date and geographic location of the samples are not filled in for novel samples.
36
+ - Date fields do not follow the YYYY-MM-DD format.
37
+ - Custom values are used for controlled vocabulary fields (indicated with a drop-down menu). Submitters should select from the values provided or contact us if the required value is not present.
38
+
39
+ Most issues around metadata will be reported in the "Metadata validation results" section of the validation report.
40
+ However, note that other validation failures may also require you to modify your metadata file.
41
+
42
+ ## VCF Checks
43
+
44
+ Ensuring data consistency upon submission is crucial for interoperability and supporting cross-study comparative genomics.
45
+ Before accepting a VCF submission, the CLI tool verifies that the submitted information adheres to the official VCF specifications.
46
+ Additionally, submitted variants must be supported by either experimentally determined sample genotypes or population allele frequencies.
47
+
48
+ Key points to note before validating your VCF file with the eva-sub-cli tool:
49
+
50
+ - File Format Version: Always start the header with the VCF version number (versions 4.1-4 are accepted).
51
+ - Header Metadata: Should include the reference genome, information fields (INFO), filters (FILTER), AF and genotype metadata
52
+ - Variant Information: VCF files must provide either sample genotypes and/or aggregated sample summary-level allele frequencies.
53
+ - Unique Variants: Variant lines should be unique and not specify duplicate loci.
54
+ - Reference Genome: All variants must be submitted with positions on a reference genome accessioned by a member of the INSDC consortium: [Genbank](https://www.ncbi.nlm.nih.gov/genbank/), [ENA](https://www.ebi.ac.uk/ena/browser/home), or [DDBJ](https://www.ddbj.nig.ac.jp/index-e.html).
55
+
56
+ Common errors seen with VCF checks:
57
+
58
+ - The VCF version is not one of 4.1, 4.2, 4.3, or 4.4.
59
+ - The VCF file contains extra spaces, blanks, or extra quotations causing validation to fail. Tools like bcftools can help verify the header before validating the file.
60
+ - GT and AF fields are not defined in the header section.
61
+ - The fields used do not conform to the official VCF specifications.
62
+
63
+ Issues in VCF format validation will be reported in the "VCF validation results" section of the validation report.
64
+ Issues in determining evidence type (genotypes or allele frequencies) are reported per analysis at the top of the report.
65
+
66
+ ## Assembly Checks
67
+
68
+ The EVA requires that all variants be submitted with an asserted position on an INSDC sequence.
69
+ This means that the reference allele for every variant must match a position in a sequence that has been accessioned in the GenBank, ENA, or DDBJ databases.
70
+ Aligning all submitted data with INSDC sequences enables integration with other EMBL-EBI resources, including Ensembl, and is crucial for maintaining standardisation at the EVA.
71
+ This also means that all sequence identifiers in your VCF must match those in the reference FASTA file.
72
+
73
+ Key points to note before validating your data with the eva-sub-cli tool:
74
+
75
+ - Ensure that the reference sequences in the FASTA file used to call the variants are accessioned in INSDC.
76
+ - Verify that the contig names in the VCF file match those in the FASTA file.
77
+
78
+ Common errors seen with assembly checks:
79
+
80
+ - VCF file uses contig name not found in the FASTA file, causing the assembly check to fail.
81
+ - Major Allele Used as REF Allele: This typically occurs when a specific version of Plink or Tassel is used to create VCF files, causing the tool to use the major allele as the reference allele. In such cases, submitters should use the GCA FASTA sequence to create corrected files.
82
+
83
+ Issues around reference allele matching in VCF files will be reported in the "VCF validation results" section of the validation report,
84
+ while issues around INSDC accessioning of the assembly will be reported in the "Reference genome INSDC check" section.
85
+
86
+ ## Sample Name Concordance Check
87
+
88
+ The sample name concordance check ensures that the sample names in the metadata spreadsheet match those in the VCF file.
89
+ This is achieved by cross-checking the "Sample name in VCF" column in the spreadsheet with the sample names registered in the VCF file.
90
+ Any discrepancies must be addressed by the submitter when the CLI tool generates a report of the mismatches found.
91
+
92
+ Key points to note before validating your data with the eva-sub-cli tool:
93
+
94
+ - Ensure that sample names between the VCF file and the metadata spreadsheet match. This comparison is case-sensitive.
95
+ - Ensure there are no extra spaces in the sample names.
96
+
97
+ Common errors seen with sample concordance checks:
98
+
99
+ - Link between "Sample" and "File" provided via the Analysis alias is not correctly defined in the metadata which causes the sample name concordance check to fail.
100
+ - Extra white spaces in the sample names can lead to mismatches.
101
+ - Case sensitivity issues between the sample names in the VCF file and the metadata spreadsheet.
102
+
103
+ Issues in sample name concordance will be reported in the "Sample name concordance check" section of the validation report.
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
28
28
  commit_id: COMMIT_ID
29
29
  __commit_id__: COMMIT_ID
30
30
 
31
- __version__ = version = '0.5.1'
32
- __version_tuple__ = version_tuple = (0, 5, 1)
31
+ __version__ = version = '0.5.3'
32
+ __version_tuple__ = version_tuple = (0, 5, 3)
33
33
 
34
- __commit_id__ = commit_id = 'g8a5f488cb'
34
+ __commit_id__ = commit_id = 'gc81081e35'
@@ -106,7 +106,10 @@
106
106
  },
107
107
  "publications": {
108
108
  "type": "array",
109
- "items": true
109
+ "items": {
110
+ "type": "string",
111
+ "pattern": "^[^:,]+?:[^:,]+?$"
112
+ }
110
113
  },
111
114
  "parentProject": {
112
115
  "$ref": "#/definitions/projectAccession"
@@ -54,6 +54,11 @@ def _get_containing_assemblies_paged(url):
54
54
 
55
55
 
56
56
  def get_containing_assemblies(md5_digest):
57
+ """
58
+ Return the INSDC accessions of assemblies in contig alias containing the sequence with the provided md5 digest.
59
+ :param md5_digest: md5 digest of the sequence to query
60
+ :return: set of INSDC accessions
61
+ """
57
62
  # Wrapper method to handle pagination
58
63
  url = f'{CONTIG_ALIAS_SERVER}/{md5_digest}'
59
64
  return _get_containing_assemblies_paged(url)
@@ -89,7 +94,7 @@ def assess_fasta(input_fasta, analyses, assembly_in_metadata):
89
94
  elif len(possible_assemblies) == 0:
90
95
  possible_assemblies = containing_assemblies
91
96
  else:
92
- possible_assemblies &= containing_assemblies
97
+ possible_assemblies = possible_assemblies.intersection(containing_assemblies)
93
98
  except Exception as e:
94
99
  # Server errors from either ENA refget or EVA contig alias will halt the check prematurely.
95
100
  # Report the error but do not return from the method, so that incomplete results can be reported
@@ -127,11 +132,15 @@ def get_analyses_and_reference_genome_from_metadata(vcf_files_for_fasta, json_fi
127
132
  else:
128
133
  all_analyses.add(analysis_aliases[0])
129
134
  # Get (single) assembly associated with these analyses
130
- assemblies = [metadata.get_reference_assembly_for_analysis(analysis) for analysis in all_analyses]
135
+ assemblies = {metadata.get_reference_assembly_for_analysis(analysis) for analysis in all_analyses}
131
136
  if len(assemblies) != 1:
132
137
  logger.error(f'Could not determine assembly accession to check against fasta file, out of: {assemblies}')
133
138
  return all_analyses, None
134
- return all_analyses, assemblies[0]
139
+ return all_analyses, assemblies.pop()
140
+
141
+
142
+ def check_assembly_in_metadata(assembly_in_metadata):
143
+ return assembly_in_metadata and assembly_in_metadata.upper().startswith('GCA')
135
144
 
136
145
 
137
146
  def main():
@@ -147,6 +156,7 @@ def main():
147
156
  help='Path to the location of the results')
148
157
  args = arg_parser.parse_args()
149
158
  logging_config.add_stdout_handler()
150
- analyses, metadata_insdc = get_analyses_and_reference_genome_from_metadata(args.vcf_files, args.metadata_json)
151
- results = assess_fasta(args.input_fasta, analyses, metadata_insdc)
159
+ analyses, assembly_in_metadata = get_analyses_and_reference_genome_from_metadata(args.vcf_files, args.metadata_json)
160
+ results = assess_fasta(args.input_fasta, analyses, assembly_in_metadata)
161
+ results['metadata_assembly_gca'] = check_assembly_in_metadata(assembly_in_metadata)
152
162
  write_result_yaml(args.output_yaml, results)
@@ -26,20 +26,6 @@ from eva_sub_cli.validators.validator import ALL_VALIDATION_TASKS
26
26
 
27
27
  def validate_command_line_arguments(args, argparser):
28
28
  fail = False
29
- if (args.vcf_files and not args.reference_fasta) or (not args.vcf_files and args.reference_fasta):
30
- print("When using --vcf_files and --reference_fasta, both need to be specified")
31
- fail = True
32
-
33
- if args.vcf_files:
34
- for vcf_file in args.vcf_files:
35
- if not os.path.isfile(vcf_file):
36
- print(f"VCF file {vcf_file} is not a file")
37
- fail = True
38
-
39
- if args.reference_fasta:
40
- if not os.path.isfile(args.reference_fasta):
41
- print(f"Fasta file {args.reference_fasta} is not a file")
42
- fail = True
43
29
 
44
30
  if args.metadata_xlsx:
45
31
  if not os.path.isfile(args.metadata_xlsx):
@@ -77,14 +63,6 @@ def parse_args(cmd_line_args):
77
63
  argparser.add_argument('--version', action='version', version=f'%(prog)s {eva_sub_cli.__version__}')
78
64
  argparser.add_argument('--submission_dir', required=True, type=str,
79
65
  help='Path to the directory where all processing is done and submission info is stored')
80
- vcf_group = argparser.add_argument_group(
81
- 'Input VCF and assembly',
82
- "Specify the VCF files and associated assembly with the following options. If you used different assemblies "
83
- "for different VCF files, then you must include these in the metadata file rather than specifying them here."
84
- )
85
- vcf_group.add_argument('--vcf_files', nargs='+', help="One or more VCF files to validate")
86
- vcf_group.add_argument('--reference_fasta',
87
- help="The FASTA file containing the reference genome from which the variants were derived")
88
66
 
89
67
  metadata_group = argparser.add_argument_group('Metadata', 'Specify the metadata in a spreadsheet or in a JSON file')
90
68
  metadata_group = metadata_group.add_mutually_exclusive_group(required=True)
@@ -9,6 +9,12 @@
9
9
  <br><strong>Error message:</strong> {{ results_for_fasta.get('connection_error') }}
10
10
  </div>
11
11
  {% endif %}
12
+ {% if 'metadata_assembly_compatible' in results_for_fasta and not results_for_fasta.get('metadata_assembly_gca') %}
13
+ <div class="report-section fail">
14
+ <strong>Warning:</strong> Non-GCA reference found in metadata. Please provide the INSDC accession for your reference assembly.
15
+ If you would like to submit using a non-GCA reference sequence, contact <a href="mailto:eva-helpdesk@ebi.ac.uk">eva-helpdesk@ebi.ac.uk</a>.
16
+ </div>
17
+ {% endif %}
12
18
 
13
19
  <!-- All INSDC check results -->
14
20
  {% set expand_icon = "" %}
@@ -52,8 +58,8 @@
52
58
  {% set text = analysis_text + ": Assembly accession in metadata is compatible" %}
53
59
  {% else %}
54
60
  {% set expand_icon = "&#9654;" %}
55
- {% set icon = "&#10060;" %}
56
- {% set row_class = "report-section fail collapsible" %}
61
+ {% set icon = "&#10071;" %}
62
+ {% set row_class = "report-section warn collapsible" %}
57
63
  {% set text = analysis_text + ": Assembly accession in metadata is not compatible" %}
58
64
  {% endif %}
59
65
  {% else %}
@@ -31,12 +31,14 @@
31
31
 
32
32
  .report-section { padding: 12px; border: 1px solid white; margin-bottom: 5px}
33
33
  .active, .collapsible:hover.fail { background-color: #e6a3ae; }
34
+ .active, .collapsible:hover.warn { background-color: #e6de7c; }
34
35
  .active, .collapsible:hover.info { background-color: #c0c0c0; }
35
36
 
36
37
  table { border-collapse: collapse; padding: 10px; margin-bottom: 20px}
37
38
  th, td { border: 1px solid black; padding: 8px; text-align: left; }
38
39
  th { background-color: lightgrey; }
39
40
  .fail { background-color: #FFB6C1; }
41
+ .warn { background-color: #f5ed7f; }
40
42
  .pass { background-color: #90EE90; }
41
43
  .info { background-color: #dadada; }
42
44
  .error-list, .no-show { display: none; }
@@ -7,6 +7,10 @@
7
7
  Please try again later for complete results.
8
8
  Error message: {{ results_for_fasta.get('connection_error') }}
9
9
  {% endif %}
10
+ {% if 'metadata_assembly_compatible' in results_for_fasta and not results_for_fasta.get('metadata_assembly_gca') %}
11
+ Warning: Non-GCA reference found in metadata. Please provide the INSDC accession for your reference assembly.
12
+ If you would like to submit using a non-GCA reference sequence, contact eva-helpdesk@ebi.ac.uk.
13
+ {% endif %}
10
14
 
11
15
  {% if results_for_fasta.get('all_insdc') %}
12
16
  {{ "\u2714" }} All sequences are INSDC accessioned.
@@ -28,7 +32,7 @@
28
32
  {% set icon = "\u2714" %}
29
33
  {% set text = analysis_text + ": Assembly accession in metadata is compatible" %}
30
34
  {% else %}
31
- {% set icon = "\u274C" %}
35
+ {% set icon = "\u2757" %}
32
36
  {% set text = analysis_text + ": Assembly accession in metadata is not compatible" %}
33
37
  {% endif %}
34
38
  {% else %}
@@ -213,7 +213,8 @@ process generate_file_size_and_md5_digests {
213
213
  script:
214
214
  // Capture the realpath of the vcf to be able to resolve the file based on path instead of name
215
215
  """
216
- echo "\$(md5sum $vcf_file | awk '{print \$1}') \$(stat -c%s \$(readlink -f $vcf_file)) \$(readlink -f $vcf_file)" > ${vcf_file}_file_size_and_digest_info.txt
216
+ set -eo pipefail
217
+ echo "\$(md5sum $vcf_file | awk '{print \$1}') \$(stat -c%s \$(readlink -f $vcf_file)) \$(readlink -f $vcf_file)" > ${vcf_file}_file_size_and_digest_info.txt
217
218
  """
218
219
  }
219
220