Skip to content

BUG: Reference editor: Repeated search for same term returns different results #4047

@lorenzulrich

Description

@lorenzulrich

Current behaviour

  • If I repeatedly search for the same term in the reference editor, I potentially get a different result set each time.

Expected behaviour

  • The search for the same term always returns the same result.

Steps to reproduce

  • I configured a reference from one node type to another
  • In my video example, I'm searching for the term "Hund". There are exactly two matching items.
neos-ui-reference-search.mp4
  • I enter "Hund" a first time.
  • ✅ Two results are being displayed
  • I delete the text and enter "Hund" a second time.
  • 🐞 Four results are being displayed
  • I delete the text and enter "Hund" a third time.
  • 🐞 Even more results are being displayed
  • I delete the text and enter "Hund" a fourth time.
  • 🐞 Even more results are being displayed.
  • I delete the text and enter "Hund" a fifth time.
  • ✅ Two results are being displayed

What happens

  • As you can see in the Network tools, for the first search, "Hund" is being sent to the API.
  • The second request has "Hun" as a payload
  • The third request has "Hu" as a payload
  • The fourth request has "H" as a payload
  • When I enter "Hund" the fifth time, somehow Neos realized that it already has results for "Hund" in the cache and returns the correct results.

I double-checked this in another installation and with longer words and it's always the same. Each time I manually re-enter the same term, one more character is trimmed from the end of the word until no character is left.

Environment

  • Neos 8.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions