Skip to content

[go_router_builder] Allow build 5.0.0 so apps can use build_runner 2.17.1 #194542

Closed
flutter/packages
#13455

Description

@nikolaspateras

Use case

build_runner 2.17.1 requires build >=5.0.0 <5.1.0. build 5.0.0 is the retracted build 4.1.0 republished as a major version (dart-lang/build#5223). go_router_builder 4.5.0, and main at 4.5.1, constrain build: ">=3.0.0 <5.0.0", so an app that uses go_router_builder stays on build_runner 2.16.x.

Steps to reproduce

  1. In an app with go_router_builder: ^4.5.0 in dev_dependencies, set build_runner: ^2.17.1.
  2. Run flutter pub get.

Expected: resolves.
Actual: version solving fails, because go_router_builder requires build <5.0.0 and build_runner 2.17.1 requires build >=5.0.0.

What we checked

With dependency_overrides: build: ^5.0.0 and build_runner 2.17.1, dart run build_runner build generates our typed routes (StatefulShellRoute with nested GoRouteData) and flutter analyze reports no issues. This was on Flutter 3.47.6 and Dart 3.13.5.

Proposal

Widen the constraint to build: ">=3.0.0 <6.0.0" (and source_gen if needed) in a release. Related: freezed (rrousselGit/freezed#1378) and json_serializable (google/json_serializable.dart#1598, merged) are doing the same.

Activity

  1. suryaKommana2662 commented on Oct 16, 2026

    @suryaKommana2662
    Contributor

    @nikolaspateras Thanks for the proposal. routing to the team-ecosystem for further investigation

  2. added
    packageflutter/packages repository. See also p: labels.
    c: proposalA detailed proposal for a change to Flutter
    and removed
    in triagePresently being triaged by the triage team
    on Oct 16, 2026
  3. self-assigned this
    on Oct 20, 2026
  4. added
    P2Important issues not at the top of the work list
    on Oct 20, 2026
  5. added a commit that references this issue on Oct 30, 2026
    39533da
  6. github-actions commented on Nov 13, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  7. locked as resolved and limited conversation to collaborators on Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2Important issues not at the top of the work listc: proposalA detailed proposal for a change to Flutterp: go_routerThe go_router packagepackageflutter/packages repository. See also p: labels.team-ecosystemOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem team

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions