Context
That PR adds an optional per-task _arg_bindings property to the serialized Dag. Review split on whether an additive field warrants a SERIALIZER_VERSION bump, which surfaced the real gap: there is no written rule for when the version changes, so every PR touching serialization re-litigates it.
Problem
SerializedDAG.SERIALIZER_VERSION is 3 today, and from_dict chains conversion_v1_to_v2 / conversion_v2_to_v3 for older blobs. But:
- No documented rule says when a bump is required, so "is this additive enough to skip it?" is argued case by case.
conversion_v2_to_v3 is a comment plus ser_obj["__version"] = 3 — it carries no conversion, so the number does not yet signal anything a reader can act on.
- In Airflow 2 the version stayed at
1 for the whole major, so it never carried information. Repeating that in Airflow 3 wastes the mechanism.
schema.json is also weaker than it looks on the write path: definitions.tasks is {"type": "array", "additionalProperties": {...}}, and additionalProperties is inert for arrays, so validate_schema never checks task objects against definitions.operator. Any policy that leans on "the schema catches it" needs this fixed first.
Scope
Decide and document:
- What a bump means — a format-compat marker, or a promise that a
conversion_vN_to_vN+1 exists and does real work.
- Whether additive optional fields bump, or only removals / renames / semantic changes.
- What a bump obligates: conversion function,
from_dict accept-list, schema.json, tests.
- How far back
from_dict supports old versions, and when old conversions can be dropped.
- Whether to repair the inert
definitions.tasks validation so schema.json is genuinely enforced.
- Release policy.
- Date based versioning? Semantic versioning?
Record the outcome in-repo (contributing docs or a serialized_objects.py module docstring) so it stops being re-decided per PR.
Context
That PR adds an optional per-task
_arg_bindingsproperty to the serialized Dag. Review split on whether an additive field warrants aSERIALIZER_VERSIONbump, which surfaced the real gap: there is no written rule for when the version changes, so every PR touching serialization re-litigates it.Problem
SerializedDAG.SERIALIZER_VERSIONis3today, andfrom_dictchainsconversion_v1_to_v2/conversion_v2_to_v3for older blobs. But:conversion_v2_to_v3is a comment plusser_obj["__version"] = 3— it carries no conversion, so the number does not yet signal anything a reader can act on.1for the whole major, so it never carried information. Repeating that in Airflow 3 wastes the mechanism.schema.jsonis also weaker than it looks on the write path:definitions.tasksis{"type": "array", "additionalProperties": {...}}, andadditionalPropertiesis inert for arrays, sovalidate_schemanever checks task objects againstdefinitions.operator. Any policy that leans on "the schema catches it" needs this fixed first.Scope
Decide and document:
conversion_vN_to_vN+1exists and does real work.from_dictaccept-list,schema.json, tests.from_dictsupports old versions, and when old conversions can be dropped.definitions.tasksvalidation soschema.jsonis genuinely enforced.Record the outcome in-repo (contributing docs or a
serialized_objects.pymodule docstring) so it stops being re-decided per PR.