OCL API 2

Build: #1470 failed Changes by Sunny Aggarwal.

Stages & jobs

  1. Build

  2. Test

  3. Deploy for testing

    Requires a user to start manually
  4. Release

    Requires a user to start manually

Build result summary

Details

Completed
Queue duration
< 1 second
Duration
4 minutes
Labels
None
Revisions
OCL API 2
731abfd57be91ce96b35a4b1af2089a8b505c524 731abfd57be91ce96b35a4b1af2089a8b505c524
OCL CI
fe5d9d08844d42b9b3fa6bac74d1f57056088b78 fe5d9d08844d42b9b3fa6bac74d1f57056088b78
Failing since
#1469 (Changes by Sunny Aggarwal.)
Fixed in
#1471 (Manual run from the stage: Deploy for testing by Sunny Aggarwal.)
No failed test found. A possible compilation error occurred.

Responsible

Code commits

OCL API 2
Author Commit Message Commit date
Sunny Aggarwal. Sunny Aggarwal. 731abfd57be91ce96b35a4b1af2089a8b505c524 731abfd57be91ce96b35a4b1af2089a8b505c524 OpenConceptLab/ocl_issues#1399 | removed redundant admin APIs for locales cleanup
Sunny Aggarwal. Sunny Aggarwal. 6fb9d8bda9f877496aafddb49a81e060fa02d3a3 6fb9d8bda9f877496aafddb49a81e060fa02d3a3 OpenConceptLab/ocl_issues#1399 | ConceptName | concept_id is mandatory | fixing tests

Error summary for Run tests

The job generated some errors, drill down into the full build log for more details.

    test_create_with_filter_and_concept ... ok
    test_create_with_filter_and_system ... ok
    test_expand ... ok
    test_public_can_find_globally ... ok
    test_public_can_find_globally_without_compose ... ok
    test_public_can_view ... ok
    test_update_with_compose ... ok
    test_validate_code ... ok
    test_validate_code_globally ... ok
    test_validate_code_globally_negative ... ok
    test_validate_code_negative ... ok

======================================================================
ERROR: test_names_post_201 (core.integration_tests.tests_concepts.ConceptCreateUpdateDestroyViewTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute
    return self.cursor.execute(sql, params)
psycopg2.errors.NotNullViolation: null value in column "concept_id" of relation "concept_names" violates not-null constraint
DETAIL:  Failing row contains (2186, null, foo, Fully Specified, en, f, 2023-01-18 05:04:49.870755+00, null).


The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/code/core/integration_tests/tests_concepts.py", line 621, in test_names_post_201
    response = self.client.post(
  File "/usr/local/lib/python3.10/site-packages/rest_framework/test.py", line 296, in post
    response = super().post(
  File "/usr/local/lib/python3.10/site-packages/rest_framework/test.py", line 210, in post
    return self.generic('POST', path, data, content_type, **extra)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/test.py", line 234, in generic
    return super().generic(
  File "/usr/local/lib/python3.10/site-packages/django/test/client.py", line 541, in generic
    return self.request(**r)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/test.py", line 286, in request
    return super().request(**kwargs)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/test.py", line 238, in request
    request = super().request(**kwargs)
  File "/usr/local/lib/python3.10/site-packages/django/test/client.py", line 810, in request
    self.check_exception(response)
  File "/usr/local/lib/python3.10/site-packages/django/test/client.py", line 663, in check_exception
    raise exc_value
  File "/usr/local/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner
    response = get_response(request)
  File "/usr/local/lib/python3.10/site-packages/django/core/handlers/base.py", line 197, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/usr/local/lib/python3.10/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
    return view_func(*args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/django/views/generic/base.py", line 103, in view
    return self.dispatch(request, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/views.py", line 509, in dispatch
    response = self.handle_exception(exc)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/views.py", line 469, in handle_exception
    self.raise_uncaught_exception(exc)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception
    raise exc
  File "/usr/local/lib/python3.10/site-packages/rest_framework/views.py", line 506, in dispatch
    response = handler(request, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/rest_framework/generics.py", line 242, in post
    return self.create(request, *args, **kwargs)
  File "/code/core/concepts/views.py", line 552, in create
    saved_instance = serializer.save()
  File "/usr/local/lib/python3.10/site-packages/rest_framework/serializers.py", line 212, in save
    self.instance = self.create(validated_data)
  File "/code/core/concepts/serializers.py", line 69, in create
    concept_desc.save()
  File "/usr/local/lib/python3.10/site-packages/django/db/models/base.py", line 812, in save
    self.save_base(
  File "/usr/local/lib/python3.10/site-packages/django/db/models/base.py", line 863, in save_base
    updated = self._save_table(
  File "/usr/local/lib/python3.10/site-packages/django/db/models/base.py", line 1006, in _save_table
    results = self._do_insert(
  File "/usr/local/lib/python3.10/site-packages/django/db/models/base.py", line 1047, in _do_insert
    return manager._insert(
  File "/usr/local/lib/python3.10/site-packages/django/db/models/manager.py", line 85, in manager_method
    return getattr(self.get_queryset(), name)(*args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/django/db/models/query.py", line 1790, in _insert
    return query.get_compiler(using=using).execute_sql(returning_fields)
  File "/usr/local/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1660, in execute_sql
    cursor.execute(sql, params)
  File "/usr/local/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute
    return self._execute_with_wrappers(
  File "/usr/local/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers
    return executor(sql, params, many, context)
  File "/usr/local/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute
    with self.db.wrap_database_errors:
  File "/usr/local/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__
    raise dj_exc_value.with_traceback(traceback) from exc_value
  File "/usr/local/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute
    return self.cursor.execute(sql, params)
django.db.utils.IntegrityError: null value in column "concept_id" of relation "concept_names" violates not-null constraint
DETAIL:  Failing row contains (2186, null, foo, Fully Specified, en, f, 2023-01-18 05:04:49.870755+00, null).

----------------------------------------------------------------------
Ran 730 tests in 159.356s

FAILED (errors=1, skipped=3)
Preserving test database for alias 'default' ('test_postgres')...
1
Stopping ocl-oclapi2-rt_es_1 ...
Stopping ocl-oclapi2-rt_db_1 ...
Stopping ocl-oclapi2-rt_db_1 ... done
Stopping ocl-oclapi2-rt_es_1 ... done
Removing ocl-oclapi2-rt_es_1 ...
Removing ocl-oclapi2-rt_db_1 ...
Removing ocl-oclapi2-rt_es_1 ... done
Removing ocl-oclapi2-rt_db_1 ... done
Removing network ocl-oclapi2-rt_default
Removing volume ocl-oclapi2-rt_postgres-data
Removing volume ocl-oclapi2-rt_es-data