Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UnicodeEncodeError on Otter apk #28

Open
StephenQuirolgico opened this issue Feb 11, 2020 · 1 comment
Open

UnicodeEncodeError on Otter apk #28

StephenQuirolgico opened this issue Feb 11, 2020 · 1 comment

Comments

@StephenQuirolgico
Copy link

Hi,

I've run into an Androwarn bug on following app:

https://play.google.com/store/apps/details?id=com.aisense.otter

Traceback (most recent call last):
File "/data/androwarn_1.6/androwarn-master/androwarn.py", line 96, in <module>
main()
File "/data/androwarn_1.6/androwarn-master/androwarn.py", line 91, in main
dump_analysis_results(data,sys.stdout)
File "/data/androwarn_1.6/androwarn-master/warn/report/report.py", line 93, in dump_analysis_results
flush_simple_string(wrapper.fill(element), file_descriptor)
File "/data/androwarn_1.6/androwarn-master/warn/report/report.py", line 67, in flush_simple_string
file.write("%s\n" % string)
UnicodeEncodeError: 'ascii' codec can't encode character '\u02ce' in position 68: ordinal not in range(128)

Can this be fixed or possibly ignored in the code so the analysis can complete?

Thanks in advance!

@StephenQuirolgico
Copy link
Author

@maaaaz I found that this error was due to trying to read a unicode char as a string. I fixed this by changing string on line 67 of /warn/report.py to string.encode('utf-8').strip() and then changing line 90 to remove 'or isinstanceof(element,unicode).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant