From cde971b28918528aaa8f899d0befdf912fb4f513 Mon Sep 17 00:00:00 2001 From: Mohammad Bagher Fakouri Date: Thu, 25 May 2023 09:12:43 +0330 Subject: [PATCH 01/39] Create CONTRIBUTING.md --- CONTRIBUTING.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 000000000..e8e749dcd --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,19 @@ +# Contributing to Parse SDK for Flutter +We want to make contributing to this project as easy and transparent as possible. + +## Pull Requests +We actively welcome your pull requests. When we get one, we'll run some Parse-specific integration tests on it first. From here, we'll need to get a core member to sign off on the changes and then merge the pull request. For API changes we may need to fix internal uses, which could cause some delay. We'll do our best to provide updates and feedback throughout the process. + +1. Fork the repo and create your branch from `master`. +4. Add unit tests for any new code you add. +3. If you've changed APIs, update the documentation. +4. Ensure the test suite passes. + +## Code of Conduct +This project adheres to the [Contributor Covenant Code of Conduct](https://github.com/parse-community/parse-server/blob/master/CODE_OF_CONDUCT.md). By participating, you are expected to honor this code. + +## License +By contributing to Parse SDK Flutter, you agree that your contributions will be licensed under its license. + +[stack-overflow]: http://stackoverflow.com/tags/parse.com +[bug-reports]: https://github.com/parse-community/parse-server From 835a1db0029a66fe80fecdfc4b88584c65dc8f45 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Thu, 25 May 2023 13:17:54 +0200 Subject: [PATCH 02/39] just some styling --- CONTRIBUTING.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e8e749dcd..5f35995ba 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,18 +1,22 @@ # Contributing to Parse SDK for Flutter + We want to make contributing to this project as easy and transparent as possible. ## Pull Requests + We actively welcome your pull requests. When we get one, we'll run some Parse-specific integration tests on it first. From here, we'll need to get a core member to sign off on the changes and then merge the pull request. For API changes we may need to fix internal uses, which could cause some delay. We'll do our best to provide updates and feedback throughout the process. 1. Fork the repo and create your branch from `master`. -4. Add unit tests for any new code you add. +2. Add unit tests for any new code you add. 3. If you've changed APIs, update the documentation. 4. Ensure the test suite passes. ## Code of Conduct + This project adheres to the [Contributor Covenant Code of Conduct](https://github.com/parse-community/parse-server/blob/master/CODE_OF_CONDUCT.md). By participating, you are expected to honor this code. ## License + By contributing to Parse SDK Flutter, you agree that your contributions will be licensed under its license. [stack-overflow]: http://stackoverflow.com/tags/parse.com From be0a838fb6252c21ddda8fa47d225406ee821da2 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Tue, 3 Oct 2023 13:47:49 +0330 Subject: [PATCH 03/39] Improve support policy --- .github/workflows/ci.yml | 48 ++++++++++++++++++----------------- packages/dart/README.md | 30 ++++++++++++++-------- packages/dart/pubspec.yaml | 2 +- packages/flutter/README.md | 37 +++++++++++++++++++-------- packages/flutter/pubspec.yaml | 3 ++- 5 files changed, 74 insertions(+), 46 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a56e36314..571f06439 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,24 +15,25 @@ jobs: strategy: matrix: include: - # Dart framework may contain breaking changes in minor version releases, not following semver. - - name: Dart 3.0, Ubuntu + # Dart 3.1 + - name: Dart 3.1, Ubuntu os: ubuntu-latest - sdk: 3.0.0 + sdk: 3.1.2 - name: Dart 3.0, macOS os: macos-latest - sdk: 3.0.0 + sdk: 3.1.2 - name: Dart 3.0, Windows os: windows-latest - sdk: 3.0.0 - # Only the latest Dart framework version (above) is tested with all architectures. Previous - # Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. + sdk: 3.1.2 + # Dart 3.0 + - name: Dart 3.0 + os: ubuntu-latest + sdk: 3.0.7 + # Dart 2.19 - name: Dart 2.19 os: ubuntu-latest sdk: 2.19.6 - - name: Dart 2.18 - os: ubuntu-latest - sdk: 2.18.7 + # Dart beta - name: Dart beta os: ubuntu-latest sdk: beta @@ -76,24 +77,25 @@ jobs: strategy: matrix: include: - # Flutter framework may contain breaking changes in minor version releases, not following semver. - - name: Flutter 3.10, Ubuntu + # Flutter 3.13 + - name: Flutter 3.13, Ubuntu os: ubuntu-latest - sdk: 3.10.x - - name: Flutter 3.10, macOS + sdk: 3.13.6 + - name: Flutter 3.13, macOS os: macos-latest - sdk: 3.10.x - - name: Flutter 3.10, Windows + sdk: 3.13.6 + - name: Flutter 3.13, Windows os: windows-latest - sdk: 3.10.x - # Only the latest Flutter framework version (above) is tested with all architectures. Previous - # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - - name: Flutter 3.7 + sdk: 3.13.6 + # Flutter 3.10 + - name: Flutter 3.10 os: ubuntu-latest - sdk: 3.7.x - - name: Flutter 3.3 + sdk: 3.10.6 + # Flutter 3.7 + - name: Flutter 3.7 os: ubuntu-latest - sdk: 3.3.x + sdk: 3.7.12 + # Flutter beta - name: Flutter beta os: ubuntu-latest sdk: beta diff --git a/packages/dart/README.md b/packages/dart/README.md index 95c1a6211..215316677 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -15,7 +15,9 @@ --- -This library gives you access to the powerful Parse Server backend from your Dart app. For more information on Parse Platform and its features, visit [parseplatform.org](https://parseplatform.org). +This library gives you access to the powerful Parse Server backend from your Dart app. For more +information on Parse Platform and its features, +visit [parseplatform.org](https://parseplatform.org). --- @@ -28,18 +30,24 @@ This library gives you access to the powerful Parse Server backend from your Dar ## Compatibility -The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to ensure compatibility. To give developers time to upgrade their app to the newest Dart framework, previous Dart framework releases are supported for at least 1 year after their [release date](https://dart.dev/get-dart/archive). +The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to +ensure compatibility. To give developers time to upgrade their app to the newest Dart framework, +previous Dart framework releases are supported for at least 1 year after +their [release date](https://dart.dev/get-dart/archive). -| Version | Latest Version | End of Support | Compatible | -|-----------|----------------|----------------|----------------------------------------------| -| Dart 3.0 | 3.0.0 | May 2024 | ✅ Yes | -| Dart 2.19 | 2.19.6 | Mar 2024 | ✅ Yes | -| Dart 2.18 | 2.18.7 | Jan 2024 | ✅ Yes | -| Dart 2.17 | 2.17.7 | Aug 2023 | ❌ No (Parse Dart SDK requires Dart >=2.18.0) | +| Version | Latest Version | End of Support | Compatible | +|-----------|----------------|----------------|------------| +| Dart 3.1 | 3.1.2 | Sep 2024 | ✅ Yes | +| Dart 3.0 | 3.0.7 | May 2024 | ✅ Yes | +| Dart 2.19 | 2.19.6 | Mar 2024 | ✅ Yes | +| Dart 2.18 | 2.18.5 | Nov 2023 | ❌ No | + +> Parse Dart SDK requires **Dart >=2.19.6** ## Getting Started -To install, add the Parse Dart SDK as a [dependency](https://pub.dev/packages/parse_server_sdk/install) in your `pubspec.yaml` file. +To install, add the Parse Dart SDK as +a [dependency](https://pub.dev/packages/parse_server_sdk/install) in your `pubspec.yaml` file. ## Documentation @@ -47,7 +55,9 @@ Find the full documentation in the [Parse Dart SDK guide][guide]. ## Contributing -We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). +We want to make contributing to this project as easy and transparent as possible. Please refer to +the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/dart/guide/ + [open-collective-link]: https://opencollective.com/parse-server diff --git a/packages/dart/pubspec.yaml b/packages/dart/pubspec.yaml index b11457b16..b720c1820 100644 --- a/packages/dart/pubspec.yaml +++ b/packages/dart/pubspec.yaml @@ -18,7 +18,7 @@ topics: - backend environment: - sdk: ">=2.18.0 <4.0.0" + sdk: ">=2.19.6 <4.0.0" dependencies: # Networking diff --git a/packages/flutter/README.md b/packages/flutter/README.md index 21ad7ecc6..88d68d95b 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -5,7 +5,7 @@ [![Build Status](https://github.com/parse-community/Parse-SDK-Flutter/workflows/ci/badge.svg?branch=master)](https://github.com/parse-community/Parse-SDK-Flutter/actions?query=workflow%3Aci+branch%3Amaster) [![Coverage](https://img.shields.io/codecov/c/github/parse-community/Parse-SDK-Flutter/master)](https://app.codecov.io/gh/parse-community/Parse-SDK-Flutter/branch/master) -[![pub package](https://img.shields.io/pub/v/parse_server_sdk_flutter.svg)](https://pub.dev/packages/parse_server_sdk_flutter) +[![pub package](https://img.shields.io/pub/v/parse_server_sdk_flutter.svg)](https://pub.dev/packages/parse_server_sdk_flutter) [![Forum](https://img.shields.io/discourse/https/community.parseplatform.org/topics.svg)](https://community.parseplatform.org/c/parse-server) [![Backers on Open Collective](https://opencollective.com/parse-server/backers/badge.svg)][open-collective-link] @@ -15,7 +15,9 @@ --- -This library gives you access to the powerful Parse Server backend from your Flutter app. For more information on Parse Platform and its features, visit [parseplatform.org](https://parseplatform.org). +This library gives you access to the powerful Parse Server backend from your Flutter app. For more +information on Parse Platform and its features, +visit [parseplatform.org](https://parseplatform.org). --- @@ -28,18 +30,29 @@ This library gives you access to the powerful Parse Server backend from your Flu ## Compatibility -The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to the newest Flutter framework, previous Flutter framework releases are supported for at least 1 year after their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the Flutter framework version cannot be supported even though its release date may have been less than a year ago. +The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework +to ensure compatibility. To give developers time to upgrade their app to the newest Flutter +framework, previous Flutter framework releases are supported for at least 1 year after +their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK +depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter +framework version, in which case the Flutter framework version cannot be supported even though its +release date may have been less than a year ago. -| Version | End of Support | Compatible | -|--------------|----------------|----------------------------------------------| -| Flutter 3.10 | May 2024 | ❌ No | -| Flutter 3.7 | Apr 2024 | ✅ Yes | -| Flutter 3.3 | Jan 2024 | ✅ Yes | -| Flutter 3.0 | Jul 2023 | ❌ No (Parse Flutter SDK requires Flutter >=3.3.0) | +| Version | Latest Version | End of Support | Compatible | +|--------------|----------------|----------------|------------| +| Flutter 3.13 | 3.13.6 | Sep 2024 | ✅ Yes | +| Flutter 3.10 | 3.10.6 | Jul 2024 | ✅ Yes | +| Flutter 3.7 | 3.7.12 | Apr 2024 | ✅ Yes | +| Flutter 3.3 | 3.3.10 | Dec 2024 | ✅ Yes | +| Flutter 3.0 | 3.0.5 | Jul 2023 | ❌ No | + +> Parse Flutter SDK requires **Flutter >=3.3.10** ## Getting Started -To install, add the Parse Flutter SDK as a [dependency](https://pub.dev/packages/parse_server_sdk_flutter/install) in your `pubspec.yaml` file. +To install, add the Parse Flutter SDK as +a [dependency](https://pub.dev/packages/parse_server_sdk_flutter/install) in your `pubspec.yaml` +file. ## Documentation @@ -47,7 +60,9 @@ Find the full documentation in the [Parse Flutter SDK guide][guide]. ## Contributing -We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). +We want to make contributing to this project as easy and transparent as possible. Please refer to +the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/flutter/guide/ + [open-collective-link]: https://opencollective.com/parse-server diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index 8f3a18c63..e527d144e 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -18,7 +18,8 @@ topics: - backend environment: - sdk: ">=2.18.0 <4.0.0" + sdk: ">=2.19.6 <4.0.0" + flutter: ">=3.3.10 <4.0.0" dependencies: flutter: From 636706c73098700dc72e67bd7067d7185b15c89e Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Tue, 3 Oct 2023 13:54:05 +0330 Subject: [PATCH 04/39] refactor: fix fix lower bound --- packages/flutter/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index e527d144e..6674b882e 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -19,7 +19,7 @@ topics: environment: sdk: ">=2.19.6 <4.0.0" - flutter: ">=3.3.10 <4.0.0" + flutter: ">=3.3.10" dependencies: flutter: From 45d957339247d27fa3a9323c99f4b07f96849022 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Tue, 3 Oct 2023 14:01:15 +0330 Subject: [PATCH 05/39] refactor: fix fix WillPopScope --- .../flutter/example/lib/pages/home_page.dart | 59 +++++++++---------- .../flutter/example/lib/pages/login_page.dart | 25 ++++---- 2 files changed, 39 insertions(+), 45 deletions(-) diff --git a/packages/flutter/example/lib/pages/home_page.dart b/packages/flutter/example/lib/pages/home_page.dart index 6c5349e64..7323d2fe4 100644 --- a/packages/flutter/example/lib/pages/home_page.dart +++ b/packages/flutter/example/lib/pages/home_page.dart @@ -33,37 +33,34 @@ class _HomePageState extends State { @override Widget build(BuildContext context) { - return WillPopScope( - onWillPop: () async => false, - child: Scaffold( - appBar: AppBar( - automaticallyImplyLeading: false, - title: const Text('Parse Server demo'), - actions: [ - TextButton( - child: const Text('Logout', - style: TextStyle(fontSize: 17.0, color: Colors.white)), - onPressed: () async { - final ParseUser user = await ParseUser.currentUser(); - user.logout(deleteLocalUserData: true); - Navigator.pop(context as dynamic, true); - }) - ], - ), - body: _showDietList(), - floatingActionButton: FloatingActionButton( - onPressed: () async { - final DietPlan dietPlan = - randomDietPlans[Random().nextInt(randomDietPlans.length - 1)]; - final ParseUser user = await ParseUser.currentUser(); - dietPlan.set('user', user); - await widget._dietPlanProvider.add(dietPlan); - setState(() {}); - }, - tooltip: 'Add Diet Plans', - child: const Icon(Icons.add), - )), - ); + return Scaffold( + appBar: AppBar( + automaticallyImplyLeading: false, + title: const Text('Parse Server demo'), + actions: [ + TextButton( + child: const Text('Logout', + style: TextStyle(fontSize: 17.0, color: Colors.white)), + onPressed: () async { + final ParseUser user = await ParseUser.currentUser(); + user.logout(deleteLocalUserData: true); + Navigator.pop(context as dynamic, true); + }) + ], + ), + body: _showDietList(), + floatingActionButton: FloatingActionButton( + onPressed: () async { + final DietPlan dietPlan = + randomDietPlans[Random().nextInt(randomDietPlans.length - 1)]; + final ParseUser user = await ParseUser.currentUser(); + dietPlan.set('user', user); + await widget._dietPlanProvider.add(dietPlan); + setState(() {}); + }, + tooltip: 'Add Diet Plans', + child: const Icon(Icons.add), + )); } Widget _showDietList() { diff --git a/packages/flutter/example/lib/pages/login_page.dart b/packages/flutter/example/lib/pages/login_page.dart index ab3a386d8..d68d86bbc 100644 --- a/packages/flutter/example/lib/pages/login_page.dart +++ b/packages/flutter/example/lib/pages/login_page.dart @@ -98,20 +98,17 @@ class _LoginPageState extends State { @override Widget build(BuildContext context) { - return WillPopScope( - onWillPop: () async => false, - child: Scaffold( - appBar: AppBar( - automaticallyImplyLeading: false, - title: const Text('Parse Server demo'), - ), - body: Stack( - children: [ - _showBody(), - _showCircularProgress(), - ], - )), - ); + return Scaffold( + appBar: AppBar( + automaticallyImplyLeading: false, + title: const Text('Parse Server demo'), + ), + body: Stack( + children: [ + _showBody(), + _showCircularProgress(), + ], + )); } Widget _showCircularProgress() { From 24febff959864373cde499f81cf6ff5be91e2d2f Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Tue, 3 Oct 2023 18:11:41 +0330 Subject: [PATCH 06/39] refactor: fix fix code formatting --- packages/dart/README.md | 15 ++++----------- packages/flutter/README.md | 19 ++++--------------- 2 files changed, 8 insertions(+), 26 deletions(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index 215316677..2124848d1 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -15,9 +15,7 @@ --- -This library gives you access to the powerful Parse Server backend from your Dart app. For more -information on Parse Platform and its features, -visit [parseplatform.org](https://parseplatform.org). +This library gives you access to the powerful Parse Server backend from your Dart app. For more information on Parse Platform and its features, visit [parseplatform.org](https://parseplatform.org). --- @@ -30,10 +28,7 @@ visit [parseplatform.org](https://parseplatform.org). ## Compatibility -The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to -ensure compatibility. To give developers time to upgrade their app to the newest Dart framework, -previous Dart framework releases are supported for at least 1 year after -their [release date](https://dart.dev/get-dart/archive). +The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to ensure compatibility. To give developers time to upgrade their app to the newest Dart framework, previous Dart framework releases are supported for at least 1 year after their [release date](https://dart.dev/get-dart/archive). | Version | Latest Version | End of Support | Compatible | |-----------|----------------|----------------|------------| @@ -46,8 +41,7 @@ their [release date](https://dart.dev/get-dart/archive). ## Getting Started -To install, add the Parse Dart SDK as -a [dependency](https://pub.dev/packages/parse_server_sdk/install) in your `pubspec.yaml` file. +To install, add the Parse Dart SDK as a [dependency](https://pub.dev/packages/parse_server_sdk/install) in your `pubspec.yaml` file. ## Documentation @@ -55,8 +49,7 @@ Find the full documentation in the [Parse Dart SDK guide][guide]. ## Contributing -We want to make contributing to this project as easy and transparent as possible. Please refer to -the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). +We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/dart/guide/ diff --git a/packages/flutter/README.md b/packages/flutter/README.md index 88d68d95b..f688d0a4e 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -15,9 +15,7 @@ --- -This library gives you access to the powerful Parse Server backend from your Flutter app. For more -information on Parse Platform and its features, -visit [parseplatform.org](https://parseplatform.org). +This library gives you access to the powerful Parse Server backend from your Flutter app. For more information on Parse Platform and its features, visit [parseplatform.org](https://parseplatform.org). --- @@ -30,13 +28,7 @@ visit [parseplatform.org](https://parseplatform.org). ## Compatibility -The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework -to ensure compatibility. To give developers time to upgrade their app to the newest Flutter -framework, previous Flutter framework releases are supported for at least 1 year after -their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK -depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter -framework version, in which case the Flutter framework version cannot be supported even though its -release date may have been less than a year ago. +The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to the newest Flutter framework, previous Flutter framework releases are supported for at least 1 year after their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the Flutter framework version cannot be supported even though its release date may have been less than a year ago. | Version | Latest Version | End of Support | Compatible | |--------------|----------------|----------------|------------| @@ -50,9 +42,7 @@ release date may have been less than a year ago. ## Getting Started -To install, add the Parse Flutter SDK as -a [dependency](https://pub.dev/packages/parse_server_sdk_flutter/install) in your `pubspec.yaml` -file. +To install, add the Parse Flutter SDK as a [dependency](https://pub.dev/packages/parse_server_sdk_flutter/install) in your `pubspec.yaml` file. ## Documentation @@ -60,8 +50,7 @@ Find the full documentation in the [Parse Flutter SDK guide][guide]. ## Contributing -We want to make contributing to this project as easy and transparent as possible. Please refer to -the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). +We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/flutter/guide/ From 35dd59f5fc015c2ad5c5be8734bbf6f678f9e966 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Tue, 3 Oct 2023 18:23:53 +0330 Subject: [PATCH 07/39] refactor: fix upgrade examples environment version --- packages/dart/example/pubspec.yaml | 2 +- packages/flutter/example/pubspec.yaml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/dart/example/pubspec.yaml b/packages/dart/example/pubspec.yaml index 331856eb3..0a2e92fa6 100644 --- a/packages/dart/example/pubspec.yaml +++ b/packages/dart/example/pubspec.yaml @@ -5,7 +5,7 @@ publish_to: 'none' version: 1.0.0 environment: - sdk: ">=2.18.0 <4.0.0" + sdk: ">=2.19.6 <4.0.0" dependencies: parse_server_sdk: diff --git a/packages/flutter/example/pubspec.yaml b/packages/flutter/example/pubspec.yaml index 0a48d0b20..1a2251ab5 100644 --- a/packages/flutter/example/pubspec.yaml +++ b/packages/flutter/example/pubspec.yaml @@ -5,7 +5,8 @@ publish_to: 'none' version: 1.0.0 environment: - sdk: ">=2.18.0 <4.0.0" + sdk: ">=2.19.6 <4.0.0" + flutter: ">=3.3.10" dependencies: flutter: From 6a70b83f879fee7776913ef6c44e9e4242d355f5 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:14:10 +0200 Subject: [PATCH 08/39] Update packages/dart/README.md --- packages/dart/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index 2124848d1..dc587374d 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -52,5 +52,5 @@ Find the full documentation in the [Parse Dart SDK guide][guide]. We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/dart/guide/ - [open-collective-link]: https://opencollective.com/parse-server + From a0e630d309f9164419e383a2829e3cb81a4a1cca Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:15:06 +0200 Subject: [PATCH 09/39] Update packages/flutter/README.md --- packages/flutter/README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/flutter/README.md b/packages/flutter/README.md index f688d0a4e..de1aef7a5 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -53,5 +53,4 @@ Find the full documentation in the [Parse Flutter SDK guide][guide]. We want to make contributing to this project as easy and transparent as possible. Please refer to the [Contribution Guidelines](https://github.com/parse-community/Parse-SDK-Flutter/blob/master/CONTRIBUTING.md). [guide]: https://docs.parseplatform.org/flutter/guide/ - [open-collective-link]: https://opencollective.com/parse-server From 9424aba6092e84d7cc4ebe9d9e565d7203f8b06c Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:19:08 +0200 Subject: [PATCH 10/39] Update packages/dart/README.md --- packages/dart/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index dc587374d..4336ca16a 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -28,7 +28,8 @@ This library gives you access to the powerful Parse Server backend from your Dar ## Compatibility -The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to ensure compatibility. To give developers time to upgrade their app to the newest Dart framework, previous Dart framework releases are supported for at least 1 year after their [release date](https://dart.dev/get-dart/archive). +The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to ensure compatibility. To give developers time to upgrade their app to a newer Dart framework, previous Dart framework releases are supported for at least 1 year after the [release date](https://dart.dev/get-dart/archive) of the next higher significant version. + | Version | Latest Version | End of Support | Compatible | |-----------|----------------|----------------|------------| From 75420cdb661656bca68f8f680551b8c0a6a7387f Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:21:14 +0200 Subject: [PATCH 11/39] Update packages/dart/README.md --- packages/dart/README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index 4336ca16a..92c578ffb 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -38,7 +38,6 @@ The Parse Dart SDK is continuously tested with the most recent release of the Da | Dart 2.19 | 2.19.6 | Mar 2024 | ✅ Yes | | Dart 2.18 | 2.18.5 | Nov 2023 | ❌ No | -> Parse Dart SDK requires **Dart >=2.19.6** ## Getting Started From e7765eeff8fe03e62cdcd3ae12e681d7ccfdfef0 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:21:40 +0200 Subject: [PATCH 12/39] Update packages/dart/README.md --- packages/dart/README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index 92c578ffb..1d666d3c4 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -36,7 +36,6 @@ The Parse Dart SDK is continuously tested with the most recent release of the Da | Dart 3.1 | 3.1.2 | Sep 2024 | ✅ Yes | | Dart 3.0 | 3.0.7 | May 2024 | ✅ Yes | | Dart 2.19 | 2.19.6 | Mar 2024 | ✅ Yes | -| Dart 2.18 | 2.18.5 | Nov 2023 | ❌ No | ## Getting Started From 362e7c0f92a1bbce5df11115a21e23ecc4f87dc3 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:22:12 +0200 Subject: [PATCH 13/39] Update packages/dart/README.md --- packages/dart/README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index 1d666d3c4..f28993b02 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -30,7 +30,6 @@ This library gives you access to the powerful Parse Server backend from your Dar The Parse Dart SDK is continuously tested with the most recent release of the Dart framework to ensure compatibility. To give developers time to upgrade their app to a newer Dart framework, previous Dart framework releases are supported for at least 1 year after the [release date](https://dart.dev/get-dart/archive) of the next higher significant version. - | Version | Latest Version | End of Support | Compatible | |-----------|----------------|----------------|------------| | Dart 3.1 | 3.1.2 | Sep 2024 | ✅ Yes | From 7b1f6804ddc6816d694ca83b25a54bec82f0c29e Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:23:13 +0200 Subject: [PATCH 14/39] Update packages/dart/README.md --- packages/dart/README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/dart/README.md b/packages/dart/README.md index f28993b02..0a751c7bd 100644 --- a/packages/dart/README.md +++ b/packages/dart/README.md @@ -36,7 +36,6 @@ The Parse Dart SDK is continuously tested with the most recent release of the Da | Dart 3.0 | 3.0.7 | May 2024 | ✅ Yes | | Dart 2.19 | 2.19.6 | Mar 2024 | ✅ Yes | - ## Getting Started To install, add the Parse Dart SDK as a [dependency](https://pub.dev/packages/parse_server_sdk/install) in your `pubspec.yaml` file. From 7deec6793e52ce232fdfff9fdbacef80adbe2fb8 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:24:00 +0200 Subject: [PATCH 15/39] Update packages/flutter/README.md --- packages/flutter/README.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/packages/flutter/README.md b/packages/flutter/README.md index de1aef7a5..8b3d12744 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -36,9 +36,6 @@ The Parse Flutter SDK is continuously tested with the most recent release of the | Flutter 3.10 | 3.10.6 | Jul 2024 | ✅ Yes | | Flutter 3.7 | 3.7.12 | Apr 2024 | ✅ Yes | | Flutter 3.3 | 3.3.10 | Dec 2024 | ✅ Yes | -| Flutter 3.0 | 3.0.5 | Jul 2023 | ❌ No | - -> Parse Flutter SDK requires **Flutter >=3.3.10** ## Getting Started From f725a5049e93fc64e950c5e16a6e47daaeb841e5 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Tue, 3 Oct 2023 18:28:34 +0200 Subject: [PATCH 16/39] Update packages/flutter/README.md --- packages/flutter/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/flutter/README.md b/packages/flutter/README.md index 8b3d12744..50ed228d9 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -28,7 +28,7 @@ This library gives you access to the powerful Parse Server backend from your Flu ## Compatibility -The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to the newest Flutter framework, previous Flutter framework releases are supported for at least 1 year after their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the Flutter framework version cannot be supported even though its release date may have been less than a year ago. +The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to a newer Flutter framework, previous Flutter framework releases are supported for at least 1 year after the [release date](https://docs.flutter.dev/release/archive?tab=linux) of the next higher significant version. The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the specific Flutter framework version cannot be supported. | Version | Latest Version | End of Support | Compatible | |--------------|----------------|----------------|------------| From acf5d009bf44bd0623edc2f9c4d166a3a68bfec8 Mon Sep 17 00:00:00 2001 From: Manuel Trezza <5673677+mtrezza@users.noreply.github.com> Date: Wed, 4 Oct 2023 00:11:40 +0200 Subject: [PATCH 17/39] extend matrix --- .github/workflows/ci.yml | 31 +++++++------------------------ 1 file changed, 7 insertions(+), 24 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 571f06439..5faf542e8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,31 +14,14 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - include: - # Dart 3.1 - - name: Dart 3.1, Ubuntu - os: ubuntu-latest - sdk: 3.1.2 - - name: Dart 3.0, macOS - os: macos-latest - sdk: 3.1.2 - - name: Dart 3.0, Windows - os: windows-latest - sdk: 3.1.2 - # Dart 3.0 - - name: Dart 3.0 - os: ubuntu-latest - sdk: 3.0.7 - # Dart 2.19 - - name: Dart 2.19 - os: ubuntu-latest - sdk: 2.19.6 - # Dart beta - - name: Dart beta - os: ubuntu-latest - sdk: beta + os: [ubuntu-latest, macos-latest, windows-latest] + sdk: + - 3.1.2 + - 3.0.7 + - 2.19.6 + - beta fail-fast: false - name: Test ${{ matrix.name }} + name: Test ${{ matrix.sdk }}, ${{ matrix.os }} steps: - name: Checkout code uses: actions/checkout@v3 From 1afb6cad5d93c742d51b208c9ac237ed74b9b8cf Mon Sep 17 00:00:00 2001 From: Manuel Trezza <5673677+mtrezza@users.noreply.github.com> Date: Wed, 4 Oct 2023 00:12:27 +0200 Subject: [PATCH 18/39] fix name --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5faf542e8..8921774ab 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,7 @@ jobs: - 2.19.6 - beta fail-fast: false - name: Test ${{ matrix.sdk }}, ${{ matrix.os }} + name: Test Dart ${{ matrix.sdk }}, ${{ matrix.os }} steps: - name: Checkout code uses: actions/checkout@v3 From 135f89b336de178bbb5c5a94f28c8f5e1e0e312d Mon Sep 17 00:00:00 2001 From: Manuel Trezza <5673677+mtrezza@users.noreply.github.com> Date: Wed, 4 Oct 2023 00:16:30 +0200 Subject: [PATCH 19/39] ci flutter matrix --- .github/workflows/ci.yml | 31 +++++++------------------------ 1 file changed, 7 insertions(+), 24 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8921774ab..6e8950105 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -59,31 +59,14 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - include: - # Flutter 3.13 - - name: Flutter 3.13, Ubuntu - os: ubuntu-latest - sdk: 3.13.6 - - name: Flutter 3.13, macOS - os: macos-latest - sdk: 3.13.6 - - name: Flutter 3.13, Windows - os: windows-latest - sdk: 3.13.6 - # Flutter 3.10 - - name: Flutter 3.10 - os: ubuntu-latest - sdk: 3.10.6 - # Flutter 3.7 - - name: Flutter 3.7 - os: ubuntu-latest - sdk: 3.7.12 - # Flutter beta - - name: Flutter beta - os: ubuntu-latest - sdk: beta + os: [ubuntu-latest, macos-latest, windows-latest] + sdk: + - 3.13.6 + - 3.10.6 + - 3.7.12 + - beta fail-fast: false - name: Test ${{ matrix.name }} + name: Test Flutter ${{ matrix.sdk }}, ${{ matrix.os }} steps: - name: Checkout code uses: actions/checkout@v3 From 20feb85697f1acdc1eee39cc34e2f48e1dba9a62 Mon Sep 17 00:00:00 2001 From: Manuel Trezza <5673677+mtrezza@users.noreply.github.com> Date: Wed, 4 Oct 2023 01:10:01 +0200 Subject: [PATCH 20/39] revert ci --- .github/workflows/ci.yml | 56 ++++++++++++++++++++++++++++++---------- 1 file changed, 42 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6e8950105..178c74572 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,14 +14,28 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, macos-latest, windows-latest] - sdk: - - 3.1.2 - - 3.0.7 - - 2.19.6 - - beta + include: + # Dart framework may contain breaking changes in minor version releases, not following semver. + - name: Dart 3.1, Ubuntu + os: ubuntu-latest + sdk: 3.1.2 + - name: Dart 3.0, macOS + os: macos-latest + sdk: 3.1.2 + - name: Dart 3.0, Windows + os: windows-latest + sdk: 3.1.2 + - name: Dart 3.0 + os: ubuntu-latest + sdk: 3.0.7 + - name: Dart 2.19 + os: ubuntu-latest + sdk: 2.19.6 + - name: Dart beta + os: ubuntu-latest + sdk: beta fail-fast: false - name: Test Dart ${{ matrix.sdk }}, ${{ matrix.os }} + name: Test ${{ matrix.name }} steps: - name: Checkout code uses: actions/checkout@v3 @@ -59,14 +73,28 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, macos-latest, windows-latest] - sdk: - - 3.13.6 - - 3.10.6 - - 3.7.12 - - beta + include: + # Flutter framework may contain breaking changes in minor version releases, not following semver. + - name: Flutter 3.13, Ubuntu + os: ubuntu-latest + sdk: 3.13.6 + - name: Flutter 3.13, macOS + os: macos-latest + sdk: 3.13.6 + - name: Flutter 3.13, Windows + os: windows-latest + sdk: 3.13.6 + - name: Flutter 3.10 + os: ubuntu-latest + sdk: 3.10.6 + - name: Flutter 3.7 + os: ubuntu-latest + sdk: 3.7.12 + - name: Flutter beta + os: ubuntu-latest + sdk: beta fail-fast: false - name: Test Flutter ${{ matrix.sdk }}, ${{ matrix.os }} + name: Test ${{ matrix.name }} steps: - name: Checkout code uses: actions/checkout@v3 From 5c95fd0cf20b665ff527fea4b8090c231df1b439 Mon Sep 17 00:00:00 2001 From: Manuel Trezza <5673677+mtrezza@users.noreply.github.com> Date: Wed, 4 Oct 2023 01:12:10 +0200 Subject: [PATCH 21/39] re-add comments in CI --- .github/workflows/ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 178c74572..d297d738a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,6 +25,8 @@ jobs: - name: Dart 3.0, Windows os: windows-latest sdk: 3.1.2 + # Only the latest Dart framework version (above) is tested with all architectures. Previous + # Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - name: Dart 3.0 os: ubuntu-latest sdk: 3.0.7 @@ -84,6 +86,8 @@ jobs: - name: Flutter 3.13, Windows os: windows-latest sdk: 3.13.6 + # Only the latest Flutter framework version (above) is tested with all architectures. Previous + # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - name: Flutter 3.10 os: ubuntu-latest sdk: 3.10.6 From dfc2f83adaec939c5a5a31fe1bcff191798e1663 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Sat, 7 Oct 2023 18:15:02 +0330 Subject: [PATCH 22/39] fix: rollback flutter changes. --- packages/dart/test/test_utils.dart | 5 ++ packages/flutter/README.md | 16 ++--- .../flutter/example/lib/pages/home_page.dart | 59 ++++++++++--------- .../flutter/example/lib/pages/login_page.dart | 25 ++++---- packages/flutter/example/pubspec.yaml | 3 +- packages/flutter/pubspec.yaml | 3 +- 6 files changed, 60 insertions(+), 51 deletions(-) diff --git a/packages/dart/test/test_utils.dart b/packages/dart/test/test_utils.dart index 2f138551a..366c0a5d8 100644 --- a/packages/dart/test/test_utils.dart +++ b/packages/dart/test/test_utils.dart @@ -112,6 +112,11 @@ void testUnmergeableOperationShouldThrow({ for (final operation in operationsFuncRefWithArgs.entries) { parseObject.unset(testingOnKey, offlineOnly: true); + ParseObject object=ParseObject(className); + ... + object.save(context: { + "key","value" + }); final functionRef = operation.key; final positionalArguments = operation.value; diff --git a/packages/flutter/README.md b/packages/flutter/README.md index 50ed228d9..06563cefa 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -28,14 +28,14 @@ This library gives you access to the powerful Parse Server backend from your Flu ## Compatibility -The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to a newer Flutter framework, previous Flutter framework releases are supported for at least 1 year after the [release date](https://docs.flutter.dev/release/archive?tab=linux) of the next higher significant version. The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the specific Flutter framework version cannot be supported. - -| Version | Latest Version | End of Support | Compatible | -|--------------|----------------|----------------|------------| -| Flutter 3.13 | 3.13.6 | Sep 2024 | ✅ Yes | -| Flutter 3.10 | 3.10.6 | Jul 2024 | ✅ Yes | -| Flutter 3.7 | 3.7.12 | Apr 2024 | ✅ Yes | -| Flutter 3.3 | 3.3.10 | Dec 2024 | ✅ Yes | +The Parse Flutter SDK is continuously tested with the most recent release of the Flutter framework to ensure compatibility. To give developers time to upgrade their app to the newest Flutter framework, previous Flutter framework releases are supported for at least 1 year after their [release date](https://docs.flutter.dev/release/archive?tab=linux). The Parse Flutter SDK depends on the Parse Dart SDK which may require a higher Dart framework version than the Flutter framework version, in which case the Flutter framework version cannot be supported even though its release date may have been less than a year ago. + +| Version | End of Support | Compatible | +|--------------|----------------|----------------------------------------------| +| Flutter 3.10 | May 2024 | ❌ No | +| Flutter 3.7 | Apr 2024 | ✅ Yes | +| Flutter 3.3 | Jan 2024 | ✅ Yes | +| Flutter 3.0 | Jul 2023 | ❌ No (Parse Flutter SDK requires Flutter >=3.3.0) | ## Getting Started diff --git a/packages/flutter/example/lib/pages/home_page.dart b/packages/flutter/example/lib/pages/home_page.dart index 7323d2fe4..6c5349e64 100644 --- a/packages/flutter/example/lib/pages/home_page.dart +++ b/packages/flutter/example/lib/pages/home_page.dart @@ -33,34 +33,37 @@ class _HomePageState extends State { @override Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - automaticallyImplyLeading: false, - title: const Text('Parse Server demo'), - actions: [ - TextButton( - child: const Text('Logout', - style: TextStyle(fontSize: 17.0, color: Colors.white)), - onPressed: () async { - final ParseUser user = await ParseUser.currentUser(); - user.logout(deleteLocalUserData: true); - Navigator.pop(context as dynamic, true); - }) - ], - ), - body: _showDietList(), - floatingActionButton: FloatingActionButton( - onPressed: () async { - final DietPlan dietPlan = - randomDietPlans[Random().nextInt(randomDietPlans.length - 1)]; - final ParseUser user = await ParseUser.currentUser(); - dietPlan.set('user', user); - await widget._dietPlanProvider.add(dietPlan); - setState(() {}); - }, - tooltip: 'Add Diet Plans', - child: const Icon(Icons.add), - )); + return WillPopScope( + onWillPop: () async => false, + child: Scaffold( + appBar: AppBar( + automaticallyImplyLeading: false, + title: const Text('Parse Server demo'), + actions: [ + TextButton( + child: const Text('Logout', + style: TextStyle(fontSize: 17.0, color: Colors.white)), + onPressed: () async { + final ParseUser user = await ParseUser.currentUser(); + user.logout(deleteLocalUserData: true); + Navigator.pop(context as dynamic, true); + }) + ], + ), + body: _showDietList(), + floatingActionButton: FloatingActionButton( + onPressed: () async { + final DietPlan dietPlan = + randomDietPlans[Random().nextInt(randomDietPlans.length - 1)]; + final ParseUser user = await ParseUser.currentUser(); + dietPlan.set('user', user); + await widget._dietPlanProvider.add(dietPlan); + setState(() {}); + }, + tooltip: 'Add Diet Plans', + child: const Icon(Icons.add), + )), + ); } Widget _showDietList() { diff --git a/packages/flutter/example/lib/pages/login_page.dart b/packages/flutter/example/lib/pages/login_page.dart index d68d86bbc..ab3a386d8 100644 --- a/packages/flutter/example/lib/pages/login_page.dart +++ b/packages/flutter/example/lib/pages/login_page.dart @@ -98,17 +98,20 @@ class _LoginPageState extends State { @override Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - automaticallyImplyLeading: false, - title: const Text('Parse Server demo'), - ), - body: Stack( - children: [ - _showBody(), - _showCircularProgress(), - ], - )); + return WillPopScope( + onWillPop: () async => false, + child: Scaffold( + appBar: AppBar( + automaticallyImplyLeading: false, + title: const Text('Parse Server demo'), + ), + body: Stack( + children: [ + _showBody(), + _showCircularProgress(), + ], + )), + ); } Widget _showCircularProgress() { diff --git a/packages/flutter/example/pubspec.yaml b/packages/flutter/example/pubspec.yaml index 1a2251ab5..0a48d0b20 100644 --- a/packages/flutter/example/pubspec.yaml +++ b/packages/flutter/example/pubspec.yaml @@ -5,8 +5,7 @@ publish_to: 'none' version: 1.0.0 environment: - sdk: ">=2.19.6 <4.0.0" - flutter: ">=3.3.10" + sdk: ">=2.18.0 <4.0.0" dependencies: flutter: diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index 6674b882e..8f3a18c63 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -18,8 +18,7 @@ topics: - backend environment: - sdk: ">=2.19.6 <4.0.0" - flutter: ">=3.3.10" + sdk: ">=2.18.0 <4.0.0" dependencies: flutter: From 9858b0700990e3d3cebdf884a6a9f5bdcf8d94f2 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Sat, 7 Oct 2023 18:16:27 +0330 Subject: [PATCH 23/39] fix: rollback flutter changes. --- packages/flutter/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/flutter/README.md b/packages/flutter/README.md index 06563cefa..21ad7ecc6 100644 --- a/packages/flutter/README.md +++ b/packages/flutter/README.md @@ -5,7 +5,7 @@ [![Build Status](https://github.com/parse-community/Parse-SDK-Flutter/workflows/ci/badge.svg?branch=master)](https://github.com/parse-community/Parse-SDK-Flutter/actions?query=workflow%3Aci+branch%3Amaster) [![Coverage](https://img.shields.io/codecov/c/github/parse-community/Parse-SDK-Flutter/master)](https://app.codecov.io/gh/parse-community/Parse-SDK-Flutter/branch/master) -[![pub package](https://img.shields.io/pub/v/parse_server_sdk_flutter.svg)](https://pub.dev/packages/parse_server_sdk_flutter) +[![pub package](https://img.shields.io/pub/v/parse_server_sdk_flutter.svg)](https://pub.dev/packages/parse_server_sdk_flutter) [![Forum](https://img.shields.io/discourse/https/community.parseplatform.org/topics.svg)](https://community.parseplatform.org/c/parse-server) [![Backers on Open Collective](https://opencollective.com/parse-server/backers/badge.svg)][open-collective-link] From 8bcc3d2b4a5d5b361f110926c99de16311b56310 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Sat, 7 Oct 2023 18:20:38 +0330 Subject: [PATCH 24/39] fix: rollback flutter changes. --- .github/workflows/ci.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d297d738a..2757cd761 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -77,23 +77,23 @@ jobs: matrix: include: # Flutter framework may contain breaking changes in minor version releases, not following semver. - - name: Flutter 3.13, Ubuntu + - name: Flutter 3.10, Ubuntu os: ubuntu-latest - sdk: 3.13.6 - - name: Flutter 3.13, macOS + sdk: 3.10.x + - name: Flutter 3.10, macOS os: macos-latest - sdk: 3.13.6 - - name: Flutter 3.13, Windows + sdk: 3.10.x + - name: Flutter 3.10, Windows os: windows-latest - sdk: 3.13.6 + sdk: 3.10.x # Only the latest Flutter framework version (above) is tested with all architectures. Previous # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - - name: Flutter 3.10 - os: ubuntu-latest - sdk: 3.10.6 - name: Flutter 3.7 os: ubuntu-latest - sdk: 3.7.12 + sdk: 3.7.x + - name: Flutter 3.3 + os: ubuntu-latest + sdk: 3.3.x - name: Flutter beta os: ubuntu-latest sdk: beta From 23dc6d269fffc9529b78024889bca0ec14d63b37 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Mon, 9 Oct 2023 09:21:19 +0330 Subject: [PATCH 25/39] refactor: bump version and add entries in CHANGELOG.md. --- packages/dart/CHANGELOG.md | 10 ++++++++++ packages/dart/lib/src/base/parse_constants.dart | 2 +- packages/dart/pubspec.yaml | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/packages/dart/CHANGELOG.md b/packages/dart/CHANGELOG.md index af36e8417..8105cc79b 100644 --- a/packages/dart/CHANGELOG.md +++ b/packages/dart/CHANGELOG.md @@ -1,3 +1,13 @@ +## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3...flutter-6.0.0) (2023-07-18) + +### BREAKING CHANGES + +* This release removes support for Dart 2.18 ([#969](https://github.com/parse-community/Parse-SDK-Flutter/pull/969)) + +### Features + +* Add support for Dart 3.1, remove support for Dart 2.18 ([#969](https://github.com/parse-community/Parse-SDK-Flutter/pull/969)) + ## [5.1.3](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.2...dart-5.1.3) (2023-07-18) ### Bug Fixes diff --git a/packages/dart/lib/src/base/parse_constants.dart b/packages/dart/lib/src/base/parse_constants.dart index 18ebe01ac..fa085fc1c 100644 --- a/packages/dart/lib/src/base/parse_constants.dart +++ b/packages/dart/lib/src/base/parse_constants.dart @@ -1,7 +1,7 @@ part of flutter_parse_sdk; // Library -const String keySdkVersion = '5.1.3'; +const String keySdkVersion = '6.0.0'; const String keyLibraryName = 'Flutter Parse SDK'; // End Points diff --git a/packages/dart/pubspec.yaml b/packages/dart/pubspec.yaml index b720c1820..56e5d407f 100644 --- a/packages/dart/pubspec.yaml +++ b/packages/dart/pubspec.yaml @@ -1,6 +1,6 @@ name: parse_server_sdk description: The Dart SDK to connect to Parse Server. Build your apps faster with Parse Platform, the complete application stack. -version: 5.1.3 +version: 6.0.0 homepage: https://parseplatform.org repository: https://github.com/parse-community/Parse-SDK-Flutter issue_tracker: https://github.com/parse-community/Parse-SDK-Flutter/issues From 5e276bd04f7ce7193e18c89a0ee1b0b4c8137c40 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Mon, 9 Oct 2023 13:12:34 +0200 Subject: [PATCH 26/39] Update packages/dart/CHANGELOG.md --- packages/dart/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dart/CHANGELOG.md b/packages/dart/CHANGELOG.md index 8105cc79b..8ec38d98b 100644 --- a/packages/dart/CHANGELOG.md +++ b/packages/dart/CHANGELOG.md @@ -1,4 +1,4 @@ -## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3...flutter-6.0.0) (2023-07-18) +## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3... dart-6.0.0) (2023-10-09) ### BREAKING CHANGES From d61701fe21370462bacc4eb4a40e5bb8d72e9cdc Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Mon, 9 Oct 2023 13:12:50 +0200 Subject: [PATCH 27/39] Update packages/dart/CHANGELOG.md --- packages/dart/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dart/CHANGELOG.md b/packages/dart/CHANGELOG.md index 8ec38d98b..1908f198a 100644 --- a/packages/dart/CHANGELOG.md +++ b/packages/dart/CHANGELOG.md @@ -1,4 +1,4 @@ -## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3... dart-6.0.0) (2023-10-09) +## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3...dart-6.0.0) (2023-10-09) ### BREAKING CHANGES From 701ecdda2180ad36672db570d878fcd845c66c93 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Mon, 9 Oct 2023 14:59:49 +0330 Subject: [PATCH 28/39] fix: test_utils.dart. --- packages/dart/test/test_utils.dart | 5 ----- 1 file changed, 5 deletions(-) diff --git a/packages/dart/test/test_utils.dart b/packages/dart/test/test_utils.dart index 366c0a5d8..2f138551a 100644 --- a/packages/dart/test/test_utils.dart +++ b/packages/dart/test/test_utils.dart @@ -112,11 +112,6 @@ void testUnmergeableOperationShouldThrow({ for (final operation in operationsFuncRefWithArgs.entries) { parseObject.unset(testingOnKey, offlineOnly: true); - ParseObject object=ParseObject(className); - ... - object.save(context: { - "key","value" - }); final functionRef = operation.key; final positionalArguments = operation.value; From 842338a1262bd051425bff0c9d06a9c9844d7851 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Thu, 12 Oct 2023 18:19:36 +0330 Subject: [PATCH 29/39] fix: remove dependency_overrides --- packages/flutter/example/pubspec.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/packages/flutter/example/pubspec.yaml b/packages/flutter/example/pubspec.yaml index 0a48d0b20..e8c0a08fc 100644 --- a/packages/flutter/example/pubspec.yaml +++ b/packages/flutter/example/pubspec.yaml @@ -20,10 +20,6 @@ dependencies: sembast: ^3.4.6+1 shared_preferences: ^2.2.0 -dependency_overrides: - parse_server_sdk: - path: ../../dart - dev_dependencies: flutter_test: sdk: flutter From c87126c4a0e2764c8577702e5082c4492199f39c Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Thu, 12 Oct 2023 18:23:24 +0330 Subject: [PATCH 30/39] fix: remove dependency_overrides --- packages/flutter/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index 8f3a18c63..c96f075f7 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -24,7 +24,7 @@ dependencies: flutter: sdk: flutter - parse_server_sdk: ^5.1.2 + parse_server_sdk: ^5.1.3 # Uncomment for local testing #parse_server_sdk: # path: ../dart From 656e704568d1581f09f1a835b15592ef19e066df Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Thu, 12 Oct 2023 18:30:53 +0330 Subject: [PATCH 31/39] refactor: Improve flutter support policy. --- packages/flutter/example/pubspec.yaml | 4 ++++ packages/flutter/pubspec.yaml | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/flutter/example/pubspec.yaml b/packages/flutter/example/pubspec.yaml index e8c0a08fc..0a48d0b20 100644 --- a/packages/flutter/example/pubspec.yaml +++ b/packages/flutter/example/pubspec.yaml @@ -20,6 +20,10 @@ dependencies: sembast: ^3.4.6+1 shared_preferences: ^2.2.0 +dependency_overrides: + parse_server_sdk: + path: ../../dart + dev_dependencies: flutter_test: sdk: flutter diff --git a/packages/flutter/pubspec.yaml b/packages/flutter/pubspec.yaml index c96f075f7..8f3a18c63 100644 --- a/packages/flutter/pubspec.yaml +++ b/packages/flutter/pubspec.yaml @@ -24,7 +24,7 @@ dependencies: flutter: sdk: flutter - parse_server_sdk: ^5.1.3 + parse_server_sdk: ^5.1.2 # Uncomment for local testing #parse_server_sdk: # path: ../dart From 0adce9e308b9d0655babc800bfb81bf9f62f3591 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Fri, 13 Oct 2023 11:01:44 +0330 Subject: [PATCH 32/39] fix: Ci separation. --- .github/workflows/ci.yml | 151 ---------------------------------- .github/workflows/dart-ci.yml | 75 +++++++++++++++++ 2 files changed, 75 insertions(+), 151 deletions(-) delete mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/dart-ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index 2757cd761..000000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,151 +0,0 @@ -name: ci -on: - push: - branches: - - "master" - - "development" - paths-ignore: - - "**/README.md" - pull_request: - branches: - - "**" -jobs: - check-dart: - runs-on: ${{ matrix.os }} - strategy: - matrix: - include: - # Dart framework may contain breaking changes in minor version releases, not following semver. - - name: Dart 3.1, Ubuntu - os: ubuntu-latest - sdk: 3.1.2 - - name: Dart 3.0, macOS - os: macos-latest - sdk: 3.1.2 - - name: Dart 3.0, Windows - os: windows-latest - sdk: 3.1.2 - # Only the latest Dart framework version (above) is tested with all architectures. Previous - # Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - - name: Dart 3.0 - os: ubuntu-latest - sdk: 3.0.7 - - name: Dart 2.19 - os: ubuntu-latest - sdk: 2.19.6 - - name: Dart beta - os: ubuntu-latest - sdk: beta - fail-fast: false - name: Test ${{ matrix.name }} - steps: - - name: Checkout code - uses: actions/checkout@v3 - - name: Setup dart - uses: dart-lang/setup-dart@v1.5.0 - with: - sdk: ${{ matrix.sdk }} - - name: Install dependencies - run: dart pub get --directory packages/dart - - name: Run build_runner - run: (cd packages/dart && dart run build_runner build --delete-conflicting-outputs) - - name: Analyze code - run: dart analyze packages/dart --fatal-infos - - name: Lint - run: dart format --output=none --set-exit-if-changed packages/dart - - name: Publish dry run - run: cd packages/dart && dart pub publish --dry-run - - name: Run tests - run: (cd packages/dart && dart test --coverage=coverage) - - name: Convert code coverage - # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. - if: ${{ always() && matrix.os == 'ubuntu-latest' }} - working-directory: packages/dart - run: | - dart pub global activate coverage - dart pub global run coverage:format_coverage -i coverage/test -o coverage/lcov.info --lcov --packages=.dart_tool/package_config.json --report-on=lib - - name: Upload code coverage - uses: codecov/codecov-action@v2 - # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. - if: ${{ always() && matrix.os == 'ubuntu-latest' }} - with: - files: packages/dart/coverage/lcov.info - fail_ci_if_error: true - check-flutter: - runs-on: ${{ matrix.os }} - strategy: - matrix: - include: - # Flutter framework may contain breaking changes in minor version releases, not following semver. - - name: Flutter 3.10, Ubuntu - os: ubuntu-latest - sdk: 3.10.x - - name: Flutter 3.10, macOS - os: macos-latest - sdk: 3.10.x - - name: Flutter 3.10, Windows - os: windows-latest - sdk: 3.10.x - # Only the latest Flutter framework version (above) is tested with all architectures. Previous - # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - - name: Flutter 3.7 - os: ubuntu-latest - sdk: 3.7.x - - name: Flutter 3.3 - os: ubuntu-latest - sdk: 3.3.x - - name: Flutter beta - os: ubuntu-latest - sdk: beta - fail-fast: false - name: Test ${{ matrix.name }} - steps: - - name: Checkout code - uses: actions/checkout@v3 - - name: Setup flutter (beta) - if: ${{ matrix.sdk == 'beta' }} - uses: subosito/flutter-action@v2 - with: - channel: "beta" - cache: true - - name: Setup flutter - if: ${{ matrix.sdk != 'beta' }} - uses: subosito/flutter-action@v2 - with: - flutter-version: ${{ matrix.sdk }} - cache: true - - name: Install dependencies on Ubuntu and MacOS - if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' - run: | - (cd packages/dart && flutter pub get) - (cd packages/flutter && flutter pub get) - - name: Install dependencies on Windows - if: matrix.os == 'windows-latest' - run: | - cmd /c "cd packages\dart && flutter pub get" - cmd /c "cd packages\flutter && flutter pub get" - - name: Analyze code - run: flutter analyze packages/flutter --fatal-infos - - name: Lint - run: dart format --output=none --set-exit-if-changed packages/flutter - - name: Publish dry run - run: cd packages/flutter && dart pub publish --dry-run - - name: Run tests - run: (cd packages/flutter && flutter test --coverage) - - name: Convert code coverage - # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. - if: ${{ always() && matrix.os == 'ubuntu-latest' }} - working-directory: packages/flutter - run: | - escapedPath="$(echo `pwd` | sed 's/\//\\\//g')" - sed "s/^SF:lib/SF:$escapedPath\/lib/g" coverage/lcov.info > coverage/lcov-full.info - - name: Upload code coverage - uses: codecov/codecov-action@v2 - # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. - if: ${{ always() && matrix.os == 'ubuntu-latest' }} - with: - files: packages/flutter/coverage/lcov-full.info - fail_ci_if_error: true -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true diff --git a/.github/workflows/dart-ci.yml b/.github/workflows/dart-ci.yml new file mode 100644 index 000000000..9109fe4d5 --- /dev/null +++ b/.github/workflows/dart-ci.yml @@ -0,0 +1,75 @@ +name: ci +on: + push: + branches: + - "master" + paths-ignore: + - "**/README.md" + pull_request: + branches: + - "**" +jobs: + check-dart: + runs-on: ${{ matrix.os }} + strategy: + matrix: + include: + # Dart framework may contain breaking changes in minor version releases, not following semver. + - name: Dart 3.1, Ubuntu + os: ubuntu-latest + sdk: 3.1.2 + - name: Dart 3.0, macOS + os: macos-latest + sdk: 3.1.2 + - name: Dart 3.0, Windows + os: windows-latest + sdk: 3.1.2 + # Only the latest Dart framework version (above) is tested with all architectures. Previous + # Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. + - name: Dart 3.0 + os: ubuntu-latest + sdk: 3.0.7 + - name: Dart 2.19 + os: ubuntu-latest + sdk: 2.19.6 + - name: Dart beta + os: ubuntu-latest + sdk: beta + fail-fast: false + name: Test ${{ matrix.name }} + steps: + - name: Checkout code + uses: actions/checkout@v3 + - name: Setup dart + uses: dart-lang/setup-dart@v1.5.0 + with: + sdk: ${{ matrix.sdk }} + - name: Install dependencies + run: dart pub get --directory packages/dart + - name: Run build_runner + run: (cd packages/dart && dart run build_runner build --delete-conflicting-outputs) + - name: Analyze code + run: dart analyze packages/dart --fatal-infos + - name: Lint + run: dart format --output=none --set-exit-if-changed packages/dart + - name: Publish dry run + run: cd packages/dart && dart pub publish --dry-run + - name: Run tests + run: (cd packages/dart && dart test --coverage=coverage) + - name: Convert code coverage + # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. + if: ${{ always() && matrix.os == 'ubuntu-latest' }} + working-directory: packages/dart + run: | + dart pub global activate coverage + dart pub global run coverage:format_coverage -i coverage/test -o coverage/lcov.info --lcov --packages=.dart_tool/package_config.json --report-on=lib + - name: Upload code coverage + uses: codecov/codecov-action@v2 + # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. + if: ${{ always() && matrix.os == 'ubuntu-latest' }} + with: + files: packages/dart/coverage/lcov.info + fail_ci_if_error: true +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true From 01d1ca4fc880a9bb2241b915ba8329a945571c7e Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Fri, 13 Oct 2023 11:04:45 +0330 Subject: [PATCH 33/39] fix: Ci separation. --- .github/workflows/dart-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dart-ci.yml b/.github/workflows/dart-ci.yml index 9109fe4d5..71d11ff06 100644 --- a/.github/workflows/dart-ci.yml +++ b/.github/workflows/dart-ci.yml @@ -1,4 +1,4 @@ -name: ci +name: Dart CI on: push: branches: From a8d96e2234f76c1b2e3323f8a6eb0b43634a9283 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Fri, 13 Oct 2023 11:12:49 +0330 Subject: [PATCH 34/39] fix: Ci separation. --- .github/workflows/dart-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dart-ci.yml b/.github/workflows/dart-ci.yml index 71d11ff06..42d70960c 100644 --- a/.github/workflows/dart-ci.yml +++ b/.github/workflows/dart-ci.yml @@ -1,4 +1,4 @@ -name: Dart CI +name: dart-ci on: push: branches: From 27d13b748dc58a6978e9ede73b8a42ea8410bc04 Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Mon, 16 Oct 2023 18:11:13 +0330 Subject: [PATCH 35/39] fix: revert CI. --- .github/workflows/{dart-ci.yml => ci.yml} | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) rename .github/workflows/{dart-ci.yml => ci.yml} (92%) diff --git a/.github/workflows/dart-ci.yml b/.github/workflows/ci.yml similarity index 92% rename from .github/workflows/dart-ci.yml rename to .github/workflows/ci.yml index 42d70960c..d61dd9b90 100644 --- a/.github/workflows/dart-ci.yml +++ b/.github/workflows/ci.yml @@ -1,4 +1,4 @@ -name: dart-ci +name: ci on: push: branches: @@ -39,7 +39,7 @@ jobs: name: Test ${{ matrix.name }} steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup dart uses: dart-lang/setup-dart@v1.5.0 with: @@ -47,7 +47,7 @@ jobs: - name: Install dependencies run: dart pub get --directory packages/dart - name: Run build_runner - run: (cd packages/dart && dart run build_runner build --delete-conflicting-outputs) + run: cd packages/dart && dart run build_runner build --delete-conflicting-outputs - name: Analyze code run: dart analyze packages/dart --fatal-infos - name: Lint @@ -55,7 +55,7 @@ jobs: - name: Publish dry run run: cd packages/dart && dart pub publish --dry-run - name: Run tests - run: (cd packages/dart && dart test --coverage=coverage) + run: cd packages/dart && dart test --coverage=coverage - name: Convert code coverage # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. if: ${{ always() && matrix.os == 'ubuntu-latest' }} From 1a6ee97823a494e94484ffc8eb71b4de3187e2df Mon Sep 17 00:00:00 2001 From: mbfakourii Date: Mon, 16 Oct 2023 18:13:10 +0330 Subject: [PATCH 36/39] fix: revert CI. --- .github/workflows/ci.yml | 75 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d61dd9b90..4d2a80033 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -70,6 +70,81 @@ jobs: with: files: packages/dart/coverage/lcov.info fail_ci_if_error: true + check-flutter: + runs-on: ${{ matrix.os }} + strategy: + matrix: + include: + # Flutter framework may contain breaking changes in minor version releases, not following semver. + - name: Flutter 3.10, Ubuntu + os: ubuntu-latest + sdk: 3.10.x + - name: Flutter 3.10, macOS + os: macos-latest + sdk: 3.10.x + - name: Flutter 3.10, Windows + os: windows-latest + sdk: 3.10.x + # Only the latest Flutter framework version (above) is tested with all architectures. Previous + # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. + - name: Flutter 3.7 + os: ubuntu-latest + sdk: 3.7.x + - name: Flutter 3.3 + os: ubuntu-latest + sdk: 3.3.x + - name: Flutter beta + os: ubuntu-latest + sdk: beta + fail-fast: false + name: Test ${{ matrix.name }} + steps: + - name: Checkout code + uses: actions/checkout@v3 + - name: Setup flutter (beta) + if: ${{ matrix.sdk == 'beta' }} + uses: subosito/flutter-action@v2 + with: + channel: "beta" + cache: true + - name: Setup flutter + if: ${{ matrix.sdk != 'beta' }} + uses: subosito/flutter-action@v2 + with: + flutter-version: ${{ matrix.sdk }} + cache: true + - name: Install dependencies on Ubuntu and MacOS + if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' + run: | + (cd packages/dart && flutter pub get) + (cd packages/flutter && flutter pub get) + - name: Install dependencies on Windows + if: matrix.os == 'windows-latest' + run: | + cmd /c "cd packages\dart && flutter pub get" + cmd /c "cd packages\flutter && flutter pub get" + - name: Analyze code + run: flutter analyze packages/flutter --fatal-infos + - name: Lint + run: dart format --output=none --set-exit-if-changed packages/flutter + - name: Publish dry run + run: cd packages/flutter && dart pub publish --dry-run + - name: Run tests + run: (cd packages/flutter && flutter test --coverage) + - name: Convert code coverage + # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. + if: ${{ always() && matrix.os == 'ubuntu-latest' }} + working-directory: packages/flutter + run: | + escapedPath="$(echo `pwd` | sed 's/\//\\\//g')" + sed "s/^SF:lib/SF:$escapedPath\/lib/g" coverage/lcov.info > coverage/lcov-full.info + - name: Upload code coverage + uses: codecov/codecov-action@v2 + # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. + if: ${{ always() && matrix.os == 'ubuntu-latest' }} + with: + files: packages/flutter/coverage/lcov-full.info + fail_ci_if_error: true concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true From a20204aec13b970a8db4a2ff9fa853ec770556c2 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Mon, 16 Oct 2023 21:31:04 +0200 Subject: [PATCH 37/39] re-add brackets --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1921582a6..c511eb5e2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,7 +47,7 @@ jobs: - name: Install dependencies run: dart pub get --directory packages/dart - name: Run build_runner - run: cd packages/dart && dart run build_runner build --delete-conflicting-outputs + run: (cd packages/dart && dart run build_runner build --delete-conflicting-outputs) - name: Analyze code run: dart analyze packages/dart --fatal-infos - name: Lint @@ -55,7 +55,7 @@ jobs: - name: Publish dry run run: cd packages/dart && dart pub publish --dry-run - name: Run tests - run: cd packages/dart && dart test --coverage=coverage + run: (cd packages/dart && dart test --coverage=coverage) - name: Convert code coverage # Needs to be adapted to collect the coverage at all platforms if platform specific code is added. if: ${{ always() && matrix.os == 'ubuntu-latest' }} From 8243b1e3b4f46b80e0c1e614a8ee385e83d8e447 Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Mon, 16 Oct 2023 21:31:43 +0200 Subject: [PATCH 38/39] changelog --- packages/dart/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/dart/CHANGELOG.md b/packages/dart/CHANGELOG.md index 1908f198a..af6613f67 100644 --- a/packages/dart/CHANGELOG.md +++ b/packages/dart/CHANGELOG.md @@ -1,4 +1,4 @@ -## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3...dart-6.0.0) (2023-10-09) +## [6.0.0](https://github.com/parse-community/Parse-SDK-Flutter/compare/dart-5.1.3...dart-6.0.0) (2023-10-16) ### BREAKING CHANGES From f1ce3b794d3d88c974db09e6969f2ace00c0f6db Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Mon, 16 Oct 2023 21:57:05 +0200 Subject: [PATCH 39/39] fix incorrect CI test tags --- .github/workflows/ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c511eb5e2..b17df6f9a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,17 +15,17 @@ jobs: matrix: include: # Dart framework may contain breaking changes in minor version releases, not following semver. + # The latest Dart framework (below) is tested on all architectures (Ubuntu, macOS, Windows). - name: Dart 3.1, Ubuntu os: ubuntu-latest sdk: 3.1.2 - - name: Dart 3.0, macOS + - name: Dart 3.1, macOS os: macos-latest sdk: 3.1.2 - - name: Dart 3.0, Windows + - name: Dart 3.1, Windows os: windows-latest sdk: 3.1.2 - # Only the latest Dart framework version (above) is tested with all architectures. Previous - # Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. + # Older Dart framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - name: Dart 3.0 os: ubuntu-latest sdk: 3.0.7 @@ -76,6 +76,7 @@ jobs: matrix: include: # Flutter framework may contain breaking changes in minor version releases, not following semver. + # The latest Flutter framework (below) is tested on all architectures (Ubuntu, macOS, Windows). - name: Flutter 3.13, Ubuntu os: ubuntu-latest sdk: 3.13.6 @@ -85,8 +86,7 @@ jobs: - name: Flutter 3.13, Windows os: windows-latest sdk: 3.13.6 - # Only the latest Flutter framework version (above) is tested with all architectures. Previous - # Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. + # Older Flutter framework versions (below) are only tested with Ubuntu to reduce CI resource usage. - name: Flutter 3.10 os: ubuntu-latest sdk: 3.10.6