NATION

PASSWORD

FluffyCogs - a module for the Red Discord bot

Bug reports, general help, ideas for improvements, and questions about how things are meant to work.
User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Fri Oct 19, 2018 11:24 pm

With the impending update to Red V3, NationCogs has been archived and is no longer supported, though Red will still be able to install it. No further features, enhancements, or bugfixes will be added to that repo.

My repo of cogs for Red V3 may be found here: https://github.com/zephyrkul/FluffyCogs
Note that V3 cogs will not function on the old version of Red, or vice versa.

The nationstates cog there is not yet complete but the new backend I wrote for it (now entirely custom rather than using the now unsupported pynationstates) will allow me to utilize more of the API's features, so stay tuned. There were some minor changes to the commands I updated, except [p]shard, which now prints the XML directly and also accepts UNIX-style arguments to allow further tuning. For example: [p]shard --nation "Great Bights Mum" census --scale "65 66" --mode score

Future plans include porting over the rest of the commands, adding auto-role functionality based on nation, and including the two missing FT-style commands, neb and nneb, that I never finished for NationCogs. The custom asynchronous backend may also be moved to its own repo to become a separate PyPi library, but as aionationstates already exists it's unlikely I'll decide to do so.

A thread specifically for the NationStates cog in the FluffyCogs repo may or may not be made in the future depending on if I have the time and effort to spare.

Until such time as that thread exists you may continue to use this thread or TG me. Alternate contact details are in the above GitHub repo's readme.
Last edited by Darcania on Fri Oct 19, 2018 11:27 pm, edited 1 time in total.

User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Sun Oct 21, 2018 2:58 pm

LUL, not soon after the above the alpha rewrite of pynationstates is released. Oh well, I've needed to use a more async-friendly library from the start anyway.

User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Fri Jan 18, 2019 7:38 pm

Darcania wrote:The custom asynchronous backend may also be moved to its own repo to become a separate PyPi library, but as aionationstates already exists it's unlikely I'll decide to do so.

I ended up seperating this backend out to its own repo for ease of testing. It can be found on PyPI here: https://pypi.org/project/sans/
It's still in alpha (so there's likely to be plenty of bugs) and mainly used for my cogs but if anyone else is interested they can use it. Note that it's designed with concurrency (i.e. async, threads) in mind, so while it can be run synchronously in a script there's some significant overhead due to the concurrency-friendly model, so it's recommended to use Dolph's pynationstates for simple scripts.

Also, if you had my cogs downloaded on V3 before this change and are getting ImportErrors after updating, run this command: [p]pipinstall sans
(replace [p] with your prefix)
V3 doesn't record changes to a cog's requirements if the cogs were already installed, so that command will install the requirement for you.

User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Mon Jan 28, 2019 7:15 pm

Good news - Red V3 has an official, stable release now, and with my port of NSEndorse now up on FluffyCogs (my repo for V3), NS support for the latest Red is now also fully set up.

Anyone looking for a bot for their NS Discord server should now look at Red V3 rather than the old version of Red - you can find install instructions for V3 here: https://red-discordbot.readthedocs.io/en/v3-develop/

Anyone still using V2 (which you are using unless you specifically installed V3) can continue using it if they wish, but every part of it - from NationCogs, to the bot itself, to the library the bot uses to connect to Discord - are no longer actively supported beyond bugfixes for the latter two. If you haven't tried V3 before, I highly recommend it, much better than the old Red, just keep in mind that it's a brand new bot, so you'll have to install it fresh. It does support some amount of data conversion from V2, but not every cog supports that feature.

Edit: Oh, and I forgot to add that the v3 version provides links to a nation's deck and its card with the [p]nation command. Something something feature-rich upgrade.
Last edited by Darcania on Mon Jan 28, 2019 7:20 pm, edited 1 time in total.

User avatar
Johaan Christian Bach
Political Columnist
 
Posts: 2
Founded: Feb 09, 2019
Ex-Nation

Postby Johaan Christian Bach » Sun Feb 10, 2019 3:10 am

Hi, but how exactly do you download the bot?

User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Sun Feb 10, 2019 12:00 pm

Johaan Christian Bach wrote:Hi, but how exactly do you download the bot?

The instructions for doing so are linked in the post.

User avatar
Darcania
Spokesperson
 
Posts: 109
Founded: Dec 29, 2014
Left-wing Utopia

Postby Darcania » Mon Feb 18, 2019 6:29 pm

The OP has been updated with the new version of my cogs for Red V3. If you're still using Red V2 I recommend upgrading to V3 ASAP - simply updating via Red's launcher won't do it since V3 has been rewritten from the ground up and is basically a brand new bot. You can find more information in the OP.

Next

Advertisement

Remove ads

Return to Technical

Who is online

Users browsing this forum: No registered users

Advertisement

Remove ads