Skip to content

Evergreen#2012

Open
rozza wants to merge 6 commits into
mongodb:mainfrom
rozza:evergreen
Open

Evergreen#2012
rozza wants to merge 6 commits into
mongodb:mainfrom
rozza:evergreen

Conversation

@rozza

@rozza rozza commented Jul 9, 2026

Copy link
Copy Markdown
Member

Various build fixes for evergreen.

  1. GPG path handling - windows builds.
  2. 8.2 fix MQL asString version - windows builds (the only tests run against 8.2 MongoDB)
  3. Added a default OS - OIDC failure and Publish Snapshots
  4. Updated Sync shutdown hook - Caused Netty failures.

rozza added 4 commits July 9, 2026 09:41
The gpg on the Evergreen Windows hosts is a Cygwin build that only
understands POSIX paths. Handed native Windows paths (C:\dir) it treats
them as relative, mangles the keyring location, and fails to find a
writable keyring. Translate drive-letter paths to the Cygwin form
(C:\dir -> /cygdrive/c/dir) on Windows for every gpg path argument
(homedir, public key, signatures, tarballs); other platforms are
unchanged.

Also surface gpg stdout/stderr and the gnupgHome/publicKey state on
failure so future gpg issues are diagnosable instead of showing only
Gradle's opaque non-zero exit value.
Should fix publishing of snapshots.

JAVA-6057
Brings it inline with the reactive streams shutdown hook.
Ensures tests don't fail on shutdown with a DatabaseDropPending exception
@rozza

rozza commented Jul 9, 2026

Copy link
Copy Markdown
Member Author

@rozza rozza marked this pull request as ready for review July 9, 2026 12:44
@rozza rozza requested a review from a team as a code owner July 9, 2026 12:44
@rozza rozza requested review from nhachicha and vbabanin July 9, 2026 12:44
Comment thread mongodb-crypt/build.gradle.kts

// Run gpg capturing both streams; on non-zero exit throw with the captured output appended so the
// underlying gpg diagnostic is visible instead of Gradle's opaque "finished with non-zero exit value N".
fun runGpg(vararg args: String, onFailure: (String) -> String) {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice 👍

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR applies a set of Evergreen/CI robustness fixes, primarily targeting Windows-host differences (GPG path semantics and environment detection) and reducing shutdown-time test flakiness, while also adjusting MQL asString functional tests to align with server-version behavior.

Changes:

  • Update mongodb-crypt tarball signature verification to translate Windows paths for Cygwin gpg and improve error diagnostics.
  • Adjust MQL asString nested conversion tests to use 8.3 as the version boundary.
  • Harden Evergreen environment setup and sync test shutdown cleanup to avoid failures from missing env vars / shutdown-time exceptions.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
mongodb-crypt/build.gradle.kts Adds Windows/Cygwin-aware GPG path translation and improved GPG exec diagnostics for libmongocrypt signature verification.
driver-sync/src/test/functional/com/mongodb/client/Fixture.java Wraps shutdown-hook database drop in a try/catch to prevent shutdown-time failures.
driver-core/src/test/functional/com/mongodb/client/model/mql/TypeMqlValuesFunctionalTest.java Shifts asString nested test gating from 8.2 to 8.3 to match server behavior.
.evergreen/setup-env.bash Defaults OS when unset to avoid set -u unbound variable failures, improving cross-platform behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread mongodb-crypt/build.gradle.kts Outdated
@rozza

rozza commented Jul 9, 2026

Copy link
Copy Markdown
Member Author

FYI A number of tests (timing related) seem to be struggling with windows. Reviewing.

rozza and others added 2 commits July 9, 2026 15:52
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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.

3 participants