How to use the jeepney.bus_messages.MatchRule function in jeepney

To help you get started, we’ve selected a few jeepney examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mitya57 / secretstorage / secretstorage / View on Github external
def add_match_rules(connection: DBusConnection) -> None:
	"""Adds match rules for the given connection.

	Currently it matches all messages from the Prompt interface, as the
	mock service (unlike GNOME Keyring) does not specify the signal

	.. versionadded:: 3.1
	rule = MatchRule(sender=BUS_NAME, interface=PROMPT_IFACE)
	dbus = DBusAddressWrapper(path='/org/freedesktop/DBus',
	dbus.bus_name = 'org.freedesktop.DBus''AddMatch', 's', rule.serialise())