archseer / scarlet Goto Github PK
View Code? Open in Web Editor NEWScriptable IRC bot framework. Full support for modern irc features: login tracking, SASL, SSL, DCC, CAP extensions
Scriptable IRC bot framework. Full support for modern irc features: login tracking, SASL, SSL, DCC, CAP extensions
I started a plugin system, but heaven knows, ITS A MESS, I'm braindead when it comes to architecture.
Currently the plugins are attached to the Handler module, I'd like if we could just spawn an instance of the bot and attach plugins to that so we didn't have so many singletons.
Plugins are meant to remove the clutter from the handle and command modules.
Because the upstream api is down at the moment (for the past few months).
We'll need a new currency api, I wonder if google has a free one
This happened today:
[21:08:08] < PING chat.freenode.net
[21:08:39] < QUIT :Ping timeout
[21:08:39] <
And Scarlet never reconnected afterwards
Sad discovery after using multiple servers for the first time, Logs are shared across servers.
THIS IS A NO.
So, we'll need a logs attribute on servers which contain a LogPool
(maybe I should consider renaming that to LogBuffer)
In addition I believe times should be stored in ISO format instead of integers, so timezones remain intact
Because we want privacy while searching for cookies and kittens!
For networks like freenode, we need to throttle the bots send rate.
Some ideas where to use a EM.defer
with a EM::ThrottledQueue
to push the data over time.
Another idea was to use a continous EM.add_timer
recursion to push the messages.
Sometimes we need the time for a location, sadly our current time command only returns the time for a user who had set his/her timezone, not very useful in all cases.
WE CANT CELEBRATE WITHOUT IT!
Nothing much to say here, irc colors will break with UTF-8, I have no idea how to fix this.
3:
That, or you sign up for some of those other apis, suggestions welcome :3
Its broken at the moment, so feel free to suggest refactors as well.
^ Title says it all, this should display how long the bot has been running
This so we can do things like @time for :you
or @time for Scarlet
Because sometimes you wanna find a gem, besides we have a github command set, why not gems, IT IS A RUBY BOT.
Parsing User and Channel modes is a horror. Why? The MODE message used for setting both public user modes, private user modes AND channel modes is the same. To make it even worse, you can set both public user modes and channel modes in the same message. And to make us wonder "what the heck were they thinking?", the format then is a mixture of both. Example:
<< MODE #bugs +i
>> :[email protected] MODE #bugs +i
This is a channel mode message. It sets the i
flag on the channel.
<< MODE #bugs +v Speed
>> :[email protected] MODE #bugs +v Speed
This is a public user mode message. You can tell it's public, because the prefix is the hostmask of the user that sent it. Private modes have a server hostmask prefix. It sets the v
flag on the user.
<< MODE #bugs +vim Speed #bugs #bugs
>> :[email protected] MODE #bugs +miv Speed
This is a mixed message. it gets converted on the server. The annoying thing is that the first two flags mi
apply to the #bugs
, while the v
applies to Speed
. IRC software needs to implement per-flag parsing logic or something to handle a case like this.
This needs to be implemented in Scarlet.
Since EM::HttpRequest
are async and their callbacks can happen anytime after the block leaves, we can't catch the errors that are produced.
This is easy to reproduce, just try one of the existing commands that use http_request
, when it fails, it crashes the entire bot.
One idea is to wrap the callbacks in a safe
callback, which will catch the errors and reply.
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.