stacklok / stacklok/toolhive-registry-server

LastAppliedFilterHash is never persisted, breaking filter change detection

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

Nobody has claimed this yet.

bug
Dominant language
Go
Stars
27
Forks
15
Avg merge
2d 1h
Merged PRs (30d)
16

Description

After a successful sync, LastAppliedFilterHash is not written to the database — only LastSyncHash is persisted. On the next coordinator cycle, isFilterChanged computes the current filter hash and compares it against the stored value. Because the stored value is never updated, any source whose filter was changed and synced once will continue to appear as "filter changed" on every subsequent cycle, triggering unnecessary re-syncs indefinitely.

LastAppliedFilterHash should be included in the status update written on successful sync completion.

Contributor guide

Open the contributing guide

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.

Research direction

Start by tracing the coordinator cycle through isFilterChanged and the status update performed after successful sync completion. Confirm where LastSyncHash is persisted, then verify that LastAppliedFilterHash is persisted there too and that a later cycle no longer reports the unchanged filter as changed.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
64/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.