Breaking changes
UK retailer data sources removed
The UK retailer feeds from the CMA open data scheme no longer exist in pyfuelprices. The affected sources are Applegreen, Ascona, Asda, BP, Esso, Jet, Karan Retail, Moto, Motor Fuel Group, Rontec, Sainsbury's, SGN Retail, Shell and Tesco. (pantherale0/pyfuelprices#103)
If you used any of them, the upgrade switches you to PetrolPrices automatically. PetrolPrices needs no extra setup. The integration deletes the sensors for the removed sources, and creates new ones for the stations PetrolPrices finds in your areas. Any automations, dashboards or templates that use the old sensors need updating.
You can use the UK Government Fuel Finder service instead of PetrolPrices. It needs an API client ID and secret, and only works from a UK IP address. See the Fuel Finder setup guide.
DirectLease replaced with ANWB Onderweg
The upgrade moves installations that use DirectLease (Netherlands) to ANWB Onderweg and deletes the DirectLease sensors. You no longer need to press the repair button.
Cheapest stations option removed
The upgrade removes the old "cheapest stations" settings from your areas. To track the cheapest stations, use the fuel_prices.find_fuels action, or one of the updated template examples below.
New and improved data sources
- Added Petrolmate for Australia and New Zealand. It needs no setup. New installs in those countries use it automatically. Existing installs can add it under "Configure data collector sources" in the integration options. (pantherale0/pyfuelprices#98)
- Fuel.gr (Greece) now reports premium fuels as separate fuel types, named with a "Premium" prefix, for example "Premium E5". (#105, pantherale0/pyfuelprices#101)
- Fixed Comparis (Switzerland) requests being blocked by the site's bot protection. (pantherale0/pyfuelprices#99)
Fixes
- New areas are now saved with the correct radius. Since the area form switched to a map picker, the integration saved the radius in meters but used it as miles, so a 5 mile area searched about 8,000 miles. Some data sources rejected those searches, which left you with very few sensors. The upgrade corrects existing areas with a radius above 200. (#106)
- Fixed the "Update area failed: 'value'" error with ANWB Onderweg. pyfuelprices now splits large searches into smaller ones. (#106, pantherale0/pyfuelprices#102)
- Changes made in the integration options now apply straight away, without restarting Home Assistant. Saving the options reloads the integration exactly once. (#93, #107)
- Changing your selected data sources no longer clears API keys you have already entered. (#107)
- The data source setup form now rejects blank or invalid credentials and shows an error. (#107)
- A data source with missing or invalid credentials no longer stops the whole integration loading. The integration skips that source and raises a repair issue telling you to re-enter the credentials. (#107)
- Fixed "Session is closed" errors that stopped every data source updating until you restarted Home Assistant. Each reload now gets a new connection. If the connection closes anyway, the integration reloads itself. (#107, pantherale0/pyfuelprices#102)
- Reloading or removing the integration now closes its network connection and removes its actions. Reloading many times no longer leaves old connections open.
- Fixed an
AttributeErrorwhen adding the integration. (#97) - Fixed adding the integration when no data sources are selected and Home Assistant has no country set.
- Data sources that cover more than one country now appear once in the source list, instead of once per country. (#86)
- Fuel station sensors show as unavailable when their station is missing from the latest data, instead of logging errors.
- The
fuel_prices.find_fuelsaction now returns a normal error when a station has no price for the requested fuel, socontinue_on_errorworks with it.
Template examples rewritten
The cheapest fuel price sensor and device tracker examples did not work as published. A comment inside the radius template made the radius a piece of text instead of a number, so every search failed. If you copied either example, replace it with the new version.
The new examples:
- set a data source, which skips the location lookup that ran on every search and often returned empty results when it hit its rate limit
- use a fixed price unit such as
GBP/L, because Home Assistant does not accept a template for the unit - become unavailable when a search fails, instead of showing an old price
- store a short summary of each station rather than the full search result, which could go over Home Assistant's attribute size limit
- search every 15 minutes in the device tracker example, rather than twice on every GPS update, and skip the search when the tracker has no location
Other changes
- Updated pyfuelprices to 2026.10. See the pyfuelprices release notes.
- Removed the
xmltodictandthese-united-statesdependencies. - The options flow now uses Home Assistant's current options flow class.
- Updated development dependencies to their latest versions. (#90, #95)
- Upgraded
cryptographyin the development requirements to 46.0.7 to fix a security vulnerability. (#99)
Contributors
Thanks to @stonith, @JodyVanden, and @pantherale0.