Skip to content

dx serve --hot-patch errors [dev] Failed to generate fat binary: rust-lld: error: cannot open __MANGANIS__07ab8298cecd86fa: no such file or directory in Windows #5008

@qouteall

Description

@qouteall

Problem

Create a new project using dx new, all options default, then use dx serve --hot-patch fails to build.

Steps To Reproduce

Steps to reproduce the behavior:

  • dx new test2
  • All options default (Bare-Bones false false false false Web)
  • cd test2
  • dx serve --hot-patch

Output:

warning: Waiting for cargo-metadata...
warning: (Try 1) Taking a while...
warning: (Try 2) Taking a while...
10:56:03 [dev] -----------------------------------------------------------------
                Serving your app: test2! 🚀
                • Press `ctrl+c` to exit the server
                • Press `r` to rebuild the app
                • Press `p` to toggle automatic rebuilds
                • Press `v` to toggle verbose logging
                • Press `/` for more commands and shortcuts
                Learn more at https://dioxuslabs.com/learn/0.7/getting_started
               ----------------------------------------------------------------
10:56:26 [dev] Failed to generate fat binary: rust-lld: error: cannot open __MANGANIS__07ab8298cecd86fa: no such file or directory
10:56:26 [dev] Build failed: Failed to write executable
               1: Failed to emit module: magic header not detected: bad magic number - expected=[
                      0x0,
                      0x61,
                      0x73,
                      0x6d,
                  ] actual=[
                      0x64,
                      0x86,
                      0x0,
                      0x0,
                  ] (at offset 0x0)
               2: magic header not detected: bad magic number - expected=[
                      0x0,
                      0x61,
                      0x73,
                      0x6d,
                  ] actual=[
                      0x64,
                      0x86,
                      0x0,
                      0x0,
                  ] (at offset 0x0)
╭──────────────────────────────────────────────────────────────────────────────── /:more ╮
│  App:     ━━━━━━━━━━━━━━━━━━━━━━━━━━  ❌           Platform: Web                       │
│  Bundle:  ━━━━━━━━━━━━━━━━━━━━━━━━━━  ❌           App features: ["web"]               │
│  Status:  Failed                                   Serving at: http://127.0.0.1:8080   │
╰────────────────────────────────────────────────────────────────────────────────────────╯

Expected behavior

It works

Screenshots

Environment:

  • Dioxus version: dx -V gives dioxus 0.7.1 (03ab7fa)
  • Rust version: rustc --version gives rustc 1.91.1 (ed61e7d7e 2025-11-07)
    rustup show gives
Default host: x86_64-pc-windows-msvc
rustup home:  C:\Users\Administrator\.rustup

installed toolchains
--------------------
stable-x86_64-pc-windows-gnu
stable-x86_64-pc-windows-msvc (active, default)
nightly-x86_64-pc-windows-msvc

active toolchain
----------------
name: stable-x86_64-pc-windows-msvc
active because: it's the default toolchain
installed targets:
  wasm32-unknown-unknown
  x86_64-pc-windows-msvc
  • OS info: Windows11
  • App platform: Web

Questionnaire

Same error even within x64 Native Tools Command Prompt for VS 2022

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions