Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[flutter_tools] A new flutter update should show version info #68936

Open
royarg02 opened this issue Oct 24, 2020 · 5 comments
Open

[flutter_tools] A new flutter update should show version info #68936

royarg02 opened this issue Oct 24, 2020 · 5 comments
Labels
c: proposal A detailed proposal for a change to Flutter P3 Issues that are less important to the Flutter project team-tool Owned by Flutter Tool team tool Affects the "flutter" command-line tool. See also t: labels. triaged-tool Triaged by Flutter Tool team

Comments

@royarg02
Copy link
Contributor

royarg02 commented Oct 24, 2020

Continuing from #67532.

Use case

Running any flutter command from a stale install would occasionally display the following message:

  ╔════════════════════════════════════════════════════════════════════════════╗
  ║ A new version of Flutter is available!                                     ║
  ║                                                                            ║
  ║ To update to the latest version, run "flutter upgrade".                    ║
  ╚════════════════════════════════════════════════════════════════════════════╝

Since #68866 and #69420 users can check for updates manually by running flutter upgrade --verify-only.

$ flutter upgrade --verify-only
A new version of Flutter is available on channel <user channel>

The latest revision: <update version>
Your current version: <user installed version>

To upgrade now, run "flutter upgrade".
$

Provided that the user is on the stable channel, the url for release notes is also shown.

Proposal

The freshness check message needs to be updated to include the update version:

A new version of Flutter is available!

The latest revision: <update version>
Your current version: <user installed version>

To update to the latest version, run "flutter upgrade".

The freshness check uses a cache to prevent network calls at every flutter command; in case the tool determines an update from the cache, we can recommend the user to run flutter upgrade --verify-only themselves instead of displaying a "stale" latest version from the cache.

A new version of Flutter is available!

To update to the latest version, run "flutter upgrade".
To compare versions, run "flutter upgrade --verify-only".

cc @christopherfujino

@royarg02 royarg02 changed the title Add update version information to flutter doctor's upgrade message [flutter_tools] Add update version information to flutter doctor's upgrade message Oct 24, 2020
@darshankawar darshankawar added passed first triage c: proposal A detailed proposal for a change to Flutter tool Affects the "flutter" command-line tool. See also t: labels. labels Oct 26, 2020
@Oklahomawhore
Copy link

I think a release note is what we need

@royarg02
Copy link
Contributor Author

The url to view the release notes is displayed running flutter upgrade --verify-only if the user is on stable channel (I didn't update the PR message then, sorry).

See #68866 (comment) for context.

I wonder whether we should follow proposal no. 2, as the changelog has now been included in #68866.

We could maybe take the middle ground:

A new version of Flutter(<update version>) is available!

For more information, run "flutter upgrade --verify-only".
To upgrade now, run "flutter upgrade".

@jmagman jmagman added this to Awaiting triage in Tools - installer / upgrade review via automation Oct 27, 2020
@christopherfujino christopherfujino moved this from Awaiting triage to Engineer reviewed in Tools - installer / upgrade review Nov 17, 2020
@maheshmnj
Copy link
Member

This is currently supported (verified on the latest master)

mahesh@Maheshs-MacBook-Air-M1 sample % flutter upgrade --verify-only
A new version of Flutter is available on channel master

The latest version: 3.1.0-0.0.pre.2057 (revision a880c4ed35)
Your current version: 3.1.0-0.0.pre.2009 (revision 9d96c7b8be)

To upgrade now, run "flutter upgrade".
mahesh@Maheshs-MacBook-Air-M1 sample % 

Closing as fixed, Incase anyone disagrees feel free to write in the comments and we will reopen it.

Thank you.

@maheshmnj maheshmnj added the r: fixed Issue is closed as already fixed in a newer version label Aug 3, 2022
@royarg02
Copy link
Contributor Author

royarg02 commented Aug 3, 2022

This is still a valid request; the subject of this issue is the message which is displayed occasionally on a freshness check, when a flutter command is run from a stale install, flutter upgrade --verify-only is a manual update check for the user.

@royarg02 royarg02 changed the title [flutter_tools] Add update version information to flutter doctor's upgrade message [flutter_tools] Add update version information to freshness message Aug 3, 2022
@maheshmnj
Copy link
Member

Thanks for the clarification, Reopening based on the above comment

@maheshmnj maheshmnj reopened this Aug 3, 2022
Tools - installer / upgrade review automation moved this from Engineer reviewed to Awaiting triage Aug 3, 2022
@maheshmnj maheshmnj removed the r: fixed Issue is closed as already fixed in a newer version label Aug 3, 2022
@maheshmnj maheshmnj changed the title [flutter_tools] Add update version information to freshness message [flutter_tools] A new flutter upgrade should show version info Aug 3, 2022
@maheshmnj maheshmnj changed the title [flutter_tools] A new flutter upgrade should show version info [flutter_tools] A new flutter update should show version info Aug 3, 2022
@christopherfujino christopherfujino added the P3 Issues that are less important to the Flutter project label Aug 3, 2022
@flutter-triage-bot flutter-triage-bot bot added team-tool Owned by Flutter Tool team triaged-tool Triaged by Flutter Tool team labels Jul 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: proposal A detailed proposal for a change to Flutter P3 Issues that are less important to the Flutter project team-tool Owned by Flutter Tool team tool Affects the "flutter" command-line tool. See also t: labels. triaged-tool Triaged by Flutter Tool team
Projects
6 participants