Lua 5.5 compatibility #66

Closed
opened 2026-06-09 13:57:00 +00:00 by scossu · 4 comments
Owner

Make Pocket Archive compatible with Lua 5.5.

It is also possible to make it backwards incompatible with Lua 5.4, to possibly reduce future maintenance, because a stable Pocket Archive version hasn't been yet released yet.

Lua 5.5 compatibility requires a change in the http library, which has a dependency on compat53, which is only required for Lua 5.2 and older, and cannot run on Lua 5.5. compat53 is likely required to maintain backwards compatibility with older Lua versions.

Solutions:

  1. Fork off http and remove the compat53 (and while at it, also bit32 which in a comment is noted as only needed by Lua 5.1). This would impose an additional long-term maintenance burden but it's the safest and most straightforward solution.
  2. Rebuild the HTTP admin module on top of a different library. This would be a big lift, fraught with problems, especially because the module was already moved from Pegasus to lua-http recently and some significant code has been built on top of it.
Make Pocket Archive compatible with Lua 5.5. It is also possible to make it backwards incompatible with Lua 5.4, to possibly reduce future maintenance, because a stable Pocket Archive version hasn't been yet released yet. Lua 5.5 compatibility requires a change in the `http` library, which has a dependency on `compat53`, which is only required for Lua 5.2 and older, and cannot run on Lua 5.5. `compat53` is likely required to maintain backwards compatibility with older Lua versions. Solutions: 1. Fork off `http` and remove the `compat53` (and while at it, also `bit32` which in a comment is noted as only needed by Lua 5.1). This would impose an additional long-term maintenance burden but it's the safest and most straightforward solution. 2. Rebuild the HTTP admin module on top of a different library. This would be a big lift, fraught with problems, especially because the module was already moved from Pegasus to lua-http recently and some significant code has been built on top of it.
scossu added this to the v1.0.0 milestone 2026-06-10 13:31:37 +00:00
Author
Owner

Deferring. Too many dependencies are still not ready for 5.5.

Removing 5.4 compatibility is definitely not a good idea even later.

Deferring. Too many dependencies are still not ready for 5.5. Removing 5.4 compatibility is definitely not a good idea even later.
scossu added
p
low
and removed
p
normal
labels 2026-07-16 13:21:08 +00:00
scossu removed this from the v1.0.0 milestone 2026-07-16 13:21:30 +00:00
Author
Owner

compat53 was updated to support Lua 5.5: https://github.com/lunarmodules/lua-compat-5.3/releases/tag/v0.15.1 and merged downstream into cqueues in a commit not yet released in Luarocks: github.com/wahern/cqueues@6bc270dd15

So, the least invasive action would be to create a local manifest for the latest cqueues version until that gets released in the root manifest.

Other dependencies remain to be seen.

compat53 was updated to support Lua 5.5: https://github.com/lunarmodules/lua-compat-5.3/releases/tag/v0.15.1 and merged downstream into cqueues in a commit not yet released in Luarocks: https://github.com/wahern/cqueues/commit/6bc270dd15c6f7ba92f0a76b399d987f17d9f3e5 So, the least invasive action would be to create a local manifest for the latest cqueues version until that gets released in the root manifest. Other dependencies remain to be seen.
scossu added this to the v1.2.0 milestone 2026-09-30 15:43:38 +00:00
scossu added reference 1.1.x 2026-10-05 01:59:47 +00:00
Author
Owner

Most dependencies have been updated or I created ad-hoc rocks.

The latest one failing is lua-vips, which is pinned behind 5.5: https://luarocks.org/manifests/lua-vips/lua-vips-1.1-12.rockspec

Attempting to install a modified the rockspec causes the runtime to crash (probably ffi incompatibility, even though the required luaffi-tkl has been updated to support 5.5 and is installed without a hitch).

Most dependencies have been updated or I created ad-hoc rocks. The latest one failing is lua-vips, which is pinned behind 5.5: https://luarocks.org/manifests/lua-vips/lua-vips-1.1-12.rockspec Attempting to install a modified the rockspec causes the runtime to crash (probably ffi incompatibility, even though the required luaffi-tkl has been updated to support 5.5 and is installed without a hitch).
Author
Owner

Fixed in 88dd3e3935.

For now, several rockspecs have to be managed independently, but no 3rd party code has been forked.

Fixed in 88dd3e3935. For now, several rockspecs have to be managed independently, but no 3rd party code has been forked.
scossu 2026-10-14 03:06:05 +00:00
scossu modified the milestone from v1.2.0 to v1.1.0 2026-11-09 03:44:23 +00:00
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
ktx/pocket_archive#66
No description provided.