Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ivi-homescreen support #6

Closed
jwinarske opened this issue Jun 9, 2022 · 73 comments
Closed

ivi-homescreen support #6

jwinarske opened this issue Jun 9, 2022 · 73 comments

Comments

@jwinarske
Copy link

I was looking to add a recipe for this app to meta-agl-flutter. Looks like it will only run on web right now.

[ERROR:flutter/lib/ui/ui_dart_state.cc(198)] Unhandled Exception: Unsupported operation: DefaultFirebaseOptions have not been configured for linux - you can reconfigure this by running the FlutterFire CLI again.
#0      DefaultFirebaseOptions.currentPlatform (package:pumped_end_device/firebase_options.dart:38:9)
#1      main (package:pumped_end_device/main.dart:72:37)
#2      _runMainZoned.<anonymous closure>.<anonymous closure> (dart:ui/hooks.dart:130:25)
#3      _rootRun (dart:async/zone.dart:1426:13)
#4      _CustomZone.run (dart:async/zone.dart:1328:19)
#5      _runZoned (dart:async/zone.dart:1861:10)
#6      runZonedGuarded (dart:async/zone.dart:1849:12)
#7      _runMainZoned.<anonymous closure> (dart:ui/hooks.dart:126:5)
#8      _delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:297:19)
#9      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:192:12)

Can we get this app into a state that builds and runs on Linux? Then after which I will implement recipe for AGL.

For secure storage you want: https://pub.dev/packages/flutter_secure_storage
ivi-homescreen has default support for the native side of flutter_secure_storage.

Cheers,
Joel

@bernardcraddock
Copy link
Collaborator

lol It was running just fine on android, ios, web and linux, then as part of Release 6 we included initial firebase integration which broke linux. If you're happy to add AGL meta-flutter recipe for Pumped great thanks save me fumbling around and we'll seek to fix linux in next release.
Thanks for including flutter_secure_storage link i see it cover all platforms so will check it out

regards
Bernard

@bernardcraddock
Copy link
Collaborator

linux (desktop) and and Chrome (web) now build and run on macOS Parallels ubuntu.
I have sent AGL members email and cc'd you and would be most grateful if you can take some time out and implement initial AGL recipe, which i'll then be happy to maintain moving forward.

best regards

@jwinarske jwinarske changed the title linux support ivi-homescreen support Jul 13, 2022
@jwinarske
Copy link
Author

jwinarske commented Jul 13, 2022

Okay this is progress :)

Output log of runtime=Debug on ivi-homescreen (debug). It's hung up on splash screen failing to get a location.

If the output looks unfamiliar I'm running on my FlutterView PR:
toyota-connected/ivi-homescreen#69

/home/joel.winarske@toyotaconnected.com/development/ivi-homescreen/cmake-build-debug/shell/homescreen --b=/home/joel.winarske@toyotaconnected.com/development/ped/.homescreen
[INFO:main.cc(96)] Bundle Path: /home/joel.winarske@toyotaconnected.com/development/ped/.homescreen
[INFO:configuration.cc(200)] View Count: 1
[INFO:configuration.cc(248)] **********
[INFO:configuration.cc(249)] * Global *
[INFO:configuration.cc(250)] **********
[INFO:configuration.cc(251)] Application Id: .......... homescreen
[INFO:configuration.cc(255)] Cursor Theme: ............ 
[INFO:configuration.cc(256)] Disable Cursor: .......... false
[INFO:configuration.cc(258)] Debug Backend: ........... false
[INFO:configuration.cc(260)] ********
[INFO:configuration.cc(261)] * View *
[INFO:configuration.cc(262)] ********
[INFO:configuration.cc(269)] Bundle Path: .............. /home/joel.winarske@toyotaconnected.com/development/ped/.homescreen
[INFO:configuration.cc(270)] Window Type: .............. NORMAL
[INFO:configuration.cc(271)] Size: ..................... 1920 x 720
[INFO:configuration.cc(273)] Fullscreen: ............... false
[INFO:configuration.cc(275)] Accessibility Features: ... 0
[INFO:display.cc(35)] + Display()
[INFO:display.cc(104)] Wayland: wl_drm version 2
[INFO:display.cc(104)] Wayland: wl_compositor version 4
[INFO:display.cc(111)] 	Buffer Scale Enabled
[INFO:display.cc(104)] Wayland: wl_shm version 1
[INFO:display.cc(104)] Wayland: wl_output version 2
[INFO:display.cc(104)] Wayland: zxdg_output_manager_v1 version 3
[INFO:display.cc(104)] Wayland: wl_data_device_manager version 3
[INFO:display.cc(104)] Wayland: zwp_primary_selection_device_manager_v1 version 1
[INFO:display.cc(104)] Wayland: gtk_primary_selection_device_manager version 1
[INFO:display.cc(104)] Wayland: wl_subcompositor version 1
[INFO:display.cc(104)] Wayland: xdg_wm_base version 3
[INFO:display.cc(104)] Wayland: zxdg_shell_v6 version 1
[INFO:display.cc(104)] Wayland: wl_shell version 1
[INFO:display.cc(104)] Wayland: gtk_shell1 version 3
[INFO:display.cc(104)] Wayland: wp_viewporter version 1
[INFO:display.cc(104)] Wayland: zwp_pointer_gestures_v1 version 1
[INFO:display.cc(104)] Wayland: zwp_tablet_manager_v2 version 1
[INFO:display.cc(104)] Wayland: wl_seat version 5
[INFO:display.cc(104)] Wayland: zwp_relative_pointer_manager_v1 version 1
[INFO:display.cc(104)] Wayland: zwp_pointer_constraints_v1 version 1
[INFO:display.cc(104)] Wayland: zxdg_exporter_v1 version 1
[INFO:display.cc(104)] Wayland: zxdg_importer_v1 version 1
[INFO:display.cc(104)] Wayland: zwp_linux_dmabuf_v1 version 3
[INFO:display.cc(104)] Wayland: zwp_keyboard_shortcuts_inhibit_manager_v1 version 1
[INFO:display.cc(104)] Wayland: zwp_text_input_manager_v3 version 1
[INFO:display.cc(104)] Wayland: gtk_text_input_manager version 1
[INFO:display.cc(104)] Wayland: wl_eglstream_controller version 1
[INFO:display.cc(49)] agl_shell extension not present
[INFO:display.cc(52)] - Display()
[INFO:app.cc(30)] +App::App
[INFO:egl.cc(33)] EGL major: 1, minor 5
[INFO:egl.cc(607)] EGL_KHR_debug initialized
[INFO:egl.cc(43)] EGL has 80 configs
[INFO:egl.cc(60)] Buffer size for config 0 is 32
[INFO:window.cc(47)] (0) + WaylandWindow()
[INFO:display.cc(197)] Physical width: 340 mm x 190 mm
[INFO:display.cc(214)] Video mode: 1920 x 1080 @ 60.001 Hz
[INFO:display.cc(226)] Display Scale Factor: 1
[INFO:display.cc(253)] Pointer Present
[INFO:display.cc(262)] Keyboard Present
[INFO:display.cc(286)] Seat: seat0
[INFO:display.cc(543)] [keyboard repeat info] rate: 33, delay: 500
[INFO:window.cc(113)] (0) - WaylandWindow()
[INFO:engine.cc(435)] (0) PersistentCachePath: /home/joel.winarske@toyotaconnected.com/.homescreen
[INFO:engine.cc(98)] (0) +Engine::Engine
[INFO:engine.cc(145)] (0) flutter_assets: /home/joel.winarske@toyotaconnected.com/development/ped/.homescreen/data/flutter_assets
[INFO:engine.cc(171)] (0) icudtl.dat: /usr/local/share/flutter/icudtl.dat
[INFO:engine.cc(184)] (0) Runtime=debug
[INFO:engine.cc(224)] (0) -Engine::Engine
[INFO:engine.cc(261)] (0) +Engine::Run
[INFO:gl_process_resolver.cc(39)] dlopen: libEGL.so.1
[INFO:gl_process_resolver.cc(39)] dlopen: libGLESv2.so.2
[INFO:engine.cc(205)] (0) Running Task
[INFO:engine.cc(277)] (0) Engine::m_running = 1
[INFO:engine.cc(301)] (0) -Engine::Run
[INFO:flutter_view.cc(75)] (0) Engine running...
[INFO:engine.cc(362)] (0) Added Texture (5150) to registry
[INFO:app.cc(43)] -App::App
[INFO:engine.cc(94)] (0) flutter: The Dart VM service is listening on http://127.0.0.1:41259/m1FvWzeZJoQ=/
[INFO:isolate.cc(31)] (0) Root Isolate Service ID: "isolates/3212065304946639"
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.678116]: DEBUG: PumpedApp : Registering instance of geoLocationWrapper
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.682723]: DEBUG: PumpedApp : Registering instance of platformWrapper
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.682823]: DEBUG: PumpedApp : Registering instance of locationDataSource
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.683477]: DEBUG: PumpedApp : Registering instance of firebaseService
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.684889]: DEBUG: FirebaseService : platformSupport is []
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.684947]: DEBUG: FirebaseService : Platform does not yet support firebase
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.684996]: DEBUG: PumpedApp : Registering instance of underMaintenanceService
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.705848]: DEBUG: PumpedApp : Registering instance of aboutScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706003]: DEBUG: PumpedApp : Registering instance of appBarColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706140]: DEBUG: PumpedApp : Registering instance of splashScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706255]: DEBUG: PumpedApp : Registering instance of navDrawerColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706455]: DEBUG: PumpedApp : Registering instance of fsScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706761]: DEBUG: PumpedApp : Registering instance of fsCardColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.706957]: DEBUG: PumpedApp : Registering instance of fsDetailsScreenColorScheme
[INFO:platform.cc(38)] (0) Platform: ApplicationSwitcherDescription
	label: ""
	primaryColor: 4282339765
[INFO:navigation.cc(33)] (0) Navigation: Select Single Entry History
[INFO:navigation.cc(48)] (0) Navigation: Route Information Updated
	location: /
	state: 
	replace: 0
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:02.818874]: DEBUG: LocationDataSource : Checking Location Service Enabled
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:03.025510]: DEBUG: PumpedApp : {name: Ubuntu, version: 20.04.4 LTS (Focal Fossa), id: ubuntu, idLike: [debian], versionCodename: focal, versionId: 20.04, prettyName: Ubuntu 20.04.4 LTS, buildId: null, variant: null, variantId: null, machineId: f2feabc9c9204b619e0716f44f3db647}
[INFO:engine.cc(94)] (0) flutter: [2022-07-13 15:50:03.030480]: DEBUG: LocationDataSource : Location Service is Enabled ? false

Known problems:

  1. The debug build of flutter build bundle has a bug which incorrectly runs the Linux Dart code. It does not compile/run the same with an AOT image. I have an open issue on this.
  2. There is no current way to build Linux plugin Dart code for an AOT image. There is not support today that enables cross compiling of Linux GTK (desktop) embedder plugins. I have a planned design doc for the Flutter team on this. If you look at the Linux specific code, it's minimal and can easily be adapted for flutter build bundle.
  3. Some plugins may require native code to be implemented in ivi-homescreen. One example is secure storage, which has been implemented already.
  4. The geoclue client expects a valid application id when talking to geoclue daemon via D-Bus. ivi-homescreen is not a glib application. It behaves different when run as debug image, vs AOT due to item 1 above. I haven't decided on the best solution yet.

So given the above possible solutions:

  1. Implement cross compiling for flutter build linux and get Linux specific dart working in AOT. Regardless it may require native platform channel implementation. I went pretty far down this path already.
  2. Implement platform channels across the board, and do not depend on any Linux specific Dart code.

What's the required list of plugins you need support for?

@bernardcraddock
Copy link
Collaborator

thank you much appreciated - following some initial replies,
as for know issues / possible solutions i need some time to ponder and talk with the boys

  1. Location Service is Enabled ? false
    usually means you haven't enabled it once enabled it should just run!
    have your tried running irrespective of ivi-homescreen?
    https://help.ubuntu.com/stable/ubuntu-help/privacy-location.html#:~:text=Turn%20off%20the%20geolocation%20features,Location%20Services%20switch%20to%20on

  2. ivi-homescreen
    When you initially released ivi-homescreen (IVI) i could build and run it on desktop together with our old ped (after some manual fiddling around copying icudtl.dat and libflutter_engine.so). Then commit 26 Remove link dependency on libflutter_engine.so (Next main minor update #26) broke my IVI build and I haven't touched it since. I still have a recording of home screen launching old-ped so will share. We took this opportunity to archive old ped flutter2-archive branch and trash everything only rebooting in 2022 on flutter 3. I'm only saying all this as thought it might be advantageous (with your help) if i can resurrect IVI on my local desktop so as we're at least comparing near apples if you're also using homescreen?

  3. plugins as per pubspec but i'll re-list contents so is obvious ping you when i push back

regards

@jwinarske
Copy link
Author

A while back I started evaluating all the flutter Linux Plugins projects. I pulled interesting ones into this test app:
https://github.com/meta-flutter/linux_plugins

This is where I identified the issues I've referenced. Also where I found the issue with application Id for geolocation. In debug build 98% of the plugins work. Geolocation is one that does not. In AOT build 98% attempt to use platform channels for to issue one above. Geolocation fails authenticating with daemon due to defaulting to invalid application Id, something like . If I add glib application implementation i strongly suspect i can make a debug image work, but the problem remains with AOT. Which I'm told by Stuart Morgan is not supposed to work by design. Really the only path to get Linux Dart plugin code into an AOT (based on work to date) is to solve the cross compile issue, run flutter build linux and pick off the build artifacts. This involves me submitting design doc, getting approval, etc. It's a process.

A short term solution on your end might be to implement mock interfaces (location, etc) in Dart based on build flag. That way it can launch and run, and once the lower level stuff is sorted out, it's just a matter of removing the build flag (dart define).

@jwinarske
Copy link
Author

jwinarske commented Jul 15, 2022

@bernardcraddock
I have ped recipe merged into meta-flutter at this time, and duplicate in AGL patchset pending review. I've added it to the AGL flutter images.

https://gerrit.automotivelinux.org/gerrit/c/AGL/AGL-repo/+/27772
https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-devel/+/27771
https://github.com/meta-flutter/meta-flutter/tree/kirkstone/recipes-graphics/agl-flutter-apps

@jwinarske
Copy link
Author

This is what you get when running AOT image of PED (from root SSH session):

root@raspberrypi0-2w-64:~# export WAYLAND_DISPLAY=wayland-1
root@raspberrypi0-2w-64:~# export XDG_RUNTIME_DIR=/run/user/1000
root@raspberrypi0-2w-64:~# cd /usr/share/flutter/
root@raspberrypi0-2w-64:/usr/share/flutter# ls
flutter_homescreen  flutter_secure_storage_example  gallery  icudtl.dat  linux_plugins	pumped_end_device  test_egl  video_player_example
root@raspberrypi0-2w-64:/usr/share/flutter# homescreen --b=`pwd`/pumped_end_device --w=640 --h=480
[INFO:configuration.cc(248)] **********
[INFO:configuration.cc(249)] * Global *
[INFO:configuration.cc(250)] **********
[INFO:configuration.cc(251)] Application Id: .......... homescreen
[INFO:configuration.cc(255)] Cursor Theme: ............ 
[INFO:configuration.cc(256)] Disable Cursor: .......... false
[INFO:configuration.cc(258)] Debug Backend: ........... false
[INFO:configuration.cc(260)] ********
[INFO:configuration.cc(261)] * View *
[INFO:configuration.cc(262)] ********
[INFO:configuration.cc(269)] Bundle Path: .............. /usr/share/flutter/pumped_end_device
[INFO:configuration.cc(270)] Window Type: .............. NORMAL
[INFO:configuration.cc(271)] Size: ..................... 640 x 480
[INFO:configuration.cc(273)] Fullscreen: ............... false
[INFO:configuration.cc(275)] Accessibility Features: ... 0
[INFO:display.cc(50)] agl_shell extension not present
[INFO:display.cc(254)] Pointer Present
[INFO:display.cc(263)] Keyboard Present
[INFO:engine.cc(571)] (0) Loading AOT: /usr/share/flutter/pumped_end_device/lib/libapp.so
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.985310]: DEBUG: PumpedApp : Registering instance of geoLocationWrapper
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.995231]: DEBUG: PumpedApp : Registering instance of platformWrapper
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.995997]: DEBUG: PumpedApp : Registering instance of locationDataSource
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.996534]: DEBUG: PumpedApp : Registering instance of firebaseService
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.996889]: DEBUG: FirebaseService : platformSupport is []
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.997054]: DEBUG: FirebaseService : Platform does not yet support firebase
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:29.997443]: DEBUG: PumpedApp : Registering instance of underMaintenanceService
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.015617]: DEBUG: PumpedApp : Registering instance of aboutScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.016534]: DEBUG: PumpedApp : Registering instance of appBarColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.017061]: DEBUG: PumpedApp : Registering instance of splashScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.017474]: DEBUG: PumpedApp : Registering instance of navDrawerColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.018114]: DEBUG: PumpedApp : Registering instance of fsScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.021739]: DEBUG: PumpedApp : Registering instance of fsCardColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.022258]: DEBUG: PumpedApp : Registering instance of fsDetailsScreenColorScheme
[INFO:engine.cc(94)] (0) flutter: [2022-07-15 16:20:30.082983]: DEBUG: LocationDataSource : Checking Location Service Enabled
[ERROR:flutter/lib/ui/ui_dart_state.cc(198)] Unhandled Exception: UnimplementedError: linuxInfo() has not been implemented.
#0      DeviceInfoPlatform.linuxInfo (package:device_info_plus_platform_interface/device_info_plus_platform_interface.dart:69)
#1      DeviceInfoPlugin.linuxInfo (package:device_info_plus/device_info_plus.dart:61)
#2      DeviceInfoPlugin.deviceInfo (package:device_info_plus/device_info_plus.dart:93)
#3      PumpedApp._deviceInfo (package:pumped_end_device/main.dart:112)
#4      PumpedApp.build (package:pumped_end_device/main.dart:86)
#5      StatelessElement.build (package:flutter/src/widgets/framework.dart:4876)
#6      ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4806)
#7      Element.rebuild (package:flutter/src/widgets/framework.dart:4529)
#8      ComponentElement._firstBuild (package:flutter/src/widgets/framework.dart:4787)
#9      ComponentElement.mount (package:flutter/src/widgets/framework.dart:4781)
#10     Element.inflateWidget (package:flutter/src/widgets/framework.dart:3817)
#11     Element.updateChild (package:flutter/src/widgets/framework.dart:3551)
#12     RenderObjectToWidgetElement._rebuild (package:flutter/src/widgets/binding.dart:1202)
#13     RenderObjectToWidgetElement.mount (package:flutter/src/widgets/binding.dart:1171)
#14     RenderObjectToWidgetAdapter.attachToRenderTree.<anonymous closure> (package:flutter/src/widgets/binding.dart:1119)
#15     BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2597)
#16     RenderObjectToWidgetAdapter.attachToRenderTree (package:flutter/src/widgets/binding.dart:1118)
#17     WidgetsBinding.attachRootWidget (package:flutter/src/widgets/binding.dart:953)
#18     WidgetsBinding.scheduleAttachRootWidget.<anonymous closure> (package:flutter/src/widgets/binding.dart:933)
#19     _rootRun (dart:async/zone.dart:1418)
#20     _CustomZone.run (dart:async/zone.dart:1328)
#21     _CustomZone.runGuarded (dart:async/zone.dart:1236)
#22     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1276)
#23     _rootRun (dart:async/zone.dart:1426)
#24     _CustomZone.run (dart:async/zone.dart:1328)
#25     _CustomZone.bindCallback.<anonymous closure> (dart:async/zone.dart:1260)
#26     Timer._createTimer.<anonymous closure> (dart:async-patch/timer_patch.dart:18)
#27     _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398)
#28     _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429)
#29     _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:192)

[ERROR:flutter/lib/ui/ui_dart_state.cc(198)] Unhandled Exception: MissingPluginException(No implementation found for method isLocationServiceEnabled on channel flutter.baseflow.com/geolocator)
#0      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:165)
<asynchronous suspension>
#1      LocationDataSource.getLocationData (package:pumped_end_device/data/local/location/location_data_source.dart:49)
<asynchronous suspension>

The screen stays at detecting location.

This follows my above statement about the Linux Dart not getting compiled for AOT. This pattern is found in plugins that "support linux"; that means only when built with flutter build linux which is the GTK embedder.

Image used: https://github.com/meta-flutter/meta-flutter/actions/runs/2677329870

@bernardcraddock
Copy link
Collaborator

@jwinarske

thanks for such prompt and detailed replies and initial ped meta-flutter recipe i really appreciate it, and please excuse if my replies are delayed it's just that I'm doing this in my spare time.

My initial aspiration for Pumped end-device (MVP) is attempt to cover as many platforms as possible android/iOS, web, linux, Android-Automotive and CarPlay on the hope we can pivot as dominate platform emerges. Within this and as part of flutter/linux combination i jumped into AGL and ped is supporting web and desktop-linux.

Of course AGL being a bespoke linux distro i always suspected at some point we may need to create and specialise a ped-agl branch. i don't think we're there yet but just pointing it out.

  1. I've pushed a small change into pubspec.yaml which identifies ped plugins as requested
  2. Still reviewing known/issues possible solutions
  3. Will soon started evaluating all the flutter Linux Plugins projects.
  4. Before going down LocationDataSource rabbit hole can you confirm ped linux/web is working on your system without homescreen as per below logging?
    it's basically setting everything up then running getFuelStationsInRange (mocking sydney lat/lng so you get results). If you can confirm results then i know you're onto something and I'll start researching your points. Also just for your own info copy/paste the below getFuelStationsInRange http call into your browser and run it you'll see the results. I'm also in the process of setting swagger so anyone can read understand our end-points.

again thanks muchly best regards

[ /home/parallels/Documents/GitHub/ped gitb:(main) flutterc:(stable) ]
parallels > flutter run -d linux
Launching lib/main.dart on Linux in debug mode...
../..
Building Linux application...
flutter: [2022-07-16 20:16:43.123719]: DEBUG: PumpedApp : Registering instance of geoLocationWrapper
flutter: [2022-07-16 20:16:43.130792]: DEBUG: PumpedApp : Registering instance of platformWrapper
flutter: [2022-07-16 20:16:43.130965]: DEBUG: PumpedApp : Registering instance of locationDataSource
flutter: [2022-07-16 20:16:43.131903]: DEBUG: PumpedApp : Registering instance of firebaseService
flutter: [2022-07-16 20:16:43.133343]: DEBUG: FirebaseService : platformSupport is []
flutter: [2022-07-16 20:16:43.133423]: DEBUG: FirebaseService : Platform does not yet support firebase
flutter: [2022-07-16 20:16:43.133502]: DEBUG: PumpedApp : Registering instance of underMaintenanceService
flutter: [2022-07-16 20:16:43.168318]: DEBUG: PumpedApp : Registering instance of aboutScreenColorScheme
flutter: [2022-07-16 20:16:43.168635]: DEBUG: PumpedApp : Registering instance of appBarColorScheme
flutter: [2022-07-16 20:16:43.168856]: DEBUG: PumpedApp : Registering instance of splashScreenColorScheme
flutter: [2022-07-16 20:16:43.169032]: DEBUG: PumpedApp : Registering instance of navDrawerColorScheme
flutter: [2022-07-16 20:16:43.169326]: DEBUG: PumpedApp : Registering instance of fsScreenColorScheme
flutter: [2022-07-16 20:16:43.169792]: DEBUG: PumpedApp : Registering instance of fsCardColorScheme
flutter: [2022-07-16 20:16:43.170087]: DEBUG: PumpedApp : Registering instance of fsDetailsScreenColorScheme
flutter: [2022-07-16 20:16:43.351403]: DEBUG: LocationDataSource : Checking Location Service Enabled

An Observatory debugger and profiler on Linux is available at: http://127.0.0.1:44541/xSm8ClWC5Wc=/
The Flutter DevTools debugger and profiler on Linux is available at: http://127.0.0.1:9100?uri=http://127.0.0.1:44541/xSm8ClWC5Wc=/
flutter: [2022-07-16 20:16:43.662962]: DEBUG: PumpedApp : {name: Ubuntu, version: 20.04.4 LTS (Focal Fossa), id: ubuntu, idLike: [debian], versionCodename: focal, versionId: 20.04, prettyName: Ubuntu 20.04.4 LTS, buildId: null, variant: null, variantId: null, machineId: 2c1f2eed457b1d4d9243138134bbd24a}
flutter: [2022-07-16 20:16:43.693536]: DEBUG: LocationDataSource : Location Service is Enabled ? true
flutter: [2022-07-16 20:16:44.913104]: DEBUG: LocationDataSource : Location found as : Latitude: -33.8715, Longitude: 151.2006
flutter: [2022-07-16 20:16:44.914792]: DEBUG: LocationDataSource : Overriding the actual location with static one, as the Browser / Linux does not allow mocking the location
flutter: [2022-07-16 20:16:44.916021]: DEBUG: SplashScreen : latitude : -33.865107, longitude : 151.205282
flutter: [2022-07-16 20:16:49.933476]: DEBUG: NearByFuelStationsService : NearByFuelStationsDataSource::getFuelStations
flutter: [2022-07-16 20:16:49.933631]: DEBUG: LocationDataSource : Checking Location Service Enabled
flutter: [2022-07-16 20:16:49.934224]: DEBUG: UnderMaintenanceService : Platform does not support firebase yet
flutter: [2022-07-16 20:16:50.026703]: DEBUG: NearbyStationsScreen : Data was found to be null
flutter: [2022-07-16 20:16:50.202677]: DEBUG: GetFuelStationsInRange : execute::url is
http://tst.pumpedsvr.com:17001/getFuelStationsInRange?lat=-33.865107&lng=151.205282&range=4.763266315977763&unit=kilometre&fuelType=ALL&numResults=20&sortOrder=CHEAPEST_CLOSEST&searchIncrementally=true&dayOfWeek=SAT&clientConfigVersion=MR1aus-nsw-Z4Sydney&excludeVetoFuelStations=true

flutter: [2022-07-16 20:16:51.673157]: DEBUG: GetFuelStationsInRange : execute::Time taken 1471
flutter: [2022-07-16 20:16:51.673556]: DEBUG: GetFuelStationsInRange : execute::response.statusCode : 200
flutter: [2022-07-16 20:16:51.679433]: DEBUG: GetFuelStationsInRange : execute::response :

etc ...

@jwinarske
Copy link
Author

@bernardcraddock this plugin device info will not work:

PumpedApp : {name: Ubuntu, version: 20.04.4 LTS (Focal Fossa), id: ubuntu, idLike: [debian], versionCodename: focal, versionId: 20.04, prettyName: Ubuntu 20.04.4 LTS, buildId: null, variant: null, variantId: null, machineId: 2c1f2eed457b1d4d9243138134bbd24a}

I'm out next week on holiday, back the following. I escalated the Linux Dart plugin issue yesterday with the flutter team. If that gets addressed, that would enable most of the plugins, with key exception being "secure" d-bus (geoclue).

@jwinarske
Copy link
Author

flutter/flutter#107762

@jwinarske
Copy link
Author

@bernardcraddock another approach is what Tizen is doing. Fork all of the 1P/3P "Linux GTK" plugins and modify them to use a custom platform, then modify SDK to enable custom platform selection. This is a terrible approach that involves lots of maintenance costs; not a fan. The changes are pretty minor. Then you have to continually merge upstream changes; lots of busy work.

So in your case it would be to recreate all the plugins to add AGL platform. Another option.

