Added:
ban-enforce.pyto kick people that match a new ban mask- MLOCK-like functionality in
channel_op.py - Channels can be opted out of inactivity pruning
- Optional to disable youtubeifying
!npoutput - Allow RSS requests to bind to specific source addresses
!wordsin PMyourls.pyfor yourl url shortners- handle
RPL_VISIBLEHOST
Changed:
ERR_LINKCHANNEL(470) now removes the initial channel from autojoin- (IRCv3)
+draft/typingwas ratified - We're no longer supporting a specific broken charybdis install, for line length calculations
- Much better line truncation
- Handle HTTP redirects ourselves, to avoid redirects on to forbidden hosts
Fixed:
- All bot.conf paths should have ~/{DATA} expanded
host-metaURL for fediverse accounts should be optional - fallback to default webfinger- Message filter
m/criterias should operate on formatting-stripped lines - Quote
!grabs were wiping the user's category - Quote
!quotedels were looking at the wrong categories !wordswas squashing results in to a dict, losing days- INVEX and EXCEPT lists were looking at the wrong index for masks
Added:
- Commands Specs. expression language for defining format of command args
.bitbot/mod-data/for addition data files for modules- Concept of core vs additional modules. Core modules can be reloaded but not unloaded
channel_accessgroups:low/high/admin- Proof of concept reminders on a cron schedule (
cron_reminders.py) - Show how many seconds by which you missed a duck (
ducks.py) - Show gitlab wiki events (
git_webhooks) - Opt-in prune inactive channels after 2 weeks (
inactive_channels.py) - Ability to export decorated functions with @utils.export
- Configrable chance of randomly triggered markovs (
markov.py) - Ability to rewrite messages as well as block them (
message_filters.py) - Ability to search through recent messages (
messages.py) rainbow.pybecause rainbow text is fun- Track time/commit of load and events handled per module and show it through
!modinfo(modules.py) - Support ranges in stepped cron schedules (
cron.py) - Format
ACCOUNTevents (format_activity.py) - Track channel list modes like ban, quiet, invex, ban exceptions (
mode_lists.py) - Support
WATCHwhen available fornick_regain.py
Changed:
- IRCv3's
labeled-responsewas ratified - IRCv3's
setnamewas ratified channel_lognow logs to.bitbot/mod-data/channel_log/channel_logcan now RSA+AES(CBC) encrypt log files- Word tracking is now done per day. use
migration/v01.19.0-words.pyto migrate old data - Totally rewrote
badges.pycommand interface - Huge refactor and rework of
channel_op.py- most commands can take duration and globs now - Improve
factoids.py(including nested factoids) - Split out
src/utils/datetime.py - Show github webhook issue/PR titles in more places (
git_webhooks) - Show google result descriptions instead of title when available (
google.py) - Minimal formatted lines should be relayed (
relay.py) - Totally rewrote
todo.pycommand interface IRCBuffernow holds 1024 lines of history (was 64; 1024 might be overkill...)- Reloaded modules will always be rolled back to previous loaded module if reload fails
- Generate usage from command spec stings when present (
help.py) - Much cleaner support for handling server
NOTICEs (line_handler) to_pretty_timecan now do relative time (e.g. including years and months)- Souped HTTP responses changed from
lxmlparsing tohtml5libby default - Bool config options now accept 0 and 1
Fixed:
- Readded lost support for SASL
USERPASSpseudo algo (ircv3_sasl) - Minor typo in
healthchecks.py - Minor typo in
votes.py - Crash caused by division by zero in
title.pydifference checking internal.identifiedcommand was being fired for every message with an@accounttag (permissions)
Changed:
- Colourise server address in
server-noticeformatting (format_activity.py)
Fixed:
uservariable doesn't exist inINVITEformatting code (format_activity.py)IRCBuffer.Buffer.find()'snot_patternarg should be optionalutils.datetime.iso8601_parseno longer has amicrosecondsarg (youtube.py)
Fixed:
- Formatting variable typo for handling TOPIC (
format_activity.py)
Added:
- New dependency in
requirements.txt:dateutils - Show
transferredgithub issues by default (git_webhooks) hostmask-tracking.py- keep a history of what hostmasks each nickname has used- Also watch
NICKandQUITlines to see when our nickname might be freee (nick_regain.py) - IRCv3
draft/deleteimplementation (ircv3_editmsg.py) - Show account and realname in
JOINformattin when available (format_activity.py)
Changed:
- Removed
--data-dir,--databaseand--log-dir, these options have been moved tobot.conf - Reworded karma change output
!grabnot tries to attach quote to account, not just nickname (quotes.py)!wordiestnot defaults to the current channel (words.py)!partnow works for+ousers or users with channel_accesspart(admin.py)
Fixed:
- cron would fail to initialise at 59 minutes past the hour (
core_modules/cron.py) - Don't send typing notications by default for pattern-based commands
- Regex error when replacement starts with a number (
sed.py) - Reimplement lost IRCv3
account-tagfunctionality (permissions) - Show username when fediverse displayname is "" (
fediverse) ++asd++used to give karma to bothasd++and++asd(karma.py)
Fixed:
- Incorrect format for HTTP UserAgent (missing ")")
Fixed:
- Crash caused by switching
coins.pyto usingcronscheduling without removing timer-related code - Typo in function call name in
cron.py
Added:
- Ability to
.save()bot.conf- we now use only this for module whitelist/blacklist - A cron system (
src/core_modules/cron.py) healthcheck.py- ping a URL every 10 minutes (for uptime-tracking services)- Support
++nicknamestyle karma (karma.py) - Bot-wide aliases (
!baliasinaliases.py) - Support per-user (PM)
command-methodsetting (commands) dnsblmodule to loop up given IPv4 and IPv6 addresses in blacklists
Changed:
- "Core" modules (modules needed for base operation of bitbot) moved to
src/core_modulesand made blacklist-immune - Better parsing error for
!config u birthday(birthday.py) - Show display name, not username, when available (
fediverse.py) - By default, show
locked/unlockedgithub issue/PR events (git_webhooks) - Switch back to full wolframalpha API but use it better than we used to (
wolframalpha.py) - Hostmasks are now precompiled to find users that match them (
permissions)
Removed:
-m/-Margs tobitbotd- didn't work any more due to databse lockingdatabase_backup.py- this was always a weird hack. Added a note about backups inREADME.md
Changed:
- Response to giving karma now makes sense
Fixed:
- Typo preventing users giving karma
Added:
- Show target in formatted private
NOTICEevents (format_activity.py) - Show first 100 chars of GitHub issue comments (
git_webhooks) - Show who opened a GitHub pull request when approperiate (
git_webhooks) - Timed user ignores (
ignore.py) - Support
"$$"as"$"in command alias argument replacement (aliases.py) - Show explicitly when only a title of an issue/PR was changed (
git_webhooks) - Show URLs in
!wikipediaoutput (wikipedia.py) !rawand!performnow support "human" formats (e.g./msg user message)- Listing servers with
!servers(stats.py)
Changed:
- Complete refactor of
permissionsmodule - now with hostmask support - Big refactor of commands module
- Command aliases moved to their own module. Run
migration/v01.16.00-aliases.pyto migrate old aliases. - Karma is now stored per-user and you can give yourself karma. Run
migration/v01.16.00-karmato migrate old karma. - Unique User-Agent (
utils.http.USERAGENT) - Nickname hashed colourisation now matches weechat's default (
utils.irc) ./bitbotd -m permissions -M master-passwordmoved to./bitbotctl command master-passwordutils.http.Response.datais now alwaysbytes- use.decode()/.json()/.soup()to.py->tell.py; move!toto!tellbut add!toas an alias- Sed edits are now cumulative (
sed.py)
Added:
- Optionally colourise nicknames when printed to log (
format_activity.pyandprint_activity.py) - Show git branch in
!versionoutput (info.py) - Stop/start REST API HTTPd when trying to reload all modules (
ModuleManagerandrest_api.py) - Individual channels can opt out of printing to INFO log (
!config c print off,print_activity.py) - Opt-in shlex argument parsing for command callbacks (
commands) - Show when BitBot first saw you speak in
!wordsoutput (words.py)
Changed:
- Logging moved to
~/.bitbot/logs/by default - Better eval API for
eval_python.py(now py3 only) - Better single-line normalisation for ActivityPub Activities (
fediverse) - Better error messages shown to user when a fediverse Actor can't be found (
fediverse) - Git hashes are now truncated to 7 chars, not 8 (
git_webhooks) - Split
utils/__init__.pyout in to more separate files - Show channel mode status symbols when formatting
NOTICEs (format_activity.py) - Conbine YouTube API requests in to 1 request, rather than 3 (
youtube.py)
Fixed:
- Multiple channel keys should be expressed as comma-separated (
channel_keys.py) !duckstats <nickname>was meant to show stats for another user (ducks.py)- Fix almost completely broken 908 (
RPL_SASLMECHS) handling - Background colour formatting was being lost (
utils.irc)
Removed:
tfl.pymoved tobitbot-modules
Added:
- Add Travis config to run
mypy !cmute/!cunmuteto mute/unmute a channel (+m) (admin.py)- Support GitLab notes and confidential issues (
git_webhooks) - Strip
"'<>()from words in titles when checking difference between a<title>and URL (title.py) - Show when a youtube video was uploaded (
youtube.py) - 15 second SASL handshake timeout (
ircv3_sasl) - Ability to disable command suggestions (
command_suggestions.py) - Format/print/log
CHGHOSTevents - Show when a
!configoption has remained unchanged (config.py) - Show GMT offset in
!timeoutput (user_time.py)
Changed:
/melines are no longer added to markov chains!seenlast action (seen-info) is now per-channel, not per-network (seen.py)
Fixed:
- Rectified
src/utils/circular dependency mess - Decode fediverse data as utf8
- A bunch of typehinting errors across
src/ - Switch to
lxmlfor fediverse note parsing.html.parserwas buggy and unpredictable (fediverse)
Removed:
!timezone
Added:
setup.pybitbotctl- daemon control system through unix domain sockets- Basic GitLab webhook support in
git_webhooks - Catch
m.youtube.comURLs inauto-youtube - Support UTF8 domains by punycode (idna) encoding
!param in!fedito denote "show content-warned content"- Opt-in URL shortening for Gitea and GitLab
?channels=GET param for git_webhooks to denote what channels should show activityvotes-cast-restrictedto restrict voting to voiced-or-above users
Changed:
start.py->bitbotd- Database and config are now expected in
~/.bitbot/(unless--databaseand--configare specified) - Database backup files are now in
bot.db.{time}.backformat - Don't say a users vote was changed when it wasn't (
vote.py) - Bot will not die when there's no connected servers
- Command output will be truncated/cut at "word bounaries" (currently only space)
!reloadallmodulesandSIGUSR1will not try to reload but rollback to currently-loaded on errorIRCBot.panic()now just callssys.exit(20)instead of trying to kill event loop
Fixed:
- Any user was able to add an API KEY (missing
permissionkwarg) - Be able to
!disconnectreconnection attempts (regression,admin.py) - Strip only unknown tags from fedi
Noteactivities - not the tag content too - Don't allow users to
!bef/!trapa triggered duck before it has quacked - Don't set
locationto just a string when we decide a!weatherarg is not a nickname - We were not pulling out account ID from
WHOX(just account name) - Outdated
tornadoversion inrequirements.txt
Removed:
cve.pyEVENTS.md
Added:
- Basic lock file mechanics (
src/LockFile.py) external_modules- an arbitrary directory in which to look for moduleschannel_blacklist.py- rewriteJOINs and send instantPARTs to avoid the bot being in certain channels- Ability to specify different
channel_op.pyban-maskfor users with accounts !inviteinchannel_op.pycheck_certificate.py- warn when a client certificate is close to expiration (or already expired)- Support
$-format for alias arg replacement - means "none or all args" - Support
!config <nickname>,!config <#channel>and!config * - Support dice roll modifiers (e.g.
!roll 2d20+1-2) indice.py - Opt-out highlight prevention for
!friends/!enemiesinducks.py - Use a random delay after a duck is triggered before showing the duck (
ducks.py) !friends/!enemiesnow defaults to the current channel (ducks.py)!actionand!msginecho.pygit-show-privatechannel setting to enable showing private github/gitea webhooks!ghcommitand supportauto-githubfor@commit!which- show what module provides a command!apropos- show commands that contain a given string!tcpup- check if a givenhost:portcan receive a TCP connectionmarkov.pymumble.py- show stats for a given mumble server!grabas an alias of!quotegrab!crateinrust.py- show information on a given crate name- Support sed
&syntax - Support
"<nickname>: s/"sed syntax (search only for messages by<nickname>) !silencenow takes an optional duration parameter!unsilence!statsnot takes an optional network parameter - to show stats only for a given server!channels- list the bot's current channels on the current networkstrip_otr.py- remove trail whitespace used for automated OTR handshakes- Support disabling
words.pyword tracking for a while channel utils.deadline_process- like@utils.deadlinebut uses a subprocess- Single-line normalisation of fediverse Notes by vaguely parsing HTML
- Single-line normalisation of RSS titles
- Single-line normalisation of tweets
Changed:
- REST API only listens on localhost now, for security reasons
!changenickname->!nick!reconnectcan take an<alias>param to tell it which server to reconnect to!disconnectcan now cancel reconnectionsauto_mode.pywas replaced by!flagsinchannel_op.py!mutemasks should also take in to consideration the configuredban-mask- Obscure output of
!config server sasl channel.get_user_status()->channel.get_user_modes()!gh/!ghissue/!ghpullcan now see private repos through API keys- Allow preventing user-specified nameservers with
!dns - Update
ircv3_multiline.pytodraft/multiline - Prevent invalid SASL mechanisms
sasl-hard-failnow defaults to False- Multi-word karma now needs parentheses, along with a few other tweaks to prevent false positives
channel.topic_setteris now aHostmaskobject- Obscure output of
!config server nickserv-password !quotegrabcan take a number of lines to grabrelay-extrasdefaults toFalserest_apiresponses now use aResponseobject for complex data and headers!apikeynow has the subcommandslist,add,removeandinfoeval_rust.py->rust.py!silencenow affects command usage errors and command suggestions- Only do
auto-titleif the<title>and URL are significantly similar - Use
"#<number>"to denote!uddefinition index - Don't use an API for
user_time.py- usepytz - Support showing
!timeand!weatherfor a location, not just a user Cache.pyis now more of akey:valuestore- Temporarily cache IRCChannel settings in memory
utils.http.request()now supports a complex request objectutils.http.request()now uses more factors to detect a HTML page's encodingutils.http.is_localhost()->utils.http.host_permitted()and reject more IP ranges!editservershould work for currently-disconnected serversINFOlogging should go to a file - stdout should only beWARN
Fixed:
badges.pynow forces UTC!op/!voiceinchannel_op.pytried to usesend_mode()without array arguments!cignorewas not working for non-bot-admin users!twshould be asking fortweet_mode="extended"- Fix
server.send_invite()arg order masterloginshould only allow you to bypasspermissionchecks, not e.g.require_accessorrequire_mode
Removed:
books.pybotsnack.pycheck_urls.pymixed_unicode.py!qget- functionality moved to!quoteshakespeare.pyslowvoice.pystrax.pytimer.py
Added:
utils.IntRangeSettingrealnamewas missing from!editserver
Changed:
- Added
"- "to start of formatted kick lines - Use
"+0000"instead of"Z"for UTC timezone
Fixed:
- Put a deadline on sed matches to prevent DoS
- Duplicate
def opinchannel_op.py(due to copypaste) git-prevent-highlightwas failing to unhighlight organisations
Added:
rss.py- Show
weather.pywindspeed in MPh too git_webhooks/gitea.pyacronym.py!editserverinadmin.pychannel_keys.pyto centrally track/use channel keys!muteand!unmuteinchannel_op.pycommand_suggestions.py- appendable command prefixes
@utils.kwargfediverse.py- gitea webhooks (
git_webhooks/gitea.py) - Show available
!hashalgorithms - per-channel-per-user ignores (
ignore.py,!cignore) ircv3.py- to show ircv3 support statsisup.pykick_rejoin.py- Handle
ERR_UNAVAILRESOURCE onionoo.py(thanks @irl)ops.pyto highlight ops (opt-in)- Per-channel
perform.py(!cperform) proxy.py- Configurable URL shorteners (
shorturl.py) !unshorten(shorturl.py)slowvoice.pythrottle.py!timezone(user_time.py)- Show
!weathertarget nickname in command prefix - Parse youtube playlists (
youtube.py) utils.http.url_sanitise()utils.http.request_many()./start.py --startup-disconnects./start.py --remove-server <alias>!remindmeas an alias of!in(in.py)!sourceand!version(info.py)- Show TTL for DNS records (
ip_addresses.py) !addpoint/!rmpointas more explicit++/--for karma (karma.py)
Changed:
- Move
_check()call to event loop func - Split out github webhook functionality to
git_webhooks/github.py - Refactored @utils.export settings to be object-oriented
- Warn when channel-only/private-only is not met
8ball.py->eightball.py(can't import things that start with a digit)github.py->git_webhooks- revamp
!dnsto take optional nameserver and record typ !quotedelwithout quote removes most recent- Relays moved to relay "groups" that channels can "join" and "leave"
- Rewrote
EventManagerfor efficiency and simplicity - Moved timers/cache/etc from read loop to event loop
- Better and more exhaustive channel move tracking
- Don't silently truncate
ParsedLineat newline @utils.hook/@utils.exportnow use a single object that handles parsing!ban/!kickban/!muteduration syntax changed (channel_op.py)- Highlight spam protection logic moved to own module (
highlight_spam.py) IRCBuffer.find()returns the matched string- Positive and negative karma throttled seperately (
karma.py) - REST API now listens in IPv6 (
rest_api.py)
Fixed:
- Catch and rethrow not-found definitions in
define.py ircv3_botignore.pyevent priorityCAP DELcrash whenDELing something that was not advertisedParsedLine.format()didn't prefixsourcewith":"_write_bufferlocking to avoid race conditionCapability().copy().depends_onwas mutable to the original copy
Added:
- Outbound message filtering (
message_filter.py) - Mid-callback command permission checks ('event"check_assert"')
connected-sinceon stats endpoint- IRCv3: draft/event-playback
auto-github-cooldownto prevent duplicateauto-githubs in quick successionvote.py- IRCv3:
ircv3_botignore.pyto ignore users withinspircd.org/bot - Catch and humanify
!loadmodule"not found" exception - cross-channel/network relay (
relay.py) - Option to allow anyone to
!startvote - IRCv3: CAP dependency system
- IRCv3: labeled-response + echo-message to correlate echos to sends
deferred_read.py
Changed:
- Only strip 2 characters (
++or--) from the end of karma - Track CHANMODE type B, C and D (not just type D)
- 'x saved a duck' -> 'x befriended a duck'
- IRCv3: CAP REQ streamline for modules
- IRCv3: SASL failure defaults to being "hard" (disconnect/crash)
auto-title,auto-youtube,auto-imguretc now work in/me- Move truncation logic from
SentLinetoParsedLine - Move
!helplogic to it's own file and rework it to be more user friendly - Get
"city, state, country"from geocoding inlocation.py, use inweather.py - Convert IRC glob to regex, instead of using fnmatch
EventManagercalls can only come from the main thread- IRCv3:
labeled-responsenow depends onbatch format_activity.pynow only shows highest channel access symbol
Fixed:
KeyErrorwhen stsportkey not present- lxml wasn't in requirements.txt but it should have been
- Any CRITICAL in read/write thread now kills the main thread too
Database.ChannelSettings.findinvalid SQLbirthday.py's year no longer .lstrip("0")ed- IRCv3: pay attention to our own msgids (
ircv3_msgid.py) - catch and WARN when trying to remove a self-mode we didn't know we had
until_read_timeout->until_read_timeout()PROTOCTL NAMESXshould have been send_raw() not send()- IRCv3: handle
CAP ACK -<cap> - IRCv3: handle
CAP ACKin response toCAP REQthat came from outsideircv3.py
Removed:
!set/!channelset/!serverset/!botset(replaced with!config)bytes-read-per-secondandbytes-written-per-secondfrom stats endpointupc.py
Added:
- Show seconds it took to !bef/!trap
Changed:
- IRCv3:
draft/resume-0.4->draft/resume-0.5
Fixed:
- Fix scenario in which some-but-not-all threads die
- Daemonify tweet thread
- Don't add TAGMSGs to IRCBuffer objects
Fixed:
- Fix ERROR on
CAP NEWcaused by STS typo - Fix hanging on
CAP NEWdue to duplicateREQ - STATUSMSG stripping should only be STATUSMSG symbols, not all PREFIX symbols
Added:
- IRCv3: Also look at CTCP events for msgids
- Sub-event system within all SentLines
- Show last action in
!seen(e.g. 'seen 1m ago ( hi)') - WARN when labels are not responded to in a timely fashion
- IRCv3: send
+draft/typingwhile processing commands - Display github
ready_for_reviewbetter - Parse 221 (RPL_UMODEIS) numerics
Changed:
!npagainst a known nickname will attempt to resolve to lastfm usernamePINGandPONGnow avoid write throttling!bang->!trap, 'shot' -> 'trapped' for ducks- Socket reads and socket writes have been moved on to seperate threads
- Use Deques for chat history (more performant!)
Fixed:
- Differentiate between send and received CTCP events
IRCSocket._sendwill now only return lines that definitely hit the wire- GitHub
commit_commentevent formatting exception - Strip xref tags from
!defineoutput check_purge()after removing contextual hooks from an EventHook- IRCv3: Escape message tag values
Added:
- Module dependency system
- Enable TCP keepalives
- IRCv3:
draft/labeltracking on every sent line when CAPs permit - Enforce Python version 3.6.0 or later
- 'module-whitelist'/'module-blacklist' in
bot.conf
Changed:
- IRCv3: Use last
server-timeforRESUME- not last .recv() time - IRCv3:
draft/labeled-response->draft/labeled-response-0.2 - IRCv3: Prune already-seen messages in
chathistorybatches - Consolidate
PRIVMSG,NOTICEandTAGMSGhandlers in to one
Fixed
- GitHub highlight prevention - don't detect highlights mid-word
- Pass already-decoded data in to BeautifulSoup
- !enablemodule actually removes module from blacklist setting
- Only enact write throttling when immediate-write-buffer is empty
- Non-throttled lines no longer delay throttled lines
Fixed:
- Fix crash caused by CAP NEW
Added:
- Add !addserver
- Add !masterpassword
- Add auto-tweet setting
- Support triggering commands by regex
Changed:
- Show usage examples for user/channel/server/bot settings
- Strip common command prefixes from PM commands so "!help" works
- Change auto-github to work for github urls too
- IRCv3: draft/resume-0.3 -> draft/resume-0.4
- Remove
ipv4server attribute - figure it out automatically
Fixed:
- Typos/bugs in BATCH and FAIL
- Fix crash caused by BitBot messaging himself