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

bindgen CI failing on Windows #352

Closed
Mytherin opened this issue Jul 10, 2024 · 0 comments · Fixed by #353
Closed

bindgen CI failing on Windows #352

Mytherin opened this issue Jul 10, 2024 · 0 comments · Fixed by #353

Comments

@Mytherin
Copy link
Contributor

The bindgen CI is failing on Windows with the latest v1.0.0 build. I've disabled the CI run for now, but this should be looked into as this could indicate problems for the Windows release. Here is an example failing CI run

failures:

---- bindings::bindgen_test_layout__opaque_pthread_cond_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_cond_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:10334:
assertion `left == right` failed: Size of: _opaque_pthread_cond_t
  left: 44
 right: 48
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_cond_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_cond_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_cond_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_attr_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_attr_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:9218:
assertion `left == right` failed: Size of: _opaque_pthread_attr_t
  left: 60
 right: 64
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_attr_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_attr_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_attr_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_condattr_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_condattr_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:11461:
assertion `left == right` failed: Size of: _opaque_pthread_condattr_t
  left: 12
 right: 16
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_condattr_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_condattr_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_condattr_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_mutex_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_mutex_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:12604:
assertion `left == right` failed: Size of: _opaque_pthread_mutex_t
  left: 60
 right: 64
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutex_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutex_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutex_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_mutexattr_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_mutexattr_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:13740:
assertion `left == right` failed: Size of: _opaque_pthread_mutexattr_t
  left: 12
 right: 16
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutexattr_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutexattr_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_mutexattr_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_once_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_once_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:14885:
assertion `left == right` failed: Size of: _opaque_pthread_once_t
  left: 12
 right: 16
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_once_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_once_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_once_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_rwlock_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_rwlock_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:16008:
assertion `left == right` failed: Size of: _opaque_pthread_rwlock_t
  left: 196
 right: 200
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlock_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlock_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlock_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- bindings::bindgen_test_layout__opaque_pthread_rwlockattr_t stdout ----
thread 'bindings::bindgen_test_layout__opaque_pthread_rwlockattr_t' panicked at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out/bindgen.rs:3:17155:
assertion `left == right` failed: Size of: _opaque_pthread_rwlockattr_t
  left: 20
 right: 24
stack backtrace:
   0: std::panicking::begin_panic_handler
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\std\src\panicking.rs:652
   1: core::panicking::panic_fmt
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:72
   2: core::panicking::assert_failed_inner
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\panicking.rs:404
   3: core::panicking::assert_failed<usize,usize>
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\panicking.rs:364
   4: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlockattr_t
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   5: libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlockattr_t::closure$0
             at D:\a\duckdb-rs\duckdb-rs\target\debug\build\libduckdb-sys-4f2c08f545dec78a\out\bindgen.rs:3
   6: core::ops::function::FnOnce::call_once<libduckdb_sys::bindings::bindgen_test_layout__opaque_pthread_rwlockattr_t::closure_env$0,tuple$<> >
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081\library\core\src\ops\function.rs:250
   7: core::ops::function::FnOnce::call_once
             at /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library\core\src\ops\function.rs:250
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Pre-v1.0.0 these bindgen tests did not exist as can be seen in this CI run. For some reason bindgen has added extra tests after the port to v1.0.0, that then failed. Perhaps there is some configuration that can be set to disable this behavior. bindgen itself seems to have lacking support for Windows so this may well be an upstream bug that we are running into that we were not running into before due to some change in our C API between the two versions.

We could also consider whether we should be using bindgen anyway - given that our C API is not particularly complex. For the Julia client, for example, we don't use a library and generate the bindings ourselves.

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

Successfully merging a pull request may close this issue.

1 participant