Skip to content

Upgrading code_builder 3 to 4

Breaking3.7.0 → 4.13.0Breaking1Platform4Deprecated3New51Changed17Fixed8Other2

BreakingUpgrade verdict

1 breaking change and 4 platform requirement changes.

  • If a response contains a text id, it is no longer converted to a number automatically. Code that relied on that conversion must handle String ids itself.
  • You must use Dart 3.10.0 or newer.
  • You need Dart 3.5.0 or newer to use this version.
  • This version needs Dart 2.19 or newer.
Top 5 of 8 that need code or config changes

Dart SDK requirement changed in 4.12.0: >=2.7.0 <3.0.0 → ^3.10.0.

Breaking1
Removes automatic parsing of String ids in responses as integers, which was never part of the spec.
Platform4
Requires Dart ^3.10.0.
Requires Dart ^3.5.0.
Requires Dart 2.19.
Updates the minimum Dart SDK version to 3.11.0.
Deprecated3
Deprecates and removes uses of Expression.expression.
Expression.expression
Deprecates Expression.operatorSubstract.
Expression.operatorSubstract
Deprecates assignVar, assignConst, and assignFinal.
assignVarassignConstassignFinal