Skip to content

Pyscript 1.7.0 release

Latest

Choose a tag to compare

@craigbarratt craigbarratt released this 09 Dec 00:23
· 2 commits to master since this release

The 1.7.0 release has several new features:

  • IDE stubs generator service for IDE support (see docs)
  • Enhanced class features (dataclass, enum, metaclass support)
  • StateVal conversion helpers and callable checks
  • MQTT retain flag and encoding support
  • Turkish translation
  • last_reported attribute for state variables

There are two minor breaking changes (hopefully unlikely for everyone):

  • Imports whose top-level package is stubs (i.e., anything below modules/stubs) are ignored at runtime, which allows you to store IDE helper modules there without affecting execution. If you have a real import called stubs you will have to rename it.
  • The period time trigger without a date in the 3rd argument now uses the date from the first argument as the default

Summary of changes:

  • Added IDE stubs generator service for better IDE support (PR #771 from @dmamelin)
  • Improved class loading to support dataclass, enum, metaclass, keywords, etc. (PR #778 from @dmamelin)
  • Added StateVal conversion helpers and availability checks (PR #769 from @dmamelin)
  • Added StateVal callable check in State.exist (PR #770 from @dmamelin)
  • Added MQTT retain flag handling to pyscript trigger and message handler (PR #755 from @3735943886)
  • Added encoding support for mqtt_trigger (PR #781 from @3735943886)
  • Added Turkish translation (PR #779 from @muminkoykiran)
  • Added last_reported to state attributes (PR #743 from @Michael-CGN)
  • Fixed @task_unique function arg (issue #761)
  • Fixed state_changed event listening to not defer until HA has started (PR #751 from @rumpeltux, fixes #750)
  • Updated period time trigger to use the date from the first argument as the default date for the 3rd argument if it is just a time
  • Full traceback now shown at debug level
  • Documentation updates

The release includes contributions from @dmamelin, @3735943886, @muminkoykiran, @rumpeltux, and @Michael-CGN. Thanks to everyone who contributed PRs and reported issues.

Enjoy!