osfans / trime

同文安卓輸入法平臺3.x/Android-rime/Rime Input Method Engine for Android
http://osfans.github.io/trime/
GNU General Public License v3.0
3.09k stars 372 forks source link

Fail to deploy schemata due to Permission denied on Android13(Realme UI4) with new installation #1405

Closed mslxl closed 3 months ago

mslxl commented 3 months ago

trime: both nightly-4-gc33a6e13-release(Nightly build on c33a6e1) and v3.2.18 have this problem os: Android13(Realme UI4)


I upgrade my phone from android 12 to android 13 with clean all data, and then trime stop work on phone.

Just install trime and after configuration guide, it reports:

--------- beginning of main
06-18 16:00:30.154 W/rime.trime(13920): replacing previously registered component: charset_filter
06-18 16:00:30.159 W/rime.trime(13920): couldn't list directory './': filesystem error: in directory_iterator::directory_iterator(...): Permission denied [./]
06-18 16:00:30.163 W/rime.trime(13920): nonexistent config file '/storage/emulated/0/rime/build/default.yaml'.
06-18 16:00:30.163 W/rime.trime(13920): nonexistent config file '/storage/emulated/0/rime/default.yaml'.
06-18 16:00:30.164 W/rime.trime(13920): nonexistent config file '/storage/emulated/0/rime/build/default.yaml'.
06-18 16:00:30.164 W/rime.trime(13920): schema list not defined.
06-18 16:00:30.165 W/rime.trime(13920): nonexistent config file '/storage/emulated/0/rime/build/default.yaml'.
06-18 16:00:30.166 W/rime.trime(13920): nonexistent config file '/storage/emulated/0/rime/user.yaml'.

the default configuration was placed in /storage/emulated/0/rime/, but there is no file in rime/build folder excepted trime.yaml

Image of folder structure ![Screenshot_2024-06-18-16-12-00-59_9e8df3d0c7c1f50248b6ee043a653d26](https://github.com/osfans/trime/assets/11132880/6cc4bdf4-62c4-4900-9c40-c6a28e1d2b7a)

I have tried to execuate chmod 770 rime/**/*, it does not work

Storage permission is given to trime

Screenshot_2024-06-18-16-04-06-94_fc704e6b13c4fb26bf5e411f75da84f2

Bambooin commented 3 months ago

Seems it's not the permission issue, Trime already had permission to check the build folder.

The root cause seems due to lack of configuration file.

You can try this configuration: https://github.com/Bambooin/rimerc

WhiredPlanck commented 3 months ago

You do not put default.yaml in the dir, nowadays only default.custom.yaml cannot make rime deloy the schemata correctly.

mslxl commented 3 months ago

I tried Bambooin/rimerc, it works. So the reason is lack of configuration file, surely. Thank you guys.

But why do the default configuration of trime not providing default.yaml file, Is this a bug, or trime does not provide configuration now? Since I didn't change configuration yet, just install trime and the problem happened.


Edited: default.custom.yaml is empty too

WhiredPlanck commented 3 months ago

I tried Bambooin/rimerc, it works. So the reason is lack of configuration file, surely. Thank you guys.

But why do the default configuration of trime not providing default.yaml file, Is this a bug, or trime does not provide configuration now? Since I didn't change configuration yet, just install trime and the problem happened.

Edited: default.custom.yaml is empty too

As for now, Trime doesn't contain any prelude configuration to reduce the app size.

lunarythia commented 2 months ago

@WhiredPlanck But the prelude config would be small. I think, either you should build it in, or you should provide instructions on where to get the prelude. Even better, provide an option to download from Bambooin/rimerc.

WhiredPlanck commented 2 months ago

@mslxl I plan to that, but am too busy recently to do that.