errors and warnings / manifest / E4334
E4334 error
Both a hand-written Bindings.xml and wowlua:bindings declarations
- area
- manifest (x4xxx)
- fails the build
- yes
The package root has a hand-written Bindings.xml (or a flavor variant such as
Bindings_Mainline.xml), and the code declares keybindings with @binding
from wowlua:bindings, which generates a Bindings.xml. The client reads only
one keybinding file per AddOn, so one set of bindings would be lost.
Declare every binding with @binding and delete the hand-written file, or keep
the file and drop wowlua:bindings.
Example
<Bindings> <Binding name="PLAYGROUND_HIDE">PlaygroundHide()</Binding></Bindings>import binding from "wowlua:bindings" @binding("PLAYGROUND_SHOW", { label = "Show" })local function show() print("show")endimport binding from "wowlua:bindings" @binding("PLAYGROUND_SHOW", { label = "Show" })local function show() print("show")end @binding("PLAYGROUND_HIDE", { label = "Hide" })local function hide() print("hide")endThe compiler reports it like this:
error[E4334]: `Bindings.xml` is hand-written, and `wowlua:bindings` would generate one ┌─ src/main.wowlua:3:10 │ 3 │ @binding("PLAYGROUND_SHOW", { label = "Show" }) │ ^^^^^^^^^^^^^^^^^ a `@binding` │ = help: declare every binding with `@binding`, or keep the hand-written file and drop `wowlua:bindings`
Offline
$ wowlua explain E4334 E4334 (error): Both a hand-written Bindings.xml and wowlua:bindings declarations