spacedriveapp / spacedriveapp/spacebot

Get error when install from source

Open
#194 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
2.4k
Forks
367
PR merge metrics
No merged PRs in 30d

Description

I follow the guide at https://docs.spacebot.sh/quickstart#build-from-source to install on Ubuntu 24.04.

git clone https://github.com/spacedriveapp/spacebot.git
cd spacebot

# Optional: build the web UI (React + Vite, embedded into the binary)
cd interface && bun install && cd ..

# Install the binary
cargo install --path .

And get error

error: #[derive(RustEmbed)] folder '/home/ubuntu/projects/spacebot/interface/dist/' does not exist. cwd: '/home/ubuntu/projects/spacebot'
  --> src/api/server.rs:24:1
   |
24 | / /// Embedded frontend assets from the Vite build output.
25 | | #[derive(Embed)]
26 | | #[folder = "interface/dist/"]
27 | | #[allow(unused)]
28 | | struct InterfaceAssets;
   | |_______________________^

error[E0599]: no function or associated item named `get` found for struct `InterfaceAssets` in the current scope
   --> src/api/server.rs:236:45
    |
 28 | struct InterfaceAssets;
    | ---------------------- function or associated item `get` not found for this struct
...
236 |     if let Some(content) = InterfaceAssets::get(path) {
    |                                             ^^^ function or associated item not found in `InterfaceAssets`
    |
    = help: items from traits can only be used if the trait is implemented and in scope
    = note: the following traits define an item `get`, perhaps you need to implement one of them:
            candidate #1: `Datum`
            candidate #2: `EmbeddingRegistry`
            candidate #3: `ReadableMultimapTable`
            candidate #4: `ReadableTable`
            candidate #5: `Row`
            candidate #6: `RustEmbed`
            candidate #7: `SliceIndex`
            candidate #8: `TableLike`
            candidate #9: `bitvec::slice::api::BitSliceIndex`
            candidate #10: `datafusion_execution::cache::CacheAccessor`
            candidate #11: `geoarrow_array::trait_::GeoArrowArrayAccessor`
            candidate #12: `icu_collections::codepointtrie::cptrie::TypedCodePointTrie`
            candidate #13: `icu_properties::names::PropertyEnumToValueNameLookup`
            candidate #14: `icu_provider::baked::DataStore`
            candidate #15: `itertools::Itertools`
            candidate #16: `itertools::Itertools`
            candidate #17: `lance_io::encodings::AsyncIndex`
            candidate #18: `lance_table::io::commit::external_manifest::ExternalManifestStore`
            candidate #19: `ndarray::impl_views::indexing::IndexLonger`
            candidate #20: `object_store::ObjectStore`
            candidate #21: `opentelemetry::propagation::Extractor`
            candidate #22: `rustls::server::server_conn::StoresServerSessions`
            candidate #23: `rustls::server::server_conn::StoresServerSessions`
            candidate #24: `rustls::server::server_conn::StoresServerSessions`
            candidate #25: `toml_parser::SourceIndex`

error[E0599]: no function or associated item named `get` found for struct `InterfaceAssets` in the current scope
   --> src/api/server.rs:246:45
    |
 28 | struct InterfaceAssets;
    | ---------------------- function or associated item `get` not found for this struct
...
246 |     if let Some(content) = InterfaceAssets::get("index.html") {
    |                                             ^^^ function or associated item not found in `InterfaceAssets`
    |
    = help: items from traits can only be used if the trait is implemented and in scope
    = note: the following traits define an item `get`, perhaps you need to implement one of them:
            candidate #1: `Datum`
            candidate #2: `EmbeddingRegistry`
            candidate #3: `ReadableMultimapTable`
            candidate #4: `ReadableTable`
            candidate #5: `Row`
            candidate #6: `RustEmbed`
            candidate #7: `SliceIndex`
            candidate #8: `TableLike`
            candidate #9: `bitvec::slice::api::BitSliceIndex`
            candidate #10: `datafusion_execution::cache::CacheAccessor`
            candidate #11: `geoarrow_array::trait_::GeoArrowArrayAccessor`
            candidate #12: `icu_collections::codepointtrie::cptrie::TypedCodePointTrie`
            candidate #13: `icu_properties::names::PropertyEnumToValueNameLookup`
            candidate #14: `icu_provider::baked::DataStore`
            candidate #15: `itertools::Itertools`
            candidate #16: `itertools::Itertools`
            candidate #17: `lance_io::encodings::AsyncIndex`
            candidate #18: `lance_table::io::commit::external_manifest::ExternalManifestStore`
            candidate #19: `ndarray::impl_views::indexing::IndexLonger`
            candidate #20: `object_store::ObjectStore`
            candidate #21: `opentelemetry::propagation::Extractor`
            candidate #22: `rustls::server::server_conn::StoresServerSessions`
            candidate #23: `rustls::server::server_conn::StoresServerSessions`
            candidate #24: `rustls::server::server_conn::StoresServerSessions`
            candidate #25: `toml_parser::SourceIndex`

For more information about this error, try `rustc --explain E0599`.
error: could not compile `spacebot` (lib) due to 3 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `spacebot v0.1.15 (/home/ubuntu/projects/spacebot)`, intermediate artifacts can be found at `/home/ubuntu/projects/spacebot/target`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.

Thanks.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the source-build steps in the quickstart guide and inspect the interface/dist path referenced by the RustEmbed declaration in src/api/server.rs. Reproduce the failure with cargo install --path . after following the documented commands, then verify the documented installation succeeds and the embedded frontend assets are available.

Written by the indexing model from the issue text.

Assessment

Tech stack
bun, react, rust, ubuntu, vite
Domain
build-system, developer-experience, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.