AttributeError: 'NoneType' object has no attribute 'policy'
Hello , Thank you for the helpful tool ... when I am trying to run it using ubuntu 16.04 as a host and android google nexus 4 and 5 with different APIs the following error comes up:
WARNING:Device:Seems like you are using an emulator. If so, please add is_emulator option.
Traceback (most recent call last):
File "/home/hayyan/droidbot/droidbot/droidbot.py", line 96, in init
self.app = App(app_path, output_dir=self.output_dir)
File "/home/hayyan/droidbot/droidbot/app.py", line 28, in init
from androguard.core.bytecodes.apk import APK
File "/usr/local/lib/python2.7/dist-packages/androguard/core/bytecodes/apk.py", line 9, in
AttributeError: 'NoneType' object has no attribute 'policy'
Regards..
Hi,I have meet same problem before, and I was able to resolve it by following these steps. (maybe it could help you or someone who have face the same issue)
- check if your device have the minicap file. The installation can see :https://github.com/DeviceFarmer/minicap
- check the apk file can install successfully on the device, you can manually drag the apk file to the device to valid.