Autocomplete/autosuggestions are not language-context sensitive with custom form

Created on 7 February 2024, 9 months ago
Updated 12 February 2024, 9 months ago

Problem/Motivation

@yannikoo and @Ludo.R are experiencing this when using the autocomplete form element in a custom form. I saw the patch in #2912246-13: Autocomplete/autosuggestions are not language-context sensitive โ†’ so I was re-rolling this so it works with the latest version.

Steps to reproduce

see parent issue comment #40
#2912246-40: Autocomplete/autosuggestions are not language-context sensitive โ†’

Proposed resolution

Patch is available. โ†’

Remaining tasks

Review patch

User interface changes

N/A

API changes

Fix language handling

Data model changes

See api fix.

๐Ÿ› Bug report
Status

Needs work

Version

1.0

Component

General code

Created by

๐Ÿ‡จ๐Ÿ‡ฆCanada joseph.olstad

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @joseph.olstad
  • Status changed to Needs work 9 months ago
  • ๐Ÿ‡ฆ๐Ÿ‡นAustria drunken monkey Vienna, Austria

    Thanks for posting this issue!
    However, I donโ€™t think the patch in its current form can be committed, as it assumes that all search pages are filtered by the current content language โ€“ which isnโ€™t necessarily the case.

    if you are using a custom search form, Iโ€™m guessing you also had to implement your own search plugin, correct? Then canโ€™t you just add the appropriate language filter to your implementation of SearchPluginInterface::createQuery()?

  • ๐Ÿ‡จ๐Ÿ‡ฆCanada joseph.olstad

    @drunken monkey
    Actually my scenario is different than the one described in this issue. I've got accents and want search results to show up even if an accent is missing but I want autocomplete to show the correct spelling which has accents. There's other tickets describing this. My setup uses solr.

    I see that additional fields are needed for autocomplete with different field types. For now we disabled the jump start accents and stopwords processing ironically to ensure that the correct spelled french language suggestions with accents show up in the suggestions and also to avoid strange stopword issues.

    Something else is strange with the acquia cloud environment, possibly edismax is affecting our core. To get a 100% resolution I have to dig in with the search_api_solr_debug module and get a better understanding of what is going on.

    For now we were able to make significant improvements by updating our config set to closer to what the jump start has for use with solr 8.11.2

Production build 0.71.5 2024