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

[pub] Log the Dart / Flutter SDK version selected #5748

Merged
merged 8 commits into from
Sep 20, 2022

Conversation

sigurdm
Copy link
Contributor

@sigurdm sigurdm commented Sep 19, 2022

Fix of #5396

@sigurdm sigurdm requested a review from a team as a code owner September 19, 2022 09:00
@@ -138,9 +144,12 @@ def ensure_right_flutter_release
end

parsed = JSON.parse(stdout)
flutter_version = parsed["frameworkVersion"]
dart_version = parsed["dartSdkVersion"].split.first
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
dart_version = parsed["dartSdkVersion"].split.first
dart_version = parsed["dartSdkVersion"]&.split&.first

Should we add this to safe-guard against parsed["dartSdkVersion"] being nil? This would now raise an error if it's nil.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should always have a dart version. I made the check such that the error message will become nicer.

@jurre
Copy link
Member

jurre commented Sep 19, 2022

Thanks @sigurdm! I noticed there are a few linter violations that you'll see in the CI output, they should be easy to fix up but lmk if I can help.

I also notice this breaks a (new) end-to-end test:

2022/09/19 09:05:04 [010] POST http://host.docker.internal:40845/update_jobs/cli/record_update_job_error
2022/09/19 09:05:04 type was unexpected: expected update_dependency_list got record_update_job_error

Which hints that this might be causing the job to fail, I left an in-line comment about what could potentially cause an issue here, but I may be off.

@sigurdm
Copy link
Contributor Author

sigurdm commented Sep 19, 2022

Now it seems to pass checks. PTAL

@sigurdm sigurdm requested a review from jurre September 19, 2022 14:18
Copy link
Member

@jurre jurre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, thanks @sigurdm!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants