From a8ea6429e1791a0fb7d428fc0a16ff8429bd98fa Mon Sep 17 00:00:00 2001 From: Florian Berthold Date: Sat, 30 May 2026 06:57:25 +0200 Subject: [PATCH 1/3] fix: restore table.getn/setn for Ace2 stack so VanillaGuide loads on 3.3.5 Lua 5.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit WoW 3.3.5 Lua 5.1 runtime has table.setn as an error stub ("'setn' is obsolete") and table.getn missing/erroring. The embedded Ace2 libs (AceLibrary, AceOO, AceEvent, AceConsole, AceDebug, AceDB, Tablet-2.0) all assign table_setn = table.setn at module scope when GetBuildInfo() does not start with "2." — causing AceOO-2.0 to crash at line 546 before any library can register, then cascading to AceConsole/FuBarPlugin. Add Lua50Compat.lua as the first TOC entry to unconditionally overwrite table.setn (no-op) and table.getn (returns #t) before any lib loads. Also shims table.foreach/foreachi in case future libs need them. Verified with LuaJIT 5.1: AceLibrary + AceOO load cleanly; all other libs stop only at WoW-API boundaries (not at obsolete-call errors). --- VanillaGuide/Lua50Compat.lua | 42 ++++++++++++ VanillaGuide/VanillaGuide.toc | 123 +++++++++++++++++----------------- 2 files changed, 104 insertions(+), 61 deletions(-) create mode 100644 VanillaGuide/Lua50Compat.lua diff --git a/VanillaGuide/Lua50Compat.lua b/VanillaGuide/Lua50Compat.lua new file mode 100644 index 0000000..4b4e17b --- /dev/null +++ b/VanillaGuide/Lua50Compat.lua @@ -0,0 +1,42 @@ +-- Lua50Compat.lua +-- Loaded FIRST (see VanillaGuide.toc) to restore Lua 5.0 table functions that +-- the WoW 3.3.5 / Project Ascension Lua 5.1 runtime has made obsolete. +-- +-- table.setn existed in 5.0 to manually hint the array length; in 5.1 the +-- length operator (#) is authoritative and table.setn is a stub that raises +-- "attempt to call a nil value" or "'setn' is obsolete". Overwrite it with a +-- no-op unconditionally so Ace2 libs (AceOO, AceEvent, AceConsole, AceDebug, +-- AceLibrary, AceDB, Tablet-2.0) can assign the local alias at module load +-- time without erroring. +-- +-- table.getn existed in 5.0 as the canonical length function; in 5.1 it was +-- removed (or kept as an error stub on some runtimes). Replace it with the +-- equivalent # operator. +-- +-- table.foreach / table.foreachi were removed in 5.1 as well; guard them in +-- case any lib uses them (none currently do, but safe to shim anyway). + +-- Unconditional overwrite -- even if these slots exist they may raise. +table.setn = function() end + +table.getn = function(t) + return #t +end + +if not table.foreach then + table.foreach = function(t, f) + for k, v in pairs(t) do + local ret = f(k, v) + if ret then return ret end + end + end +end + +if not table.foreachi then + table.foreachi = function(t, f) + for i = 1, #t do + local ret = f(i, t[i]) + if ret then return ret end + end + end +end diff --git a/VanillaGuide/VanillaGuide.toc b/VanillaGuide/VanillaGuide.toc index 92414ea..0ff707e 100644 --- a/VanillaGuide/VanillaGuide.toc +++ b/VanillaGuide/VanillaGuide.toc @@ -1,61 +1,62 @@ -## Interface: 30300 -## Title: VanillaGuide |cff7fff7f -Ace2-|r |cffff7f7f(CoA)|r -## Notes: Step-by-Step 1-60 Guides (CoA fork: Ascension 3.3.5 port, Joana H/A paths) -## Author: mrmr -## Version: 1.04.2-coa1 -## DefaultState: enabled -## LoadOnDemand: 0 - -## X-Credits: Joana/Mancow and Brian Kopps for the guides. mrmr for the Joana addon. Kira and Cdlp for the Brian Kopps' guide. Velenran for Profession guides. CoA Guild 'Exiles' for the 3.3.5 port. -## X-Category: Quests -## X-Date: 2026-05-11 -## X-ReleaseDate: 2012-xx-xx -## X-Email: rsheep@gmail.com -## X-Website: https://git.sub-net.at/Exiles/coa-vanillaguide -## X-Embeds: Ace2, FuBar-Plugin-2.0, Tablet-2.0 -## OptionalDeps: Ace2, FuBar, Tablet-2.0 - -## SavedVariables: VanillaGuideDB -## SavedVariablesPerCharacter: VanillaGuideDBPC - -libs\AceLibrary\AceLibrary.lua -libs\AceOO-2.0\AceOO-2.0.lua -libs\AceConsole-2.0\AceConsole-2.0.lua -libs\AceEvent-2.0\AceEvent-2.0.lua -libs\AceAddon-2.0\AceAddon-2.0.lua -libs\AceDB-2.0\AceDB-2.0.lua -libs\AceDebug-2.0\AceDebug-2.0.lua - -Core.lua -Settings.lua -GuideTables\001_Introduction.lua -GuideTables\Horde\002_Mulgore.lua -GuideTables\Horde\002_TirisfalGlades.lua -GuideTables\Horde\002_Durotar.lua -GuideTables\Horde\003_Horde_12to20.lua -GuideTables\Horde\003_Horde_20to30.lua -GuideTables\Horde\003_Horde_30to40.lua -GuideTables\Horde\003_Horde_40to50.lua -GuideTables\Horde\003_Horde_50to60.lua -GuideTables\Alliance\002_ElwynnForest.lua -GuideTables\Alliance\002_Teldrassil.lua -GuideTables\Alliance\002_DunMorogh.lua -GuideTables\Alliance\003_Alliance_12to20.lua -GuideTables\Alliance\003_Alliance_20to30.lua -GuideTables\Alliance\003_Alliance_30to40.lua -GuideTables\Alliance\003_Alliance_40to50.lua -GuideTables\Alliance\003_Alliance_50to60.lua -GuideTables\004_Professions.lua -GuideTable.lua -Display.lua -SlashCommands.lua -Frame_MainFrame.lua -Frame_AboutFrame.lua -Frame_SettingsFrame.lua -UI.lua - -libs\Tablet-2.0\Tablet-2.0.lua -libs\Dewdrop-2.0\Dewdrop-2.0.lua -libs\FuBarPlugin-2.0\FubarPlugin-2.0.lua - -VGuideFu.lua +## Interface: 30300 +## Title: VanillaGuide |cff7fff7f -Ace2-|r |cffff7f7f(CoA)|r +## Notes: Step-by-Step 1-60 Guides (CoA fork: Ascension 3.3.5 port, Joana H/A paths) +## Author: mrmr +## Version: 1.04.2-coa1 +## DefaultState: enabled +## LoadOnDemand: 0 + +## X-Credits: Joana/Mancow and Brian Kopps for the guides. mrmr for the Joana addon. Kira and Cdlp for the Brian Kopps' guide. Velenran for Profession guides. CoA Guild 'Exiles' for the 3.3.5 port. +## X-Category: Quests +## X-Date: 2026-05-11 +## X-ReleaseDate: 2012-xx-xx +## X-Email: rsheep@gmail.com +## X-Website: https://git.sub-net.at/Exiles/coa-vanillaguide +## X-Embeds: Ace2, FuBar-Plugin-2.0, Tablet-2.0 +## OptionalDeps: Ace2, FuBar, Tablet-2.0 + +## SavedVariables: VanillaGuideDB +## SavedVariablesPerCharacter: VanillaGuideDBPC + +Lua50Compat.lua +libs\AceLibrary\AceLibrary.lua +libs\AceOO-2.0\AceOO-2.0.lua +libs\AceConsole-2.0\AceConsole-2.0.lua +libs\AceEvent-2.0\AceEvent-2.0.lua +libs\AceAddon-2.0\AceAddon-2.0.lua +libs\AceDB-2.0\AceDB-2.0.lua +libs\AceDebug-2.0\AceDebug-2.0.lua + +Core.lua +Settings.lua +GuideTables\001_Introduction.lua +GuideTables\Horde\002_Mulgore.lua +GuideTables\Horde\002_TirisfalGlades.lua +GuideTables\Horde\002_Durotar.lua +GuideTables\Horde\003_Horde_12to20.lua +GuideTables\Horde\003_Horde_20to30.lua +GuideTables\Horde\003_Horde_30to40.lua +GuideTables\Horde\003_Horde_40to50.lua +GuideTables\Horde\003_Horde_50to60.lua +GuideTables\Alliance\002_ElwynnForest.lua +GuideTables\Alliance\002_Teldrassil.lua +GuideTables\Alliance\002_DunMorogh.lua +GuideTables\Alliance\003_Alliance_12to20.lua +GuideTables\Alliance\003_Alliance_20to30.lua +GuideTables\Alliance\003_Alliance_30to40.lua +GuideTables\Alliance\003_Alliance_40to50.lua +GuideTables\Alliance\003_Alliance_50to60.lua +GuideTables\004_Professions.lua +GuideTable.lua +Display.lua +SlashCommands.lua +Frame_MainFrame.lua +Frame_AboutFrame.lua +Frame_SettingsFrame.lua +UI.lua + +libs\Tablet-2.0\Tablet-2.0.lua +libs\Dewdrop-2.0\Dewdrop-2.0.lua +libs\FuBarPlugin-2.0\FubarPlugin-2.0.lua + +VGuideFu.lua From 9e3caf71df6bc4f25bcc1686d4b218a2ceafa198 Mon Sep 17 00:00:00 2001 From: Florian Berthold Date: Wed, 10 Jun 2026 02:11:47 +0200 Subject: [PATCH 2/3] ci(release): sync release.yml from coa-template MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit hide_archive_links is only honored by Gitea on release edit, not create — add the PATCH step after create/lookup so auto-generated source archive links actually stay hidden (coa-template 90874c5). --- .gitea/workflows/release.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index 709a7cd..2f93975 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -37,10 +37,14 @@ jobs: RID=$(curl -sf -X POST -H "Authorization: token $GITEA_TOKEN" \ -H "Content-Type: application/json" \ "$API/repos/$REPO/releases" \ - -d "$(jq -nc --arg t "$TAG" '{tag_name:$t,name:$t,draft:false,prerelease:false}')" \ + -d "$(jq -nc --arg t "$TAG" '{tag_name:$t,name:$t,draft:false,prerelease:false,hide_archive_links:true}')" \ | jq -r '.id') fi echo "release id: $RID" + # Gitea honors hide_archive_links only on edit, not create — PATCH it + # so the auto-generated Source Code (zip/tar.gz) links stay hidden. + curl -sf -X PATCH -H "Authorization: token $GITEA_TOKEN" -H "Content-Type: application/json" \ + "$API/repos/$REPO/releases/$RID" -d '{"hide_archive_links":true}' >/dev/null || true # Upload every dist/*.zip. Per-asset failures don't fail the job — # we want partial releases to still publish rather than block the # whole pipeline on one big file. From 0c5dd38839dbef6c413984b635dfef93e6b688f4 Mon Sep 17 00:00:00 2001 From: Florian Berthold Date: Wed, 10 Jun 2026 02:16:42 +0200 Subject: [PATCH 3/3] chore: toc version/path nits + drop stale smoke-test TODO - Version 1.04.2-coa1 -> 1.04.2 (release tags carry the -coa.N suffix) - fix FuBarPlugin-2.0.lua path case to match on-disk file - README-CoA: remove 'not yet loaded against the Ascension client' TODO; load-tested in-game (a8ea642, 330a6cf) --- README-CoA.md | 4 ---- VanillaGuide/VanillaGuide.toc | 4 ++-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/README-CoA.md b/README-CoA.md index 14cf6db..e8d1f4d 100644 --- a/README-CoA.md +++ b/README-CoA.md @@ -63,10 +63,6 @@ crashed on the very first guide load with What is still TODO ------------------ -- **In-game smoke test.** The addon has not yet been loaded against - the Ascension client. Expect further small breakage (frame APIs, - `GetAddOnInfo` signature, possibly map-zone coords) once we drive it - through `/vguide`. - **MetaMapBWP integration.** MetaMap doesn't exist on 3.3.5. The hooks in `Settings.lua` and `Frame_SettingsFrame.lua` are gated behind `IsAddOnLoaded("MetaMap")` so they're effectively dead, but diff --git a/VanillaGuide/VanillaGuide.toc b/VanillaGuide/VanillaGuide.toc index 0ff707e..ec68195 100644 --- a/VanillaGuide/VanillaGuide.toc +++ b/VanillaGuide/VanillaGuide.toc @@ -2,7 +2,7 @@ ## Title: VanillaGuide |cff7fff7f -Ace2-|r |cffff7f7f(CoA)|r ## Notes: Step-by-Step 1-60 Guides (CoA fork: Ascension 3.3.5 port, Joana H/A paths) ## Author: mrmr -## Version: 1.04.2-coa1 +## Version: 1.04.2 ## DefaultState: enabled ## LoadOnDemand: 0 @@ -57,6 +57,6 @@ UI.lua libs\Tablet-2.0\Tablet-2.0.lua libs\Dewdrop-2.0\Dewdrop-2.0.lua -libs\FuBarPlugin-2.0\FubarPlugin-2.0.lua +libs\FuBarPlugin-2.0\FuBarPlugin-2.0.lua VGuideFu.lua