Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help Request: dx bundle tries to create a directory with a too long path #2409

Closed
Tobi34 opened this issue May 12, 2024 · 1 comment
Closed

Comments

@Tobi34
Copy link

Tobi34 commented May 12, 2024

dx bundle creates directories recurviely. When I create a project in "dioxus-test",
this is the path that gets generated in the dioxus-test build directory:
dioxus-test/dist/bundle/deb/dioxus-test_0.1.0_amd64/data/usr/lib/
dioxus-test/dist/bundle/deb/dioxus-test_0.1.0_amd64/data/usr/lib/
dioxus-test/dist/bundle/deb/dioxus-test_0.1.0_amd64/data/usr/lib/
dioxus-test/dist/bundle/deb/dioxus-test_0.1.0_amd64/data/usr/lib/
dioxus-test/dist/bundle/deb/dioxus-test_0.1.0_amd64/data/usr/lib/ .. goes on recursively ..
The "bundle" directory seems to be missplaced.

Steps to reproduce:

  • go to empty build directory (dioxus-test)
  • run following commands
> dx init
Select Web
Select Vanilla
Select true (router)
> dx bundle

The output is:

build desktop done
Adding assets from dist to bundle
thread 'main' panicked at src/cli/bundle.rs:193:13:
Failed to bundle project: BundlerError(
    Error {
        context: "Failed to build data folders and files",
        source: BundlerError(
            Error {
                context: "Failed to copy resource files",
                source: IoError(
                    Os {
                        code: 36,
                        kind: InvalidFilename,
                        message: "File name too long",
                    },
                ),
            },
        ),
    },
)
stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: dioxus_cli::cli::bundle::Bundle::bundle
   3: tokio::runtime::park::CachedParkThread::block_on
   4: dx::main
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Versions:
Os: Nixos 23.11 with latest dioxus packets from unstable.
 dx -V
dioxus 0.5.4
 rustc --version
rustc 1.78.0 (9b00956e5 2024-04-29)

dx serve and dx build work fine. They don't create the additional "bundle" directory.

My shell.nix file:

{ pkgs ? import <nixpkgs-unstable> {} }:
  pkgs.mkShell {
    nativeBuildInputs = with pkgs.buildPackages; [ pkg-config cmake clang dioxus-cli];
    buildInputs =   [
      pkgs.wasmi
      pkgs.wasm-bindgen-cli
      pkgs.openssl 
    ];
}

Why is the bundle directory created in this place ?

@ealmloff
Copy link
Member

Closing this as a duplicate of #2239

@ealmloff ealmloff closed this as not planned Won't fix, can't repro, duplicate, stale May 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants