File tree Expand file tree Collapse file tree 1 file changed +13
-7
lines changed
testapps/testapp_keyboard Expand file tree Collapse file tree 1 file changed +13
-7
lines changed Original file line number Diff line number Diff line change 2
2
3
3
import os
4
4
print ('imported os' )
5
+ import sys
6
+ print ('imported sys' )
5
7
6
8
from kivy import platform
7
9
8
10
if platform == 'android' :
9
- print ('contents of ./lib/python2.7/site-packages/ etc.' )
10
- print (os .listdir ('./lib' ))
11
- print (os .listdir ('./lib/python2.7' ))
12
- print (os .listdir ('./lib/python2.7/site-packages' ))
11
+ site_dir_path = './_python_bundle/site-packages'
12
+ if not os .path .exists (site_dir_path ):
13
+ print ('warning: site-packages dir not found: ' + site_dir_path )
14
+ else :
15
+ print ('contents of ' + site_dir_path )
16
+ print (os .listdir (site_dir_path ))
13
17
14
18
print ('this dir is' , os .path .abspath (os .curdir ))
15
19
16
20
print ('contents of this dir' , os .listdir ('./' ))
17
21
18
- with open ('./lib/python2.7/site-packages/kivy/app.pyo' , 'rb' ) as fileh :
19
- print ('app.pyo size is' , len (fileh .read ()))
22
+ if (os .path .exists (site_dir_path ) and
23
+ os .path .exists (site_dir_path + '/kivy/app.pyo' )
24
+ ):
25
+ with open (site_dir_path + '/kivy/app.pyo' , 'rb' ) as fileh :
26
+ print ('app.pyo size is' , len (fileh .read ()))
20
27
21
- import sys
22
28
print ('pythonpath is' , sys .path )
23
29
24
30
import kivy
You can’t perform that action at this time.
0 commit comments