45 Commits

Author SHA1 Message Date
Toby Harradine
e6495bc7c0
[Trivia] Move Trivia lists back home (#2028)
* [Trivia] Move trivia lists back home

Removes red-trivia as a dependency.

Signed-off-by: Toby Harradine <tobyharradine@gmail.com>

* Include package data in distribution

Signed-off-by: Toby Harradine <tobyharradine@gmail.com>

* Add test from red-trivia repo, and fix package data setup

* The distribution will now include all files under any data/ sub-directory of a package, as well as all *.po files under any locales/ sub-directory (as it should have been before).

* MANIFEST.in has been simplified to comply with these changes and redbot/cogs/audio/application.yml has been moved to the data/ sub-directory to maintain consistency in how we declare package data.

Signed-off-by: Toby Harradine <tobyharradine@gmail.com>
2018-08-26 23:39:46 +10:00
Toby Harradine
1b196bf0fb
[i18n] Use redgettext over pygettext (#2023)
* [i18n] Use redgettext over pygettext

* Clear out autogenerated `messages.pot` files

* Remove redundant `regen_messages.py` files

* Refactor `generate_strings.py` to use redgettext

* Install redgettext in Travis Crowdin job

* Clean up some problematic usages of gettext function

* Reformat

* Replace generate_strings.py with Makefile argument

* Update to redgettext 2.1, use exclusion pattern

Signed-off-by: Toby Harradine <tobyharradine@gmail.com>
2018-08-26 23:35:42 +10:00
Brramble
0aca00b245 [Audio] Embed colours respect user settings (#2046)
* Embed colours now respect what the user set

* Formatting

* Get embed colour when ctx is unavailable
2018-08-26 13:09:03 +10:00
aikaterna
dd5ef3696f [Audio] Add thumbnail display with toggle (#1998)
* [V3 Audio] Add thumbnail display with toggle

* [V3 Audio] Add thumbnail to notify messages

* Formatting

* Update thumbnail fetching

* Update thumbnail fetching

* Track thumbnail moved to Red-Lavalink

* Formatting
2018-08-25 10:47:20 +10:00
Toby Harradine
ae7b912ac8
Major dependency update (#1974)
* [V3] Stop `tmp` dir showing up

* [V3] Remove requirements.txt and declare in install_requires

* Remove requirements.txt from tox.ini

* Update and pin all dependencies and sub-dependencies

* Update for breaking changes

* Reformat

* Update docs/requirements.txt and tox.ini requirements

* Add 3.7 to identifiers and travis/tox builds

* Attempt at fixing the travis build matrix

* Attempt #2

* Attempt 3

* aiohttp.ClientSession.close() -> detach() in sync code

* Add raven-aiohttp to requirements

* Fix stuff in setup.py

 - Added discord.py back into requirements list
 - Fix typo in alabaster extra requirement

Also in the Pipfile:
 - Removed allow_prereleases and explicitly pinned black, since this is the only dep we want a prerelease for.

* Update to Rapptz/discord.py@8ccb98d395

* Add proper 3.7 build in Travis

See travis-ci/travis-ci#9815

* Which version of 3.6 does Xenial install then?

* Maybe we should stop pipenv installing useless stuff

* Nevermind, back to specific minor version

* Remove lots of WET dependency stuff

* Fix egg fragment for dependency link
2018-08-15 12:10:55 +10:00
aikaterna
e701ec9617 [V3 Audio] More aggressive empty disconnect (#1925) 2018-07-12 04:14:58 +02:00
aikaterna
2df282222f [V3 Audio] Fix for playlist queue duplicates (#1890)
* [V3 Audio] Fix for playlist queue duplicates

And some sanitizing of playlist names.

* [V3 Audio] Playlist naming standardization

Enforced single-word playlist name across all playlist commands, removed A-Z 0-9 name standardization. [p]playlist delete will still accept playlist names with quotes as there should be a way to remove already-existing playlists with spaces in their name.

* [V3 Audio] Black formatting
2018-07-12 04:01:11 +02:00
aikaterna
eb73e48192 [V3 Audio] Respect voice channel permissions (#1878)
* [V3 Audio] Respect voice channel permissions

* [V3 Audio] Respect the user limit

* [V3 Audio] Exemption for channels with no limit
2018-07-12 03:11:51 +02:00
Michael H
1c2196f78f autohelp changes. (#1836) 2018-07-12 01:23:18 +02:00
aikaterna
3ece3a1f2b [V3 Audio] Fix for not saving via playlist create (#1889) 2018-06-25 21:20:28 +10:00
aikaterna
1f1a85de18 [V3 Audio] Add checking for valid file on upload (#1891) 2018-06-25 20:32:46 +10:00
aikaterna
3759fce090 [V3 Audio] Empty channel disconnect setting (#1832)
* [V3 Audio] Empty channel disconnect setting

* [V3 Audio] Small fixes

* [V3 Audio] Remove unused variable

* [V3 Audio] Timer task
2018-06-09 21:55:28 -04:00
Tobotimus
033d0113a5 [V3] Send meaningful responses on conversion failure (#1817)
* [V3] Send meaningful responses on conversion failures

* Replace existing `discord.ext.commands` imports

Just to be sure

* Better Permissions converter response
2018-06-08 21:20:40 -04:00
Michael H
17c7dd658d [V3 Core] Command group automatic help (#1790)
* decorator inheritence

* black format

* add autohelp

* modify commands to use autohelp
2018-06-08 20:54:36 -04:00
Eslyium
60a72b2ba4 [V3] Cleanup quotes in cogs (#1782)
* Cleanup quotes in cogs

* More quote cleanup that I missed

fixed a little bit of grammar here and there as well.

* [V3 Warnings] Change allowcustomreasons docstring

To help not confuse users who would believe that the command would use allow or disallow.

* Run black reformat
2018-06-07 00:42:59 -04:00
aikaterna
2ab8890540 [V3 Audio] Check for empty queue in [p]skip (#1769)
Privileged users outside of the channel could invoke skip with an empty queue.
2018-06-02 18:15:10 -04:00
Tobotimus
0d193d3e9e [V3] Make bot send typing whilst loading cogs (#1756)
* Show bot is responsive during cog load

* Log download of Lavalink.jar event

* Fix #1709's other bug

* Reformat

* Update core_commands.py from merge
2018-06-02 18:06:10 -04:00
aikaterna
d47d12e961 [V3 Audio] Restrict check for reactions on [p]now (#1752) 2018-06-02 02:44:30 +02:00
Tobotimus
14cc701b25 [V3] Update black version and reformat (#1745)
* Update black version and reformat

* Pin black in extras_require
2018-05-29 18:37:00 -08:00
aikaterna
abfee70eb3 [V3 Audio] Only allow audio commands in servers (#1682)
* [V3 Audio] Only allow audio commands in servers

Fixes #1681

* [V3 Audio] Formatting fix
2018-05-22 19:39:01 -04:00
aikaterna
28bc68c916 [V3 Audio] [p]llsetup fixes (#1656)
* [V3 Audio] [p]llsetup fixes

[p]llset wsport changed to not use the rest port setting and both the rest and ws ports were changed to use ints instead of strings.

* [V3 Audio] Version change
2018-05-22 19:19:47 -04:00
Michael H
d3f406a34a [V3 Travis] Update travis to not skip pipfile lock... (#1678)
* Update travis to not sip pipfile lock

update pipfile dependencies

additional black formatting pass to conform to black 18.5b

* .

* pin async timeout until further discussion of 3.5 support

* .
2018-05-18 17:48:22 -08:00
Michael H
b88b5a2601 [V3] Update code standards (black code format pass) (#1650)
* ran black: code formatter against `redbot/` with `-l 99`

* badge
2018-05-14 15:33:24 -04:00
aikaterna
4a8358ecb4 [V3 Audio] Update queue and search to use menus (#1633)
* [V3 Audio] Update queue and search to use menus

* [V3 Audio] Fix for playlist upload saving

* [V3 Audio] Add position in queue to enqueued songs

Also a bit of cleanup.

* [V3 Audio] Improvements for mobile formatting
2018-05-14 10:01:46 +10:00
Tobotimus
15ea5440a3 [V3 i18n] Internationalise help for commands and cogs (#1143)
* Framework for internationalised command help

* Translator for class docstring of cog

* Remove references to old context module

* Use CogManagerUI as PoC

* Replace all references to RedContext

* Rename CogI18n object to avoid confusion

* Update docs

* Update i18n docs.

* Store translators in list instead of dict

* Change commands module to package, updated refs in cogs

* Updated docs and more references in cogs

* Resolve syntax error

* Update from merge
2018-05-12 01:47:49 +02:00
aikaterna
79676c4f72 Playlist additions and cleanup (#1579)
Add playlist append, create, remove, and upload.
2018-05-04 05:43:00 +02:00
palmtree5
d8c85a2b15 [V3 Audio] fix zombie process on unload (#1575) 2018-04-29 08:19:49 +02:00
palmtree5
efdf69552f
[V3] Beta 12 release (#1525)
* [V3] update translations from Crowdin

* [V3] bump version to 3.0.0b12
2018-04-16 19:05:21 -08:00
Wyn
6d714db928 [V3 Audio] Add Lavalink Jar build to settings (#1430)
* [V3 Audio] Add Lavalink Jar build to settings

Added Lavalink Jar build to Lavalink settings since build number now stored in config.

* Forgot import

Added import

* Left align

K im done for real this time
2018-04-16 18:57:17 -08:00
aikaterna
59276ce2a5 [V3 Audio] External lavalink server settings, playlist saving & recall, bugfixes (#1528)
* Add settings for external lavalink servers

* Add external lavalink server to settings display

* Add simple error handling

* Remove future permissions conflict

Assuming base Red permissions will be accessed with the 'p' command in the future

* Update prev to set requester to user instead of id

* Various fixes

Jukebox: Plebs not in a channel will not have the song cost deducted before the warning to join a channel first.
DJ role: Finer grained permissions for plebs that are alone: they can use prev (if shuffle is off), skip, pause, resume

* Update permissions

* Add track number to footer when queueing

* Add basic playlist saving

More subcommands to come later

* Check if user is not in voice

* Restrict playlist deletion to author and mods

* Add playlist info command
2018-04-17 00:42:32 +02:00
bobloy
705d9b8238 [V3] guild->server (#1529)
Mostly string renames
customcom now recognized {guild} and {server}
2018-04-16 11:32:51 -08:00
Will
5be967e8c5 [V3 Audio] Harden Lavalink boot sequence (#1498)
* Do a bit of hardening

* Loop not asyncio

* Don't use new asyncio coolness

* I hate you all

* Muck up everything

* Fix version comparisons
2018-04-15 14:01:56 -08:00
aikaterna
d9c71bddb8 [V3 Audio] Add voteskip and DJ role (#1473)
* [V3 Audio] Add voteskip and DJ role

* Fix connection time storage for audiostats

* Update pause command for more explicit handling

Partially fixes #1478. Users will need to use pause twice before resuming until issue no. 20 on the Red-Lavalink repo is addressed.

* Update pause command

* Update pause command

* Add jukebox mode

Adds a price option for enqueuing songs. If DJ mode is active when jukebox mode is active, no one is charged credits as mods are exempt and plebs can't queue songs without the DJ role.
2018-04-02 20:53:37 -04:00
palmtree5
d60fc06379 [V3] Update translations from Crowdin (#1490) 2018-04-02 19:39:07 -04:00
Wyn
a813260717 [V3 Audio] Bump timeout connecting to Lavalink (#1474)
* [V3 Audio] Bump timeout connecting to Lavalink

Lavalink server can take 20-35 seconds to start, bumped to 50 seconds for good measure.

* Update audio.py

Added proper timeout

* Update __init__.py

Removed old timeout
2018-04-02 19:36:26 -04:00
aikaterna
2e9a0de4a1 [V3 Audio] Update audio to use Red-Lavalink (#1440)
* [V3 Audio] Update audio for Red-Lavalink

* Update requirements for new library

* Fix logic for connect time storage for audiostats

Only store time when connecting to the voice channel.
2018-03-20 23:28:31 +01:00
Adam
16da9f52ac [V3 Audio] update Lavalink build (#1427) 2018-03-12 21:48:13 -08:00
Will
ccb322d08e [Audio] V3/auto autostart only (#1420)
* Download jar at audio load

* Messy...

* Remove leftover log file stuff

* Keep application.yml

* Damn you windows
2018-03-12 00:49:08 +01:00
Wyn
b27e0f2d21 [V3 Audio] Rename Game to Activity (#1409)
* Rename `Game` to `Activity` for audio

Add on to pull #1397

* Update audio.py

Whoops, don't need this here

* Update audio.py

Now fixed
2018-03-08 20:55:03 -05:00
aikaterna
6a715d87dd [V3 Audio] Add prev command, bugfixes for audiostats, search (#1405)
* Update audiostats to display days in timer

* Add prev command

* Update search button to play enqueued song
2018-03-08 20:50:54 -05:00
aikaterna
3816385228 [V3 Audio] Fix repeat, Message deletions (#1379)
* Fix repeat

Also remove restriction on if the player is playing.

* Auto-delete existing Now Playing message

* Auto-delete existing notify message

* Wrap line on Now Playing message

* Add connected duration to audiostats

_dynamic_time based on a function written by Redjumpman

* Return negative seek past song start as 00:00:00

* Version number
2018-03-03 18:55:24 -05:00
Will
f65085946c [V3 Audio] Initial V3 addition (#1373)
* Initial audio

* Add application data and modify port

* Modify codeowners

* Need extra newline

* add yml to manifest

* lock lavalink version
2018-03-03 15:42:20 +11:00
palmtree5
0593bb9c53 [V3 i18n] Update translations from Crowdin (#1350) 2018-02-25 21:57:14 -05:00
palmtree5
86b5932c8f [V3] add a script for regenerating all strings (#1318)
* [V3] add a script for regenerating all strings

* Edits to the yml files

* Fix up deploy section

* Make generate_strings upload to Crowdin
2018-02-19 03:02:22 +01:00
Will
d69fd63da7 [V3 Everything] Package bot and write setup scripts (#964)
Ya'll are gonna hate me.

* Initial modifications

* Add initial setup.py

* working setup py help

* Modify setup file to package stuff

* Move a bunch of shit and fix imports

* Fix or skip tests

* Must add init files for find_packages to work

* Move main to scripts folder and rename

* Add shebangs

* Copy over translation files

* WORKING PIP INSTALL

* add dependency information

* Hardcoded version for now, will need to figure out a better way to do this

* OKAY ITS FINALLY FUCKING WORKING

* Add this guy

* Fix stuff

* Change readme to rst

* Remove double sentry opt in

* Oopsie

* Fix this thing

* Aaaand fix test

* Aaaand fix test

* Fix core cog importing and default cog install path

* Adjust readme

* change instance name from optional to required

* Ayyy let's do more dependency injection
2017-09-08 23:14:32 -04:00