From 438daea20866753ae7776309c4526dec6f6885a9 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:47:34 -0800 Subject: [PATCH 01/28] Add flutter_dependencies --- cookiecutter.json | 1 + {{cookiecutter.out_dir}}/lib/main.dart | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/cookiecutter.json b/cookiecutter.json index e147a53..6c06820 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,6 +7,7 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", + "flutter_dependencies": [], "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index cf61a02..5951ebe 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -9,6 +9,10 @@ import 'package:path/path.dart' as path; import 'package:serious_python/serious_python.dart'; import 'package:url_strategy/url_strategy.dart'; +{% for dep in cookiecutter.flutter_dependencies %} +import 'package:{{ dep }}/{{ dep }}.dart' as {{ dep }}; +{% endfor %} + const bool isProduction = bool.fromEnvironment('dart.vm.product'); const assetPath = "app/app.zip"; @@ -19,6 +23,12 @@ final hideLoadingPage = const outLogFilename = "out.log"; const errorExitCode = 100; +const createControlFactories = [ +{% for dep in cookiecutter.flutter_dependencies %} +{{ dep }}.createControl, +{% endfor %} +]; + const pythonScript = """ import certifi, os, runpy, socket, sys, traceback From 3d3a54c4868a98bb62377060211831ffb5809937 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:51:54 -0800 Subject: [PATCH 02/28] Fix cookiecutter.flutter.dependencies --- cookiecutter.json | 4 +++- {{cookiecutter.out_dir}}/lib/main.dart | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/cookiecutter.json b/cookiecutter.json index 6c06820..268a7d4 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,7 +7,9 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", - "flutter_dependencies": [], + "flutter": { + "dependencies": [] + }, "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 5951ebe..b6e9ba9 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -9,7 +9,7 @@ import 'package:path/path.dart' as path; import 'package:serious_python/serious_python.dart'; import 'package:url_strategy/url_strategy.dart'; -{% for dep in cookiecutter.flutter_dependencies %} +{% for dep in cookiecutter.flutter.dependencies %} import 'package:{{ dep }}/{{ dep }}.dart' as {{ dep }}; {% endfor %} @@ -24,7 +24,7 @@ const outLogFilename = "out.log"; const errorExitCode = 100; const createControlFactories = [ -{% for dep in cookiecutter.flutter_dependencies %} +{% for dep in cookiecutter.flutter.dependencies %} {{ dep }}.createControl, {% endfor %} ]; From 417ae1c0c79bd247a6ce735a1a2db19d1b1851fd Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:52:58 -0800 Subject: [PATCH 03/28] Remove from cookiecutter.json --- cookiecutter.json | 3 --- 1 file changed, 3 deletions(-) diff --git a/cookiecutter.json b/cookiecutter.json index 268a7d4..e147a53 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,9 +7,6 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", - "flutter": { - "dependencies": [] - }, "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, From 31dca2b5e558dd99224df4dffb2c045dde543d74 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:54:27 -0800 Subject: [PATCH 04/28] "flutter": null --- cookiecutter.json | 1 + 1 file changed, 1 insertion(+) diff --git a/cookiecutter.json b/cookiecutter.json index e147a53..c629ec8 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,6 +7,7 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", + "flutter": null, "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, From aadcfb3baa9c6c681dda119dced3909aeb57833c Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:57:49 -0800 Subject: [PATCH 05/28] Back flutter_dependencies --- cookiecutter.json | 2 +- {{cookiecutter.out_dir}}/lib/main.dart | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cookiecutter.json b/cookiecutter.json index c629ec8..2bae6d9 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,7 +7,7 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", - "flutter": null, + "flutter_dependencies": null, "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index b6e9ba9..5951ebe 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -9,7 +9,7 @@ import 'package:path/path.dart' as path; import 'package:serious_python/serious_python.dart'; import 'package:url_strategy/url_strategy.dart'; -{% for dep in cookiecutter.flutter.dependencies %} +{% for dep in cookiecutter.flutter_dependencies %} import 'package:{{ dep }}/{{ dep }}.dart' as {{ dep }}; {% endfor %} @@ -24,7 +24,7 @@ const outLogFilename = "out.log"; const errorExitCode = 100; const createControlFactories = [ -{% for dep in cookiecutter.flutter.dependencies %} +{% for dep in cookiecutter.flutter_dependencies %} {{ dep }}.createControl, {% endfor %} ]; From 4fa29e6f5d34cdfdef0afd1d7b8f950ce6ecf033 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 10:59:23 -0800 Subject: [PATCH 06/28] flutter_dependencies didn't work --- cookiecutter.json | 2 +- {{cookiecutter.out_dir}}/lib/main.dart | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cookiecutter.json b/cookiecutter.json index 2bae6d9..c629ec8 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -7,7 +7,7 @@ "org_name": "com.flet", "company_name": "Your Company", "copyright": "Copyright (c) 2023 Your Company", - "flutter_dependencies": null, + "flutter": null, "sep": "/", "kotlin_dir": "{{ cookiecutter.org_name.replace('.', cookiecutter.sep) }}{{ cookiecutter.sep }}{{ cookiecutter.project_name }}{{ cookiecutter.sep }}", "hide_loading_animation": true, diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 5951ebe..b6e9ba9 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -9,7 +9,7 @@ import 'package:path/path.dart' as path; import 'package:serious_python/serious_python.dart'; import 'package:url_strategy/url_strategy.dart'; -{% for dep in cookiecutter.flutter_dependencies %} +{% for dep in cookiecutter.flutter.dependencies %} import 'package:{{ dep }}/{{ dep }}.dart' as {{ dep }}; {% endfor %} @@ -24,7 +24,7 @@ const outLogFilename = "out.log"; const errorExitCode = 100; const createControlFactories = [ -{% for dep in cookiecutter.flutter_dependencies %} +{% for dep in cookiecutter.flutter.dependencies %} {{ dep }}.createControl, {% endfor %} ]; From 52ebf165078b0b27c8522a7c867187ba4b8670ab Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 23 Jan 2024 11:19:11 -0800 Subject: [PATCH 07/28] var createControlFactories --- {{cookiecutter.out_dir}}/lib/main.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index b6e9ba9..7de2401 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -23,7 +23,7 @@ final hideLoadingPage = const outLogFilename = "out.log"; const errorExitCode = 100; -const createControlFactories = [ +var createControlFactories = [ {% for dep in cookiecutter.flutter.dependencies %} {{ dep }}.createControl, {% endfor %} From 5a1fc38804d13e8f4198b56be04cc254dd373cf2 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Sun, 4 Feb 2024 09:44:50 -0800 Subject: [PATCH 08/28] Pyodide v0.25.0 --- {{cookiecutter.out_dir}}/web/python-worker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/web/python-worker.js b/{{cookiecutter.out_dir}}/web/python-worker.js index 130690b..7e4e4eb 100644 --- a/{{cookiecutter.out_dir}}/web/python-worker.js +++ b/{{cookiecutter.out_dir}}/web/python-worker.js @@ -1,4 +1,4 @@ -importScripts("https://cdn.jsdelivr.net/pyodide/v0.24.1/full/pyodide.js"); +importScripts("https://cdn.jsdelivr.net/pyodide/v0.25.0/full/pyodide.js"); self.pythonModuleName = null; self.initialized = false; From 2546c20766be73675dbd7bb00bd7b0d9d2a71cd2 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 9 Feb 2024 12:47:09 -0800 Subject: [PATCH 09/28] {{ dep }}.ensureInitialized() --- {{cookiecutter.out_dir}}/lib/main.dart | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 7de2401..b7cae11 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -29,6 +29,10 @@ var createControlFactories = [ {% endfor %} ]; +{% for dep in cookiecutter.flutter.dependencies %} +{{ dep }}.ensureInitialized(); +{% endfor %} + const pythonScript = """ import certifi, os, runpy, socket, sys, traceback From 6c78ea8471bdc163407946bf57c8faaedef91acb Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 9 Feb 2024 12:53:58 -0800 Subject: [PATCH 10/28] Move ensureInitialized --- {{cookiecutter.out_dir}}/lib/main.dart | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index b7cae11..21095ce 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -29,10 +29,6 @@ var createControlFactories = [ {% endfor %} ]; -{% for dep in cookiecutter.flutter.dependencies %} -{{ dep }}.ensureInitialized(); -{% endfor %} - const pythonScript = """ import certifi, os, runpy, socket, sys, traceback @@ -93,6 +89,10 @@ void main() async { debugPrint = (String? message, {int? wrapWidth}) => null; } + {% for dep in cookiecutter.flutter.dependencies %} + {{ dep }}.ensureInitialized(); + {% endfor %} + runApp(FutureBuilder( future: prepareApp(), builder: (BuildContext context, AsyncSnapshot snapshot) { From bd9285b831497c499910e95d9a449329e6ff3048 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Wed, 14 Feb 2024 18:06:36 -0800 Subject: [PATCH 11/28] Use Flet 0.20.0 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 95094c7..6e8deab 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.19.0 + flet: ^0.20.0 # flet: # git: # url: https://github.com/flet-dev/flet.git From c25fa1db79a0591b7ba45bc4fd190793219fca44 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Wed, 14 Feb 2024 18:51:11 -0800 Subject: [PATCH 12/28] Fix `createControlFactories` --- .../android/app/build.gradle | 2 + .../android/app/src/debug/AndroidManifest.xml | 5 +- .../android/app/src/main/AndroidManifest.xml | 15 +-- .../app/src/profile/AndroidManifest.xml | 5 +- .../ios/Runner/Info.plist | 99 ++++++++++--------- {{cookiecutter.out_dir}}/lib/main.dart | 2 + 6 files changed, 71 insertions(+), 57 deletions(-) diff --git a/{{cookiecutter.out_dir}}/android/app/build.gradle b/{{cookiecutter.out_dir}}/android/app/build.gradle index 4a43123..6a707bf 100644 --- a/{{cookiecutter.out_dir}}/android/app/build.gradle +++ b/{{cookiecutter.out_dir}}/android/app/build.gradle @@ -50,6 +50,8 @@ android { versionCode flutterVersionCode.toInteger() versionName flutterVersionName + minSdkVersion 21 + ndk { abiFilters 'arm64-v8a', 'armeabi-v7a' } diff --git a/{{cookiecutter.out_dir}}/android/app/src/debug/AndroidManifest.xml b/{{cookiecutter.out_dir}}/android/app/src/debug/AndroidManifest.xml index 399f698..7792018 100644 --- a/{{cookiecutter.out_dir}}/android/app/src/debug/AndroidManifest.xml +++ b/{{cookiecutter.out_dir}}/android/app/src/debug/AndroidManifest.xml @@ -3,5 +3,6 @@ the Flutter tool needs it to communicate with the running application to allow setting breakpoints, to provide hot reload, etc. --> - - + + + \ No newline at end of file diff --git a/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml b/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml index 632e253..6b01650 100644 --- a/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml +++ b/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml @@ -1,5 +1,6 @@ - + + + android:name="io.flutter.embedding.android.NormalTheme" + android:resource="@style/NormalTheme" + /> - - + + - - + + + \ No newline at end of file diff --git a/{{cookiecutter.out_dir}}/ios/Runner/Info.plist b/{{cookiecutter.out_dir}}/ios/Runner/Info.plist index 6d95a10..ed7b6f8 100644 --- a/{{cookiecutter.out_dir}}/ios/Runner/Info.plist +++ b/{{cookiecutter.out_dir}}/ios/Runner/Info.plist @@ -1,49 +1,56 @@ - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleDisplayName - {{ cookiecutter.product_name }} - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - {{ cookiecutter.project_name }} - CFBundlePackageType - APPL - CFBundleShortVersionString - $(FLUTTER_BUILD_NAME) - CFBundleSignature - ???? - CFBundleVersion - $(FLUTTER_BUILD_NUMBER) - LSRequiresIPhoneOS - - UILaunchStoryboardName - LaunchScreen - UIMainStoryboardFile - Main - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - CADisableMinimumFrameDurationOnPhone - - UIApplicationSupportsIndirectInputEvents - - - + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + {{ cookiecutter.product_name }} + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + {{ cookiecutter.project_name }} + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + CADisableMinimumFrameDurationOnPhone + + UIApplicationSupportsIndirectInputEvents + + NSAppTransportSecurity + + NSAllowsArbitraryLoads + + + NSMicrophoneUsageDescription + Audio Recording + + \ No newline at end of file diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 21095ce..4e35ab8 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -103,6 +103,7 @@ void main() async { pageUrl: pageUrl, assetsDir: assetsDir, hideLoadingPage: hideLoadingPage, + createControlFactories: createControlFactories ) : FutureBuilder( future: runPythonApp(), @@ -121,6 +122,7 @@ void main() async { pageUrl: pageUrl, assetsDir: assetsDir, hideLoadingPage: hideLoadingPage, + createControlFactories: createControlFactories ); } }); From a233de7547c0bcb41f4015cf6df472fe2555a8fa Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Thu, 15 Feb 2024 10:59:07 -0800 Subject: [PATCH 13/28] Fix type of `createControlFactories` --- {{cookiecutter.out_dir}}/lib/main.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 4e35ab8..7f56a9a 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -23,7 +23,7 @@ final hideLoadingPage = const outLogFilename = "out.log"; const errorExitCode = 100; -var createControlFactories = [ +List createControlFactories = [ {% for dep in cookiecutter.flutter.dependencies %} {{ dep }}.createControl, {% endfor %} From 5e1d40c94c335eb3f76692bca3729910960d637b Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 16 Feb 2024 12:16:41 -0800 Subject: [PATCH 14/28] Remove minSdkVersion 21 --- {{cookiecutter.out_dir}}/android/app/build.gradle | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/{{cookiecutter.out_dir}}/android/app/build.gradle b/{{cookiecutter.out_dir}}/android/app/build.gradle index 6a707bf..3248c35 100644 --- a/{{cookiecutter.out_dir}}/android/app/build.gradle +++ b/{{cookiecutter.out_dir}}/android/app/build.gradle @@ -41,17 +41,12 @@ android { } defaultConfig { - // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). applicationId "{{ cookiecutter.org_name }}.{{ cookiecutter.project_name }}" - // You can update the following values to match your application needs. - // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration. minSdkVersion flutter.minSdkVersion targetSdkVersion flutter.targetSdkVersion versionCode flutterVersionCode.toInteger() versionName flutterVersionName - minSdkVersion 21 - ndk { abiFilters 'arm64-v8a', 'armeabi-v7a' } @@ -59,8 +54,6 @@ android { buildTypes { release { - // TODO: Add your own signing config for the release build. - // Signing with the debug keys for now, so `flutter run --release` works. signingConfig signingConfigs.debug } } @@ -70,4 +63,4 @@ flutter { source '../..' } -dependencies {} +dependencies {} \ No newline at end of file From d48614191d507802702968cfecc053ffb7f177d3 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 16 Feb 2024 12:19:14 -0800 Subject: [PATCH 15/28] Fix settings.gradle --- {{cookiecutter.out_dir}}/android/build.gradle | 3 +-- {{cookiecutter.out_dir}}/android/settings.gradle | 13 +++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/{{cookiecutter.out_dir}}/android/build.gradle b/{{cookiecutter.out_dir}}/android/build.gradle index ce647a4..2dcf86f 100644 --- a/{{cookiecutter.out_dir}}/android/build.gradle +++ b/{{cookiecutter.out_dir}}/android/build.gradle @@ -6,7 +6,6 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:7.4.2' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } @@ -28,4 +27,4 @@ subprojects { tasks.register("clean", Delete) { delete rootProject.buildDir -} +} \ No newline at end of file diff --git a/{{cookiecutter.out_dir}}/android/settings.gradle b/{{cookiecutter.out_dir}}/android/settings.gradle index 55c4ca8..45d92d2 100644 --- a/{{cookiecutter.out_dir}}/android/settings.gradle +++ b/{{cookiecutter.out_dir}}/android/settings.gradle @@ -10,11 +10,20 @@ pluginManagement { includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle") + repositories { + google() + mavenCentral() + gradlePluginPortal() + } + plugins { id "dev.flutter.flutter-gradle-plugin" version "1.0.0" apply false } } -include ":app" +plugins { + id "dev.flutter.flutter-plugin-loader" version "1.0.0" + id "com.android.application" version "7.3.0" apply false +} -apply from: "${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle/app_plugin_loader.gradle" +include ":app" \ No newline at end of file From d96ce5a5711198951e211c4b3a3bea27d0504bff Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 16 Feb 2024 17:38:57 -0800 Subject: [PATCH 16/28] Use Flet 0.20.1 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 6e8deab..8a23035 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.20.0 + flet: ^0.20.1 # flet: # git: # url: https://github.com/flet-dev/flet.git From 50c7144fca8c52fdd233dff32fa6620dfda006c0 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Sat, 17 Feb 2024 09:47:56 -0800 Subject: [PATCH 17/28] cupertino_icons: ^1.0.6 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 8a23035..799346b 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -27,7 +27,7 @@ dependencies: path: ^1.8.3 url_strategy: ^0.2.0 - cupertino_icons: ^1.0.2 + cupertino_icons: ^1.0.6 dev_dependencies: flutter_test: From 52d86b3bd32be5d1b93385a765d2092d94ea031a Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Sat, 17 Feb 2024 14:47:05 -0800 Subject: [PATCH 18/28] flet: ^0.20.2 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 799346b..25603b8 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.20.1 + flet: ^0.20.2 # flet: # git: # url: https://github.com/flet-dev/flet.git From 4ffc1adf42d19a87f02725befe4e88c2f7074c7a Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 20 Feb 2024 14:12:50 -0800 Subject: [PATCH 19/28] android:label="{{ cookiecutter.product_name }}" --- .../android/app/src/main/AndroidManifest.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml b/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml index 6b01650..8b74dc2 100644 --- a/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml +++ b/{{cookiecutter.out_dir}}/android/app/src/main/AndroidManifest.xml @@ -2,7 +2,7 @@ Date: Wed, 6 Mar 2024 11:04:10 -0800 Subject: [PATCH 20/28] Use Flet 0.21.0 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 25603b8..539d72d 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.20.2 + flet: ^0.21.0 # flet: # git: # url: https://github.com/flet-dev/flet.git From 0b83309df0cc7ec53f5820f09a2b175346d0ec68 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Wed, 6 Mar 2024 13:24:17 -0800 Subject: [PATCH 21/28] Use Flet 0.21.1 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 539d72d..4cf1a25 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.21.0 + flet: ^0.21.1 # flet: # git: # url: https://github.com/flet-dev/flet.git From e2ab18efddf9d3354b99256335587b1e91de0766 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Thu, 7 Mar 2024 08:57:54 -0800 Subject: [PATCH 22/28] Use Flet 0.21.2 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 4cf1a25..0b34484 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.21.1 + flet: ^0.21.2 # flet: # git: # url: https://github.com/flet-dev/flet.git From 7bc5081b003d96a24c873aa2376013d4fbde3021 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Mon, 11 Mar 2024 11:12:05 -0700 Subject: [PATCH 23/28] Squashed commit of the following: commit e8217a057a0b672cb2ef6c8895bfd89fde10fda1 Author: Feodor Fitsner Date: Mon Mar 11 11:11:48 2024 -0700 Squashed commit of the following: commit 7660adc12c2c75c12ca1bfa78e9e59924845b25d Author: Feodor Fitsner Date: Mon Mar 11 11:11:30 2024 -0700 minSdkVersion 21 --- {{cookiecutter.out_dir}}/android/app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/android/app/build.gradle b/{{cookiecutter.out_dir}}/android/app/build.gradle index 3248c35..44029cd 100644 --- a/{{cookiecutter.out_dir}}/android/app/build.gradle +++ b/{{cookiecutter.out_dir}}/android/app/build.gradle @@ -42,7 +42,7 @@ android { defaultConfig { applicationId "{{ cookiecutter.org_name }}.{{ cookiecutter.project_name }}" - minSdkVersion flutter.minSdkVersion + minSdkVersion 21 targetSdkVersion flutter.targetSdkVersion versionCode flutterVersionCode.toInteger() versionName flutterVersionName From 9496a9b3defa22046ee433953ba6ec836d7ac2e4 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Fri, 12 Apr 2024 10:13:59 -0700 Subject: [PATCH 24/28] Use Flet 0.22.0 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 0b34484..3f2f468 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.21.2 + flet: ^0.22.0 # flet: # git: # url: https://github.com/flet-dev/flet.git From 14a925be087e48ed57db42a7adbe55ecf2b33553 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Thu, 18 Apr 2024 12:17:32 -0700 Subject: [PATCH 25/28] Fix for apps with numpy on macOS https://github.com/flet-dev/serious-python/issues/85#issuecomment-2065000974 --- {{cookiecutter.out_dir}}/lib/main.dart | 3 +++ 1 file changed, 3 insertions(+) diff --git a/{{cookiecutter.out_dir}}/lib/main.dart b/{{cookiecutter.out_dir}}/lib/main.dart index 7f56a9a..7216580 100644 --- a/{{cookiecutter.out_dir}}/lib/main.dart +++ b/{{cookiecutter.out_dir}}/lib/main.dart @@ -35,6 +35,9 @@ import certifi, os, runpy, socket, sys, traceback os.environ["REQUESTS_CA_BUNDLE"] = certifi.where() os.environ["SSL_CERT_FILE"] = certifi.where() +# fix for: https://github.com/flet-dev/serious-python/issues/85#issuecomment-2065000974 +os.environ["OPENBLAS_NUM_THREADS"] = "1" + if os.getenv("FLET_PLATFORM") == "android": import ssl From a88b3b8e48472b77c043631ac7e4cd4999772861 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Mon, 29 Apr 2024 11:36:46 -0700 Subject: [PATCH 26/28] Squashed commit of the following: commit cb9af5b9a64396835120754eb085a62fcc0b558b Author: Feodor Fitsner Date: Mon Apr 29 11:32:15 2024 -0700 Add NSMicrophoneUsageDescription to Info.plist --- .../macos/Runner/Info.plist | 60 ++++++++++--------- 1 file changed, 31 insertions(+), 29 deletions(-) diff --git a/{{cookiecutter.out_dir}}/macos/Runner/Info.plist b/{{cookiecutter.out_dir}}/macos/Runner/Info.plist index 4789daa..8d5a11d 100644 --- a/{{cookiecutter.out_dir}}/macos/Runner/Info.plist +++ b/{{cookiecutter.out_dir}}/macos/Runner/Info.plist @@ -1,32 +1,34 @@ - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIconFile - - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - $(PRODUCT_NAME) - CFBundlePackageType - APPL - CFBundleShortVersionString - $(FLUTTER_BUILD_NAME) - CFBundleVersion - $(FLUTTER_BUILD_NUMBER) - LSMinimumSystemVersion - $(MACOSX_DEPLOYMENT_TARGET) - NSHumanReadableCopyright - $(PRODUCT_COPYRIGHT) - NSMainNibFile - MainMenu - NSPrincipalClass - NSApplication - - + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIconFile + + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSMinimumSystemVersion + $(MACOSX_DEPLOYMENT_TARGET) + NSHumanReadableCopyright + $(PRODUCT_COPYRIGHT) + NSMainNibFile + MainMenu + NSPrincipalClass + NSApplication + NSMicrophoneUsageDescription + Audio Recording + + \ No newline at end of file From 326209fdbf5fa9aad5438de872aca3cb263c3577 Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Tue, 30 Apr 2024 12:05:58 -0700 Subject: [PATCH 27/28] Use Flet 0.22.1 --- {{cookiecutter.out_dir}}/pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/pubspec.yaml b/{{cookiecutter.out_dir}}/pubspec.yaml index 3f2f468..1c85753 100644 --- a/{{cookiecutter.out_dir}}/pubspec.yaml +++ b/{{cookiecutter.out_dir}}/pubspec.yaml @@ -18,7 +18,7 @@ dependencies: # path: src/serious_python # ref: 'd059aef' - flet: ^0.22.0 + flet: ^0.22.1 # flet: # git: # url: https://github.com/flet-dev/flet.git From 1cc0c49f296bc871f8465a08e00c2e4aafcd403f Mon Sep 17 00:00:00 2001 From: Feodor Fitsner Date: Thu, 13 Jun 2024 11:52:50 -0700 Subject: [PATCH 28/28] minSdkVersion 23 for Android app --- {{cookiecutter.out_dir}}/android/app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.out_dir}}/android/app/build.gradle b/{{cookiecutter.out_dir}}/android/app/build.gradle index 44029cd..59a566d 100644 --- a/{{cookiecutter.out_dir}}/android/app/build.gradle +++ b/{{cookiecutter.out_dir}}/android/app/build.gradle @@ -42,7 +42,7 @@ android { defaultConfig { applicationId "{{ cookiecutter.org_name }}.{{ cookiecutter.project_name }}" - minSdkVersion 21 + minSdkVersion 23 targetSdkVersion flutter.targetSdkVersion versionCode flutterVersionCode.toInteger() versionName flutterVersionName