devolo / cockpit_open_frontend

A rewrite of the devolo Cockpit front end in Flutter
BSD 3-Clause "New" or "Revised" License
6 stars 3 forks source link

CI: Add nightly build for android, iOS, Web, Windows, Linux and macOS #11

Closed olof-nord closed 2 years ago

olof-nord commented 2 years ago

Using the same GitHub Action which is already in use for the unit tests, add a nightly build for all flutter supported platforms.

The configuration of the jobs is basically that which the readme of the Action is outlining: I do not know which platforms are intended to be supported - this is the maximum possible, feel free to adjust accordingly.

https://github.com/subosito/flutter-action

olof-nord commented 2 years ago

The motivation for a nightly build job is to aim to avoid situations like the one fixed with #10

Shutgun commented 2 years ago

Hi @olof-nord , could you please remove Android, iOS and web as the don't target those platforms?

We will then merge the MR but will deactivate the workflow to save the CI time github offers us. We have an internal job that builds for us and does the same job. Nevertheless, we find the idea useful to have a job like that so that e.g. you could activate it in your fork. And we still need to investigate, why we didn't catch #10 ...

olof-nord commented 2 years ago

Hello @Shutgun, if you already have internal jobs for this then there's no need to merge this.

When executed locally, I was using the following flutter version:

$ flutter --version
Flutter 2.10.3 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 7e9793dee1 (2 weeks ago) • 2022-03-02 11:23:12 -0600
Engine • revision bd539267b4
Tools • Dart 2.16.1 • DevTools 2.9.2

Looking at the unit test job, the flutter version is specified to 2.8.1: That is a version from 16/12/2021. One idea would be to adjust the CI to use the latest version of flutter rather than a specific version.

Shutgun commented 2 years ago

Yeah, I'd love to always use the latest flutter version, but when I made the unit test CI workflow, subosito's flutter-action didn't work with specifying the channel only. I had to give it a version. Do you have any experience, if that changed in the meantime?

olof-nord commented 2 years ago

The "Test" CI runs through fine using the "stable" channel: what was needed is to adjust the flutter dependencies with flutter pub upgrade. This updates the packages automatically - https://docs.flutter.dev/development/tools/sdk/upgrading#upgrading-packages

Instead of executing flutter pub upgrade in the CI, I think it would be better to run this locally and commit the changes (on my machine using the latest "stable" toolchain, its two files, pubspec.lock and windows/flutter/generated_plugin_registrant.cc) - once this is done we can see that the CI runs fine.

CI: https://github.com/olof-nord/cockpit_open_frontend/runs/6043097976?check_suite_focus=true

Commit: https://github.com/olof-nord/cockpit_open_frontend/commit/3c68a3393a96c8a20963778736619e675811db2a