Skip to content

search_graph returns null for list-valued requested fields despite stored graph properties #1284

Closed

Description

@Enferlain

Version

codebase-memory-mcp dev

Platform

Linux (x64)

What happened?

search_graph(fields=[...]) returns null for list-valued node properties even though the properties exist in the graph and query_graph returns their values correctly.

This was reproduced with:

  • Class.base_classes
  • Method.decorators
  • Method.decorator_tags

Scalar requested fields such as signature render normally.

Public reproduction

Repository and commit:

A fresh full index reported:

12,131 nodes
70,850 edges
generation_matches=true

Reproduction: class bases

{
  "project": "home-imi-Projects-sd-scripts",
  "label": "Class",
  "name_pattern": "^(SdTrainingStrategy|Sd3TrainingStrategy|SdxlTrainingStrategy)$",
  "fields": ["base_classes"],
  "format": "json",
  "limit": 10,
  "offset": 0
}

Actual search_graph rows contain:

["SdTrainingStrategy", "Class", "19-50", 15, 13, null]
["Sd3TrainingStrategy", "Class", "17-63", 2, 12, null]
["SdxlTrainingStrategy", "Class", "20-58", 12, 13, null]

But the property is present and ordered in query_graph:

MATCH (c:Class)
WHERE c.name IN ['SdTrainingStrategy', 'Sd3TrainingStrategy', 'SdxlTrainingStrategy']
RETURN c.qualified_name, c.base_classes
ORDER BY c.qualified_name

For example, SdTrainingStrategy.base_classes returns:

[
  "SdModelLoadingStrategy",
  "SdTokenizeStrategy",
  "SdTextEncodingStrategy",
  "SdConditioningStrategy",
  "SdCachingStrategy",
  "SdSampleGenerationStrategy",
  "SdCheckpointingStrategy",
  "SdValidationStrategy",
  "SdDiffusionTrainingStrategy",
  "SdDenoiserCallingStrategy",
  "SdModelPreparationStrategy",
  "WeightedPromptStrategy",
  "TrainingStrategy"
]

Reproduction: method decorators

{
  "project": "home-imi-Projects-sd-scripts",
  "label": "Method",
  "name_pattern": "^process_batch$",
  "qn_pattern": "^home-imi-Projects-sd-scripts\\.library\\.strategies\\.base\\.contracts\\..*",
  "fields": ["decorators", "decorator_tags"],
  "format": "json",
  "limit": 10,
  "offset": 0
}

Actual row:

["process_batch", "Method", "380-403", 0, 10, null, null]

But query_graph returns:

decorators=["@abstractmethod"]
decorator_tags=["abstractmethod"]

The graph schema also lists base_classes, decorators, and decorator_tags as properties of their respective node labels.

All cited source paths returned no_recorded_issue with matching coverage metadata.

Expected behavior

Requested list-valued properties should be serialized in search_graph results, preserving order where the property is ordered:

["SdTrainingStrategy", "Class", "19-50", 15, 13, ["SdModelLoadingStrategy", "..."]]

If list-valued properties are intentionally unsupported, search_graph should return an explicit validation error or document the limitation rather than silently returning null for an existing property.

Impact

This is a smaller query-output issue; the underlying index data is intact and query_graph is a workaround. It still affects normal agent workflows because search_graph is the preferred discovery tool:

  • inheritance order appears absent;
  • abstract/decorator metadata appears absent;
  • agents may draw false conclusions or issue unnecessary fallback queries;
  • inheritance and framework audits become more expensive.

Confirmations

  • Searched current open and closed issues; no exact duplicate found.
  • Reproduced across three separate list-valued properties and two node labels.
  • Scalar requested fields work.
  • Underlying values are confirmed through query_graph.

Activity

  1. added
    cypherCypher query language parser/executor bugs
    parsing/qualityGraph extraction bugs, false positives, missing edges
    on Jul 27, 2026
  2. added this to the 0.9.1-rc milestone on Jul 28, 2026
  3. added
    priority/highNeeds near-term maintainer attention; high-impact bug, regression, safety issue, or release blocker.
    on Jul 28, 2026
  4. DeusData commented on Jul 28, 2026

    @DeusData
    Owner

    Thanks for the focused property-type report.

    The current serializer handles requested extra fields only when the JSON value is string, boolean, integer, or real; every array/object falls through to an empty cell (src/mcp/mcp.c:3085-3103). That is the direct reason a stored list-valued property becomes null/blank in search_graph.

    I have routed this to 0.9.1-rc at priority/high because the requested field is silently misrepresented. Thank you for proving the value exists in storage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcypherCypher query language parser/executor bugsparsing/qualityGraph extraction bugs, false positives, missing edgespriority/highNeeds near-term maintainer attention; high-impact bug, regression, safety issue, or release blocker.

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions