Releases: 3urobeat/steam-comment-service-bot
Releases · 3urobeat/steam-comment-service-bot
Version 2.13.3
Additions:
- Added library patch for my SteamCommunity PR to fix resolving private profile of sharedfile owner returning an error
Fixes:
- Fixed commenting on sharedfiles associated to private profiles, see above
Changes:
- Reworked getting missing app licenses to reduce memory consumption. This also fixes a small memory leak.
- Removed now unused clearPicsCache() library patch
- Removed vanity resolving fix library patch as my PR to the SteamCommunity library got merged
- Updated dependencies
Version 2.13.2
This is a hotfix update for 2.13.1, please read the release notes of that update as well.
Fixes:
- Fixed links as command parameters being recognized as invalid, caused by embed junk inside the received message
Version 2.13.1
Changes of note (TL;DR):
- Greatly reduced memory consumption by clearing picsCache after using it once on ready
- Greatly reduced size of node_modules folder
- Fixed tons of logger issues
- Added a !joingroup command
Additions:
- Added a !joingroup command
- Added support for adding new bot accounts at runtime to login()
- Added a wiki page for creating plugins
- Added library patches for my steam-user clearPicsCache() PR and steamcommunity vanity resolving fix PR
Fixes:
- Fixed tons of logger issues and improved its memory consumption
- Fixed cache of plugins not being cleared correctly when running !reload
- Fixed msg hold back check throwing error when logging non-string
- Fixed bot sending unprocessed response when requesting only 1 comment
- (Hopefully) fixed any "Already logged on" errors when login times out while waiting for
loggedOn
event - Fixed Steam Chat send message handler retrying failed messages for bot accounts that are offline
Changes:
- Greatly reduced the child process's memory consumption by clearing picsCache after using it once
- Increased the memory limit of the child process to 2 GB and enabled the Garbage Collector's
optimize-for-size
option - Greatly reduced the size of the
node_modules
folder by using the npm--production
flag when automatically installing dependencies - Shipping disabled webserver config for new users now
- ASCII Art and login summary on ready event are now being cut to the current terminal width
- Reworked !leavegroup command to use handleSteamIdResolving helper
- Moved the Wiki from GitHub to the git repository
- Reworked and improved wiki pages, especially the changelogs
- Updated library patches as my sharedfiles PR to the SteamCommunity library got accepted
- Updated usage of deprecated friendMessage event
- Updated dependencies
Version 2.13.0
Changes of note (TL;DR):
- Added new commands: !upvote, !downvote, !favorite, !unfavorite, !reload
- Added support for commenting on sharefiles (screenshots, artworks & guides)
- Added a completely new plugin system, command handler system and improved the data management system
- Greatly improved handling of long and failed steam chat messages
- Reworked the whole application for better code quality and expansibility
- Added some miscellaneous new features, for example a progress bar during startup, owners not friend with main account check and warning counter
- Fixed a lot of bugs
If you are using a customlang.json
, make sure to read the language string changes at the end and update your file.
Additions:
- Added new commands: !upvote, !downvote, !favorite, !unfavorite, !reload
- Added support for commenting, voting & favorizing sharedfiles by updating !comment and adding two new commands as mentioned above!
- Added a library patches system to load my changes until my PR to the SteamCommunity library gets accepted
- Added support for figuring out sharedfile IDs to the handleSteamIdResolving() helper
- Added a ratingHistory database to track which bot accounts have voted on or favorized which item
- Added a completely new plugin system, co-author @DerDeathraven #174
- Added a plugin loader which dynamically loads all installed npm packages with the prefix
steam-comment-bot-
@DerDeathraven #174 - Added new template plugin which you can fork here to create your own plugin
- Added plugin functions:
load
,ready
,statusUpdate
,steamGuardInput
- Added plugin data directory and functions to handle data reading & writing:
getPluginDataPath
,loadPluginData
,writePluginData
,loadPluginConfig
,writePluginConfig
- Added a reload system to apply changes at runtime for development using command !reload
- Added a plugin loader which dynamically loads all installed npm packages with the prefix
- Added a separate data management system
- Added dataProcessing helper to handle converting group & ownerids
- Added support for repairing
defaultlang.json
andquotes.txt
- Added a handleCooldown helper
- Added warning for long language strings
- Added a Controller event system
- Added events:
ready
,statusUpdate
,steamGuardInput
- steamGuardInput event allows plugins to submit steam guard codes as well
- Added events:
- Added a command handler system
- Added
restrictAdditionalCommandsToOwners
setting toadvancedconfig.json
to restrict specific commands to owners only. Supports aliases. - Added system for dynamically loading core commands on start
- Added functions for registering & unregistering commands at runtime
- Added a reload system to apply changes at runtime for development using command !reload
- Added a respond module system that supports the usage of core commands from different sources. Callers can supply this information to the
resInfo
object:steamID64
,prefix
,cmdprefix
,charLimit
,cutChars
- Command prefixes are now replaced dynamically in language strings, based on the
cmdprefix
value inresInfo
. If omitted, the default prefix "!" will be used - Steam Chat message prefixes are now added dynamically based on the
prefix
value inresInfo
- Added
- Added a proper steam chat message handler
- Send long log messages in intelligently cut parts to not break links etc.
- Retry failed messages with increasing delay and ignore them on certain errors
- Added a typing indicator when the bot is waiting for the next msg part to be sent
- Added a readChatInput helper function to get user input from the steam chat
- Added algorithm for handling tokens that either expire soon or are already expired
- Added proxy support to the sessionHandler
- Added an EStatus enum for storing the online status of every bot account
- Added more misc helpers and referenced them from Controller
- Added getAvailableAccounts(), timeToString() and cutStringsIntelligently() helper
- Added support for forcing an update from a compatibility feature
- Added support for accepting logins from the Mobile Steam App
- Added support for setting a primary group by loading a patch until my PR to the SteamCommunity library gets accepted
- Added support for requesting free games licenses for missing games set in config.json. This also adds a listener for the SteamUser ownershipCached event
- Added Controller restart() & stop() functions to replace all manual process.send()'s
- Added Controller getBots() helper function to easily get bot accounts filtered by status
- Added proper JsDoc documentation for every function & object for full IntelliSense support and generated
d.ts
file for TypeScript support - Added a different finished message sent to users when their request was aborted
- Added a different message sent to users if either not enough unlimited accounts are found for a request or the bot has none at all
- Added check with warning message on ready for owners who are not friend with the main bot account
- Added a fancy progress bar to startup, powered by my output-logger library
- Added startup warnings counter with log message on ready
- Added compatibility feature for update from 2.12 to 2.13
Reworks:
- Reworked basically the whole application to follow a proper object oriented approach
- Reworked login function to wait for last user object to populate before calling ready event
- Reworked comment cmd to support profiles, groups and sharedfiles from the same command instead of 3
- Reworked comment cmd to work with the new OOP structure and reduced complexity
- Reworked comment error handler
- Reworked lots of messages and comment cmd references to be applicable to other request types as well
- Reworked retry comments algorithm to work with the new OOP structure
- Reworked how references to bot accounts are stored
- Reworked how imported logininfo data is formatted & stored
- Reworked checkAvailability & getAccountOrder helpers with a better getAvailableAccounts helper
- Reworked getCommentArgs to work with new OOP structure
- Reworked logger to work with the new OOP structure
- Reworked friendlist helper to work with the new OOP structure
- Reworked checkMsgBlock helper to the new OOP structure
- Reworked message prefixes to be prepended dynamically instead of being hardcoded to support different message destinations (e.g. a Discord plugin)
- Reworked the existing webserver plugin to work with the new OOP structure
- Simplified skippedaccounts system
- Simplified proxy index calculation for all bot accounts
- Simplified waitTime & commentCounter calculation
- Improved !failed command to group the same request errors together
- Improved login function to handle filtering and relogging
- Improved log footprint of updater
- Improved error messages when file can't be restored and make sure to stop the bot
- Updated error & disconnect events to work with the improved login function
- Updated sessionHandler to work with the new OOP structure
- Updated handleLoginTimeout() to work with the new OOP structure
- Updated the updater itself and its prepareUpdate(), createBackup(), customUpdateRules(), downloadUpdate() and restoreBackup() helpers to work with the new OOP structure
- Updated all compatibility features to work with the new OOP structure
- Updated various core commands to work with the new OOP structure
- Replaced activecommentprocess object with an activeRequests object that supports other request types as well
- Removed additionalaccinfo obj and replaced usage with new system
- Converted all event listeners to use OOP structure
Fixes:
- Fixed the webserver plugin from being completely broken #172
- Fixed return parameters of checkConnection
- Fixed webSession looping caused by broken botsgroup check
- Fixed accounts.txt import still checking for loginfo.json
- Fixed limited check sometimes failing because user object was not fully populated instantly after login
- Fixed login function not waiting correctly between accounts
- Fixed botIsReady not being updated when logAfterReady is empty
- Fixed singular comment requests not being handled correctly
- Fixed first comment process iteration being counted in until calculation
- Fixed possible inconsistencies in comment error checks by forcing them to lowercase
- Fixed relog on error not using advancedconfig relogTimeout
- Fixed duplicate SessionHandler object being created on relogs
- Fixed prepareUpdate() response message sometimes failing by increasing log off delay
- Fixed bot softlocking on start when ownerids array is empty
- Fixed !help and !info commands inflating message length with unnecessary whitespaces
- Fixed error on update when certain data.json keys were missing
- Fixed friendlist checks failing when accounts were skipped
- Fixed cooldown issues when cooldown is disabled and process got aborted
- Fixed a data check error on broken internet connection by checking it beforehand
- Fixed handleLoginTimeout causing a DuplicateRequest error on 2FA input
- Fixed output-logger causing crash when running bot with pm2 #48
- Fixed potential bug where whenAvailableStr in comment command could display wrong information if allAccounts was empty or if more accounts got removed after the activeRequests loop ran 9e6c569
- Fixed/Removed minor unnecessary checks in comment command
- Fixed user added while offline message being able to fail because it was sent too early after logging in
Changes:
- Removed support for the old login flow: f5957bb
- Removed v2.13 login flow change notification message
- Removed
disableCommentCmd
setting fromadvancedconfig.json
and replaced it withrestrictAdditionalCommandsToOwners
array - Re...
Version 2.12.5
Additions:
- Added force-unfriend system to always keep 1 slot free on the friendlist of every bot account
- Added automatic compatibility finding & running system
- Added comments request amount
max
as alias for keywordall
- Added info message on config import error should firststart be true to explain new users what happened
- Friend messages from blocked users will now be logged with logtype DEBUG
Fixes:
- Fixed unfriend messages missing from lang file
Changes:
- Edited chat message error message to be more concise
- Edited login flow change msg to warning and send it via steam chat
- Optimized accsToAdd message constructor by using the cachefile botaccid array instead of creating a new SteamID obj for every account
- Moved friendMessage event block checks to a dedicated helper
- Shortened data import section in
controller.js
- Updated
steam-session
to v1.1.0
Version 2.12.4
Fixes:
- Fixed bot asking for steam guard code even for accounts with a shared_secret #152
Changes:
- Updated dependency
steam-session
Version 2.12.3
Version 2.12.2
Additions:
- Added a login timeout detection system that force-progresses the relogQueue to prevent the bot from soft-locking (#139)
Fixes:
- Fixed sessionHandler throwing an cancelLoginAttempt() error when skipping steamGuardCode
- Fixed ready check not working when an account was skipped
- Fixed error on cache refresh when an account was skipped
- Fixed relog retry on relog error not working
- Fixed relogAccount not countring logOnTries correctly, resulting in endless relog retries
- Fixed relog skip not removing account from relogQueue
- Fixed skipped accounts after relog being selected for comment requests, leading to comment failures
Changes:
- Chat messages sent by the bot will now always be logged (cut down version)
- Ready check will now be attached only on the last login iteration to improve performance a bit
- Account that encounters the "impossible 2fa code error message" in sessionHandler will now be skipped to prevent soft-lock
- Accounts disconnecting because of LogOnSessionReplaced are now skipped correctly
- Failed to send chat msg fallback msg will now be sent after 5 seconds instead of instantly to prevent further rate limiting
- Updated dependencies
Version 2.12.1
Additions:
- Added support for Steam's new token based login flow with a new sessionHandler module powered by node-steam-session
- Added a token storage system with invalid token checking and cleanup
- Added a token expiring in <=7 days warning system (runs every 24h) which also allows the user to directly refresh the tokens of all bot accounts while the application is running (requires a relog)
- Added compatibility system between old and new login flow to make auto updating possible
- Added info message about new login flow
- Added more debug log messages
- Added instructions comment to proxies.txt to improve first time user experience
Fixes:
- Fixed steamID related errors in ready.js by making sure bot object is populated before proceeding (#135)
- Fixed relogInterval from being able to be set multiple times
- Fixed disconnected event trying to initiate a relog for accounts which are already in the relogQueue
- Fixed an error when accounts.txt or proxies.txt was completely empty (even missing the comment)
- Fixed an error when activecommentprocess entry was deleted by updater or handleExpiringTokens.js while comment module was busy handling an aborted comment process
- Fixed bot not responding to comment command when no arguments were provided
- Fixed a lot of spelling mistakes
Changes:
- Removed steam-user's steamGuard event which is now unused as the sessionHandler handles 2FA
- Exchanged all numeric enums with text enums to avoid issues should they change
- Removed logininfo.json from default files and focused documentation and comments more on accounts.txt to improve first time user experience (logininfo.json is still supported!)
- Removed old unused 2.10 -> 2.11 compatibility files (not compatibility features but files that were required because of hard coded file paths)
- Prioritized logininfo empty check over config checks to make the user focus on the more important error
- Added printNow parameter to logger, making readyafterlogs detection less wonky
- Added eslint code styling rules and enforced them (massive commit)
- Updated dependencies
Version 2.12.0
Additions:
- Added advancedconfig.json with lots of options
- Added basic plugin support
- Added a retryComments system that can automatically retry failed comments (#104)
- Added steamid-resolver support to !comment, !groupcomment, !abort, !failed, !rc, !addfriend, !unfriend, !block and !unblock commands so that you can now specify profile links as well and the bot automatically converts them to IDs
- Added !sessions and !mysessions command to view all active comment sessions and their status (owner only) as well as only sessions for your profile (all users)
- Added debug messages that can be enabled in the advancedconfig
- Added a create and restore backup system that is executed by updater
- Added module to convert ownerids to steamID64s to improve amount of accepted formats in config and increase ease of setup
- Added support for setting primaryGroup (sadly currently disabled by node-steamcommunity)
- Added useLocalIP setting to disable usage of your own IP in proxy system
- Added more default quotes
Reworks:
- Reworked profile- and groupcomment command files by splitting it up into modules and reworking loop
- Renamed cmisc.js file to commentmisc.js
- Renamed globalcommentcooldown value in config to botaccountcooldown
- Removed allowcommentcmdusage value from config as it is now controlled by maxComments
- Removed differentiation between error on first comment iteration and another, which was a relic from older versions and is now more of an inconvenience
- Removed a default quote that was >1000 chars, leading to error
Fixes:
- Fixed trailing slash in config owner & group urls causing a profile not found error in my node-steamid-resolver library (#119)
- Fixed proxy index in login error message being undefined, relog message showing wrong proxy index and removed error enum from relog error message as it was undefined
- Fixed unfriend check running even when unfriendtime is set to 0 (#124)
- Fixed chat messages failing when >1000 chars by cutting them and sending users a fallback message if Steam blocked a message (#125)
- Fixed config owner /profiles/ URL not being accepted
- Fixed multiple useradded messages from main bot when adding x child accounts while bot was offline
- Fixed typo leading to unfriendall cmd not working
- Fixed auth code not getting regenerated on relog if user provided shared_secret in logininfo, leading to invalid steam guard code and relog failing
- Fixed numberOfComments not provided check not checking correctly
- Fixed finished message being sent again when all proxies failed message had already been sent
- Fixed getQuote helper being able to return all quotes as array at once, leading to >1000 chars error
- Fixed group invites handling when acceptgroupinvites is disabled not working as expected
- Fixed botsgroup auto join feature not working and moved it to webSession event handler
- Fixed command spam protection not working
- Fixed webSession event handler constantly re-running when no botsgroup was set (caused by botsgroup checker)
- (Hopefully) fixed encryption error disconnect leading to relog breaking with steam-user update. Forum Thread
Changes:
- Improved accountOrder algorithm, it will now prioritize bot accounts the user is already friend with to avoid repeating friend request messages
- Using !unfriend command without providing profileid now unfriends the message sender with all bot accounts
- Drastically reduced the amount of log messages (especially on startup) and improved behaviour of log lib in stdout
- Changed order of called modules in controller.js to make more sense
- Changed update from chat instructions when automatic updater is turned off
- Moved webserver to a plugin that is shipped by default
- Delayed updater to make sure accounts log off loop has finished
- Ready message now shows project name instead of bot0 username
- Hiding "Deleting node_modules folder content" message in npminteraction helper when folder was created a second earlier to reduce possible confusion
- The bot now checks if the id of a bot account matches with an owner link/id in config and displays a warning
- Improved checkAndGetFile() to handle error on require and checking controller.js as well
- Improved code quality by changing many callbacks to promises (no more callback hell in controller.js hurray!), splitting more stuff up into modules and letting the logging lib handle reading input from stdin instead of doing it myself
- Reduced RAM usage (steam-user update)
- Improved startup time by a few seconds
- Fixed a few ascii art issues and added some more arts
- Updated dependencies
- Improved and refreshed README