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

Failed Pip Install - libsql-ffi v0.2.1 #63

Open
itsnumpty opened this issue Jun 9, 2024 · 6 comments
Open

Failed Pip Install - libsql-ffi v0.2.1 #63

itsnumpty opened this issue Jun 9, 2024 · 6 comments

Comments

@itsnumpty
Copy link

error: failed to run custom build command forlibsql-ffi v0.2.1 (https://github.com/penberg/libsql/?rev=5a806fe53cc84a5a49853d4ae30bad64b7210c67#5a806fe5)`

  Caused by:
    process didn't exit successfully: `C:\Users\<>\AppData\Local\Temp\pip-install-kwpyryow\libsql-experimental_12cb8194173940f88b6ecbc5b9c5d2ec\target\release\build\libsql-ffi-8105b99e0fa61d6e\build-script-build` (exit code: 101)
    --- stdout
    cargo:rerun-if-changed=bundled/src/sqlite3.c
    cargo:rerun-if-changed=bundled/SQLite3MultipleCiphers/build/libsqlite3mc_static.a
    cargo:lib_dir=C:\Users\<>\AppData\Local\Temp\pip-install-kwpyryow\libsql-experimental_12cb8194173940f88b6ecbc5b9c5d2ec\target\release\build\libsql-ffi-627ab9f5a78bbde9\out
    Running `cmake` with options: -DCMAKE_BUILD_TYPE=Release -DSQLITE3MC_STATIC=ON -DCODEC_TYPE=AES256 -DSQLITE3MC_BUILD_SHELL=OFF -DSQLITE_SHELL_IS_UTF8=OFF -DSQLITE_USER_AUTHENTICATION=OFF -DSQLITE_SECURE_DELETE=OFF -DSQLITE_ENABLE_COLUMN_METADATA=ON -DSQLITE_USE_URI=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON

    --- stderr
    thread 'main' panicked at C:\Users\<>\.cargo\git\checkouts\libsql-e519d6234c1a233a\5a806fe\libsql-ffi\build.rs:358:33:
    called `Result::unwrap()` on an `Err` value: Error { kind: NotFound, message: "program not found" }
    note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
  warning: build failed, waiting for other jobs to finish...
  💥 maturin failed
    Caused by: Failed to build a native library through cargo
    Caused by: Cargo build finished with "exit code: 101": `"cargo" "rustc" "--features" "pyo3/extension-module" "--message-format" "json-render-diagnostics" "--manifest-path" "C:\\Users\\<>\\AppData\\Local\\Temp\\pip-install-kwpyryow\\libsql-experimental_12cb8194173940f88b6ecbc5b9c5d2ec\\Cargo.toml" "--release" "--lib"`
  Error: command ['maturin', 'pep517', 'build-wheel', '-i', 'C:\\Users\\<>\\AppData\\Local\\Programs\\Python\\Python310\\python.exe', '--compatibility', 'off'] returned non-zero exit status 1`

Cannot pip install, fails build. This was closed off for OS X but no fix found for Windows.

@LucioFranco
Copy link
Collaborator

you may need to install cmake etc

@itsnumpty
Copy link
Author

you may need to install cmake etc

cmake is installed on my machine prior to this error.

@nikhil-swamix
Copy link

this is a blocker for all windows users. can confirm
image
python 3.12
everything is installed! cmake msvc, so problem is with dependencies or packages.

@PrinceBaghel258025
Copy link

guys, was having the same problem but it got resolved after installing rust and cmake in my windows machine
able to install 0.0.38 version inside a poetry env

@minhquan23102000
Copy link

minhquan23102000 commented Oct 26, 2024

Any update so far. Hope this package will update to production ready soon. Python really a huge community for agent development

OS: Win 11
Python: 3.12
Cargo version: 1.82.0 (8f40fc59f 2024-08-21)
Cmake: version 3.30.5
Clang version 19.1.2

Resolved 112 packages in 87ms
error: Failed to prepare distributions
  Caused by: Failed to download and build `libsql-experimental==0.0.41`
  Caused by: Build backend failed to build wheel through `build_wheel` (exit code: 1)

[stdout]
Running `maturin pep517 build-wheel -i C:\Users\PC\AppData\Local\uv\cache\builds-v0\.tmpmqnS34\Scripts\python.exe --compatibility off`

[stderr]
📦 Including license file "C:\Users\PC\AppData\Local\uv\cache\sdists-v5\pypi\libsql-experimental\0.0.41\5XwiJnUIC1DRVfvR9ZjQq\libsql_experimental-0.0.41.tar.gz\LICENSE.md"
🔗 Found pyo3 bindings
🐍 Found CPython 3.12 at C:\Users\PC\AppData\Local\uv\cache\builds-v0\.tmpmqnS34\Scripts\python.exe
📡 Using build options features from pyproject.toml
   Compiling ring v0.17.8
   Compiling pyo3-build-config v0.19.2
   Compiling libsql-ffi v0.3.0 (https://github.com/tursodatabase/libsql/?rev=21f405b087b210734367fb1343ed436249c8dc10#21f405b0)
   Compiling libsql-sqlite3-parser v0.12.0 (https://github.com/tursodatabase/libsql/?rev=21f405b087b210734367fb1343ed436249c8dc10#21f405b0)
error: failed to run custom build command for `libsql-ffi v0.3.0 (https://github.com/tursodatabase/libsql/?rev=21f405b087b210734367fb1343ed436249c8dc10#21f405b0)`

Caused by:
  process didn't exit successfully: `C:\Users\PC\AppData\Local\uv\cache\sdists-v5\pypi\libsql-experimental\0.0.41\5XwiJnUIC1DRVfvR9ZjQq\libsql_experimental-0.0.41.tar.gz\target\release\build\libsql-ffi-53910dba132d728a\build-script-build` (exit code: 101)
  --- stdout
  cargo:rerun-if-changed=bundled/src/sqlite3.c
  cargo:rerun-if-changed=C:\Users\PC\AppData\Local\uv\cache\sdists-v5\pypi\libsql-experimental\0.0.41\5XwiJnUIC1DRVfvR9ZjQq\libsql_experimental-0.0.41.tar.gz\target\release\build\libsql-ffi-e718525dc38faed8\out/sqlite3mc/libsqlite3mc_static.a

  --- stderr
  thread 'main' panicked at C:\Users\PC\scoop\persist\rustup\.cargo\git\checkouts\libsql-311658d335deb3b1\21f405b\libsql-ffi\build.rs:48:10:
  called `Result::unwrap()` on an `Err` value: Error { kind: NotFound, message: "program not found" }
  stack backtrace:
     0:     0x7ff77a0e3f41 - std::backtrace_rs::backtrace::dbghelp64::trace
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\..\..\backtrace\src\backtrace\dbghelp64.rs:91
     1:     0x7ff77a0e3f41 - std::backtrace_rs::backtrace::trace_unsynchronized
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\..\..\backtrace\src\backtrace\mod.rs:66
     2:     0x7ff77a0e3f41 - std::sys::backtrace::_print_fmt
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:66
     3:     0x7ff77a0e3f41 - std::sys::backtrace::impl$0::print::impl$0::fmt
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:39
     4:     0x7ff77a105b39 - core::fmt::rt::Argument::fmt
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\fmt\rt.rs:177
     5:     0x7ff77a105b39 - core::fmt::write
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\fmt\mod.rs:1178
     6:     0x7ff77a0df4b7 - std::io::Write::write_fmt<std::sys::pal::windows::stdio::Stderr>
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\io\mod.rs:1823
     7:     0x7ff77a0e6309 - std::panicking::default_hook::closure$1
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:266
     8:     0x7ff77a0e5e8c - std::panicking::default_hook
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:293
     9:     0x7ff77a0e6c12 - std::panicking::rust_panic_with_hook
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:797
    10:     0x7ff77a0e6a56 - std::panicking::begin_panic_handler::closure$0
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:671
    11:     0x7ff77a0e49ff - std::sys::backtrace::__rust_end_short_backtrace<std::panicking::begin_panic_handler::closure_env$0,never$>
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\sys\backtrace.rs:170
    12:     0x7ff77a0e6666 - std::panicking::begin_panic_handler
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:662
    13:     0x7ff77a10eae4 - core::panicking::panic_fmt
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\panicking.rs:74
    14:     0x7ff77a10ef00 - core::result::unwrap_failed
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/core\src\result.rs:1677
    15:     0x7ff779b7460e - enum2$<core::result::Result<std::process::Output,std::io::error::Error> >::unwrap
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\core\src\result.rs:1102
    16:     0x7ff779b7460e - build_script_build::main
                                 at C:\Users\PC\scoop\persist\rustup\.cargo\git\checkouts\libsql-311658d335deb3b1\21f405b\libsql-ffi\build.rs:42
    17:     0x7ff779b7201b - core::ops::function::FnOnce::call_once<void (*)(),tuple$<> >
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\core\src\ops\function.rs:250
    18:     0x7ff779b71a6e - core::hint::black_box
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\core\src\hint.rs:388
    19:     0x7ff779b71a6e - std::sys::backtrace::__rust_begin_short_backtrace<void (*)(),tuple$<> >
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\std\src\sys\backtrace.rs:154
    20:     0x7ff779b71921 - std::rt::lang_start::closure$0<tuple$<> >
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\std\src\rt.rs:164
    21:     0x7ff77a0dad99 - std::rt::lang_start_internal::closure$2
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\rt.rs:143
    22:     0x7ff77a0dad99 - std::panicking::try::do_call
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:554
    23:     0x7ff77a0dad99 - std::panicking::try
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panicking.rs:518
    24:     0x7ff77a0dad99 - std::panic::catch_unwind
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\panic.rs:345
    25:     0x7ff77a0dad99 - std::rt::lang_start_internal
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library/std\src\rt.rs:143
    26:     0x7ff779b718fa - std::rt::lang_start<tuple$<> >
                                 at /rustc/f6e511eec7342f59a25f7c0534f1dbea00d01b14\library\std\src\rt.rs:163
    27:     0x7ff779b78d59 - main
    28:     0x7ff77a10bf00 - invoke_main
                                 at D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:78
    29:     0x7ff77a10bf00 - __scrt_common_main_seh
                                 at D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288
    30:     0x7ff875bd257d - BaseThreadInitThunk
    31:     0x7ff87736af08 - RtlUserThreadStart
warning: build failed, waiting for other jobs to finish...
💥 maturin failed
  Caused by: Failed to build a native library through cargo
  Caused by: Cargo build finished with "exit code: 101": `"cargo" "rustc" "--features" "pyo3/extension-module" "--message-format" "json-render-diagnostics" "--manifest-path" "C:\\Users\\PC\\AppData\\Local\\uv\\cache\\sdists-v5\\pypi\\libsql-experimental\\0.0.41\\5XwiJnUIC1DRVfvR9ZjQq\\libsql_experimental-0.0.41.tar.gz\\Cargo.toml" "--release" "--lib"`
Error: command ['maturin', 'pep517', 'build-wheel', '-i', 'C:\\Users\\PC\\AppData\\Local\\uv\\cache\\builds-v0\\.tmpmqnS34\\Scripts\\python.exe', '--compatibility', 'off'] returned non-zero exit status 1

@minhquan23102000
Copy link

Reopen new issue: #74

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

5 participants