Также я должен упомянуть, что я использую шаблон mvvm и инструмент, который я использую для это набор инструментов сообщества.
- Проблема:
Вот как я внедрил службу:
Код: Выделить всё
builder.Services.AddTransient((e) => FilePicker.Default);
I shared vs 2022 output information and the Huawei phone's logcat when error happened.
I styled the error part of the logs to bold. I hope it is understandable.
What did i tried to fix the problem or find the causes of the error:
- I tried bypassing mvvm pattern and I called filepicker.pickasync() inside clicked event of a button using either static method or injected service. No luck.
- Tried the first way on several different pages in case navigation causes a problem. Nope!!
- I tried mediapicker instead of filepicker to see if the file picker the problem. Nope! Mediapicker causes the same problem.
- But if I create new maui project and use the file picker or media picker as either static method or the injected service on both code behind clicked event and mvvm pattern's command there is no problem. works perfectly.
What do you think?
PS: sorry for my english.
VS 2022 Output:
[MouseWheelSynthesizer] mMoveStepInDp: 64, mMoveStepInPixel: 192,
mUpTimeDelayed: 100
[ViewRootImpl] ViewRootImpl mIsInProductivePCDisplay: false
[InputEventReceiver]
dispatchInputInterval 1000000
[DecorView] showOrHideHighlightView:
hasFocus=false; winMode=1; isMrgNull=true
[HiTouch_PressGestureDetector] onAttached, package=com.andromeda.gis,
windowType=1, mIsHiTouchRestricted=false
[mali_winsys] EGLint
new_window_surface(egl_winsys_display *, void *, EGLSurface,
EGLConfig, egl_winsys_surface **, EGLBoolean) returns 0x3000
[AudioManager] getStreamMaxVolume treamType: 3
[AudioManager]
getStreamVolume streamType: 3 volume: 5 [AudioManager]
getStreamMaxVolume treamType: 3
[AudioManager] getStreamVolume
streamType: 3 volume: 5 [AudioManager] getStreamMaxVolume treamType:
3
[AudioManager] getStreamVolume streamType: 3 volume: 5
[AudioManager] getStreamMaxVolume treamType: 3 [AudioManager]
getStreamVolume streamType: 3 volume: 5 [WindowDecorActionBar] should
not do the transition or the transition anim is null or it is running
or the mContainer view is null or mContainer view hasn't been drawn
to screen [Icon_Cache] add:2131558400#com.andromeda.gis [DecorView]
showOrHideHighlightView: hasFocus=true; winMode=1; isMrgNull=true
[InputMethodManager] startInputReason = 1
[HwRemoteInputMethodManager] isCasting false because
IHwDistributedWindowManager is invalid. [AudioManager]
getStreamMaxVolume treamType: 3 [AudioManager] getStreamVolume
streamType: 3 volume: 5 [DecorView] showOrHideHighlightView:
hasFocus=false; winMode=1; isMrgNull=true [RmeSchedManager] init Rme,
version is: v1.0 [libEGL] EGLNativeWindowType 0x7988c3eed0 disconnect
failed [libEGL] EGLNativeWindowType 0x79fe7b1ad0 disconnect failed
[0:] Lifecycle event: OnStop [AudioManager] getStreamMaxVolume
treamType: 3 [AudioManager] getStreamVolume streamType: 3 volume: 5
[AudioManager] getStreamMaxVolume treamType: 3 [AudioManager]
getStreamVolume streamType: 3 volume: 5 [0:] Lifecycle event: OnStop
[AudioManager] getStreamMaxVolume treamType: 3 [AudioManager]
getStreamVolume streamType: 3 volume: 5 [AudioManager]
getStreamMaxVolume treamType: 3 [AudioManager] getStreamVolume
streamType: 3 volume: 5 [Ads] JS:
type=omidMeasurementBelow&time=2024-10-23T15%3A16%3A27.362Z&message=Geometry%20change%20event%20occurred&event=%7B%22adSessionId%22%3A%22e325ddc7-84ad-40d6-9f72-8223c28968da%22%2C%22timestamp%22%3A1729696587362%2C%22type%22%3A%22geometryChange%22%2C%22data%22%3A%7B%22viewport%22%3A%7B%22width%22%3A360%2C%22height%22%3A780%7D%2C%22adView%22%3A%7B%22percentageInView%22%3A0%2C%22pixelsInView%22%3A0%2C%22reasons%22%3A%5B%22notFound%22%2C%22backgrounded%22%5D%2C%22geometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%2C%22pixels%22%3A0%7D%2C%22onScreenGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%2C%22pixels%22%3A0%2C%22obstructions%22%3A%5B%5D%2C%22friendlyObstructions%22%3A%5B%5D%7D%2C%22containerGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%7D%2C%22onScreenContainerGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%7D%2C%22measuringElement%22%3Atrue%7D%2C%22declaredFriendlyObstructions%22%3A0%7D%7D
(https://pagead2.googlesyndication.com/o ... n_bin.js:6)
[chromium] [INFO:CONSOLE(6)]
"type=omidMeasurementBelow&time=2024-10-23T15%3A16%3A27.362Z&message=Geometry%20change%20event%20occurred&event=%7B%22adSessionId%22%3A%22e325ddc7-84ad-40d6-9f72-8223c28968da%22%2C%22timestamp%22%3A1729696587362%2C%22type%22%3A%22geometryChange%22%2C%22data%22%3A%7B%22viewport%22%3A%7B%22width%22%3A360%2C%22height%22%3A780%7D%2C%22adView%22%3A%7B%22percentageInView%22%3A0%2C%22pixelsInView%22%3A0%2C%22reasons%22%3A%5B%22notFound%22%2C%22backgrounded%22%5D%2C%22geometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%2C%22pixels%22%3A0%7D%2C%22onScreenGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%2C%22pixels%22%3A0%2C%22obstructions%22%3A%5B%5D%2C%22friendlyObstructions%22%3A%5B%5D%7D%2C%22containerGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%7D%2C%22onScreenContainerGeometry%22%3A%7B%22width%22%3A0%2C%22height%22%3A0%2C%22x%22%3A0%2C%22y%22%3A0%7D%2C%22measuringElement%22%3Atrue%7D%2C%22declaredFriendlyObstructions%22%3A0%7D%7D",
source:
https://pagead2.googlesyndication.com/o ... ion_bin.js
(6) [Choreographer] Skipped 31 frames! The application may be doing
too much work on its main thread. [m.andromeda.gi] Suspending all
threads took: 80.701ms [AudioManager] getStreamMaxVolume treamType:
3 [AudioManager] getStreamVolume streamType: 3 volume: 5
[AudioManager] getStreamMaxVolume treamType: 3 [AudioManager]
getStreamVolume streamType: 3 volume: 5 [AudioManager]
getStreamMaxVolume treamType: 3 [AudioManager] getStreamVolume
streamType: 3 volume: 5 [AudioManager] getStreamMaxVolume treamType:
3 [AudioManager] getStreamVolume streamType: 3 volume: 5 [FA]
Application backgrounded at: timestamp_millis: 1729696586233
[m.andromeda.gi] Accessing hidden method
Lsun/misc/Unsafe;->getLong(Ljava/lang/Object;J)J
(greylist,core-platform-api, linking, allowed) [RmeSchedManager] init
Rme, version is: v1.0 [RtgSchedEvent] current pid:19835 AppType:-1
[m.andromeda.gi] Explicit concurrent copying GC freed 133957(6786KB)
AllocSpace objects, 20(7764KB) LOS objects, 39% free, 36MB/60MB,
paused 190us total 155.101ms [] * Assertion at
/__w/1/s/src/mono/mono/mini/interp/interp.c:2106, condition
`context->stack_pointer < context->stack_end' not met
**> [libc] Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 19835
(m.andromeda.gis), pid 19835 (m.andromeda.gis)**
logcat:
Zaman Cihaz Adı Tür PID Etiket İleti 10-23 18:16:33.052 HUAWEI
POT-LX1 Info 2328 ChannelRating getChloadScore channel: 165,
bestscore: 7500.0, chload: 0 10-23 18:16:34.882 HUAWEI
POT-LX1 Debug 1584 GnssLocationProvider report sv info 10-23
18:16:34.881 HUAWEI
POT-LX1 Debug 643 GnssHAL_GnssInterface gnssSvStatusCb_1_1: Sv status
callback V1_1 called 10-23 18:16:34.881 HUAWEI
POT-LX1 Debug 643 GNSS_ADAPTER gnss_sv_status_cb_1_1, num: 19 10-23
18:16:34.881 HUAWEI
POT-LX1 Debug 643 GNSS_ADAPTER hisi_callback_report_sv_status, cbv: 1,
count: 19 10-23 18:16:34.878 HUAWEI
POT-LX1 Verbose 1584 ActivityManager Successfully start provider
ContentProviderRecord{5b89572 u0
com.google.android.gsf/.gservices.GservicesProvider}
launchingApp=ProcessRecord{adc427d
16420:com.google.process.gservices/u0a154} caller pid= 22094 10-23
18:16:33.898 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.888 HUAWEI
POT-LX1 Info 1584 chatty uid=1000(system) PowerManagerSer identical 3
lines 10-23 18:16:34.580 HUAWEI POT-LX1 Error 22240 DEBUG backtrace:
#00 pc 000000000007066c /apex/com.android.runtime/lib64/bionic/libc.so (abort+160) (BuildId:
b91c775ccc9b0556e91bc575a2511cd0)
#01 pc 000000000002680c /data/app/com.andromeda.gis-hPKv5fEbNmTPTOtkhLi2CA==/lib/arm64/libmonodroid.so
(xamarin::android::Helpers::abort_application()+8) (BuildId:
d3e684eeba0642f045c5712ac9fab524a65cd38d)
#02 pc 0000000000041edc /data/app/com.andromeda.gis-hPKv5fEbNmTPTOtkhLi2CA==/lib/arm64/libmonodroid.so
(xamarin::android::internal::MonodroidRuntime::mono_log_handler(char
const*, char const*, char const*, int, void*)+144) (BuildId:
d3e684eeba0642f045c5712ac9fab524a65cd38d)
#03 pc 00000000001d759c /data/app/com.andromeda.gis-hPKv5fEbNmTPTOtkhLi2CA==/lib/arm64/libmonosgen-2.0.so
SOME OTHER BUILDID.....
**> 18:16:34.580 HUAWEI POT-LX1 Error 22240 DEBUG 10-23
18:16:34.572 HUAWEI POT-LX1 Error 22240 DEBUG signal 6 (SIGABRT), code
-1 (SI_QUEUE), fault addr --------**
x0 0000000000000000 x1 0000000000004d7b x2 0000000000000006 x3 0000007ff002cec0
x4 0000000000000000 x5 0000000000000000 x6 0000000000000000 x7 7f7f7f7f7f7f7f7f
x8 00000000000000f0 x9 57c2ef4d9878e3b8 x10 0000000000000001 x11 0000000000000000
x12 fffffff0fffffbdf x13 0000000000000000 x14 0000000000000004 x15 00000af820354e25
x16 0000007a90c27a08 x17 0000007a90c077c0 x18 0000007a958ba000 x19 0000000000004d7b
x20 0000000000004d7b x21 00000000ffffffff x22 0000007ff002d718 x23 0000007949b78058
x24 0000007995a1ff18 x25 0000007ff002d770 x26 000000799bf53170 x27 0000000000000000
x28 0000007a9461f020 x29 0000007ff002cf60
sp 0000007ff002cea0 lr 0000007a90bbc640 pc 0000007a90bbc66c 10-23 18:16:34.572 HUAWEI POT-LX1 Error 22240 DEBUG uid: 10383 10-23
> 18:16:34.572 HUAWEI POT-LX1 Error 22240 DEBUG pid: 19835, tid: 19835,
name: m.andromeda.gis >>> com.andromeda.gis stack_end' not met 10-23
18:16:33.123 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.121 HUAWEI
POT-LX1 Warning 1584 ProcBatteryStats timer is not running , not stop,
name: com.google.android.gms, uid: 10154, tag: location 10-23
18:16:33.121 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.119 HUAWEI
POT-LX1 Info 1584 chatty uid=1000(system) PowerManagerSer identical 3
lines 10-23 18:16:33.118 HUAWEI
POT-LX1 Warning 1698 GNSS_CONTROL AGNSS_STATUS_ENUM_UINT32
EACommMgr::ProcessEngineMessage(AGNSSMessage ) -- 717: unrecognized
cmd id from engine, 0x00000010 10-23 18:16:33.117 HUAWEI
POT-LX1 Debug 643 GNSS_ADAPTER hisi_cmd_process called, cmd id:6 10-23
18:16:33.117 HUAWEI POT-LX1 Debug 643 GNSS_ADAPTER Receive
hisi_inject_location cmd, accuracy:14.454000 10-23 18:16:33.117 HUAWEI
POT-LX1 Debug 643 GnssHAL_GnssInterface injectLocation: Use HIDL_V1_1
10-23 18:16:33.117 HUAWEI
POT-LX1 Debug 1584 GnssLocationProvider injectLocation:
Location[network 40*****,33****** hAcc=14 et=+2d14h50m58s175ms
alt=974.7000122070312 vAcc=5 sAcc=??? bAcc=???
{Bundle[{noGPSLocation=Location[network 40******,33****** hAcc=14
et=+2d14h50m58s175ms alt=974.7000122070312 vAcc=5 sAcc=??? bAcc=???
{Bundle[mParcelledData.dataSize=52]}], verticalAccuracy=4.5534}]}]
10-23 18:16:33.115 HUAWEI POT-LX1 Info 1584 LocationManagerService key
of receiver: 9ef981e mPendingBroadcasts=0 10-23 18:16:33.115 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.115 HUAWEI
POT-LX1 Warning 1584 ProcBatteryStats timer is running , not start,
name: com.google.android.gms, uid: 10154, tag: location 10-23
18:16:33.113 HUAWEI POT-LX1 Info 1584 LocationManagerService key of
receiver: 4ea8e0f mPendingBroadcasts=0 10-23 18:16:33.113 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.112 HUAWEI
POT-LX1 Warning 1584 ProcBatteryStats timer is running , not start,
name: com.google.android.gms, uid: 10154, tag: location 10-23
18:16:33.110 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.108 HUAWEI
POT-LX1 Info 1584 chatty uid=1000(system) PowerManagerSer identical 5
lines 10-23 18:16:33.110 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: ce991fc
mPendingBroadcasts=0 10-23 18:16:33.107 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: e70bd28
mPendingBroadcasts=0 10-23 18:16:33.100 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: 18d8d5f
mPendingBroadcasts=0 10-23 18:16:33.097 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: 6b0e5e4
mPendingBroadcasts=0 10-23 18:16:33.094 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: bc7efba
mPendingBroadcasts=0 10-23 18:16:33.087 HUAWEI
POT-LX1 Info 1584 LocationManagerService key of receiver: 79f86cc
mPendingBroadcasts=0 10-23 18:16:33.084 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.083 HUAWEI
POT-LX1 Info 1584 ActivityManager sendIntentSender
target:PendingIntentRecord{a4f1de7 com.google.android.gms
startService}, intent:hwFlg=0x10 10-23 18:16:33.082 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.080 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.076 HUAWEI
POT-LX1 Info 1584 ActivityManager sendIntentSender
target:PendingIntentRecord{1f69fac com.google.android.gms
startService}, intent:hwFlg=0x10 10-23 18:16:33.075 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.067 HUAWEI
POT-LX1 Info 1584 ActivityManager sendIntentSender
target:PendingIntentRecord{bc3f9ca com.google.android.gms
startService}, intent:hwFlg=0x10 10-23 18:16:33.066 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.063 HUAWEI
POT-LX1 Info 4472 SUPL20_SPIMESLP-SENDING bBrokenPipe = false 10-23
18:16:33.063 HUAWEI
POT-LX1 Info 4472 SUPLHIDL suplPlatformServiceSend2server send. 10-23
18:16:33.062 HUAWEI POT-LX1 Debug 645 HISUPL_ADAPTER size:563 10-23
18:16:33.062 HUAWEI POT-LX1 Debug 645 HISUPL_ADAPTER ps send data to
server 10-23 18:16:33.061 HUAWEI
POT-LX1 Info 4472 SUPL20_LocMan cellInfo NetworkType:NOT RETERIVE,21
10-23 18:16:33.060 HUAWEI POT-LX1 Info 4472 SUPL20_LocMan NULL Value
received for network operator 10-23 18:16:33.059 HUAWEI
POT-LX1 Info 1584 PowerManagerService handleSandman: wakefulness:
1,startDreaming: false 10-23 18:16:33.059 HUAWEI
POT-LX1 Info 4472 SUPL20_LocMan Phone type:GSM 10-23
18:16:33.052 HUAWEI POT-LX1 Info 2328 ChannelRating channel rating
remote size: 37 10-23 18:16:33.052 HUAWEI
POT-LX1 Info 2328 ChannelRatingResult conclusion is: channel: 165,
score: 100.0 10-23 18:16:33.052 HUAWEI
POT-LX1 Info 2328 ChannelRating getNoiseScore channel: 165, bestscore:
500.0, noise: -100
Подробнее здесь: https://stackoverflow.com/questions/791 ... -6-sigabrt