6 ms·
Python Ported to WebAssembly
- MuffinFlavored 7y agoSo... Python now runs in the WebBrowser, kind of? just... every website that wants to serve you Python-generate content now needs to ship the entire Python runtime as a WASM dependency? :P
- Finnucane 7y agoJust think, we’ll be able to send whole applications over the Internet that will be able to run without being connected. That will be totally game changing.
- singularity2001 7y agoSmart browsers would cache the 10MB python.wasm file across applications. But so far each refresh results in a new download.
- MuffinFlavored 7y agoIs this sarcasm?
- KenoFischer 7y agoNot sure what the "Show HN" part of this is, but here's a link to the original announcement post for Python-on-WASM by Mike Droettboom and the team at mozilla: https://hacks.mozilla.org/2019/04/pyodide-bringing-the-scientific-python-stack-to-the-browser/ https://hacks.mozilla.org/2019/04/pyodide-bringing-the-scien.... This seems to just be repackaging that.
- mkl 7y agosyrusakbary is the CEO of Wasmer.
- KenoFischer 7y agoSure, but to what extent are they "showing" us that they "Ported Python to WebAssembly". Isn't this more of a "Show HN: Python packaged for Wasmer"? To my mind, part of the purpose of these show HN threads is to ask questions and give feedback about whatever it is that the post is showing, so I'm asking to what extent the Wasmer folks actually did any "porting", since (to me) that seems like the interesting part.
- mkl 7y agoPrevious discussion of Pyodide: https://news.ycombinator.com/item?id=19677721 https://news.ycombinator.com/item?id=19677721 https://news.ycombinator.com/item?id=19684321 https://news.ycombinator.com/item?id=19684321
- stcredzero 7y agoWe should just up and have an "OS" on WebAssembly. It could be based on packages from something like NixOS. There could even be a local server with cached packages
- the_pwner224 7y agoYou mean we should replace Windows/macOS/Linux and package managers with a web browser? Cool.
- oconnor663 7y agoMy understanding is that the wasm runtime is substantially independent from the browser, like NodeJS but maybe moreso?
- the_pwner224 7y agoI suppose you are correct. But AFAIK at the moment it's not really used anywhere except in browsers. If you need to run it locally, why not just use normal Python?
- abecedarius 7y agoAs wasm is designed compatibly with capability security, that's not a crazy idea. (See e.g. the first section of https://github.com/CraneStation/wasmtime/blob/master/docs/WASI-overview.md https://github.com/CraneStation/wasmtime/blob/master/docs/WA...)
- flaque 7y agoSuper excited to see this used in scientific computing; python notebooks will get quite a big upgrade.
- snek 7y agoMy experience with the wasmer entity has been and continues to be that it is just copying/repackaging stuff other people do to get VC money. Something of this sort was done a long time ago with pypy[1] and more recently CPython[2] 1: https://pypyjs.org/ https://pypyjs.org/ 2: https://hacks.mozilla.org/2019/04/pyodide-bringing-the-scientific-python-stack-to-the-browser/ https://hacks.mozilla.org/2019/04/pyodide-bringing-the-scien...
- opencl 7y agoThis one appears to be a repackaging of Mozilla's CPython/numpy wasm build (your [2] link).
- syrusakbary 7y agoWe’ve been in contact with people from Mozilla regarding Pyodide, so our intention is not really repackaging but being able to use Python server side via WebAssembly (eventually we want to get rid of our package and use Pyodide directly). We don’t want to steal other people attention but to bring more people into the WebAssembly ecosystem, and you can only do that by helping bringing more packages to it. If you are aware of other ways of running Python server side with WebAssembly I’d love to know more!
- syrusakbary 7y agoHi HN, I’m Syrus, CEO of Wasmer. I started the company with the goal of running WebAssembly server side (same concept on what Node.js did with js). We believe WebAssembly will be very relevant in the future and we are betting big on it. Please check more about our project here: https://github.com/wasmerio/wasmer https://github.com/wasmerio/wasmer
- rambojazz 7y agoHow do you believe to make money with this technology instead? Other than maybe make it proprietary.