forgejo_backup/modules/indexer/issues
Danko Aleksejevs 4935e6e1a3 fix: skip empty tokens in SearchOptions.Tokens() (#8261)
Query string tokenizer could return a list containing empty tokens when the query string was `\` or `"` (probably in other scenarios as well).

This seems undesirable and is what triggered #8260, but I'm posting this separately from that fix in case I'm wrong. Feel free to reject if so.

The actual change in behavior is that now searching for `\` or `"` behaves the same as if the query were empty (the bleve/elastic code checks that the tokenizer actually returned, anything rather than just query being non-empty).

### Tests

- I added test coverage for Go changes...
  - [x] in their respective `*_test.go` for unit tests.

### Documentation

- [ ] I created a pull request [to the documentation](https://codeberg.org/forgejo/docs) to explain to Forgejo users how to use this change.
- [x] I did not document these changes and I do not expect someone else to do it.

### Release notes

- [x] I do not want this change to show in the release notes.
- [ ] I want the title to show in the release notes with a link to this pull request.
- [ ] I want the content of the `release-notes/<pull request number>.md` to be be used for the release notes instead of the title.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8261
Reviewed-by: Shiny Nematoda <snematoda@noreply.codeberg.org>
Co-authored-by: Danko Aleksejevs <danko@very.lv>
Co-committed-by: Danko Aleksejevs <danko@very.lv>
2025-07-03 11:29:04 +02:00
..
bleve fix: skip empty tokens in SearchOptions.Tokens() (#8261) 2025-07-03 11:29:04 +02:00
db feat: show more relevant results for 'dependencies' dropdown (#8003) 2025-06-26 20:06:21 +02:00
elasticsearch fix: skip empty tokens in SearchOptions.Tokens() (#8261) 2025-07-03 11:29:04 +02:00
internal fix: skip empty tokens in SearchOptions.Tokens() (#8261) 2025-07-03 11:29:04 +02:00
meilisearch chore: QoL improvements to tests (#7917) 2025-05-21 15:45:56 +02:00
dboptions.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
indexer.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
indexer_test.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
util.go Add issue number to the search index, rank number and title matches higher (#7956) (#7968) 2025-06-04 07:42:29 +02:00