The "Linux GTK" 1P Plugins directly load shared modules without validating then, which is something you wouldn't want to ship in a production release. So the-writing them targeting AGL platform might be the best approach.

I'll mock something up when I'm back next week.

@bernardcraddock
Copy link
Collaborator

@jwinarske thanks for the post I know little of Tizen, and regardless would never adopt an approach requiring continuous retrofit work.

We're running right to the bone and only have single shot refer ped/Linux so I'm ok to follow AGL route but looks like I'm going to need a lot of help to get it all working

If you're now on vacation please enjoy talk next week
regards

@bernardcraddock
Copy link
Collaborator

@jwinarske FYI we're doing significant simplification refactoring of ped for agl specifically landscape and just desktop-linux and web; no firebase/android/iOS/macOS and having absolute minimum pubspec.yaml 1P plugin entries as such will create new ped-agl repo let you know when done.

As you suggested will implement secure storage https://pub.dev/packages/flutter_secure_storage.
Also if you/Toyota have any flutter dev standards or install/deploy guideline etc please share
and lastly https://github.com/meta-flutter/linux_plugins seems boken ?

regards

@bernardcraddock
Copy link
Collaborator

@jwinarske - i've just pushed new release of ped on new agl branch
as previously mentioned it's significant simplification over main branch which is iOS and android centric.

As part of this push I've culled all non essential pubspec plugins so what's left are mandatory, so hopefully together with your help we can find an elegant solution for our linux AOT AGL compilation issue!

As your time permits appreciate if can you update PED recipe flutter-app-pumped-fuel-ped_git.bb for agl branch etc, (incidentally we never had an issues when flutter team bumped stable from 3.0.5 to 3.3.0)

Once you give me the all clear i'll take the flutter workspace tool for a spin, log any issues in meta-flutter
incidentally did you say the tool works on mac ?

thankyou
regards Bern

@jwinarske
Copy link
Author

@bernardcraddock
What branch should I point the ped recipe to?

The is a master merge pending with an AGL meta-agl-flutter README.md you should find useful.
https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-devel/+/27976/2

The script runs successfully on Mac. It currently only installs runtime artifacts on Ubuntu. In general custom-device support does work on Mac. To support Mac correctly I need image artifacts that are not yet getting published (QEMU aarch64 images). The x86_64 QEMU images are coming from meta-flutter which are my staging/test builds for downstream AGL master. Once AGL build infra is publishing flutter images I will update AGL workspace config accordingly.

Flutter Workspace Automation is currently working and available. It will be included in my upcoming training session.

@bernardcraddock
Copy link
Collaborator

@jwinarske
the AGL branch https://github.com/bernardpumped/ped/tree/agl

got the README thanks, it expects user running Ubuntu 20.04, which is fine as i've got Ubuntu desktop VM on my Mac, but does it work on both x86_64 and M1 or am i restricted to x86_64 ?

training sessions sound good
regards

@jwinarske
Copy link
Author

jwinarske commented Sep 8, 2022

The changeset pending review is for the last needlefish point release. Early next week tag.

These are the gaps to Mac multi-arch support in setup_flutter_workspace.py:

  • Sed command to patch (enable) custom devices
  • Requirement installation - x86_64/aarch64
  • Download aarch64 QEMU. Needs a pipeline publishing artifact.
  • JSON Config support for multi-arch

So the tip of tree for your AGL branch will be locked in this release. If you have anything you want to add, I'll be locking by 10:30AM PST tomorrow.

@bernardcraddock
Copy link
Collaborator

ok thank you, and nothing to add as just playing around for now becoming familiar

@bernardcraddock
Copy link
Collaborator

Hi @jwinarske - trust i find you well ,

i have extensively tested and now pushed ped latest to agl branch ready for meta-flutter testing. As your time permits (no rush) could you please bump flutter-app-pumped-fuel-ped_git.bb SRCREV with my last commit

Also could you clarify at what point or change should i trash and rebuild the workspace automation tool ?

I'm cautiously optimistic ped will launch or at least make significantly more progress than previous attempts assuming url_launcher_linux doesn't trip me up which it might, and if so i'll try to figure out why myself but failing that i'll need to escalate to you if that's ok.

best regards

@jwinarske
Copy link
Author

@bernardcraddock Yes I'll bump it. Same branch?

@bernardcraddock
Copy link
Collaborator

@jwinarske Yes same branch

@jwinarske
Copy link
Author

@bernardcraddock I just rolled kirkstone and dunfell. The mock location works for me with your recent changes. I get a fuel listing.

@bernardcraddock
Copy link
Collaborator

@jwinarske oh beauty mate, small milestone !!
i haven't even tried yet, working on Pumped backend today , give it a whirl tonight

@bernardcraddock
Copy link
Collaborator

Hi @jwinarske

I checked flutter aps - ped, gallery, flutter_animated_background/example and flutter_homescreen
they are all working fine when using device [1] Toyota flutter-auto (desktop-auto)
But - none of them are working when using device [2]: AGL x86_64 QEMU Image (AGL-qemu)
they all fail with the following.

ERROR:flutter/shell/common/shell.cc(93)] Dart Error: Can't load Kernel binary: Invalid SDK hash.
[ERROR:flutter/runtime/dart_isolate.cc(143)] Could not prepare isolate.
[ERROR:flutter/runtime/runtime_controller.cc(385)] Could not create root isolate.
[ERROR:flutter/shell/common/shell.cc(604)] Could not launch engine with configuration.

Is this and flutter SDK mismatch version between meta-flutter and AGL ?

If not can you confirm AGL x86_64 QEMU Image (AGL-qemu) is working your end ,
and if so then problem is with me, and Ubuntu is forever patching itself and i'm running following do you know of any concerns with this release ?

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.1 LTS
Release: 22.04
Codename: jammy

Failing that I am still running 2 installs of flutter the original snap for my own dev purposes and now meta-flutter's
but i keep them separate and would have thought if this was an issue it would have failed earlier either in build or flutter-auo run

Following is PED failing
ped-vm /home/parallels/Documents/GitHub/meta-flutter/tools/app/ped
parallels > flutter run
Multiple devices found:
Toyota flutter-auto (mobile) • desktop-auto • linux-x64 • flutter-auto x86_64
AGL x86_64 QEMU Image (mobile) • AGL-qemu • linux-x64 • agl-image-flutter-runtimedebug-qemux86-64
[1]: Toyota flutter-auto (desktop-auto)
[2]: AGL x86_64 QEMU Image (AGL-qemu)
Please choose one (To quit, press "q/Q"): 2
Launching lib/main.dart on AGL x86_64 QEMU Image in debug mode...
[INFO:configuration.cc(248)] **********
[INFO:configuration.cc(249)] * Global *
[INFO:configuration.cc(250)] **********
[INFO:configuration.cc(251)] Application Id: .......... flutter-auto
[INFO:configuration.cc(253)] JSON Configuration: ...... /tmp/pumped_end_device/default_config.json
[INFO:configuration.cc(255)] Cursor Theme: ............
[INFO:configuration.cc(256)] Disable Cursor: .......... false
[INFO:configuration.cc(258)] Debug Backend: ........... false
[INFO:configuration.cc(260)] ********
[INFO:configuration.cc(261)] * View *
[INFO:configuration.cc(262)] ********
[INFO:configuration.cc(264)] VM Args:
[INFO:configuration.cc(266)] --observatory-host=0.0.0.0
[INFO:configuration.cc(266)] --observatory-port=1234
[INFO:configuration.cc(269)] Bundle Path: .............. /tmp/pumped_end_device
[INFO:configuration.cc(270)] Window Type: .............. BG
[INFO:configuration.cc(271)] Size: ..................... 1920 x 1080
[INFO:configuration.cc(273)] Fullscreen: ............... false
[INFO:configuration.cc(275)] Accessibility Features: ... 0
[INFO:display.cc(275)] Keyboard Present
[INFO:engine.cc(173)] (0) Runtime=debug
[ERROR:flutter/shell/common/shell.cc(93)] Dart Error: Can't load Kernel binary: Invalid SDK hash.
[ERROR:flutter/runtime/dart_isolate.cc(143)] Could not prepare isolate.
[ERROR:flutter/runtime/runtime_controller.cc(385)] Could not create root isolate.
[ERROR:flutter/shell/common/shell.cc(604)] Could not launch engine with configuration.

please advise
regards

@jwinarske
Copy link
Author

For AGL it's running 3.3.1. meta-flutter is running 3.3.7. The error you are seeing is due to a mismatch with the QEMU image. So the-run the script passing flutter version 3.3.1.

@jwinarske
Copy link
Author

Also with meta-flutter config, M1 support for QEMU is present. Perf isn't great, and I'm looking into another solution that would require updating to Ventura; where perf should be optimal.

@bernardcraddock
Copy link
Collaborator

hey @jwinarske New issue and I'm a little stumped appreciate any help
running ped on "AGL-qemu" is now failing with Failed to find "xdg-user-dir" in the search path.
and It's working fine on flutter-auto just fine

Issue could be mine but I can't see how any ideas ?
if issue is not mine could there be :
Missing or disabled mandatory XDG components on AGL?
Anything to do with my Ubuntu parallels user trying to connect to AGL agl-driver user?
Anything missing or incorrect in meta-flutter/tools/.config/flutter/custom_devices.json ?

Also came across this flutter/flutter#74392

For additional context in this release PED still using local store for local persistence but, at your suggestion we're imminently switching to flutter_secure_store, But does secure_store use xdg_directories and if so will it incur same issue?

parallels > flutter run
Multiple devices found:
Toyota flutter-auto (mobile) • desktop-auto • linux-x64 • flutter-auto x86_64
AGL x86_64 QEMU Image (mobile) • AGL-qemu • linux-x64 • agl-image-flutter-runtimedebug-qemux86-64
[1]: Toyota flutter-auto (desktop-auto)
[2]: AGL x86_64 QEMU Image (AGL-qemu)
Please choose one (To quit, press "q/Q"): 2
Launching lib/main.dart on AGL x86_64 QEMU Image in debug mode...
[INFO:configuration.cc(248)] **********
[INFO:configuration.cc(249)] * Global *
[INFO:configuration.cc(250)] **********
[INFO:configuration.cc(251)] Application Id: .......... flutter-auto
[INFO:configuration.cc(253)] JSON Configuration: ...... /tmp/pumped_end_device/default_config.json
[INFO:configuration.cc(255)] Cursor Theme: ............
[INFO:configuration.cc(256)] Disable Cursor: .......... false
[INFO:configuration.cc(258)] Debug Backend: ........... false
[INFO:configuration.cc(260)] ********
[INFO:configuration.cc(261)] * View *
[INFO:configuration.cc(262)] ********
[INFO:configuration.cc(264)] VM Args:
[INFO:configuration.cc(266)] --observatory-host=0.0.0.0
[INFO:configuration.cc(266)] --observatory-port=1234
[INFO:configuration.cc(269)] Bundle Path: .............. /tmp/pumped_end_device
[INFO:configuration.cc(270)] Window Type: .............. BG
[INFO:configuration.cc(271)] Size: ..................... 1920 x 1080
[INFO:configuration.cc(273)] Fullscreen: ............... false
[INFO:configuration.cc(275)] Accessibility Features: ... 0
[INFO:display.cc(275)] Keyboard Present
[INFO:engine.cc(173)] (0) Runtime=debug
[INFO:engine.cc(94)] (0) flutter: [2022-11-25 07:55:27.847745]: DEBUG: UiSettingsDao : retrieving instance of UiSettings
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: ProcessException: Failed to find "xdg-user-dir" in the search path.
Command: xdg-user-dir
#0 LocalProcessManager.runSync (package:process/src/interface/local_process_manager.dart:118:7)
#1 getUserDirectory (package:xdg_directories/xdg_directories.dart:153:48) <-- path_provider dependant on xdg_directories
#2 PathProviderLinux.getApplicationDocumentsPath (package:path_provider_linux/src/path_provider_linux.dart:71:38)
#3 getApplicationDocumentsDirectory (package:path_provider/path_provider.dart:115:40) <-- localstore dependant on path_provider
#4 Utils.getDocumentDir (package:localstore/src/utils/io.dart:175:25)
#5 new Utils.
(package:localstore/src/utils/io.dart:12:5)
#6 Utils.utils (package:localstore/src/utils/io.dart:14:37)
#7 Utils.utils (package:localstore/src/utils/io.dart)
#8 Utils.instance (package:localstore/src/utils/io.dart:15:32)
#9 new DocumentRef.
(package:localstore/src/document_ref.dart:31:24)
#10 new Localstore.
(package:localstore/src/localstore_base.dart:11:33)
#11 Localstore._localstore (package:localstore/src/localstore_base.dart:13:52)
#12 Localstore._localstore (package:localstore/src/localstore_base.dart)
#13 Localstore.instance (package:localstore/src/localstore_base.dart:16:37) <-- PED currently using localstore
#14 UiSettingsDao.getUiSettings (package:pumped_end_device/data/local/dao/ui_settings_dao.dart:38:27)
#15 main (package:pumped_end_device/main.dart:47:57)
#16 _runMain. (dart:ui/hooks.dart:134:23)
#17 _delayEntrypointInvocation. (dart:isolate-patch/isolate_patch.dart:297:19)
#18 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:192:12)

appreciate any feedback
regards

@jwinarske
Copy link
Author

It may be that one of the plugins you're using has a runtime dependency on "xdg-user-dirs". That may not be present in the AGL QEMU image. That being the case there may be others missing as well. Then keep in mind testing with AOT is also required to see impact from "Linux" plugin debug bug.

As a side note i see when running ped via flutter-auto it's writing a whole lot of files directly to my home folder. It should be using the following folder: $HOME/.config/$APP_NAME

@bernardcraddock
Copy link
Collaborator

@jwinarske
it's a dependency of https://pub.dev/packages/localstore which is also the culprit dropping the JSON files in the home folder.

Latest PED release (just pushed) in addition to new functionality includes https://pub.dev/packages/flutter_secure_storage which is working fine on all the other platforms so see how it goes 1st using flutter-auto then on AGL

I believe i need to ensure AGL has libsecret-1-dev and libjsoncpp-dev to build the project, and libsecret-1-0 and libjsoncpp1 to run the application: So how to i check if AGL has these libraries and if not how do i install them?

When i get your reply i'm going to close this ticket and open new issues on meta-flutter should i have problems with flutter_secure_storage on AGL, so as the other guys can follow along and benefit.

regards

|-- localstore 1.3.4
| |-- flutter...
| |-- path...
| '-- path_provider 2.0.11
| |-- flutter...
| |-- path_provider_linux 2.1.7
| | |-- ffi 2.0.1
| | |-- flutter...
| | |-- path...
| | |-- path_provider_platform_interface...
| | '-- xdg_directories 0.2.0+2
| | |-- meta...
| | |-- path...
| | '-- process...

@bernardcraddock
Copy link
Collaborator

Hi @jwinarske
finally got some time to look at this and as discussed, installed libsecret-devel then

git clone https://github.com/meta-flutter/workspace-automation -b jw/impeller_gl
./flutter_workspace.py --clean

this ran for ages completed all the 'cipd ensure' stuff then failed on ninja OSError: [Errno 5] Input/output error
as follows appreciate any feedback. I haven't yet tried your main branch and remember i switched from Ubuntu to fedora38 if that makes any difference. Following logging is from end of cipd ensure' last fetch and deploy.

regards

• [fetch 9/14] Fetched fuchsia/sdk/core/linux-amd64:K3jvECt7y1_-zBVw3qjEV8RzqYkrIQfQIP9-wk6V5AgC …
• [unzip 9/14] Deployed fuchsia/sdk/core/linux-amd64:K3jvECt7y1_-zBVw3qjEV8RzqYkrIQfQIP9-wk6V5AgC…
[P76998 19:00:16.741 client.go:2139 I] All changes applied.
________ running 'python3 src/third_party/dart/tools/generate_package_config.py' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
________ running 'python3 src/third_party/dart/tools/generate_sdk_version_file.py' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
________ running 'python3 src/build/linux/sysroot_scripts/install-sysroot.py --arch=x64' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
Installing Debian sid amd64 root image: /home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/build/linux/debian_sid_amd64-sysroot
Downloading https://commondatastorage.googleapis.com/chrome-linux-sysroot/toolchain/79a7783607a69b6f439add567eb6fcb48877085c/debian_sid_amd64_sysroot.tar.xz
________ running 'python3 src/build/linux/sysroot_scripts/install-sysroot.py --arch=arm64' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
Installing Debian sid arm64 root image: /home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/build/linux/debian_sid_arm64-sysroot
Downloading https://commondatastorage.googleapis.com/chrome-linux-sysroot/toolchain/2cade9ee1ca9186b28ac768c19e1ab7c45ee0600/debian_sid_arm64_sysroot.tar.xz
Hook 'python3 src/build/linux/sysroot_scripts/install-sysroot.py --arch=arm64' took 11.27 secs
________ running 'python3 src/flutter/tools/pub_get_offline.py' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
Hook 'python3 src/flutter/tools/pub_get_offline.py' took 12.24 secs
________ running 'python3 src/flutter/tools/githooks/setup.py' in '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine'
local: PATH = /home/parallels/Documents/GitHub/workspace-automation/app/depot_tools:/home/parallels/Documents/GitHub/workspace-automation/flutter/bin:/home/parallels/dev/android-studio:/home/parallels/dev/android-studio/bin:/home/parallels/dev/android-studio/jbr/bin:/home/parallels/dev/Android/Sdk/build-tools:/home/parallels/dev/Android/Sdk/platform-tools:/home/parallels/dev/Android/Sdk/cmdline-tools/latest/bin:/home/parallels/Documents/GitHub/pumped-scripts/platform/common:/home/parallels/Documents/GitHub/pumped-scripts/platform/common/sh:/home/parallels/Documents/GitHub/pumped-scripts/platform/common/sql:/usr/lib64:/usr/include:/usr/share/doc:/usr/share/licenses:/home/parallels/bin:/home/parallels/.local/share::/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib:.:/home/parallels/Documents/GitHub/workspace-automation/flutter/bin
cwd: /home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/flutter
cmd: ['git', 'reset', '--hard']
HEAD is now at a18ee3c7f5 Reverts Dart SDK to 3.3.0-120.0.dev (#47959)
cmd: ['git', 'apply', '/home/parallels/Documents/GitHub/workspace-automation/patches/0001-IsCreationThreadCurrent-workaround.patch']
local: PATH = /home/parallels/Documents/GitHub/workspace-automation/app/depot_tools:/home/parallels/Documents/GitHub/workspace-automation/flutter/bin:/home/parallels/dev/android-studio:/home/parallels/dev/android-studio/bin:/home/parallels/dev/android-studio/jbr/bin:/home/parallels/dev/Android/Sdk/build-tools:/home/parallels/dev/Android/Sdk/platform-tools:/home/parallels/dev/Android/Sdk/cmdline-tools/latest/bin:/home/parallels/Documents/GitHub/pumped-scripts/platform/common:/home/parallels/Documents/GitHub/pumped-scripts/platform/common/sh:/home/parallels/Documents/GitHub/pumped-scripts/platform/common/sql:/usr/lib64:/usr/include:/usr/share/doc:/usr/share/licenses:/home/parallels/bin:/home/parallels/.local/share::/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib:.:/home/parallels/Documents/GitHub/workspace-automation/flutter/bin
cwd: /home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src
cmd: ['./flutter/tools/gn', '--unoptimized', '--runtime-mode=debug', '--embedder-for-target', '--enable-fontconfig', '--no-build-embedder-examples', '--enable-impeller-3d', '--enable-impeller-opengles', '--enable-impeller-vulkan', '--no-lto', '--no-goma']
Using prebuilt Dart SDK binary. If you are editing Dart sources and wish to compile the Dart SDK, set --no-prebuilt-dart-sdk.
Generating GN files in: out/host_debug_unopt
Generating compile_commands took 40ms
Done. Made 1198 targets from 376 files in 49562ms
cmd: ['echo', '>>', '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/out/host_debug_unopt/args.gn']

/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/out/host_debug_unopt/args.gn
cmd: ['ninja', '-C', '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/out/host_debug_unopt']
Traceback (most recent call last):
File "/home/parallels/Documents/GitHub/workspace-automation/app/depot_tools/ninja.py", line 89, in
sys.exit(main(sys.argv))
^^^^^^^^^^^^^^
File "/home/parallels/Documents/GitHub/workspace-automation/app/depot_tools/ninja.py", line 82, in main
return subprocess.call([ninja_path] + args[1:])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/subprocess.py", line 389, in call
with Popen(*popenargs, **kwargs) as p:
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/subprocess.py", line 1026, in init
self.execute_child(args, executable, preexec_fn, close_fds,
File "/usr/lib64/python3.11/subprocess.py", line 1950, in execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
OSError: [Errno 5] Input/output error: '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/flutter/third_party/ninja/ninja'
Traceback (most recent call last):
File "/home/parallels/Documents/GitHub/workspace-automation/./flutter_workspace.py", line 2520, in
main()
File "/home/parallels/Documents/GitHub/workspace-automation/./flutter_workspace.py", line 304, in main
setup_platforms(platforms, github_token, cookie_file, args.plex)
File "/home/parallels/Documents/GitHub/workspace-automation/./flutter_workspace.py", line 1915, in setup_platforms
setup_platform(platform
, git_token, cookie_file, plex)
File "/home/parallels/Documents/GitHub/workspace-automation/./flutter_workspace.py", line 1903, in setup_platform
handle_commands_obj(runtime.get('post_cmds'), cwd)
File "/home/parallels/Documents/GitHub/workspace-automation/./flutter_workspace.py", line 1536, in handle_commands_obj
subprocess.check_call(cmd_arr, cwd=cwd, env=local_env, shell=shell
)
File "/usr/lib64/python3.11/subprocess.py", line 413, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['ninja', '-C', '/home/parallels/Documents/GitHub/workspace-automation/.config/flutter_workspace/flutter-engine/engine/src/out/host_debug_unopt']' returned non-zero exit status 1.

@bernardcraddock
Copy link
Collaborator

@jwinarske - above issue is mine my Mac parallels VM blew up.
time permitting I'll rebuild it and give it another try.

regards

@bernardcraddock
Copy link
Collaborator

@jwinarske
rebuilt my VM and got this working just fine against gallery and saw the TextScaler errors in ped AGL branch you mentioned which incidentally don't appear in either Ubuntu or Fedora desktop, but none the less I'll look into it.

regards

@bernardcraddock
Copy link
Collaborator

Hey @jwinarske - ped agl branch using secure_storage is now running against -b jw/impeller_gl

I now need to switch away from jw/impeller_gl as flutter main channel changes too often.
When you can please merge jw/impeller_gl back into main and if possible, pin flutter-version": "3.16.0" or thereabouts.

Couple of other things if i may

  1. The way you're building everything from source is simply stunning, but I can't properly follow it. Therefore, and long as it's not too much trouble when you have time can you update flutter_workspace.py to additionally log stdout/stderr into a build log/s so as me and anyone else can follow along, without asking lots of questions.

  2. Can you update your README to include ped as an example

thank you and regards.

@jwinarske
Copy link
Author

@bernardcraddock I'm working on Firebase plugin support right now. The intent is to run your main branch as-is. I will most likely show your app at CES for a Firebase example.

@jwinarske
Copy link
Author

jwinarske commented Dec 7, 2023

#Main Plugin status

ivi-homescreen linux-gtk plugin
yes no google_sign_in
yes yes device_info_plus
no no fluttertoast
no no geocoding
no no geolocator
no no webview_flutter
yes no cloud_firestore
yes no firebase_auth
yes no firebase_core
? ? flutter_facebook_auth
? ? twitter_login

@jwinarske
Copy link
Author

AGL is currently at 3.13.9. Stable is currently at 3.16.x After CES I will move AGL to 3.16.x

@bernardcraddock
Copy link
Collaborator

bernardcraddock commented Dec 8, 2023 via email

@bernardcraddock
Copy link
Collaborator

@jwinarske

Oh yes please I'm very excited at the possibility you may show PED at CES as a Firebase example and between now and then will do whatever it takes to make that happen.

I'm also a little confused perhaps you can advise.

  1. main is portrait specifically designed for handhelds we've restricted firebase configuration to android and ios
  2. in its current state main won't run on Linux-desktop.
  3. If you still want to demo main it needs to be android as we're still registering ios on Apple's side
  4. I assume you're aware of the build changes you need to make for firebase as per README. If not just search for YOUR

Other
5. We're very close to releasing a new drop that includes firebase changes that when done I'll push to PED -b next_main (early next week) that when passes all tests will merge too main and then will freeze main so use that.
6. This drop we're also planning to be our initial Play Store worldwide developers release. So would be great if during demo you can mention so anyone interested can download.
7. We will release on the App Store just as soon as we can.
8. Once you have firebase sorted in meta-flutter, I'll configure same in the PED IVI branches including AGL
9. Lastly, I'm looking at integrating generative AI in PED "ai journey concierge" and have written a couple of draft documents you may find interesting and happy to share if you're interested a) pitch deck, b) Architecture design.

regards

@bernardcraddock
Copy link
Collaborator

@jwinarske
@jwinarske
referring above Main Plugin status nice to see you're extending homescreen and linux-gtk to support these plugins and in next drop we're adding firebase_crashlytics which is super helpful.

@jwinarske
Copy link
Author

Crashalytics is not supported on Linux in any format. Sentry is supported on ivi-homescreen. It uses the sentry-native library found on GitHub. Essentially a Crashpad port that connects to sentry.io's backend. Sentry has two tiers, one is free.

For the firebase stuff in options return android when platform.linux. No other change should be required. It works in flutter-desktop today. Will be adding to ivi-homescreen soon.

I'm not supporting linux-gtk for any plugins at this time.

@jwinarske
Copy link
Author

For main I was thinking it could be common for all platforms. That would require some refactoring on your end.

For location on Linux use the geoclue plug-in.
https://pub.dev/packages/geoclue

@bernardcraddock
Copy link
Collaborator

@jwinarske -

My original intention was main would be common for all platforms, but it proved very difficult ensuring both Portrait and Landscape looked good using material. At the time General consensus was that IVI would/should be landscape.

So, I instead created portrait and landscape branches.

  1. Portrait -b main / next_main, android and ios includes firebase.
  2. Landscape -b agl / ivi_, linux-desktop, hopefully AGL - firebase not officially supported on Linux

I am so caught up with Google and Apple getting ped published, but as soon as that is done, I'd really appreciate your help getting -b agl released to AGL on ivi-homescreen with sentry, geoclue and whatever else is important for demo

@jwinarske
Copy link
Author

jwinarske commented Jan 4, 2024

#Following up here.

I have an internal branch that implements a desktop registrar. I have the following plugins ported:

  • audioplayers (multi-channel audio player - supports games)

  • cloud_firestore

  • filament view (android view implementation of Google Filament)

  • file selector

  • firebase_auth

  • firebase_core

  • firebase_storage

  • key_event - keyboard functional

  • layer_playground view (android view impelemtation of a simple EGL scene - interface test tool)

  • url_launcher

  • secure_storage

  • Sentry native is supported. This is independent of the Sentry flutter option. I intend to talk to Sentry about enabling sentry-native crashes for sentry flutter projects.

The way one uses firebase with ivi-homescreen in my upcoming release is to change firebase options to return type of "android" when it is linux. This works for all the associated firebase functional test cases as well as for the Super Dash game.

next_main:

