Skip to content

Releases: agittins/bermuda

v0.6.7 - Fix for HA 2024.6.0 lockup adding devices

06 Jun 14:47
Compare
Choose a tag to compare

Significant change here is avoiding a race condition exposed by HA 2024.6.0 (from beta6). This was seen when adding a configured device to Bermuda, the dialog would hang spinning waiting for the config flow to apply, and the HA server would loop infinitely restarting Bermuda. Huge thanks to @andreasbrett for raising the issue before the HA release and submitting a comprehensive bug report - much appreciated!

This release also includes the current MAC address for any iBeacons being selected in the Configure Devices config flow. This should make it easier to find and identify devices while setting things up.

Changes

  • Fix!: race condition in 2024.6.0b6 @agittins (#211)
  • feat: Add MAC address to iBeacon listings in configure
  • fix: Don't restore scanner options from saved device
    • We store the options struct along with the cached scanner entries in entry.data. Prevent restoring it, since it overwrites
      newer options set by config. Only affects display of data in the dump_devices service, but might become important if we
      operate using those values later.
  • fix: Ignore disabled PrivateBLE devices

📦 Dependencies

  • chore(deps): bump ruff from 0.4.4 to 0.4.7 @dependabot (#208)
  • chore(deps): bump reorder-python-imports from 3.12.0 to 3.13.0 in /.github/workflows @dependabot (#209)
  • chore(deps): bump ruff from 0.4.7 to 0.4.8 @dependabot (#212)

v0.6.6 - Better device selection and Fewer crashes!

19 May 11:51
Compare
Choose a tag to compare

This release features:

  • 🚨 Hopefully fewer crashes :-/ Since 2024.5 we've seen a lot more thread/async related issues like all of HA bogging down or locking up. This has been tricky to fault-find because it only shows up on some systems, and seemingly rarely on mine. This release includes two fixes that will hopefully eliminate (or at least reduce) these instances.
  • Device selection in configuration now uses Bermuda's own full list of devices, instead of just the recent devices from the bluetooth backend. Hopefully this will solve some issues people have had finding their devices, or maybe it won't. Note that PrivateBLE devices are not chosen per se, they will always be configured. The list now also indicates if a device is using a so-called "Random MAC" as a warning that tracking that particular MAC address may be futile. The list is also sorted with iBecons first, then static addresses, then random addresses.
  • Config flow (more accurately the options flow, via the configure button(!)) is now set up with sub-menus, because soon we will have too many options to fit on one page :-)

Changes

📦 Dependencies

  • chore(deps): bump pre-commit from 3.7.0 to 3.7.1 in /.github/workflows @dependabot (#192)
  • chore(deps): bump ruff from 0.4.3 to 0.4.4 @dependabot (#191)

v0.6.5

09 May 18:18
Compare
Choose a tag to compare

This release fixes the nasty bug from v0.6.4 detailed in #185

Big thanks to @sdholden28, @terryhonn and @tbrasser for their contributions in narrowing down the fault, and again to @skrashevich for some more safety checks 👍🏼

Changes

  • ⚠️ fix: Resolve infinite loop on config reload in 2024.5 @agittins (#189)
  • 🧷 fix(bermuda): Improved condition checks and handling of MAC addresses @skrashevich (#186)
  • 📚 chore (docs): Refactoring docs over to wiki @agittins (#187)
  • 📚 chore (docs): Fix link to FAQ from readme @agittins (#188)

v0.6.4 !!Broken!! Do not install

08 May 07:31
Compare
Choose a tag to compare

⚠️ Note that this release has a critical bug, I recommend sticking with v0.6.3 for now and holding tight for the next release. Details at #185

Very much a maintenance release, but with a few important bug fixes.

Thanks to @skrashevich and @itsteddyyo for their much-appreciated contributions via PRs merged into this release, and to those who have generously offered financial support to keep Bermuda improving. As well as the amazing community support these things make it that much more enjoyable to further this thing that I made to scratch my own itches :-)

Most of these changes have been sitting in the main branch of the repo for about two weeks, so you may already have these changes if you're tracking that branch rather than official releases.

This release sees:

  • fixes to the dump_devices service call
  • making sure that changing the Area on a scanner applies properly
  • an important fix for devices that are both Private_ble and iBeacon (ie, all Android HA Companion app beacons) that would stop updating after a time
  • some tidying / hardening of calculations
  • a process that "prunes" stale mac addresses from the in-memory cache to keep only the last 1000 un-tracked devices over the past 3 days. This may offer some CPU usage improvements, after 6 days my server went from 0.004 seconds per update cycle to 0.100s per cycle. Now it remains pretty stable around 0.005. It may improve memory usage but I didn't see much difference there on my machine.
  • 🚨 Device names are now filtered for whitespace and binary cruft before and after the name. I have a device that calls itself 'UC96BLE\0\0\0\0' which makes it very unpopular with my long-term stats database :-) Note that you might find some device names may change if they had whitespace or non-alphanum chars in their names previously.

Changes

📦 Dependencies

v0.6.3 HACS-ready

06 Apr 19:34
c602efa
Compare
Choose a tag to compare

No user-facing changes in this release, it exists to confirm tests etc for the HACS default repo.

Changes

v0.6.2 ready for HA 2024.4.0

02 Apr 20:48
4fe3c26
Compare
Choose a tag to compare

This release brings compatibility for changes due to be introduced in HA 2024.4.0 (tested currently against 2024.4.0b4)
Big thanks to @tbrasser and @sambarlick for the heads-up on the impending changes!

Note: Anyone who ran the main version with the 2024.4 betas between v0.6.1 and now may find some stale private_ble-related devices/entities that need to be cleaned up - they can be deleted once you've updated (comments in #147).

Changes

📦 Dependencies

  • chore(deps): bump actions/setup-python from 5.0.0 to 5.1.0 @dependabot (#145)

v0.6.1 IRK address-change fix

25 Mar 09:36
fcb2d27
Compare
Choose a tag to compare

A bug in 0.6.0 (well, you could say a missing, but vital feature) caused Private BLE Devices to not update their MAC address, so the Bermuda sensors for them would go stale.

Changes

  • fix: Update IRK device source addresses on change @agittins (#143)

v0.6.0 (2024-03-25) IRK / Private BLE Device (iPhone) support!

25 Mar 07:24
81c944b
Compare
Choose a tag to compare

🚀 This release brings the long-awaited support for iPhones and other iOS devices (and any other devices that use private MAC addresses with IRK).

Adding any device to the Private BLE Device integration will automatically create Bermuda tracking entities for area-based location.

This release includes bug-fixes for:

  • #135 Integrate with Private BLE Device to support iOS / iPhone tracking with IRK
  • #137 Changing Area of a scanner does not get reflected in Bermuda
  • #138 Log spamming "Using freshest advert but it's still too old!"

What's Changed

  • feat: iOS / iPhone / Private BLE Device / IRK Support! by @agittins in #140
  • chore(deps): bump ruff from 0.3.3 to 0.3.4 by @dependabot in #139
  • fix: properly search for Private ble devices via config entries by @agittins in #142
  • chore(deps): bump pre-commit from 3.6.2 to 3.7.0 in /.github/workflows by @dependabot in #141

Full Changelog: v0.5.1...v0.6.0

2024.03.19 - v0.5.1 Bugfix for local usb BlueZ dongles

18 Mar 16:30
87af4b6
Compare
Choose a tag to compare

This release fixes a bug where local bluetooth adaptors (which are now, tentatively, enabled for area tracking) would "stick" and catch devices that went out-of-range.

Changes

2024.3.18: v0.5.0! iBeacons! Faster Updates! Filtering!

18 Mar 09:36
c1021ad
Compare
Choose a tag to compare

This is a pretty major release with some nice, juicy features and fixes :-)

  • 📱 iBeacon support means that Android phones using the HA Companion app can now be tracked! Of course, any other iBeacon can also be tracked. Just look for the UUID in the configured devices drop-down (in the CONFIGURE dialog). Don't worry, iPhone users - IRK support is in the works.
  • ⏱️ Faster sensor updates - Bermuda now checks for new advertisements every second, meaning that responsiveness to entering an area etc should be much faster now. In order to do this without impacting system performance, I've implemented a sort of caching on sensor updates, which you can configure in the the options with the update_interval setting. This sets a maximum interval for sensor updates. Bermuda still checks every second, but if the update is boring (or unlikely to be accurate) the sensor won't update. This saves database space, browser memory and cpu cycles. However, if Bermuda notices that a device has come closer to an Area, it publishes the update immediately. You can change the update_interval without having to reload HA so it's easy to ramp it down to 1 second for some troubleshooting or wind it back up to reduce database impact.
  • 📈 Sensor smoothing/filtering. Bermuda now uses a custom filtering chain to try and clean up the very noisy data that is inherent to RSSI measurements. The main thrust of the work is:
    • MAX_VELOCITY setting allows us to ignore any measurement that implies a device has moved away from an area at an improbable speed. These readings are almost always noise-induced.
    • Moving-window average smooths out the noisy data, but always gives preference to "nearer" distance measurements, as they are less susceptible to noise (or more concisely, nearer measurements have less noise). You can configure how many samples this filter uses to have a rough control over the maximum slope angle of distance increases.

Thanks to @jaymunro for his help and ideas while testing these filtering options!

  • 📏 Unit conversion should now work - nobody filed a bug for it but it's fixed 🎉

  • 📊 More fun sensors! Bermuda now provides sensors for every combination of device and proxy - but they are disabled by default. This means you can enable any that are of interest, particuarly useful for troubleshooting filters or learning more about how it is behaving. Adding more sensors can have an impact on your database size and system load, so bear that in mind before you turn them all on! Usually enabling a few key sensors on one testing device is enough to get the insight you need.

Your filtering dollars at work:
image

  • 😐 The history card that pops up when you click a distance sensor now uses the default HA "5 minute averaged min/max/mean" graph instead of individual measurements mode. This results in no data showing until its been running for 5 minutes, but on the up-side it reduces the amount of data that needs to stay loaded in browsers so seems a reasonable compromise. The dedicated "History" tool is so much better these days, so I'd recommend using that any time you want to analyse the data.

Breaking Changes

  • 💣 For performance improvements, many (most?) of the sensor extra attributes have been moved out to their own sensors. So if you were running automations that relied on attributes they will likely need updating. For example, if you triggered an automation on an Area sensor, and checked the distance attribute of that sensor, you'll now have to trigger on the Area sensor, and add a separate step to check the separate Distance sensor.

Changes

  • wip: Get tests running again @agittins (#87)
  • chore: Update issue template for config screenshot @agittins (#88)
  • perf: Downgrade TX Power change log to debug @agittins (#89)
  • (feat) Per-proxy distance sensors @agittins (#107)
  • (chore) calmed some warnings down to debug. @agittins (#108)
  • fix: prevent non-scanner devices being saved to config @agittins (#109)
  • Chore: Replace reorder-imports with isort @agittins (#115)
  • feat: iBeacon Support! @agittins (#116)
  • Faster Polling (0.9seconds instead of 5), cleanups @agittins (#117)
  • Add mac_is_random, shorten update_interval, cleanups @agittins (#120)
  • Filtering of Distance sensors, startup and reload fixes, performance and db improvements @agittins (#127)
  • fix: Add timeout logic for distance measurements @agittins (#128)
  • feat: Ignore long distance readings that would require high velocity @agittins (#129)
  • Docs, Sensor Churn fixes, Unit conversions, Max_Velocity via ConfigFlow @agittins (#133)

📦 Dependencies