Back to coding...

ilan

Expert
Licensed User
Longtime User
After a short break, I’m back to coding.
I’ve been playing around with PyBridge, and I have to say, this might be the most impressive library Erel has created in years. I already finished my B4J server using a great Python library I downloaded, and everything works beautifully.

Now I’m working on the B4X clients, and I’ll upload them to the store soon. The huge advantage here is how easily we can use external Python libraries. I even configured the server to use the
latest Python framework instead of the minimal version bundled with B4J, and it runs perfectly.

B4X:
Dim opt As PyOptions = Py.CreateOptions("C:\Users\ilan1\AppData\Local\Programs\Python\Python314\python.exe")

This is a game changer. We can build so many powerful things while still staying in our familiar environment.


THANK YOU @Erel 🙏 🙏 🙏 🙏
 

hatzisn

Expert
Licensed User
Longtime User
I have tried it too. It is incredible. And the fact that it is implementable in B4J it is a plus^2. The only caveat is if the python code has long processing time you cannot implement it easily in a WebApp because the calls are sequential. Although I cannot understand why is this happening... Since it is communication with open ports why don't we run more instances of the bridge in the Java part (or one instance with multiple open ports in different threads) and the Python part will just communicate in different ports with the Java side bridge as different instances (I am not familiar with threads in the Python side). It is just a Try-Except block to select the appropriate port in python side or am I thinking it is easy because I have not checked the implementation?
 
Top