Hi
We noticed that our Mobile app changes language to english randomly. We have updated our code with V7.1.0 version. Any adwise how to fix?
Mika
10 Answer(s)
-
0
hi Mika,
- Which platform ? iOS / Android
- Which device? Emulator / Real device
- What's your device language?
- What's the user language coming from Host?
- When the language changes, do you see the login screen?
Write a log here to see if you get CultureNotFoundException https://github.com/aspnetzero/aspnet-zero-core/blob/a99934d7851ff4b55a88d3df1ab9457afd25a9be/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Mobile.Shared/ViewModels/Base/UserConfigurationManager.cs#L101
-
0
hi alper,
- Android
- Real device
- Finnish
- We have added finnish language and it is being used as default language (Host and Tenant)
- Language changed randomly when screen was changed. No login screen
The problem has occured about 5 times and I have not been able to reproduce it but I will set breakpoint there and try if it hits..
-
0
Hi @mika
Did you find out anything about this ?
-
0
Hi No. It happens randomly and about 2 times after last edit and both times on my personal phone where I use our released app.
-
0
if you can save logs (to FireBase or to local device) and send us after this happens, we'll try to figure out the problem.
-
0
Can you provide more detail what kind of logs you need and where to look for errors beside the "CultureNotFoundException"
-
0
Add an exception handling to the
UserConfigurationManager.GetUserCulture()
method. https://github.com/aspnetzero/aspnet-zero-core/blob/a99934d7851ff4b55a88d3df1ab9457afd25a9be/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Mobile.Shared/ViewModels/Base/UserConfigurationManager.cs#L101try { return new CultureInfo(AppContext.Value.Configuration.Localization.CurrentCulture.Name); } catch (CultureNotFoundException ex) { ExceptionHandler.LogException(ex); /*--- added this ---*/ return locale.GetCurrentCultureInfo(); }
Also send exception logs to FireBase or save it to local device in
ExceptionHandler.LogException()
method. https://github.com/aspnetzero/aspnet-zero-core/blob/a99934d7851ff4b55a88d3df1ab9457afd25a9be/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Mobile.Shared/Core/Exception/ExceptionHandler.cs#L22Send us the exception logs to investigate.
-
0
Don't know why you closed this.. We use app center and we updated our app last sunday and I have seen one time this since but there was no log in app center.
Problem still exists and if next time problem happens to me and there is no log in our appcenter account, we need more hepl to pinpoint the problem.
-
0
Hi @mika
This is closed automatically since there was no answer for a long time. I will leave this open and will wait exception logs from your side.
Thanks,
-
0
This issue is closed because of no recent activity. Please open a new issue if you are still having this problem.