top 10 modules

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

top 10 modules

Andre Murbach Maidl
I wrote a script to find the most popular Lua
modules in LuaRocks, and I wanted to share
the results here.
I used only the latest version of each module
to compute the ranking below.

ND = Number of Dependents

ND   Module
50     luasocket
32     luafilesystem
22     lpeg
21     busted
15     lua-cjson
12     lusty
10     penlight
09     luaposix
09     luajson
09     copas

Andre

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Evandro Leopoldino Gonçalves
very interesting, man! thanks!

I'm curious about how you got this response. Is there any api?

2015-02-25 0:05 GMT-03:00 Andre Murbach Maidl <[hidden email]>:
I wrote a script to find the most popular Lua
modules in LuaRocks, and I wanted to share
the results here.
I used only the latest version of each module
to compute the ranking below.

ND = Number of Dependents

ND   Module
50     luasocket
32     luafilesystem
22     lpeg
21     busted
15     lua-cjson
12     lusty
10     penlight
09     luaposix
09     luajson
09     copas

Andre




--
Att,
Evandro
Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Andre Murbach Maidl
> I'm curious about how you got this response. Is there any api?

A rockspec is also a Lua file, so I just loaded
each rockspec and counted which are the
dependencies that each module has.
I also used luarocks.deps.compare_versions to
get only the latest version of each module.

André

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Valerio
I see. So those are  not the most popular modules in the Lua ecosystem, but instead
the modules upon which most of the other modules depend upon (a sort of page-rank for lua modules). 
Right?

On Thu, Feb 26, 2015 at 3:10 AM, Andre Murbach Maidl <[hidden email]> wrote:
> I'm curious about how you got this response. Is there any api?

A rockspec is also a Lua file, so I just loaded
each rockspec and counted which are the
dependencies that each module has.
I also used luarocks.deps.compare_versions to
get only the latest version of each module.

André


Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Andre Murbach Maidl
> I see. So those are  not the most popular modules in the Lua ecosystem, but
> instead
> the modules upon which most of the other modules depend upon (a sort of
> page-rank for lua modules).
> Right?

Yeah, but to my mind this is also a kind of popularity.

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Aapo Talvensaari

On Thu, Feb 26, 2015, 23:59 Andre Murbach Maidl <[hidden email]> wrote:


Yeah, but to my mind this is also a kind of popularity.



E.g. Lusty is splitted  to many subprojects of which most (all?) come from same developer. Also busted is from there. So, I think it is more like a page rank. rocks.moonscript.org has download count but it is missleading as well (as it is static because most common deps are always at top). Also many rocks don't describe deps (even if there are deps, luajit c deps to shared libs is especially problematic, or say deps to openresty ecosystem).

But yes, they tell something... but not much in my opinion. Good modules none the less.

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Aapo Talvensaari

On Fri, Feb 27, 2015, 00:10 Aapo Talvensaari <[hidden email]> wrote:

On Thu, Feb 26, 2015, 23:59 Andre Murbach Maidl <[hidden email]> wrote:

Yeah, but to my mind this is also a kind of popularity.


E.g. Lusty is splitted  to many subprojects of which most (all?) come from same developer. Also busted is from there. So, I think it is more like a page rank. rocks.moonscript.org has download count but it is missleading as well (as it is static because most common deps are always at top). Also many rocks don't describe deps (even if there are deps, luajit c deps to shared libs is especially problematic, or say deps to openresty ecosystem).

But yes, they tell something... but not much in my opinion. Good modules none the less.

Also it would be interesting to see how many times socket is required just to get more precise time(r) (socket. gettime) ;-) - hey could we finally have microseconds or even milliseconds time function in plain Lua?


Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Hisham
On 26 February 2015 at 19:16, Aapo Talvensaari
<[hidden email]> wrote:

> On Fri, Feb 27, 2015, 00:10 Aapo Talvensaari <[hidden email]>
> wrote:
>
> On Thu, Feb 26, 2015, 23:59 Andre Murbach Maidl <[hidden email]> wrote:
>
> Yeah, but to my mind this is also a kind of popularity.
>
>
> E.g. Lusty is splitted  to many subprojects of which most (all?) come from
> same developer. Also busted is from there. So, I think it is more like a
> page rank. rocks.moonscript.org has download count but it is missleading as
> well (as it is static because most common deps are always at top). Also many
> rocks don't describe deps (even if there are deps, luajit c deps to shared
> libs is especially problematic, or say deps to openresty ecosystem).
>
> But yes, they tell something... but not much in my opinion. Good modules
> none the less.
>
> Also it would be interesting to see how many times socket is required just
> to get more precise time(r) (socket. gettime) ;-) - hey could we finally
> have microseconds or even milliseconds time function in plain Lua?

Just repeating what the Lua team has said many times: this
functionality is not available in ANSI C 89, therefore: not likely. (I
think the only non-ANSI-C feature added to the language is dynamic
library loading.)

-- Hisham

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Daurnimator
In reply to this post by Aapo Talvensaari
On 26 February 2015 at 17:16, Aapo Talvensaari <[hidden email]> wrote:
>
> could we finally have microseconds or even milliseconds time function in plain Lua?

Sadly accuracy of time varies quite a lot across platforms and environments.

FWIW, luatz has a module to try and get the most accurate time available "luatz.gettime".
You can use the via the more handy aliases `require "luatz".time()` or `require "luatz".now()` for a broken down 'timetable' object.

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Aapo Talvensaari
In reply to this post by Hisham

On Fri, Feb 27, 2015, 00:29 Hisham <[hidden email]> wrote:


Just repeating what the Lua team has said many times: this
functionality is not available in ANSI C 89, therefore: not likely.



I knew the answer. Maybe this is beaten to death already. Daurnimator's luatz is a nice abstraction and has a support for different time providing back ends (like ljsyscall and socket), but this seems so unnecessary, :-/. Or maybe PUC Lua could distribute some _official_ batteries that do not have that strict requirements as core lib. Still has to work on say all main platforms like Linux, BSDs, Windows, OSX, Android, IOS, Solaris out of the box and patches for others welcomed.

Reply | Threaded
Open this post in threaded view
|

Re: top 10 modules

Isaac
In reply to this post by Aapo Talvensaari
Aapo Talvensaari <aapo.talvensaari <at> gmail.com> writes:

>
>
> On Thu, Feb 26, 2015, 23:59 Andre Murbach Maidl <andremm <at>
gmail.com> wrote:
>
>
> Yeah, but to my mind this is also a kind of popularity.
>
>
>
>
>
> E.g. Lusty is splitted  to many subprojects of which most (all?) come
from same developer. Also busted is from there. So, I think it is more
like a page rank. rocks.moonscript.org has download count but it is
missleading as well (as it is static because most common deps are always
at top). Also many rocks don't describe deps (even if there are deps,
luajit c deps to shared libs is especially problematic, or say deps to
openresty ecosystem).
> But yes, they tell something... but not much in my opinion. Good
modules none the less.
>

If we have download times from luarocks respo (or moonrocks),    
    sum(download_times * counts_of_package_call)
would be something interesting as an utility matrix.

- I have always been thinking/wishing a programming language that would
involve with more 'measurement/feedbacks' from its usage, then we may
have some means to improve based on numbers/facts (putting more
resources there).

Isaac