@ParseFlow.register('route','extend-name')
def route (tokeniser):
	change = Change(
		Flow(),
		Attributes()
	)

	while True:
		command = tokeniser()

		if not command:
			break

		action = ParseFlow.action[command]

		if action == 'nlri-add':
			for adding in ParseFlow.known[command](tokeniser):
				change.nlri.add(adding)
		elif action == 'attribute-add':
			change.attributes.add(ParseFlow.known[command](tokeniser))
		elif action == 'nexthop-and-attribute':
			nexthop,attribute = ParseFlow.known[command](tokeniser)
			change.nlri.nexthop = nexthop
			change.attributes.add(attribute)
		elif action == 'nop':
			pass  # yes nothing to do !
		else:
			raise ValueError(command % 'flow: unknown command "%s"')

	return [change]
dataset/ETHPy150Open Exa-Networks/exabgp/lib/exabgp/configuration/flow/__init__.py/route/swapped operands of `%`