lycheedev 3.2.6 → 3.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/THIRD_PARTY_NOTICES +4631 -253
  2. package/bin/lycheedev.mjs +1 -1
  3. package/bin/update.mjs +5 -1
  4. package/native/windows-amd64/lycheedev.exe +0 -0
  5. package/package.json +1 -1
  6. package/payload/addon/Bridge/ReceiverBindings.lua +25 -5
  7. package/payload/addon/Core/Execute.lua +19 -4
  8. package/payload/addon/Core/Runtime.lua +6 -1
  9. package/payload/addon/Core/Serializer.lua +5 -1
  10. package/payload/addon/Lychee Dev.toc +1 -1
  11. package/payload/addon/THIRD_PARTY_NOTICES +4631 -253
  12. package/payload/skill/SKILL.md +38 -93
  13. package/payload/skill/agents/openai.yaml +2 -2
  14. package/payload/skill/references/data-investigation.md +52 -88
  15. package/payload/skill/references/live-probes.md +65 -167
  16. package/payload/skill/references/publish.md +30 -0
  17. package/payload/skill/references/runtime-investigations.md +41 -120
  18. package/payload/skill/references/source-research.md +49 -156
  19. package/release.json +34 -109
  20. package/payload/skill/references/addon-validation.md +0 -108
  21. package/payload/skill/references/asset-export.md +0 -192
  22. package/payload/skill/references/commands.md +0 -222
  23. package/payload/skill/references/data-hotfix.md +0 -128
  24. package/payload/skill/references/data-query-recipes.md +0 -92
  25. package/payload/skill/references/data-recovery.md +0 -73
  26. package/payload/skill/references/data-tables.md +0 -207
  27. package/payload/skill/references/data-targets.md +0 -99
  28. package/payload/skill/references/error-diagnosis.md +0 -69
  29. package/payload/skill/references/installation.md +0 -133
  30. package/payload/skill/references/live-investigation.md +0 -127
  31. package/payload/skill/references/live-recovery.md +0 -275
  32. package/payload/skill/references/live-startup.md +0 -124
  33. package/payload/skill/references/source-preparation.md +0 -82
  34. package/payload/skill/references/source-relations.md +0 -65
  35. package/payload/skill/references/source-value-flow.md +0 -67
package/bin/lycheedev.mjs CHANGED
@@ -60,7 +60,7 @@ if (process.argv[1] && realpathSync(resolve(process.argv[1])) === fileURLToPath(
60
60
  }
61
61
  if (args[commandIndex] === 'update') args = ['update', ...args.slice(0, commandIndex), ...args.slice(commandIndex + 1)];
62
62
  activeArgs = args;
63
- const managedUpdate = args[0] === 'update' && !args.some(arg => ['--help', '-h', '--plan', '--release'].includes(arg) || arg.startsWith('--release='));
63
+ const managedUpdate = args[0] === 'update' && !args.some(arg => ['--help', '-h', '--plan', '--help=true', '-h=true', '--plan=true', '--release'].includes(arg) || arg.startsWith('--release='));
64
64
  let result;
65
65
  if (managedUpdate) {
66
66
  const { update } = await import('./update.mjs');
package/bin/update.mjs CHANGED
@@ -83,7 +83,11 @@ export async function update(root, args, nativePath) {
83
83
  }
84
84
  const npm = npmEntry();
85
85
  // Validate arguments and all existing targets before downloads or npm writes.
86
- const plan = nativeResult(nativePath(root), [...args, '--plan', '--format=json']);
86
+ const planArgs = [...args];
87
+ const planIndex = planArgs.indexOf('--plan=false');
88
+ if (planIndex >= 0) planArgs[planIndex] = '--plan';
89
+ else planArgs.push('--plan');
90
+ const plan = nativeResult(nativePath(root), [...planArgs, '--format=json']);
87
91
  const directory = join(prefix, '.lycheedev-update');
88
92
  mkdirSync(directory, { recursive: true });
89
93
  if (lstatSync(directory).isSymbolicLink() || realpathSync(directory).toLowerCase() !== resolve(directory).toLowerCase()) throw new Error('update.redirected_state');
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lycheedev",
3
- "version": "3.2.6",
3
+ "version": "3.2.9",
4
4
  "private": false,
5
5
  "description": "Unified native World of Warcraft development toolkit",
6
6
  "license": "MIT",
@@ -37,6 +37,9 @@ local function current()
37
37
  end
38
38
  return profile
39
39
  end
40
+ local function stopWaiting()
41
+ if deferred then deferred:UnregisterAllEvents(); deferred:SetScript("OnEvent", nil) end
42
+ end
40
43
  local function installDefaults()
41
44
  local ready, reason = noncombat()
42
45
  if not ready then return nil, reason end
@@ -59,6 +62,18 @@ local function installDefaults()
59
62
  end
60
63
  end
61
64
  end
65
+ -- Bindings can still be loading at PLAYER_LOGIN. Resolve the player's
66
+ -- writable set before any mutation; never save defaults to a guessed set.
67
+ local bindingSet
68
+ if #pending > 0 then
69
+ bindingSet = GetCurrentBindingSet()
70
+ if restricted(bindingSet) or (bindingSet ~= 1 and bindingSet ~= 2) then
71
+ return nil, "receiver_binding_set_unavailable"
72
+ end
73
+ end
74
+ -- SetBinding/SaveBindings can synchronously emit UPDATE_BINDINGS, including
75
+ -- when a manual reset completes an outstanding startup wait.
76
+ stopWaiting()
62
77
  local assigned = {}
63
78
  for _, entry in ipairs(pending) do
64
79
  if not SetBinding(entry.key, entry.action) then
@@ -67,17 +82,19 @@ local function installDefaults()
67
82
  end
68
83
  assigned[#assigned + 1] = entry.key
69
84
  end
70
- if #assigned > 0 then SaveBindings(GetCurrentBindingSet()) end
85
+ if #assigned > 0 then SaveBindings(bindingSet) end
71
86
  return current()
72
87
  end
73
88
  local function defer(event)
74
89
  if not deferred then deferred = CreateFrame("Frame") end
75
90
  deferred:RegisterEvent(event)
76
- deferred:SetScript("OnEvent", function(self)
77
- self:UnregisterAllEvents(); self:SetScript("OnEvent", nil)
91
+ if event == "BINDINGS_LOADED" then deferred:RegisterEvent("UPDATE_BINDINGS") end
92
+ deferred:SetScript("OnEvent", function()
93
+ stopWaiting()
78
94
  local ok, reason = installDefaults()
79
95
  if not ok and reason == "receiver_combat" then defer("PLAYER_REGEN_ENABLED")
80
- elseif ns.Startup then ns.Startup.receiverFailure = reason end
96
+ elseif not ok and reason == "receiver_binding_set_unavailable" then defer("BINDINGS_LOADED") end
97
+ if ns.Startup then ns.Startup.receiverFailure = reason end
81
98
  if ns.Bootstrap then ns.Bootstrap.Publish() end
82
99
  end)
83
100
  return true
@@ -94,7 +111,9 @@ ns.ReceiverBindings = {
94
111
  end,
95
112
  Reset = function()
96
113
  if ns.InputProtection and ns.InputProtection.IsActive() then return nil, "receiver_active" end
97
- return installDefaults()
114
+ local profile, reason = installDefaults()
115
+ if profile and ns.Startup then ns.Startup.receiverFailure = nil end
116
+ return profile, reason
98
117
  end,
99
118
  Register = function(callbacks)
100
119
  if handlers then local profile, reason = current(); return profile and true or nil, reason end
@@ -105,6 +124,7 @@ ns.ReceiverBindings = {
105
124
  if type(IsLoggedIn) == "function" and IsLoggedIn() ~= true then return defer("PLAYER_LOGIN") end
106
125
  local profile, reason = installDefaults()
107
126
  if not profile and reason == "receiver_combat" then return defer("PLAYER_REGEN_ENABLED") end
127
+ if not profile and reason == "receiver_binding_set_unavailable" then return defer("BINDINGS_LOADED") end
108
128
  return profile and true or nil, reason
109
129
  end,
110
130
  }
@@ -16,11 +16,12 @@ local function AddOutput(output, text)
16
16
  local prefix = #output.parts > 0 and "\n" or ""
17
17
  local remaining = MAX_CAPTURE_BYTES - output.length - #prefix
18
18
  if #text > remaining then
19
- output.parts[#output.parts + 1] = prefix
19
+ local marker = "\n... <output truncated>"
20
+ local captured = table.concat(output.parts) .. prefix
20
21
  .. text:sub(1, math.max(0, remaining))
21
- .. "\n... <output truncated>"
22
+ output.parts = { captured:sub(1, MAX_CAPTURE_BYTES - #marker) .. marker }
22
23
  output.truncated = true
23
- output.length = output.length + #output.parts[#output.parts]
24
+ output.length = #output.parts[1]
24
25
  return
25
26
  end
26
27
 
@@ -99,7 +100,21 @@ function ns.Execute(code)
99
100
 
100
101
  local formatted, liveTree, storedTree = pcall(function()
101
102
  if not succeeded then
102
- AddOutput(output, L.RUNTIME_ERROR .. tostring(packed[2]))
103
+ local diagnostic = L.RUNTIME_ERROR .. tostring(packed[2])
104
+ if #diagnostic >= MAX_CAPTURE_BYTES then
105
+ local marker = "\n... <output truncated>"
106
+ diagnostic = diagnostic:sub(1, MAX_CAPTURE_BYTES - 1 - #marker) .. marker
107
+ end
108
+ local captured = table.concat(output.parts)
109
+ if #captured + 1 + #diagnostic > MAX_CAPTURE_BYTES then
110
+ output.parts = { captured:sub(1, MAX_CAPTURE_BYTES - #diagnostic - 1)
111
+ .. "\n" .. diagnostic }
112
+ output.length = #output.parts[1]
113
+ else
114
+ -- A previous truncation must not suppress the actual failure.
115
+ output.truncated = false
116
+ AddOutput(output, diagnostic)
117
+ end
103
118
  return
104
119
  end
105
120
  local values = { n = packed.n - 1 }
@@ -1,6 +1,6 @@
1
1
  local ADDON_NAME, ns = ...
2
2
 
3
- ns.Release = "3.2.6"
3
+ ns.Release = "3.2.9"
4
4
  ns.Startup = { ready = false, reason = "addon_not_loaded" }
5
5
  _G.LycheeDevInternal = ns
6
6
 
@@ -45,6 +45,11 @@ loader:SetScript("OnEvent",function(self,event,name)
45
45
  else ok,started,reason=true,nil,"startup_module_unavailable" end
46
46
  if not ok then started,reason=nil,"startup_exception" end
47
47
  if started then phase,failure="ready",""
48
+ elseif reason=="actor_unavailable" and event=="ADDON_LOADED" and IsLoggedIn()==false then
49
+ -- Character identity is not available yet during normal addon loading.
50
+ -- Keep the existing PLAYER_LOGIN retry without reporting an error.
51
+ phase,failure="loading",reason
52
+ ns.Startup.ready,ns.Startup.reason=false,reason
48
53
  else
49
54
  phase,failure="failed",reason or "startup_failed"
50
55
  ns.Startup.ready,ns.Startup.reason=false,failure
@@ -33,7 +33,11 @@ local function Append(state, text)
33
33
  end
34
34
 
35
35
  if state.length + #text > state.maxOutputBytes then
36
- state.parts[#state.parts + 1] = "\n... <output truncated>"
36
+ local marker = "\n... <output truncated>"
37
+ local captured = table.concat(state.parts)
38
+ state.parts = { captured:sub(1, math.max(0, state.maxOutputBytes - #marker))
39
+ .. marker:sub(1, state.maxOutputBytes) }
40
+ state.length = #state.parts[1]
37
41
  state.truncated = true
38
42
  state.incomplete = true
39
43
  return
@@ -1,6 +1,6 @@
1
1
  ## Interface: 120105, 120100, 50504, 38002, 16001, 11509, 20506
2
2
  ## Title: Lychee Dev
3
- ## Version: 3.2.6
3
+ ## Version: 3.2.9
4
4
  ## SavedVariables: LycheeToolkitDB
5
5
  ## SavedVariablesPerCharacter: LycheeToolkitBridgeDB
6
6