Repository navigation
fix: accept string Steam IDs in SDA imports - #521
Merged
Merged
Conversation
dyc3
approved these changes
Sep 22, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Session.SteamIDas either a JSON number or a quoted decimal string in SDA maFilesnullSteam IDsRoot cause
Import first attempts the current
SteamGuardAccountschema. SDA maFiles do not have its required top-levelsteam_id, so falling back to external account import is expected.The SDA fallback then deserializes
Session.SteamIDasOption<u64>.Optionsupports an absent field ornull, but Serde does not coerce the posted string value ("76561000000000000") into au64, so the SDA variant fails. The alternative Steam Mobile v2 variant also fails because it requires a top-levelsteamid. SinceExternalAccountis untagged, Serde reports only the genericdata did not match any varianterror after both variants fail. The Winauth message is from the subsequent fallback and is not the cause.The field now uses a compatibility deserializer accepting both supported SDA representations while still rejecting invalid or out-of-range values.
Verification
steamguard importwith a sanitized copy of the posted JSONcargo test -p steamguard-cli --features qrcargo fmt --all -- --checkgit diff --checkCloses #520
GPT Sol(free via Pullfrog for OSS) | 𝕏