dinnerbone / grumpypie Goto Github PK
View Code? Open in Web Editor NEWIRC bot for freenode #minecraft
License: MIT License
IRC bot for freenode #minecraft
License: MIT License
If a winner changes nick, they keep their hat. Also, if they leave the channel and rejoin, they lose their hat. We should track their changes and give it back if we think they lost it.
Instead of checking the user when banning, also allow banning based on hostmask (in case the user is not in the channel).
Requires regex support for IRC hostmasks (See https://gist.github.com/datagrok/380449c30fd0c5cf2f30 for an example)
/home/dinnerbone/buttler/node_modules/irc/lib/irc.js:849
throw err;
^
TypeError: Cannot read property 'indexOf' of undefined
at Object.events.parseUsersChannel.events.leave.events.quit.events.joined.events.kick.events.renamed.events.changeMode (/home/dinnerbone/buttler/core/users.js:67:66)
at Client.<anonymous> (/home/dinnerbone/buttler/core/core.js:188:26)
at emitMany (events.js:121:13)
at Client.emit (events.js:195:7)
at /home/dinnerbone/buttler/node_modules/irc/lib/irc.js:316:30
at Array.forEach (native)
at Client.<anonymous> (/home/dinnerbone/buttler/node_modules/irc/lib/irc.js:270:26)
at emitOne (events.js:90:13)
at Client.emit (events.js:182:7)
at iterator (/home/dinnerbone/buttler/node_modules/irc/lib/irc.js:846:26)
Use case:
Right now, it will add 2 unban timers to the list:
One after 1 day, the other after 30 days.
It would be preferred if the action from user B overwrites the action of user A.
Source is possibly caused by invalid timers.
Example:
{
"timers": [
{
"time": "2016-05-24T12:06:35.378Z",
"action": "-b",
"target": "*!*@REMOVED",
"channel": "#minecraft"
}
]
}{
"time": "2016-05-25T21:24:39.358Z",
"action": "unban",
"target": "*!*@REMOVED2",
"channel": "#minecraft"
}
]
}
We'll need to tell the plugin to clean up its own stuff (like timers), so that nothing holds a reference back to it. Then clean the node module cache and load it up again.
See old bot for example: https://github.com/brownan/abbott/blob/master/abbott/plugins/admin.py#L1100
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.