Add support for optional 'feels like' temperature info - #59
Open
coko7 wants to merge 5 commits into
Open
Conversation
Add `apparent_temperature` (feels-like) field across the full stack: fetch it from Open-Meteo and Met Office APIs, propagate it through the provider response, normalizer, and WeatherData types, and optionally display it alongside the actual temperature in the HUD as `(~<value><unit>)`. Controlled via `--use-apparent-temperature` CLI flag and `use_apparent_temperature` config key under `[location]`.
Add unit and integration tests to verify apparent temperature is correctly normalized, displayed, and converted across units. - app_state: test helper `make_app_with_apparent_temp` + three test cases covering Celsius display, disabled flag, and Fahrenheit conversion (22.0°C → 71.6°F) - normalizer unit test: assert apparent_temperature field after normalization (22.5) - integration tests: assert apparent_temperature for clear (24.0), rainy (17.0), and snowy (-1.0) conditions
…ent_temperature`
Renames the "apparent temperature" concept to "feels like temperature" across the entire codebase for clarity and consistency with common weather terminology. - Rename `WeatherData::apparent_temperature` → `feels_like_temperature` - Rename `WeatherProviderResponse::apparent_temperature` → `feels_like_temperature` - Rename `AppState::use_apparent_temperature` → `use_feels_like_temperature` - Rename `Config::Location::use_apparent_temperature` → `Config::use_feels_like_temperature` (also moved from `[location]` scope to top-level config) - Rename CLI flag `--use-apparent-temperature` → `--use-feels-like-temperature` - Update all tests, docs, and provider implementations accordingly BREAKING CHANGE: config key `use_apparent_temperature` under `[location]` is replaced by `use_feels_like_temperature` at the top level; CLI flag `--use-apparent-temperature` is replaced by `--use-feels-like-temperature`
coko7
marked this pull request as ready for review
May 26, 2026 07:40
Matroskin86
pushed a commit
to Matroskin86/weathr
that referenced
this pull request
Jul 14, 2026
… скрытия подсказки выхода - Время ЧЧ:ММ в начале HUD, обновление раз в минуту - use_feels_like_temperature из PR Veirt#59, HUD-строка адаптирована под русский перевод - hide_quit_hint в конфиге: на скринсейвере подсказка 'Выход: q' не нужна Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01F7C4m7uLkeMxvhNpUkk8AN
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for displaying the feels-like temperature alongside the actual temperature in the HUD.
What's new
Feature
feels_like_temperaturefrom the Open-Meteo (apparent_temperaturefield) and Met Office (feelsLikeTemperaturefield) APIs and propagates it through the full stack:provider response → normalizer → WeatherData → AppState(~<value><unit>).Example:
Temp: 20.0°C (~22.0°C)Configuration
Opt-in, disabled by default. Can be enabled in two ways:
config.toml
CLI flag
Tests added
app_state— three new cases: feels-like temperature shown in Celsius, hidden when the flag is off, and correctly converted to Fahrenheit (22.0°C → 71.6°F).normalizerunit test — asserts thefeels_like_temperaturefield is correctly passed through after normalization.weather_normalizerintegration tests — assertsfeels_like_temperatureis preserved for clear, rainy, and snowy conditions.Checklist
README.md