Skip to content

6.0: allow expect in webauthn-authenticator-rs, and in all tests#540

Merged
Firstyear merged 1 commit intokanidm:6.0-dev-drop-opensslfrom
micolous:6.0-clippy-expect
Feb 17, 2026
Merged

6.0: allow expect in webauthn-authenticator-rs, and in all tests#540
Firstyear merged 1 commit intokanidm:6.0-dev-drop-opensslfrom
micolous:6.0-clippy-expect

Conversation

@micolous
Copy link
Copy Markdown
Collaborator

The master branch currently allows expect() to be used anywhere, but the 6.0 branch doesn't.

In the longer term, we should fix these.

But denying expect() currently triggers CI build failures with certain features enabled (cable, mozilla, softtoken, ui-cli, win10), which aren't enabled by default.

Some of these uses will be addressed as we rewrite to drop OpenSSL support for #499, but with clippy being an early step in CI, additional failures make it impossible to measure progress using the CI build matrix (ie: feature combinations becoming or returning to green).

I've also allowed expect() in tests, like unwrap() is allowed. Using expect() or unwrap() gives us stack traces for unexpected errors in tests, so it's much easier to trace how a test broke.

This takes us from 11/35 to 19/35 passing tests.

  • cargo test has been run and passes
  • documentation has been updated with relevant examples (if relevant)

@micolous micolous added the openssl removal OpenSSL removal project (#499) label Feb 16, 2026
@micolous micolous mentioned this pull request Feb 16, 2026
40 tasks
@yaleman
Copy link
Copy Markdown
Member

yaleman commented Feb 16, 2026

How many uses of expect are there in the non-test code? normally we just allow-list them on a case-by-case basis to indicate it's been checked etc.

Test code it's fine to use, since it gives feedback unlike unwrap 😄

Copy link
Copy Markdown
Member

@Firstyear Firstyear left a comment

Choose a reason for hiding this comment

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

Yep, this is fine shortterm.

@Firstyear Firstyear merged commit 7e74fb6 into kanidm:6.0-dev-drop-openssl Feb 17, 2026
19 of 35 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

openssl removal OpenSSL removal project (#499)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants