Remove SteamKit2 in favor of steamcmd - #267
Open
JantsoP wants to merge 1 commit into
Open
Conversation
This will completely remove SteamKit2 hacks in favor of official steamcmd with way faster downloads and able to download multiple mods at the same time.
|
Collaborator
|
It might take a bit of time for this to be gone through due to how busy I know @Foxlider is and ive been pretty busy lately as well. Really appreciate the PR. Ive change your push branch to update as it won't go straight to master. Make sure you have a read of the contributing file. |
Author
|
I have tested this on my machine and the migration was flawless. I had 97 out of 126 mods which were not loaded. With current version, it would take me hours to download them all. Now it took few minutes (fast internet and all) |
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.




Remove SteamKit2 in favor of official SteamCMD
Description
Removes the
BytexDigital.Steamgit submodule and all SteamKit2-baseddownload/update logic, replacing it with a first-party
SteamCmdservicelayer (
FASTER/Services/SteamCmd/) that drives Valve's realsteamcmd.exethrough the native Windows pseudoconsole (ConPTY) and parses its console
output into structured events.
Key changes:
SteamCmdInstallerbootstraps/updates SteamCMD automatically if it'smissing from the configured path — no manual setup required.
SteamCmdSession/SteamCmdPseudoConsolehost a long-lived SteamCMDprocess and stream its stdout/stdin through ConPTY, since SteamCMD requires
a real console to prompt for passwords/Steam Guard.
SteamCmdOutputParserincrementally turns SteamCMD's raw console textinto typed events (login prompts, Steam Guard/mobile confirmation prompts,
per-item download progress, success/failure, app update percentages, etc.),
redacting secrets from anything it emits.
SteamCmdClientexposesDownloadWorkshopItemsAsyncandUpdateServerAsync, and downloads multiple Workshop items in a singleSteamCMD session instead of one process per mod.
WorkshopContentMirrorcopies each completed SteamCMD Workshopdownload into FASTER's mod staging directory and atomically swaps it in,
so an interrupted copy never leaves a half-updated mod.
SteamUpdaterViewModelrewritten around the new client: retries failedWorkshop items, supports Steam Guard/mobile-approval prompts via dialog,
reports live download/update percentages to the progress bar, and now
writes a detailed, timestamped SteamCMD session log to
%LocalAppData%\FASTER\Logs\SteamCmd.logfor troubleshooting withoutflooding the on-screen console.
SteamWebApi's download/auth responsibilities — the Web API keyis now optional and only used for Workshop metadata/update-timestamp
lookups, not authentication.
setting and login flow.
for ConPTY) and a full explanation of the SteamCMD update workflow.
Motivation and Context
The previous SteamKit2 (
BytexDigital.Steam) integration required workaroundsto authenticate and pull Workshop content, downloaded mods one at a time, and
was fragile around Steam Guard/2FA flows. Valve's own
steamcmd.exeis theofficially supported way to automate Steam/Workshop operations, downloads
multiple Workshop items in one session, and is noticeably faster in practice.
This also drops an entire external git submodule dependency, simplifying the
build and reducing maintenance surface.
How Has This Been Tested?
SteamCmdCommandBuilderTests,SteamCmdOutputParserTests(parsing prompts, Steam Guard/mobile confirmation, workshop success/failure,
progress lines, secret redaction),
SteamCmdClientTests, andWorkshopContentMirrorTests.SteamCmdLiveSmokeTests([Category("SteamCmdLive")])that exercises a real SteamCMD handshake up to the authenticated
server-update prompt; skipped unless
FASTER_STEAMCMD_SMOKE_ROOTis set,so it doesn't run in normal CI.
publish, ran a real Arma 3 dedicated server update (
Publicbranch) throughthe app, confirmed cached-login authentication, live progress bar updates
matching SteamCMD's reported percentages, and a clean
"Arma 3 Dedicated Server update completed" result — cross-checked line by
line against the new
SteamCmd.logoutput.each mod correctly.
Types of changes
This removes the
BytexDigital.Steamsubmodule and changes how Workshopdownloads authenticate (a real Steam account is now required instead of
relying solely on a Web API key), so existing users need to reconfigure
their SteamCMD path/Steam login on first run after upgrading.
Checklist: