booleanbites / houzi-support

Support forum repo for issues & bugs reported for Houzi Flutter App.
4 stars 0 forks source link

Errors with localizations #3

Closed roccinio closed 1 year ago

roccinio commented 1 year ago

Hello,

Changed path to 1.8.2 (please update your script to support the latest flutter sdk. I have other projects and it is a pain to downgrade and upgrade all the time) and updated your Kurdish file (why on earth you have those specific files for that language is beyond me. Maybe is you mother tongue and you forgot them there?) but i am getting

error: Target of URI doesn't exist: 'package:flutter_gen/gen_l10n/app_localizations.dart'. (uri_does_not_exist at [houzi_package] lib/houzi_main.dart:6) error: Target of URI doesn't exist: 'package:flutter_localizations/flutter_localizations.dart'. (uri_does_not_exist at [houzi_package] lib/houzi_main.dart:7) error: Undefined name 'AppLocalizations'. (undefined_identifier at [houzi_package] lib/houzi_main.dart:121) error: Undefined name 'KurdishMaterialLocalizations'. (undefined_identifier at [houzi_package] lib/houzi_main.dart:122) error: Undefined name 'GlobalMaterialLocalizations'. (undefined_identifier at [houzi_package] lib/houzi_main.dart:124) error: Undefined name 'GlobalCupertinoLocalizations'. (undefined_identifier at [houzi_package] lib/houzi_main.dart:125)

I have cleaned the project, restarted the IDE, restarted the Dart analysis etc but still get the same errors.

Any ideas?

Kind regards

AdilSoomro commented 1 year ago

Hello, we’re working on updating the source code to latest flutter with null safety. However for the current version, can you please confirm:

You are using Android Studio, (VS Code has issues) You’ve Flutter 3.0.5.

If both of above are okay, then the path can be set to 1.8.1 in pubspec. Please do clean project after changing any of these thing and then retry.

roccinio commented 1 year ago

Hello, I am using Android studio on an m1 if it matters. No I haven't downgraded because as I explained earlier I am simultaneously working on other projects, and doing that every time I move back and forth between them is torture. I guess I am stuck with a non working script until you update it. Do you have an ETA because I am on a deadline and I could never have thought before buying from a reputable publisher, that your product would be so out of date.

Regards

AdilSoomro commented 1 year ago

Hello,

Please replace your kurdish_material_localization_delegate.dart with the attached file.

kurdish_material_localization_delegate.dart.zip

Where: houzi_package > lib > l10n > kurdish_material_localization_delegate.dart

Why we have this file? That's because its used in Kurdish localization. We've clients from Iraq who are using this app.

I've checked this with following state:

Do a clean & compile after replace. If you still face issue, email at houziapp@gmail.com, and I'll send you fresh release code with the above file fixed.

Hassan6197 commented 1 year ago

Hello @roccinio, have you tried to run the project?

roccinio commented 1 year ago

Hello Hassan,

run a project with errors? How? XD

Please fix it and update it to support null safety and the latest flutter versions. Those kurdish dart files are causing troubles and they should be either removed or refactored in a different way.

Regards

Edit: Apologies. I just realised that you were talking about the previous fix. We had a private conversation and i reported that now it is even worse.

AdilSoomro commented 1 year ago

@roccinio you either have strict mode on for flutter warning or something else is going on. The errors you’ve posted are result of dart analysis. You can remove the Kurdish translation related issue by removing the two files for Kurdish, and their references from houzi_main.dart as we cannot remove these.

The other issues are due to files, that requires to be generated by compiler. Once you remove the Kurdish lang files, and compile the project, the localisation file will be generated and references will be linked and error will be gone.

There’s nothing in the app that requires null safety. App still supports latest version of Flutter with the changes I sent yesterday.

AdilSoomro commented 1 year ago

Latest firebase configuration introduced a breaking change in library. To solve this, please goto pubspec file:

houzi > packages > houzi_package > pubspec.yaml

and add this dependency:

firebase_core_platform_interface: 4.5.1

This should solve your dependency issue.

AdilSoomro commented 1 year ago

the new version 1.1.4.3 should solve this particular issue. I'm marking this issue as closed.