4 ms·
Ah, I remember watching the PyCon talk on VOC, a lot of cool work. No disrespect ot the work, but I'm always a bit worried about a thing that starts with "we'r
by rtpg 10y ago
Ah, I remember watching the PyCon talk on VOC, a lot of cool work.
No disrespect ot the work, but I'm always a bit worried about a thing that starts with "we're swapping out the Python interpreter for a compiler". For example, this doesn't include generator support, which is a big part of my Python usage.
"Just" having the CPython bridge is so tempting, because your python code will work (modulo C extensions), plus we get all the performance work too. I believe you tried this, of course.
For VOC, is there a guide to calling Java code from Python code? I see you have Toga, but being able to write my own abstractions without much work would be neat.
- freakboy3742 10y agoGood news on the generator front - VOC fully supports generators, lambdas, passing functions as arguments, and all sorts of things that Python allows but Java (the language) doesn't. As for a guide to calling Java from Python - we don't have any good documentation for this (yet), but it's entirely possible. Here's a sample Android application. If you're familiar with the Android APIs, you should be able to see the syntax conventions in place. https://gist.github.com/freakboy3742/7beb22c587e57240610777a44af645d8 https://gist.github.com/freakboy3742/7beb22c587e57240610777a...
- rtpg 10y agoOh, so you simply import java packages in the same way you import python packages? That's a pretty transparent mechanism. Thanks for the clarifications! I suppose that this is more "Python (the language) for other systems" more than "Python (the environment) for other systems". Is any of the standard library supported given this import scenario?
- freakboy3742 10y agoThe full standard library is a work in progress; at the moment, there's only a couple of key parts of sys, os, and the like. But Ouroboros (https://github.com/pybee/ouroboros https://github.com/pybee/ouroboros) is a project to develop a full standard library that can be integrated into any Python implementation. Effectively, you can use all the bits of the standard library that are written in Python by just compiling them; the rest requires native integration (which is the work in progress).
- kingosticks 10y agoThat is good news. Perhaps the website could be updated to reflect that, it might be putting people off. "there are some language features (like generators and context managers) that still need to be implemented"