Skip to content

Conversation

@eitsupi
Copy link
Contributor

@eitsupi eitsupi commented Jul 13, 2025

Fix #3149
Close #3122

  • adbc_snowflake tests for Windows fails so excluded.
  • Some tests of driver_manager are skipped because they fail for windows.

@zeroshade
Copy link
Member

Welp, looks like I gotta fix the windows build code for the driver manager. ☹️

@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 13, 2025

Apparently, use windows_sys as windows doesn't work!
Sorry...

@eitsupi eitsupi marked this pull request as ready for review July 13, 2025 17:20
@github-actions github-actions bot added this to the ADBC Libraries 20 milestone Jul 13, 2025
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 13, 2025

CI is apparently working now, but the build is failing, so do I need to temporarily exclude windows-latest from the matrix so it can be merged?

@zeroshade
Copy link
Member

Yea, let's temporarily exclude windows while I fix the windows build so we can merge this

@eitsupi eitsupi changed the title ci(rust): enable tests on windows ci(rust): add a job for tests on windows (excluded for now) Jul 13, 2025
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 13, 2025

let's temporarily exclude windows while I fix the windows build so we can merge this

Thanks!

I've excluded windows for now and opened a follow up issue #3149.

@zeroshade
Copy link
Member

@eitsupi I've worked out the necessary changes to get it to build on windows. Should I push it to this PR or do you want to get this merged and I'll make a follow-up PR to enable the windows build with my changes?

@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 13, 2025

That's so fast! Either is fine with me.
(I'm going to sleep now so I won't be able to reply for a while, so please feel free to edit this PR etc.)

@zeroshade zeroshade requested a review from wjones127 as a code owner July 13, 2025 18:33
@zeroshade
Copy link
Member

Okay, so I've almost got this except for one weird linking issue with the rust adbc_snowflake crate on windows:

nowflake-0.natvis" "/NATVIS:C:\\Users\\zotth\\AppData\\Local\\Temp\\rustcbQbqD9\\adbc_snowflake-1.natvis"
  = note: some arguments are omitted. use `--verbose` to show all linker arguments
  = note: legacy_stdio_definitions.lib(legacy_stdio_definitions.obj) : warning LNK4078: multiple '.drectve' sections found with different attributes (00100A00)␍
          snowflake.lib(go.o) : fatal error LNK1223: invalid or corrupt file: file contains invalid .pdata contributions␍

I've hit a wall here. Any ideas @eitsupi @kou @lidavidm @paleolimbot ?

@lidavidm
Copy link
Member

@lidavidm
Copy link
Member

So I guess you can dynamically link Go libraries on Windows, but not statically.

@zeroshade
Copy link
Member

sigh well, at least they found the issue and are fixing it, even though it'll be a while before we can use that fix. I guess we can disable the bundled feature on windows for now so that it doesn't do the static link

@eitsupi eitsupi marked this pull request as draft July 14, 2025 07:42
Co-authored-by: Matthijs Brobbel <[email protected]>
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 14, 2025

Thanks all! I'll take a look the build error.

@eitsupi eitsupi changed the title ci(rust): add a job for tests on windows (excluded for now) fix(rust/core): fix build errror on windows and enable ci for windows Jul 14, 2025
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 14, 2025

Some tests are failing on Windows:

running 14 tests
test driver_manager::tests::test_get_search_paths ... ok
test driver_manager::tests::test_default_entrypoint ... FAILED
test driver_manager::tests::test_load_driver_env ... FAILED
test driver_manager::tests::test_load_absolute_path ... ok
test driver_manager::tests::test_load_absolute_path_no_ext ... ok
test driver_manager::tests::test_disallow_env_config ... FAILED
test driver_manager::tests::test_load_relative_path ... ok
test driver_manager::tests::test_load_driver_env_multiple_paths ... ok
test driver_manager::tests::test_load_non_ascii_path ... ok
test driver_manager::tests::test_manifest_missing_driver ... ok
test driver_manager::tests::test_manifest_wrong_arch ... ok
test driver_manager::tests::test_manifest_user_config ... FAILED
test ffi::types::tests::test_error_roundtrip ... ok
test ffi::types::tests::test_partitions_roundtrip ... ok

failures:

---- driver_manager::tests::test_default_entrypoint stdout ----

thread 'driver_manager::tests::test_default_entrypoint' panicked at core\src\driver_manager.rs:1887:13:
assertion `left == right` failed
  left: "AdbcLibadbcDriverSqliteInit"
 right: "AdbcDriverSqliteInit"
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

---- driver_manager::tests::test_load_driver_env stdout ----

thread 'driver_manager::tests::test_load_driver_env' panicked at core\src\driver_manager.rs:1921:9:
assertion `left == right` failed
  left: Internal
 right: NotFound

---- driver_manager::tests::test_disallow_env_config stdout ----

thread 'driver_manager::tests::test_disallow_env_config' panicked at core\src\driver_manager.rs:1995:9:
assertion `left == right` failed
  left: Internal
 right: NotFound

---- driver_manager::tests::test_manifest_user_config stdout ----

thread 'driver_manager::tests::test_manifest_user_config' panicked at core\src\driver_manager.rs:2123:9:
assertion `left == right` failed
  left: Internal
 right: NotFound


failures:
    driver_manager::tests::test_default_entrypoint
    driver_manager::tests::test_disallow_env_config
    driver_manager::tests::test_load_driver_env
    driver_manager::tests::test_manifest_user_config

test result: FAILED. 10 passed; 4 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.21s

@eitsupi eitsupi marked this pull request as ready for review July 14, 2025 12:57
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 14, 2025

@zeroshade I was not able to fix the adbc_snowflake build error today. Also, I am currently skipping some tests of driver_manager.
Feel free to edit this PR as you did yesterday.
(However, since we are making a lot of progress compared to yesterday, I feel it is better to merge them anyway.)

@zeroshade
Copy link
Member

I agree. Let's merge what we have and then open a new PR to continue fixing the windows tests.

@zeroshade zeroshade merged commit 442dce1 into apache:main Jul 14, 2025
8 checks passed
@eitsupi eitsupi deleted the rust-ci-windows branch July 14, 2025 14:54
@eitsupi
Copy link
Contributor Author

eitsupi commented Jul 14, 2025

Thanks!

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 this pull request may close these issues.

Rust: can't build adbc_core on windows ci+rust: enable windows-latest in Rust workflow

4 participants