mage icon indicating copy to clipboard operation
mage copied to clipboard

`elastic_search_serialization` is having issues with dateTime() fields on indexing the DB

Open batuhandirek opened this issue 1 year ago • 0 comments

Memgraph version 2.19.0

Environment Docker image of memgraph-mage

Describe the bug elastic_search_serialization is having issues with entities if they have dateTime() kind of field - it cannot index

To Reproduce Follow along this blog post

  1. Load the Karate Dataset
  2. Run MATCH (a) SET a.test = dateTime()
  3. Try to follow the steps - indexing with CALL elastic_search_serialization.index_db("mem_nodes", "mem_edges", 4) YIELD * RETURN *; will fail with _mgp.LogicErrorError: Logic error.

Expected behavior DB should be indexed

Logs Error stack:

elastic_search_serialization.index_db: Traceback (most recent call last):
  File "/usr/lib/memgraph/query_modules/elastic_search_serialization.py", line 343, in index_db
    nodes, edges = generate_documents_from_db(context)
  File "/usr/lib/memgraph/query_modules/elastic_search_serialization.py", line 142, in generate_documents_from_db
    vertices.append(serialize_vertex(vertex))
  File "/usr/lib/memgraph/query_modules/elastic_search_serialization.py", line 69, in serialize_vertex
    doc = serialize_properties(vertex.properties.items())
  File "/usr/lib/memgraph/query_modules/elastic_search_serialization.py", line 96, in serialize_properties
    for prop_key, prop_value in properties:
  File "/usr/lib/memgraph/python_support/mgp.py", line 289, in items
    properties_it = self._vertex_or_edge.iter_properties()
_mgp.LogicErrorError: Logic error.

Additional context Not really

Verification Environment I will replicate it again and check

batuhandirek avatar Sep 25 '24 08:09 batuhandirek