bihealth/sodar-server

Upgrade to altamISA v0.3.0

Closed this issue · 2 comments

What it says on the tin. The release is here.

To fully support this release we also need to support importing, exporting and editing performer and factor value fields as lists. The alternative would be to prohibit importing them as lists, but that would be pretty much the same amount of work.

Tasks

  • Upgrade dependency
  • Add support for newlines in error messages
  • Fix breaking changes (see comments)
  • Add browser/editor support for performer and contact fields as list (#1789)
  • Add browser/editor support for factor value as list (#1789)
  • Add browser/editor support for comment as list (#1789)
  • Update tests where applicable
  • Update docs

Some failed tests, will see about fixing these issues tomorrow:

======================================================================
ERROR: test_import_multi_val (samplesheets.tests.test_io.TestSampleSheetIOImport)
Test _import_multi_val()
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_io.py", line 386, in test_import_multi_val
    'name': in_data.name,
AttributeError: 'list' object has no attribute 'name'

======================================================================
FAIL: test_isa_export_batch (samplesheets.tests.test_io.TestSampleSheetIOBatch)
Test ISA-Tab export in batch
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_io.py", line 215, in test_isa_export_batch
    sheet_io.export_isa(investigation)
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/io.py", line 1390, in export_isa
    StudyValidator(
  File "/opt/hostedtoolcache/Python/3.9.20/x64/lib/python3.9/site-packages/altamisa/isatab/validate_assay_study.py", line 439, in validate
    self._validate_materials()
  File "/opt/hostedtoolcache/Python/3.9.20/x64/lib/python3.9/site-packages/altamisa/isatab/validate_assay_study.py", line 449, in _validate_materials
    validator.validate(m)
  File "/opt/hostedtoolcache/Python/3.9.20/x64/lib/python3.9/site-packages/altamisa/isatab/validate_assay_study.py", line 80, in validate
    self._validate_material_annotations(material)
  File "/opt/hostedtoolcache/Python/3.9.20/x64/lib/python3.9/site-packages/altamisa/isatab/validate_assay_study.py", line 99, in _validate_material_annotations
    any_fact = any([any(has_content(v) for v in fact.value) for fact in material.factor_values])
  File "/opt/hostedtoolcache/Python/3.9.20/x64/lib/python3.9/site-packages/altamisa/isatab/validate_assay_study.py", line 99, in <listcomp>
    any_fact = any([any(has_content(v) for v in fact.value) for fact in material.factor_values])
TypeError: 'OntologyTermRef' object is not iterable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_io.py", line 218, in test_isa_export_batch
    return self.fail_isa(zip_name, ex)
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_io.py", line 143, in fail_isa
    self.fail('Exception in {}: {}'.format(zip_name, ex))
AssertionError: Exception in BII-I-1_edited.zip: 'OntologyTermRef' object is not iterable

======================================================================
FAIL: test_import_ref_val (samplesheets.tests.test_io.TestSampleSheetIOImport)
Test _import_ref_val()
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_io.py", line 356, in test_import_ref_val
    self.assertEqual(out_data, in_data)
AssertionError: None != ['200']

======================================================================
FAIL: test_sync_task (samplesheets.tests.test_tasks_celery_taskflow.TestSheetRemoteSyncTask)
Test sync
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/sodar-server/sodar-server/samplesheets/tests/test_tasks_celery_taskflow.py", line 197, in test_sync_task
    self.assertEqual(data_target, data_source)
AssertionError: {'ass[640 chars]sv': "Source Name\tCharacteristics[organism]\t[5065 chars]xt'}} != {'ass[640 chars]sv': 'Source Name\tCharacteristics[organism]\t[4980 chars]xt'}}
Diff is 13514 characters long. Set self.maxDiff to None to see it.

Done.