Compare commits

...

9 Commits

Author SHA1 Message Date
Michael H
ec0c71d5c2 [3.1.9]
- Patches over an issue with audio
  - More comprehensive fix restoring some of this functionality more
  safely planned Please enter the commit message for your changes. Lines starting
2020-01-08 14:57:13 -05:00
Michael H
3eb4017263 [3.1.9]
- Patches over an issue with audio
  - More comprehensive fix restoring some of this functionality more
  safely planned
2020-01-08 14:48:12 -05:00
Michael H
6b5bcdfe74 d.py version 1.2.5 2019-11-18 19:23:56 -05:00
Michael H
2bd082e8f2 This is everything *except* the d.py update 2019-11-18 18:56:02 -05:00
Michael H
7d36cc8366 3.1.7 2019-11-05 05:53:29 -05:00
Michael H
9fc0e627ee [Release] 3.1.7
- Handles a dependency issue for python3.8
- Updates the Lavalink jar used
  - This include's Nin's stat fix
  - Streaming from Soundcloud is working again, at least for now.
2019-11-05 05:29:08 -05:00
Michael H
989e16b20b Lavalink bump to 3.2.1_846 2019-11-05 05:28:34 -05:00
Michael H
1c648abea2 uvloop + python3.8 2019-11-05 05:23:25 -05:00
Michael H
11d87067aa Version Bump
- d.py 1.2.3 -> 1.2.4
 - Red 3.1.5 -> 3.1.6

This fixes a critical issue with voice connections.
2019-10-17 21:43:24 -04:00
4 changed files with 29 additions and 5 deletions

View File

@@ -173,7 +173,7 @@ class VersionInfo:
)
__version__ = "3.1.5"
__version__ = "3.1.9"
version_info = VersionInfo.from_str(__version__)
# Filter fuzzywuzzy slow sequence matcher warning

View File

@@ -1737,6 +1737,9 @@ class Audio(commands.Cog):
# YouTube or Soundcloud playlist
track_len = 0
for track in tracks:
if len(player.queue) >= 10000:
await ctx.send("I can't add anything else to the queue.")
break
if guild_data["maxlength"] > 0:
if self._track_limit(ctx, track, guild_data["maxlength"]):
track_len += 1
@@ -1774,11 +1777,15 @@ class Audio(commands.Cog):
single_track = tracks[0]
if guild_data["maxlength"] > 0:
if self._track_limit(ctx, single_track, guild_data["maxlength"]):
if len(player.queue) >= 10000:
return await ctx.send("I can't add anything else to the queue.")
player.add(ctx.author, single_track)
else:
return await self._embed_msg(ctx, _("Track exceeds maximum length."))
else:
if len(player.queue) >= 10000:
return await ctx.send("I can't add anything else to the queue.")
player.add(ctx.author, single_track)
except IndexError:
return await self._embed_msg(
@@ -1939,6 +1946,7 @@ class Audio(commands.Cog):
"""Playlist configuration options."""
pass
@checks.is_owner()
@playlist.command(name="append")
async def _playlist_append(self, ctx, playlist_name, *, url):
"""Add a track URL, playlist link, or quick search to a playlist.
@@ -2066,6 +2074,7 @@ class Audio(commands.Cog):
),
)
@checks.is_owner()
@playlist.command(name="create")
async def _playlist_create(self, ctx, playlist_name):
"""Create an empty playlist."""
@@ -2139,6 +2148,7 @@ class Audio(commands.Cog):
await ctx.send(file=discord.File(to_write, filename=f"{playlist_name}.txt"))
to_write.close()
@checks.is_owner()
@playlist.command(name="info")
async def _playlist_info(self, ctx, playlist_name):
"""Retrieve information from a saved playlist."""
@@ -2241,7 +2251,7 @@ class Audio(commands.Cog):
)
return embed
@commands.cooldown(1, 15, discord.ext.commands.BucketType.guild)
@checks.is_owner()
@playlist.command(name="queue")
async def _playlist_queue(self, ctx, playlist_name=None):
"""Save the queue to a playlist."""
@@ -2297,6 +2307,7 @@ class Audio(commands.Cog):
),
)
@checks.is_owner()
@playlist.command(name="remove")
async def _playlist_remove(self, ctx, playlist_name, url):
"""Remove a track from a playlist by url."""
@@ -2336,6 +2347,7 @@ class Audio(commands.Cog):
),
)
@checks.is_owner()
@playlist.command(name="save")
async def _playlist_save(self, ctx, playlist_name, playlist_url):
"""Save a playlist from a url."""
@@ -2367,6 +2379,9 @@ class Audio(commands.Cog):
try:
player = lavalink.get_player(ctx.guild.id)
for track in playlists[playlist_name]["tracks"]:
if len(player.queue) >= 10000:
await ctx.send("I can't add anything else to the queue.")
break
if track["info"]["uri"].startswith("localtracks/"):
if not await self._localtracks_check(ctx):
pass
@@ -2376,6 +2391,7 @@ class Audio(commands.Cog):
if not self._track_limit(ctx, track["info"]["length"], maxlength):
continue
player.add(author_obj, lavalink.rest_api.Track(data=track))
await asyncio.sleep(0)
track_len += 1
if len(playlists[playlist_name]["tracks"]) > track_len:
maxlength_msg = " {bad_tracks} tracks cannot be queued.".format(
@@ -3046,6 +3062,9 @@ class Audio(commands.Cog):
track_len = 0
for track in tracks:
if len(player.queue) >= 10000:
await ctx.send("I can't add anything else to the queue.")
break
if guild_data["maxlength"] > 0:
if self._track_limit(ctx, track, guild_data["maxlength"]):
track_len += 1
@@ -3053,6 +3072,7 @@ class Audio(commands.Cog):
else:
track_len += 1
player.add(ctx.author, track)
await asyncio.sleep(0)
if not player.current:
await player.play()
if len(tracks) > track_len:
@@ -3189,10 +3209,14 @@ class Audio(commands.Cog):
if guild_data["maxlength"] > 0:
if self._track_limit(ctx, search_choice.length, guild_data["maxlength"]):
if len(player.queue) >= 10000:
return await ctx.send("I can't add anything else to the queue.")
player.add(ctx.author, search_choice)
else:
return await self._embed_msg(ctx, _("Track exceeds maximum length."))
else:
if len(player.queue) >= 10000:
return await ctx.send("I can't add anything else to the queue.")
player.add(ctx.author, search_choice)
if not player.current:
await player.play()

View File

@@ -17,7 +17,7 @@ from redbot.core import data_manager
from .errors import LavalinkDownloadFailed
JAR_VERSION = "3.2.1"
JAR_BUILD = 823
JAR_BUILD = 846
LAVALINK_DOWNLOAD_URL = (
f"https://github.com/Cog-Creators/Lavalink-Jars/releases/download/{JAR_VERSION}_{JAR_BUILD}/"
f"Lavalink.jar"

View File

@@ -35,7 +35,7 @@ install_requires =
Click==7.0
colorama==0.4.1
contextlib2==0.5.5
discord.py==1.2.3
discord.py==1.2.5
distro==1.4.0; sys_platform == "linux"
fuzzywuzzy==0.17.0
idna==2.8
@@ -45,7 +45,7 @@ install_requires =
Red-Lavalink==0.3.0
schema==0.7.0
tqdm==4.32.2
uvloop==0.12.2; sys_platform != "win32" and platform_python_implementation == "CPython"
uvloop==0.14.0; sys_platform != "win32" and platform_python_implementation == "CPython"
websockets==6.0
yarl==1.3.0