diff --git a/lib/firebase_options.dart b/lib/firebase_options.dart
index 00c12d7..3e779ef 100644
--- a/lib/firebase_options.dart
+++ b/lib/firebase_options.dart
@@ -24,6 +24,7 @@ class DefaultFirebaseOptions {
     }
     switch (defaultTargetPlatform) {
       case TargetPlatform.android:
+      case TargetPlatform.linux:
         return android;
       case TargetPlatform.iOS:
         return ios;
@@ -37,11 +38,6 @@ class DefaultFirebaseOptions {
           'DefaultFirebaseOptions have not been configured for windows - '
           'you can reconfigure this by running the FlutterFire CLI again.',
         );
-      case TargetPlatform.linux:
-        throw UnsupportedError(
-          'DefaultFirebaseOptions have not been configured for linux - '
-          'you can reconfigure this by running the FlutterFire CLI again.',
-        );
       default:
         throw UnsupportedError(
           'DefaultFirebaseOptions are not supported for this platform.',

@jwinarske
Copy link
Author

jwinarske commented Jan 4, 2024

@bernardcraddock

Running next_main with above change on my internal branch and not updating firebase credentials I see:

DEBUG: Creating Firebase App [DEFAULT] for Firebase C++ 11.6.0
DEBUG: Validating semaphore creation.
DEBUG: Added app name=[DEFAULT]: options, api_key=YOUR_android_apiKey, app_id=YOUR_android_appId, database_url=, messaging_sender_id=YOUR_messagingSenderId, storage_bucket=YOUR_storageBucket, project_id=YOUR_projectId (0x98007000)
[17:45:41.934168] [D] [secure_storage] read
[17:45:41.934180] [D] secure_storage: [Read] key: ped_ui_settings_coll-ped_ui_settings
[17:45:41.948478] [I] [2024-01-03 17:45:41.930963]: DEBUG: UiSettingsDao : Retrieving SecureStorage instance of UiSettings
[17:45:41.980603] [I] [2024-01-03 17:45:41.964650]: DEBUG: PumpedApp : Registering instance of geoLocationWrapper
[17:45:41.980612] [I] [2024-01-03 17:45:41.965869]: DEBUG: PumpedApp : Registering instance of locationDataSource
[17:45:41.980615] [I] [2024-01-03 17:45:41.966460]: DEBUG: PumpedApp : Registering instance of firebaseService
[17:45:41.980619] [I] [2024-01-03 17:45:41.967086]: DEBUG: FirebaseService : platformSupport is null
[17:45:41.980622] [I] [2024-01-03 17:45:41.967111]: DEBUG: FirebaseService : Platform does not yet support firebase
[17:45:41.980626] [I] [2024-01-03 17:45:41.967143]: DEBUG: PumpedApp : Registering instance of underMaintenanceService
[17:45:41.980629] [I] [2024-01-03 17:45:41.971466]: DEBUG: main : Value of textScale found as 1.0
[17:45:42.039060] [D] selectSingleEntryHistory
[17:45:42.049500] [I] [go_router] Route Information Updated
	uri: / 
	replace: false
[17:45:42.240516] [D] (0) SetWindowSize: width=800, height=600, pixel_ratio=1
[17:45:42.240556] [I] [2024-01-03 17:45:42.227064]: DEBUG: PumpedApp : {name: Fedora Linux, version: 39 (Workstation Edition), id: fedora, idLike: null, versionCodename: , versionId: 39, prettyName: Fedora Linux 39 (Workstation Edition), buildId: null, variant: Workstation Edition, variantId: workstation, machineId: 4aa152898c774426807777c2ceeba836}
WARNING: WatchStream (7fff280373f8) Stream error: 'Permission denied: Permission denied on resource project YOUR_projectId.'
WARNING: Could not reach Cloud Firestore backend. Connection failed 1 times. Most recent error: Permission denied on resource project YOUR_projectId.
 This typically indicates that your device does not have a healthy Internet connection at the moment. The client will operate in offline mode until it is able to successfully connect to the backend.
[17:45:42.243514] [D] [secure_storage] read
[17:45:42.243529] [D] secure_storage: [Read] key: ped_ui_settings_coll-ped_ui_settings
[17:45:42.253638] [I] [2024-01-03 17:45:42.242824]: DEBUG: SplashScreen : Error happened in querying Firestore [cloud_firestore/unavailable] Failed to get document because the client is offline., still making attempt
[17:45:42.253646] [I] [2024-01-03 17:45:42.243397]: DEBUG: UiSettingsDao : Retrieving SecureStorage instance of UiSettings
[17:45:42.253649] [I] [2024-01-03 17:45:42.244257]: DEBUG: LocationDataSource : Developer Options not turned on
[17:45:42.253653] [I] [2024-01-03 17:45:42.244276]: DEBUG: LocationDataSource : Checking Location Service Enabled
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method isLocationServiceEnabled on channel flutter.baseflow.com/geolocator)
#0      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:320:7)
<asynchronous suspension>
#1      MethodChannelGeolocator.isLocationServiceEnabled.<anonymous closure> (package:geolocator_platform_interface/src/implementations/method_channel_geolocator.dart:70:13)
<asynchronous suspension>
#2      LocationDataSource.getLocationData (package:pumped_end_device/data/local/location/location_data_source.dart:56:27)
<asynchronous suspension>
#3      _SplashScreenState._getLocationFromOnDeviceLocationService.<anonymous closure> (package:pumped_end_device/user-interface/splash/screen/splash_screen.dart:167:32)
<asynchronous suspension>

[17:45:42.269728] [I] [2024-01-03 17:45:42.258224]: DEBUG: SplashScreen : Error happened in querying Firestore [cloud_firestore/unavailable] Failed to get document because the client is offline., still making attempt
WARNING: WatchStream (7fff280373f8) Stream error: 'Permission denied: Permission denied on resource project YOUR_projectId.'

If next_main implements geoclue for the linux platform it should then just work work provided the credentials were plugged in. If you want to make that change and create a sandbox set of credentials I can test further. If it works I will show as one of the apps at my station on the CES floor.

Screenshot from 2024-01-03 17-56-23

@jwinarske
Copy link
Author

@bernardcraddock I take that back the tip of tree flutter-geolocator functional test case (example) is working on my branch. It requires creating a file:
~/.config/flutter/dconf/user

I added contents of:

user-db:user
system-db:local
system-db:ibus

@jwinarske
Copy link
Author

I copied latest geolocator linux release to local filesystem then modified pubspec.yaml:

diff --git a/pubspec.yaml b/pubspec.yaml
index d2f1a3a..537145c 100644
--- a/pubspec.yaml
+++ b/pubspec.yaml
@@ -34,7 +34,10 @@ dependencies:
   flutter_signin_button: ^2.0.0
   flutter_svg: ^2.0.9
   fluttertoast: ^8.2.1
-  geolocator: ^10.1.0
+  geolocator:
+    path: geolocator_linux_v0.2.0-1/geolocator
+  geolocator_linux:
+    path: geolocator_linux_v0.2.0-1/geolocator_linux
   get_it: ^7.2.0
   google_sign_in: ^6.1.6
   http: ^1.1.0

Screenshot from 2024-01-04 08-15-00

https://github.com/Baseflow/flutter-geolocator/tags

next_main

@jwinarske
Copy link
Author

I got it. I created an Android Firebase app, and then pinned to Fishburners. No errors in the log. Good to go!
Screenshot from 2024-01-04 11-38-43

@jwinarske
Copy link
Author

Only remaining issue is to get firebase-cpp-sdk to cross compile for aarch64. That's not supported today

@jwinarske
Copy link
Author

@bernardcraddock
Copy link
Collaborator

@jwinarske - sorry for late reply been away on family matters.

thank you for researching this, I was very pleasantly surprised this morning and please give me some time to come up to speed, as I need to ensure I don't break anything else. I'm still battling with Apple and then need to do some pumped AWS backend stuff so may take a little while before I circle back to this.
If you can showcase your branch that is working at CES that would be awesome

Also, back in Nov on jw/impller_gl branch you added commit "Add missing packages" which enables libsecret and secure storage as part of ivi-homescreen make which worked fine, however I stopped using jw/impller_gl as it's too unstable for me and I switched back to main.

Therefore, can you please merge that commit back into main so as my AGL and ivi_secure_storage branches (hardcoded location) work in main branch, instead of just failing.

regards

@jwinarske
Copy link
Author

My work will be released early February. We have to circle back on unit tests, and test the current very large test matrix.

Today after porting the 11.6.0 firebase packages I am seeing. Not sure if it's you or me.

/home/joel/ivi-homescreen/cmake-build-debug-clang/shell/homescreen --b=/home/joel/workspace-automation/app/ped/.desktop-homescreen --w=1280 --h=980
[21:42:51.205986] [I] jw/registrar @ 10b2cea
[21:42:51.206017] [I] **********
[21:42:51.206019] [I] * Global *
[21:42:51.206022] [I] **********
[21:42:51.206024] [I] Application Id: .......... homescreen
[21:42:51.206027] [I] Disable Cursor: .......... false
[21:42:51.206030] [I] Debug Backend: ........... false
[21:42:51.206033] [I] ********
[21:42:51.206035] [I] * View *
[21:42:51.206036] [I] ********
[21:42:51.206039] [I] Bundle Path: .............. /home/joel/workspace-automation/app/ped/.desktop-homescreen
[21:42:51.206043] [I] Window Type: .............. NORMAL
[21:42:51.206058] [I] Output Index: ............. 0
[21:42:51.206063] [I] Size: ..................... 1280 x 980
[21:42:51.206067] [I] Fullscreen: ............... false
[21:42:51.206071] [I] Accessibility Features: ... 0
[21:42:51.456019] [I] Pointer Present
[21:42:51.456033] [I] Keyboard Present
[21:42:51.498155] [I] (0) Runtime=debug
DEBUG: Creating Firebase App [DEFAULT] for Firebase C++ 11.6.0
DEBUG: Validating semaphore creation.
DEBUG: Added app name=[DEFAULT]: options, api_key=xxxxxxxxxxxxxxxxxxxxxxxxxxxx, app_id=xxxxxxxxxxxxxxxxxxx, database_url=, messaging_sender_id=xxxx, storage_bucket=xxxx, project_id=ivi-homescreen (0x88007230)
[21:42:51.838756] [I] [go_router] Route Information Updated
	uri: / 
	replace: false
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
[21:43:03.834011] [I] [go_router] Route Information Updated
	uri: /ped/fuel-stations/nearby  
	replace: false
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: [cloud_firestore/permission-denied] Missing or insufficient permissions.
#0      EventChannelExtension.receiveGuardedBroadcastStream (package:_flutterfire_internals/src/exception.dart:67:43)
#1      MethodChannelDocumentReference.snapshots.<anonymous closure> (package:cloud_firestore_platform_interface/src/method_channel/method_channel_document_reference.dart:132:18)
<asynchronous suspension>

[21:43:11.938957] [I] [go_router] Route Information Updated
	uri: /ped/settings 
	replace: false
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: [cloud_firestore/permission-denied] Missing or insufficient permissions.
#0      EventChannelExtension.receiveGuardedBroadcastStream (package:_flutterfire_internals/src/exception.dart:67:43)
#1      MethodChannelDocumentReference.snapshots.<anonymous closure> (package:cloud_firestore_platform_interface/src/method_channel/method_channel_document_reference.dart:132:18)
<asynchronous suspension>

[21:43:17.586435] [I] [go_router] Route Information Updated
	uri: /ped/settings/mocklocation 
	replace: false
[21:43:27.140698] [I] [go_router] Route Information Updated
	uri: /ped/settings 
	replace: false
[21:43:29.492346] [I] [go_router] Route Information Updated
	uri: /ped/fuel-stations/nearby 
	replace: false
WARNING: Listen for query at pumped-documents/under-maintenance failed: Missing or insufficient permissions.
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: [cloud_firestore/permission-denied] Missing or insufficient permissions.
#0      EventChannelExtension.receiveGuardedBroadcastStream (package:_flutterfire_internals/src/exception.dart:67:43)
#1      MethodChannelDocumentReference.snapshots.<anonymous closure> (package:cloud_firestore_platform_interface/src/method_channel/method_channel_document_reference.dart:132:18)
<asynchronous suspension>

@bernardcraddock
Copy link
Collaborator

@jwinarske,
I haven't touched next_main so suspect issue is yours

Concerning ivi_secure_storage and agl branches I just now manually updated configs/desktop-homescreen.json on my local in main to include the libsecret and -DBUILD_PLUGIN_SECURE_STORAGE changes you did, deleted ped and ivi-homescreen then

flutter_workspace.py --flutter-version=3.16.5
source ./setup_env.sh
cd app/ped
flutter run -d desktop-homescreen

and both branches working fine just switch branch in app/ped, i even tried ivi_localstore also working fine.
if you can confirm, demo this, and let them know we'll soon have it working with firebase next_main or other?

wa-vm > git branch

  • agl
    ivi_localstore
    ivi_secure_storage

wa-vm > git checkout ivi_localstore
Switched to branch 'ivi_localstore'
Your branch is up to date with 'origin/ivi_localstore'.

I'm happy to stick around if you need more input from me, to get this working - happy to have Googe Hangout if you want.

@bernardcraddock
Copy link
Collaborator

wa-vm > gitd configs/desktop-homescreen.json
diff --git a/configs/desktop-homescreen.json b/configs/desktop-homescreen.json
index 88ba0dc..d6977c9 100644
--- a/configs/desktop-homescreen.json
+++ b/configs/desktop-homescreen.json
@@ -13,7 +13,7 @@
"env": {
"HOMESCREEN_SRC_DIR": "${FLUTTER_WORKSPACE}/app/ivi-homescreen",
"HOMESCREEN_BUILD_DIR": "${FLUTTER_WORKSPACE}/app/ivi-homescreen/build",

  • "HOMESCREEN_CMAKE_ARGS": "-DCMAKE_BUILD_TYPE=Debug -DENABLE_DLT=OFF",
  • "HOMESCREEN_CMAKE_ARGS": "-DCMAKE_BUILD_TYPE=Debug -DENABLE_DLT=OFF -DBUILD_PLUGIN_SECURE_STORAGE=ON",
    "HOMESCREEN_EXE": "${HOMESCREEN_BUILD_DIR}/shell/homescreen --j=${PLATFORM_ID_DIR_RELATIVE}/default_config.json --b=${PLATFORM_ID_DIR_RELATIVE}",
    "PING_CMD": "loginctl show-session $(awk '/tty/ {print $1}' <(loginctl)) -p Type",
    "CREATE_BUNDLE_FOLDER": "mkdir -p ${PLATFORM_ID_DIR_RELATIVE}/data",
    @@ -43,7 +43,7 @@
    "sudo apt install lsb-release wget software-properties-common gnupg apt-file",
    "sudo apt-file update",
    "sudo apt install -y libwayland-dev wayland-protocols mesa-common-dev libegl1-mesa-dev libgles2-mesa-dev mesa-utils libxkbcommon-dev ninja-build",
  •        "sudo apt install -y build-essential libvulkan-dev vulkan-tools vulkan-validationlayers vulkan-utils libtool",
    
  •        "sudo apt install -y build-essential libvulkan-dev vulkan-tools vulkan-validationlayers vulkan-utils libtool libsecret-1-dev libcurl4-openssl-dev",
           "sudo apt autoremove -y",
           "sudo apt clean -y",
           "cmake --version",
    

@@ -54,7 +54,7 @@
"cmds": [
"sudo dnf -y update",
"sudo dnf -y upgrade",

  •        "sudo dnf -y install wayland-devel wayland-protocols-devel libxkbcommon-devel cmake ninja-build mesa-dri-drivers mesa-filesystem mesa-libEGL-devel mesa-libGL-devel mesa-libGLU-devel mesa-libgbm-devel mesa-libglapi mesa-libxatracker mesa-vulkan-drivers vulkan-tools libunwind-devel gstreamer1-devel gstreamer1-plugins-base-devel gstreamer1-plugins-bad-free-devel gstreamer1-plugins-bad-free-extras gstreamer1-plugins-base-tools gstreamer1-plugins-good gstreamer1-plugins-good-extras gstreamer1-plugins-ugly-free libtool",
    
  •        "sudo dnf -y install wayland-devel wayland-protocols-devel libxkbcommon-devel cmake ninja-build mesa-dri-drivers mesa-filesystem mesa-libEGL-devel mesa-libGL-devel mesa-libGLU-devel mesa-libgbm-devel mesa-libglapi mesa-libxatracker mesa-vulkan-drivers vulkan-tools libunwind-devel gstreamer1-devel gstreamer1-plugins-base-devel gstreamer1-plugins-bad-free-devel gstreamer1-plugins-bad-free-extras gstreamer1-plugins-base-tools gstreamer1-plugins-good gstreamer1-plugins-good-extras gstreamer1-plugins-ugly-free libtool libsecret-devel libcurl-devel",
           "sudo dnf -y autoremove",
           "cmake --version",
           "dnf provides cmake"
    

@@ -89,4 +89,4 @@
"forwardPortSuccessRegex": null,
"screenshot": null
}
-}

@bernardcraddock
Copy link
Collaborator

that was a bit ugly hopefully to can see the .png attachment ok
Untitled 2

@jwinarske
Copy link
Author

I'm sticking with next_main. Not focused on anything else. Way too much work and not enough time to do it

@bernardcraddock
Copy link
Collaborator

bernardcraddock commented Jan 8, 2024 via email

@jwinarske
Copy link
Author

PXL_20240108_194809064

@bernardcraddock
Copy link
Collaborator

Oh my Goodness, you got it working yippee thank you very much!
Pity it looks so ugly, and that's why we created the IVI (landscape) branch as looks so much nicer.
If anyone is curious, please pass on my details.

We originally didn't include firebase within IVI, because if you recall way back when, I did mention it and you said you weren't going to use/adopt it. Do you plan on bringing it to AGL?

next_main/main branches have considerable firebase functionality that we're constantly adding to.
We develop on macOS as mandatory requirement for iOS and CarPlay currently running firebase 12.9.1.
If you're happy to continue demo for us, we'll figure out how we can share everything with you without comprising keys.

As soon as I've finished with iOS and AWS, will switch back and review the tweaks you did to get this working.

on a separate note,
I'm going to submit an application on Converge-2 OpenAI Startup Fund https://openai.fund/news/converge-2.
and I'm going to mention our collaboration meta-flutter/PED

In addition to this I have friends who work in AI/LLM Persona Modulation, who feel this technology could potentially be a good candidate for an In-vehicle AI system in the context of a Personalised journey concierge, that is combined with robust critical safety/security and privacy concerns.

thoughts?

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

No branches or pull requests

2 participants