Fixing `../../.pub-cache/hosted/pub.dartlang.org/charts_flutter-0.12.0/lib/src/chart_container.dart:205:27: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.`

This error has been going on for a while. It is not too bad since it is just a warning, not an error. So it does not prevent compilation. Still, after all this time, I expected the Google team, author of the package, to have fixed it by now.

This morning, I was slightly surprised to see that the package has been discontinued.

Someone actually did contribute a PR, which was closed by stuartmorgan, expert Google ticket closer. He also filed this ticket to invite anyone to fork the now discontinued project, and re-publish the package under a new name.

For now, the easier fix is to use the fork that the author of the PR made, using the git override (yaml doc):

dependency_overrides:
  charts_flutter:
    git:
      url: https://github.com/fzyzcjy/charts.git
      ref: master
      path: charts_flutter

I left a comment in the ticket as well for visibility.