Motivation:
The number of Lua 5.1 compat hacks is increasing.
Supporting 3-4 different Lua versions isn't going to be sustainable.
List of issues (add more in comments):
* _G.unpack vs table.unpack (see everywhere)
* xpcall takes no arguments for the function (reason for util.compat/.xpcall)
* math.log missing the 'base' argument (see util.human.units)
* __len meta-method does not work on tables (see #1598)
* Missing luaL_buffinitsize (see https://hg.prosody.im/trunk/rev/712b2e6a09d9 )
Zash
on
Plan:
1. Post heads-up / announcement to lists
2. Increase urgency of warning in util.dependencies
3. Wait for at least one nightly build
4. Update buildbot to not build trunk on 5.1
5. Drop 5.1 from debian-trunk
6. Reject 5.1 in configure
7. Drop all Lua 5.1 COMPAT
8. Add new awesome features that would have been painful before!
Changes
tags Milestone-0.13 Status-Started
Zash
on
Many Lua 5.1 compat things can be found in the C code by seaching for LUA_VERSION_NUM, mainly in the form of #define to handle API differences.
Prosody trunk nightly build 1674 (2022-07-02, b5d9f1829b15) will be the last trunk build with Lua 5.1 support.
Buildbot CI will no longer check test trunk against Lua 5.1
Motivation: The number of Lua 5.1 compat hacks is increasing. Supporting 3-4 different Lua versions isn't going to be sustainable. List of issues (add more in comments): * _G.unpack vs table.unpack (see everywhere) * xpcall takes no arguments for the function (reason for util.compat/.xpcall) * math.log missing the 'base' argument (see util.human.units) * __len meta-method does not work on tables (see #1598) * Missing luaL_buffinitsize (see https://hg.prosody.im/trunk/rev/712b2e6a09d9 )
Plan: 1. Post heads-up / announcement to lists 2. Increase urgency of warning in util.dependencies 3. Wait for at least one nightly build 4. Update buildbot to not build trunk on 5.1 5. Drop 5.1 from debian-trunk 6. Reject 5.1 in configure 7. Drop all Lua 5.1 COMPAT 8. Add new awesome features that would have been painful before!
ChangesMany Lua 5.1 compat things can be found in the C code by seaching for LUA_VERSION_NUM, mainly in the form of #define to handle API differences.
https://hg.prosody.im/trunk/rev/b5d9f1829b15 So it begins.
Prosody trunk nightly build 1674 (2022-07-02, b5d9f1829b15) will be the last trunk build with Lua 5.1 support. Buildbot CI will no longer check test trunk against Lua 5.1
Compat code and support removed in https://hg.prosody.im/trunk/rev/b5d9f1829b15 .. https://hg.prosody.im/trunk/rev/f888c84b2284 So long, and thanks for all the fish!
Changes