Skip to content

Fix deserialization of AuthenticationMethod#6

Merged
paolobarbolini merged 2 commits into
M4SS-Code:mainfrom
dodomorandi:fix-authentication-method-none
Apr 30, 2026
Merged

Fix deserialization of AuthenticationMethod#6
paolobarbolini merged 2 commits into
M4SS-Code:mainfrom
dodomorandi:fix-authentication-method-none

Conversation

@dodomorandi
Copy link
Copy Markdown
Contributor

If no authentication methods are provided, serde should create an AuthenticationMethod::None variant. However, in order to do so, the representation of the variant should be None {} instead of None.

Added a bunch of regression tests for the deserialization of FromEnv to prevent regressions.

@dodomorandi
Copy link
Copy Markdown
Contributor Author

We have an unrelated cargo-deny failure in the CI.

@paolobarbolini
Copy link
Copy Markdown
Member

Fixed on main

`serde` triggers an error if none of the fields in the other variants
are found, it does not like the _stateless variant form_.
To avoid analogous problems in the future.
@dodomorandi dodomorandi force-pushed the fix-authentication-method-none branch from 12bf2b6 to 9a4dd7b Compare April 30, 2026 15:37
@paolobarbolini paolobarbolini merged commit 8d8f3c8 into M4SS-Code:main Apr 30, 2026
8 checks passed
@dodomorandi dodomorandi deleted the fix-authentication-method-none branch April 30, 2026 15:40
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.

2 participants