4 ms·
I'm not sure I see what is the problem here. Gluing together pieces of C code is one of the main reasons to use a scripting language like Python.
by ufo 6y ago
I'm not sure I see what is the problem here. Gluing together pieces of C code is one of the main reasons to use a scripting language like Python.
- jpgvm 6y agoYes but if to achieve good performance in Python you have to implement all the domain specific code (in this case the redis protocol) in C then you: a) aren't writing Python b) invalidates all of the points for writing in Python. i.e speed of implementation, etc.
- timlatim 6y agoThe problem is how the author frames it in the README: "an experiment to disprove some of the falsehoods about performance and optimisation regarding software and interpreted languages in particular", "unfortunately many programmers [...] spend countless hours by making life harder for themselves in the name of marginal performance gains, often trading many other conveniences (such as type safety)". Between the heavy use of C libraries and correctness issues (https://github.com/boramalper/pydis/issues/12 https://github.com/boramalper/pydis/issues/12), I don't see how this project proves that Python is faster or safer than other languages. That being said, the speed with which it was developed can certainly be seen as Python's strong point.
- noname120 6y agoIt's a failed experiment — an experiment nonetheless.
- kortex 6y agoI definitely see both sides. Python is meant to be used exactly like this. It's an exemplar of python-as-library-glue. I also saw the title and clicked on it because I thought to myself "no fricken way...in pure python?" It's a touch baity.