"""
This node is designed to consume input bundle and test bundle change tracking.
"""


class OgnBundleConsumerPy:
    @staticmethod
    def compute(db) -> bool:
        with db.inputs.bundle.changes() as bundle_changes:
            if bundle_changes:
                db.outputs.bundle = db.inputs.bundle
                db.outputs.hasOutputBundleChanged = True
            else:
                db.outputs.hasOutputBundleChanged = False

        return True
