Skip to content
This repository has been archived by the owner on Sep 27, 2022. It is now read-only.

Change ages indexation approach #133

Open
duozersk opened this issue Jan 12, 2022 · 6 comments
Open

Change ages indexation approach #133

duozersk opened this issue Jan 12, 2022 · 6 comments
Labels
enhancement New feature or request

Comments

@duozersk
Copy link
Contributor

Currently we are indexing from min age to max age with the 6 months steps.

https://github.com/ymcatwincities/openy_activity_finder/blob/4.x/src/Plugin/search_api/processor/AgesMinMax.php#L67

It has several flaws:

@podarok
Copy link
Contributor

podarok commented Jan 12, 2022

@KylieAldridge for the Jira

@podarok podarok added the enhancement New feature or request label Jan 12, 2022
@shelleygoetz
Copy link

@podarok
Copy link
Contributor

podarok commented Feb 15, 2022

merged, this one should be fixed now

@duozersk is there any test we can use for QA?

@duozersk
Copy link
Contributor Author

Well... testing it is quite cumbersome.

We should have the session/activity (either in demo content or create manually) with the min age set to smth that is not dividable by 6 (in months). Like from min age 15 months to max age 36 months. The code before the fix would index 15, 21, 27 and 33 months into the search index for this activity and this session wouldn't be there in the results for any of the age filters (as the ages configuration doesn't have these numbers). The new version of code would index 18, 24 and 36 months - based on the ages configuration - and the activity will be there in the results in you select appropriate age filter.

Ages configuration is this one - https://github.com/ymcatwincities/openy_activity_finder/blob/4.x/config/install/openy_activity_finder.settings.yml#L4

@froboy
Copy link
Contributor

froboy commented Mar 8, 2022

I installed openy_prgf_af4_demo on 4.0.9 and got this error right off the bat:

Drupal\search_api_solr\SearchApiSolrException: Facets having a mincount of "0" is not yet supported by Solr for point based field types. Consider converting the following field to a string or index it twice as string: field_session_min_age. in Drupal\search_api_solr\Plugin\search_api\backend\SearchApiSolrBackend->setFacets() (line 3552 of modules/contrib/search_api_solr/src/Plugin/search_api/backend/SearchApiSolrBackend.php).

Once I updated to 4.x-dev the issue was resolved and the error gone. I think we should be good to tag a new release with this fix since AF4 on 4.0.9 seems broken.

@podarok
Copy link
Contributor

podarok commented Mar 8, 2022

Yes, we need to tag a new release @froboy
It's war slowed down me a bit.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants