echo 0.14.1


pip install echo

  Latest version

Released: Mar 30, 2026

Project Links

Meta
Author: Chris Beaumont and Thomas Robitaille
Maintainer: Chris Beaumont and Thomas Robitaille
Requires Python: >=3.10

Classifiers

Intended Audience
  • Developers

Natural Language
  • English

Operating System
  • OS Independent

Programming Language
  • Python :: 3 :: Only
  • Python :: 3.10
  • Python :: 3.11
  • Python :: 3.12
  • Python :: 3.13

CI Status Coverage Status PyPI Version

echo: Callback Properties in Python

Echo is a small library for attaching callback functions to property state changes. For example:

class Switch(object):
    state = CallbackProperty('off')

def report_change(state):
    print 'the switch is %s' % state

s = Switch()
add_callback(s, 'state', report_change)

s.state = 'on'  # prints 'the switch is on'

CalllbackProperties can also be built using decorators

class Switch(object):

      @callback_property
      def state(self):
        return self._state

      @state.setter
      def state(self, value):
          if value not in ['on', 'off']:
              raise ValueError("invalid setting")
          self._state = value

Full documentation is avilable here

Wheel compatibility matrix

Platform Python 3
any

Files in release

Extras:
Dependencies:
numpy