News for hackers. Stuff that matters.
Re:From Python to Lua: Why We Switched by btilly on Tuesday January 26, 2016 @03:18PM (#10975698)
The reason why people don't want you to ship your version of Python is that it takes a lot of space. Lua makes that hurdle much easier.

For example my local Python venv is about 130 MB. It symlinks in another 52 MB of standard Python libraries. And I know it won't run without some unknown amount of additional dependencies in C-libraries. If I wanted to send that to someone I'm starting at 200 MB. After compression that might be 40 MB or so. You're going to have to work to strip that down.

By comparison their download including Lua, code, and libraries is under 6 MB.

I have a minimal running Python application that was started recently and has done nothing. It takes close to 90 MB of RAM just to start.

Theirs is generally under 10 MB while it is running.

So at every step Python requires 5-10 times as much data. If you're trying to get other people to put you in their containers, this can matter a lot.

Re:From Python to Lua: Why We Switched by richardwhiuk on Tuesday January 26, 2016 @03:30PM (#10975783)
PyInstaller will generate a ~minimal installation. I've written an app which has a full python runtime, and images, and dozens of python files and modules in 6MB.
Re:From Python to Lua: Why We Switched by dottrap on Tuesday January 26, 2016 @03:45PM (#10975914)
If we're going minimal, the base Lua install is still measured in hundreds of kilobytes, not megabytes.
Re:From Python to Lua: Why We Switched by vetinari on Tuesday January 26, 2016 @06:09PM (#10976978)
Minimal means, that will it bring in only those modules, that are really used by your application. And that includes lib*.so.
Re:From Python to Lua: Why We Switched by mixmastamyk on Tuesday January 26, 2016 @04:40PM (#10976319)
> It takes close to 90 MB of RAM just to start.

A minimal Python app on my machine takes 6MB RAM.

Re:From Python to Lua: Why We Switched by dottrap on Tuesday January 26, 2016 @05:37PM (#10976775)
A minimal created lua_State on my machine takes about 4 kilobytes of RAM.
Re:From Python to Lua: Why We Switched by mixmastamyk on Tuesday January 26, 2016 @08:59PM (#10977715)
So what? It does more. Are you running it on a pocket calculator?
Re:From Python to Lua: Why We Switched by echochar on Tuesday January 26, 2016 @10:50PM (#10978079)
Brilliant.
Re:From Python to Lua: Why We Switched by ronreiter on Wednesday January 27, 2016 @12:30AM (#10978412)
OK, so the original post doesn't say that, which kind of misses the whole point in the section that explains why Python was a bad choice.
Re:From Python to Lua: Why We Switched by lmm on Wednesday January 27, 2016 @03:56AM (#10979010)
Or it can not matter at all. To the kind of enterprise that is still running RHEL 6, maybe shipping a 200mb install on a CD will show them that you're a serious business.

There are use cases where 200mb of disk space matters, but for the overwhelming majority of applications, a 5% (say) increase in developer productivity would be well worth adding 200mb to the install.

Re:From Python to Lua: Why We Switched by brimworks on Wednesday January 27, 2016 @10:26AM (#10980481)
The point of the Distelli Agent is to deploy software. Think of it as the "bootstrapper". Serious customers would rather use that 200MB for their own software, not for the "bootstrapper" :). Here at Distelli we optimize for the customer, not for our own internal developer productivity.
Re:From Python to Lua: Why We Switched by lmm on Wednesday January 27, 2016 @10:33AM (#10980530)
Good soundbite, but if using 200MB of extra space would let you lower your prices while offering the same service (by increasing developer productivity) then I bet many customers would take that.

And did you try spending a person-week or so of dev time trying to minimize the size of the Python version? That would be a much smaller one-off cost than the costs of migrating everything to Lua, and I could easily imagine you'd get it down by one or two orders of magnitude. (You could do the same for Lua too I'm sure, but if we're talking about say 5mb vs 200k then that's "who cares?" size for most customers).

Re:From Python to Lua: Why We Switched by 59nadir on Thursday January 28, 2016 @08:15AM (#10987917)
Nowhere in this article does it really state that they're less productive in Lua, though. In fact, the main engineer on it is well versed in it. Your 5% may actually be negative in this case.

From where do you get this impression that Python is the only high productivity language in the world? There are plenty of languages that can compete with Python in terms of productivity and a lot of them offer better abstractions for it. Lua is known for being one of the best escape hatches for scripting.

Re:From Python to Lua: Why We Switched by lmm on Thursday January 28, 2016 @08:55AM (#10988114)
If you're more productive in Lua than in Python then I support using Lua 100%. It's switching languages to gain a measly 200MB of disk space that I'm objecting to. For 99% of projects 200MB is just an irrelevant consideration compared to how much difference language productivity makes.
Re:From Python to Lua: Why We Switched by 59nadir on Thursday January 28, 2016 @09:30AM (#10988314)
For general cases, I agree that 200 MBs isn't enough to consider very important nowadays, but I still don't get how we're automatically talking about language productivity being a trade-off. Is the assumption that Python is a more productive language regardless of what it stands against?
Re:From Python to Lua: Why We Switched by lmm on Thursday January 28, 2016 @04:15PM (#10991420)
btilly was talking about the disk space as if it were important.

My opinion is that Python is more productive than Lua, but if you disagree by all means use Lua. But if you're talking about saving 200mb of disk space as though it makes the difference, then I think you're using the wrong criteria for choosing your language.