Skip to content

Releases: leosperry/ha-kafka-net

V10.2.1

07 Dec 12:29
Compare
Choose a tag to compare

Enhancements

  • Automation Mode added to automation detail page in UI
  • Dependencies updated

Breaking Changes

  • none

V10.2

29 Nov 13:45
Compare
Choose a tag to compare

New Features

  • Added Automation Modes - You can now manage how threads are managed for rapidly firing automations.
  • Smart Mode - Automation mode that combines the best parts of different automation modes. See Parallelism and Threads for complete details.

Enhancement

  • Added Increment/Decrement methods for number helper entitites

Bug Fix

  • Fixed exception being thrown in auto updating entity Snapshot method

Breaking changes

  • Previously thread management behaved like AutomationMode.Parallel. The default is now AutomationMode.Smart. See Parallelism and Threads for complete details.
  • Methods in IAutomationRegistry previously marked obsolete have been removed.

V10.1.1

21 Nov 14:47
Compare
Choose a tag to compare

New Features

  • Updating entities now initialize on startup instead of waiting for a state change
  • New helper extension method for IAutomationBuilder to create scene controller automation.

Breaking Changes

  • none

V10.1

10 Nov 13:02
Compare
Choose a tag to compare

Features

  • The IHaStateCache has methods for storing and retrieving user defined types.
  • Added state change Increase/Decreased helpers

Enhancements

  • Memory optimization during type conversion.
  • Consistent and documented behavior for entities entering a bad state.

Bug Fixes

  • auto-updating entities entering bad state can prevent automations with TriggerOnBadState set to true from firing.

Breaking changes

  • The return types for methods in the IUpdatingEntityProvider have been changed and new methods added.

V10.0.2

27 Oct 21:37
Compare
Choose a tag to compare

Enhancements

  • Automations on dashboard are now sorted by last time they were triggered. Previously they were sorted by the order in which they were registered, which has no real value. Now, when you go to the dashboard, you'll see the most recently triggered automations.
  • Removed requirement to set EntityId on LightTurnOnModel during init. Sometimes it is helpful to hold onto light settings without setting the entity id immediately. If you do not set it prior to making an API call, Home Assistant will return a 500.
  • Aggregate exceptions caught in the automation trace provider where the inner exception is a TaskCanceledException will now behave the same as if the outer exception was a TaskCancelledException. It will be logged, and will not report that the automation failed.
     

Bug Fixes

  • Sometimes meta data set by a user would not be used. Automations would still run as expected, but Name, Description, etc. were ignored.

Breaking changes

  • None

V10.0.1

26 Oct 13:35
Compare
Choose a tag to compare

This release fixes a couple minor bugs introduced with V10 and adds some generic automation specific enhancements.

Enhancements

  • Added strong-typed interfaces for common use cases
    • IAutomation_SceneController
    • IAutomation_ColorLight
    • IAutomation_DimmableLight
    • IAutomation_Button
  • Added state extension for getting entity Friendly Name
  • Pretty print generic automation types on dashboard

Bug Fixes

  • Automation wrappers may not always expose meta data correctly
  • Legacy LightOffOnNoMotion automation could not be registered

Breaking Changes

  • None

Version 10

25 Oct 17:00
855378c
Compare
Choose a tag to compare

New Features

  • Strongly-typed Automations. IAutomation, IConditionalAutomation, and ISchedulableAutomation all now have generic implementations. e.g. IAutomation<OnOff, ColorLightModel>. When you implement one of the generic versions, you no longer need to convert the raw HaEntityStateChange into a strongly-typed version before working with it. The conversion will be done for you.
  • IAutomationBuilder has generic methods associated with each of the new generic types.
  • IAutomationRegistrar now has TryRegister methods - Previously, the IAutomationRegistrar had different Register methods for simple and delayable automations. It was not always obvious why you could not register multiple at the same time if they were different types. This confusion would have been increased with the new generic types. The TryRegister methods take in any IAutomationBase, and find the appropriate wrapper to register them all.
  • An overload of TryRegister takes in a Func<IAutomationBase>. This expands on the safe startup ideas from V9.3. The IAutomationBuilder can throw an exception if you do not correctly configure an automation before calling the Build() method. If that occurs when using the overload that takes a Func, instead of raising the exception immediately, it will instead add the error to the initialization error collection and allow all other automations created in the registry to be registered.
  • Added AutomationTypeConversionFailure to ISystemMonitor. If type conversion for any of your strongly-typed automations fails, the system monitor will be called. This could happen if there was a breaking change in either Home Assistant or an integration you have enabled.
  • Added IFallbackExecution interface for use with strongly typed automations. If you would like to handle type conversion errors in the automation itself, you can implement this interface to receive the raw state.

Enhancements

  • Added more "For" methods for Scheduled Automations when using the builder to match existing methods for conditional automations.
  • Added more state change extension methods such as BecameGreaterThan when working with non-nullable types.

Bug Fixes

  • Automation builder would not respect some settings for delayable automations. Specifically ShouldContinueOnError
    and ShouldExecutePastEvents

Breaking Changes

  • IAutomationRegistrar has deprecated methods. They will continue to work, but will be removed in a future version.
  • Removed support for custom delay evaluators. Users can implement ISchedulableAutomation to get the same functionality.

V 9.2.2

13 Oct 15:30
Compare
Choose a tag to compare

New Features

  • Added IStartupHelpers object for injecting into your implementations of IAutomationRegistry. The only thing it does is wrap the IAutomationBuilder, IAutomationFactory, and IUpdatingEntityProvider into a single object so you have less to inject and less boiler plate to write.
  • Added API extension methods for setting values of "Input Date and/or Time" helper entities

V 9.2.1

12 Oct 17:45
Compare
Choose a tag to compare

Bug Fix

  • Ha has become sensitive to additional null values being passed in API calls. This fix is to remove any null values from API calls.

V 9.2

12 Oct 15:16
Compare
Choose a tag to compare

This version is all about startup routines. New features have been added to enable asynchronous initialization of your classes as well as several defensive startup measures.

New Features

  • New IInitializeOnStartup interface that can be applied to any automation or registry. It implements one method which will be called exactly one time at startup to allow you to execute any initialization logic you need outside of the constructor.
  • ISystemMonitor has new method called InitializationFailure, which will be called exactly 1 time at startup if there are any failures during startup. It has a default implementation that will send a persistent notification to your Home Assistant instance. If you do not like this behavior, simply implement the method and handle errors as you see fit.
  • New defensive startup routines - Along with the IInitializeOnStartup interface being added, several places in the code are now surrounded by try/catch blocks. Whereas previously, an error in startup in any automation or registry may have prevented startup. Now, if at all possible, HaKafkaNet will start and be able to execute some automations. See Startup Routines for complete details.
  • New TimeSpan extension methods on entity providers for use when you use "Date and/or Time" helper entities and select "Time" only.

Bug Fixes

  • Issue #77 - Fixed Json parsing of HA Date/Time helper states with both date and time are used

Breaking Changes

  • If you are using the test harness, you will need update it to version 9.2 also.