Tribler/py-ipv8

is pyipv8 compatible with android?

magowiz opened this issue · 2 comments

Hi,
I'm trying to make run in a kivy aplication a small ipv8 example, just to try if ipv8 can run in such particular context, but I got a strange error on socket module:

ipv8/messaging/interfaces/lan_addresses/Unix/ioctl.py line 36
AttributeError: module 'socket' has no attribute 'if_nameindex'

I just wanted to know, if you know, if your library can work in android, I think also I'm going to ask this also to buildozer

Hi.

There is a Kotlin offshoot of IPv8, specifically for Android: https://github.com/Tribler/kotlin-ipv8 However, it only supports a subset of IPv8 functionality.

If you still want to fix your particular error, you have two options. The easiest (probably?) option is to install netifaces. The harder option would be to overwrite ipv8.messaging.interfaces.lan_addresses.interfaces.get_providers() in the Python code.

All of that said, I have no clue what other errors you may run into when this is fixed though.

I hope your question has been sufficiently addressed. I'll close this issue now, but feel free to reopen it if you have other questions.