Skip to content

Fix meal category lookup in quick-add#35

Merged
milldr merged 1 commit into
mainfrom
fix/meal-category-lookup
May 22, 2026
Merged

Fix meal category lookup in quick-add#35
milldr merged 1 commit into
mainfrom
fix/meal-category-lookup

Conversation

@milldr

@milldr milldr commented May 22, 2026

Copy link
Copy Markdown
Owner

what

  • Replace exact text selector (text="Lunch") with targeted element selectors (td:text(), div:text()) for meal category lookup
  • Retry when meal category element isn't found instead of failing immediately

why

  • The exact text selector failed because Cronometer meal category elements contain additional text (calorie summaries), not just the meal name
  • The old retry loop only retried when the right-click succeeded but the context menu didn't appear — if the element wasn't found at all (e.g. GWT still rendering), it returned an error immediately

ref

  • Tested with local Playwright backend against live Cronometer

@milldr milldr added the patch Bug fix - bumps patch version label May 22, 2026
@milldr milldr merged commit 2e39fb6 into main May 22, 2026
3 checks passed
@milldr milldr deleted the fix/meal-category-lookup branch May 22, 2026 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

patch Bug fix - bumps patch version

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant