-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test failure on different pg text search settings #336
Comments
bickelj
changed the title
Test failure on different pg settings
Test failure on different pg text search settings
May 5, 2023
bickelj
added a commit
that referenced
this issue
May 5, 2023
While the postgres (PG) text search (TS) config 'english' is specified when building the text search column and index in the migration script `0010-alter-proposal_field_values-value_search.sql`, when the postgres `default_text_search_config` is set to `pg_catalog.simple` rather than to `pg_catalog.english`, the test named `returns a subset of proposals present in the database when search is provided` in file `proposals.int.test.ts` will fail. For consistency in search results across instances, this commit sets the query with search to use the same `english`. Without this commit, tests will fail with different PG settings for default text search config and inconsistent search results will appear between instances. Issue #336 Test failure on different pg text search settings
bickelj
added a commit
that referenced
this issue
May 5, 2023
While the postgres (PG) text search (TS) config 'english' is specified when building the text search column and index in the migration script `0010-alter-proposal_field_values-value_search.sql`, when the postgres `default_text_search_config` is set to `pg_catalog.simple` rather than to `pg_catalog.english`, the test named `returns a subset of proposals present in the database when search is provided` in file `proposals.int.test.ts` will fail. For consistency in search results across instances, this commit sets the query with search to use the same `english`. Without this commit, tests will fail with different PG settings for default text search config and inconsistent search results will appear between instances. The test now sets a different language than english to ensure that the search continues to explicitly specify the language when searching. Issue #336 Test failure on different pg text search settings
bickelj
added a commit
that referenced
this issue
May 5, 2023
While the postgres (PG) text search (TS) config 'english' is specified when building the text search column and index in the migration script `0010-alter-proposal_field_values-value_search.sql`, when the postgres `default_text_search_config` is set to `pg_catalog.simple` rather than to `pg_catalog.english`, the test named `returns a subset of proposals present in the database when search is provided` in file `proposals.int.test.ts` will fail. For consistency in search results across instances, this commit sets the query with search to use the same `english`. Without this commit, tests will fail with different PG settings for default text search config and inconsistent search results will appear between instances. The test now sets a different language than english to ensure that the search continues to explicitly specify the language when searching. Issue #336 Test failure on different pg text search settings
bickelj
added a commit
that referenced
this issue
May 8, 2023
While the postgres (PG) text search (TS) config 'english' is specified when building the text search column and index in the migration script `0010-alter-proposal_field_values-value_search.sql`, when the postgres `default_text_search_config` is set to `pg_catalog.simple` rather than to `pg_catalog.english`, the test named `returns a subset of proposals present in the database when search is provided` in file `proposals.int.test.ts` will fail. For consistency in search results across instances, this commit sets the query with search to use the same `english`. Without this commit, tests will fail with different PG settings for default text search config and inconsistent search results will appear between instances. Issue #336 Test failure on different pg text search settings
I believe this is resolved with #337 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Locally, I got this test failure every time on main after the merge of #320:
Locally I experienced this issue with two bitnami images of postgresql (14.7.0-debian-11-r5 and 15.2.0-debian-11-r28) while the automated test job for 320 (that did not see this issue) ran this image, presumably the stock pg 15.2.0 image on debian:
Other team members who did not see this issue run from PostgreSQL APT packages for Ubuntu 22.04 or homebrew.
We found a difference in postgres settings for
default_text_search_config
:pg_catalog.simple
vspg_catalog.english
. Where I havepg_catalog.simple
as the default tscfg and experience failures, at least one other system not experiencing the failure haspg_catalog.english
.Usually it wouldn't matter if one dev machine has an odd configuration, but this dev machine's configuration is most closely aligned with the test and production machines, so it is likely a real issue.
More details are in chat at https://chat.opentechstrategies.com/#narrow/stream/75-PDC/topic/search.20implementation.
The text was updated successfully, but these errors were encountered: