Arch Linux not handling error unions correctly?

I am not sure what is happening. but from this code, I get this error.

        pub fn start(this: *@This(), _controler: *con.newController()) !void {
            _ = this; // autofix
            rl.beginDrawing();
            defer rl.endDrawing();

            if (_controler.model.Textures2D.get("backround")) |br| {
                //rl.drawTexture(br, 0, 0, rl.Color.white);
                rl.drawTextureEx(br, rl.Vector2.init(0, 0), 0, 1.4, rl.Color.white);
            } else {

                const backround = try rl.Texture.init("src/assets/d95yko3-2f800ab5-9211-40e8-a8be-b0186dd6b23c.png");
                try _controler.model.add2DTexture("backround", backround);
            }
            drawMenu(_controler);
        }

FROM THE ERROR MES

view.zig:69:64: error: expected type 'raylib.Texture', found 'error{LoadFileData,LoadImageColors,LoadImagePalette,LoadFont,LoadFontData,LoadCodepoints,LoadMaterial,LoadMaterials,LoadModelAnimations,LoadShader,LoadImage,LoadModel,LoadTexture,LoadRenderTexture,LoadWave,LoadSound,LoadMusic,LoadAudioStream}!raylib.Texture'
                try _controler.model.add2DTexture("backround", backround);
                                                               ^~~~~~~~~
view.zig:69:64: note: cannot convert error union to payload type
view.zig:69:64: note: consider using 'try', 'catch', or 'if'
/home/jameson/.cache/zig/p/1220eedbc450fcfced1599d69f1e2c38b60af51616dbf724f6b9a8ed2c2a7c62cf9c/lib/raylib.zig:1182:28: note: struct declared here
pub const Texture = extern struct {
                    ~~~~~~~^~~~~~
model.zig:69:81: note: parameter type declared here
        pub fn add2DTexture(this: *@This(), name: *const [9:0]u8, _Texture2D: rl.Texture2D) !void {
                                                                              ~~^~~~~~~~~~
referenced by:
    drawScreen: controller.zig:24:42
    startApp: controller.zig:39:25
    remaining reference traces hidden; use '-freference-trace' to see all reference traces
player.zig:153:52: error: enum 'raylib.KeyboardKey' has no member named 'key_e'

This same code works on MacOS and Windows, but I get this error when using Manjaro Linux.

first I am not sure how to proceed other than opening a bug report but I have no clue how to reproduce this. because when I try to recreate within a new project error unions work properly.

the final error line makes it seem like you’re not referencing what you think you reference. the first few makes it seem like the source you’re compiling is not the one you showed us. backround does not seem initialized with a try or catch to unwrap the error/payload.

Try reproducing this in a fresh environment. Maybe nuke your ~/.cache/zig as well. Did you copy this from your macos? I don’t think this has anything to do with arch / manjaro.

I did nuke the ~/.cache/zig I got the same error. I was developing the game with Raylib on Windows macOS and Ubuntu LTS 24.04 I cloned it from a git repo.

that makes it seem like you’ve also updated external dependencies. Using Not-Nik raylib-zig? This seems familiar. Probably the fix is using .e instead of .key_e; then I can only assume your update added potential errors to other methods as well which now may fail. I’ve had to add some trys at places when updating raylib-zig last time in texture loading code. The code you posted well has it, seemingly, so that’s either not the code that’s being compiled or you have it duplicated elsewhere.

doing a zig fetch on macOS updated my bindings, and now I get the same error on both platforms

The compiler tells you where to look. Handle the potential errors of the texture loading, update your enums, and you ought to be fine.