Bing: renew the session when its results are off-topic

Open
#809 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
backend, search

Research direction

Read the implementation of the off-topic check, Bing session handling, and the engine hook; the issue does not name their files, so locate them in the repository. Add tests for one renewal after an off-topic result, no second renewal during the same search, and no renewal for an on-topic result. Keep the change limited to Bing and follow dependency #795.

Written by the indexing model from the issue text.

Description

area:search maintainers roadmap

Problem

The spike in #738 found that a Bing session that gets off-topic pages gets them for every query it sends, from the first to the last. Keeping such a session keeps every later Bing result off-topic until it expires.

Change

  • When the off-topic check drops a Bing set, discard the session, so the next Bing request warms a new one.
  • At most one renewal per search. No retry inside the same search.
  • Engines opt in through a hook on the engine, not through a check on the engine's name.

Done when

  • A test: an off-topic set discards the session, and the next request makes one home-page visit on a new session.
  • A test: a second off-topic set in the same search does not renew again.
  • A test: an on-topic set keeps the session, with no extra warm-up.

Out of scope

Retrying the query inside the same search. Other engines.

Depends on: #795

Dominant language
TypeScript
Stars
5.4k
Forks
445
Avg merge
20h 41m
Merged PRs (30d)
85

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from KnockOutEZ/wigolo

All issues in KnockOutEZ/wigolo

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.