Commit c63588d
authored
Update storage.py fixes runtime errors
1) fixes isExternalStorageRemovable is expecting a file object, error was:
```
07-28 16:36:46.845 2152 2784 I python : File "/home/andre/workspace/EtherollApp/.buildozer/android/platform/build/build/python-installs/etheroll/android/storage.py", line 61, in primary_external_storage_path
07-28 16:36:46.847 2152 2784 I python : File "jnius/jnius_export_class.pxi", line 1034, in jnius.jnius.JavaMultipleMethod.__call__
07-28 16:36:46.848 2152 2784 I python : jnius.jnius.JavaException: No methods matching your arguments, available: ['()Z', '(Ljava/io/File;)Z']
```
2) fixes `os.path.exists()` doesn't accept `None`, error was:
07-28 22:31:25.877 31203 31313 I python : File "/home/andre/workspace/EtherollApp/.buildozer/android/platform/build/build/python-installs/etheroll/android/storage.py", line 101, in secondary_external_storage_path
07-28 22:31:25.878 31203 31313 I python : File "/home/andre/workspace/EtherollApp/.buildozer/android/platform/build/build/other_builds/python3-libffi-openssl-sqlite3/armeabi-v7a__ndk_target_21/python3/Lib/genericpath.py", line 19, in exists
07-28 22:31:25.879 31203 31313 I python : TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType
3) fixes on services `PythonActivity.mActivity` is None, refs kivy/kivy#63881 parent 7d5fdee commit c63588d
1 file changed
+19
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | 1 | | |
3 | 2 | | |
4 | 3 | | |
5 | 4 | | |
6 | 5 | | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
27 | 40 | | |
28 | 41 | | |
29 | 42 | | |
| |||
32 | 45 | | |
33 | 46 | | |
34 | 47 | | |
35 | | - | |
36 | | - | |
37 | | - | |
| 48 | + | |
| 49 | + | |
38 | 50 | | |
39 | 51 | | |
40 | 52 | | |
| |||
58 | 70 | | |
59 | 71 | | |
60 | 72 | | |
61 | | - | |
| 73 | + | |
62 | 74 | | |
63 | 75 | | |
64 | 76 | | |
| |||
88 | 100 | | |
89 | 101 | | |
90 | 102 | | |
91 | | - | |
| 103 | + | |
92 | 104 | | |
93 | 105 | | |
94 | 106 | | |
| |||
98 | 110 | | |
99 | 111 | | |
100 | 112 | | |
101 | | - | |
| 113 | + | |
102 | 114 | | |
103 | 115 | | |
0 commit comments