Cog-Creators / Red-DiscordBot

A multi-function Discord bot
https://docs.discord.red
GNU General Public License v3.0
4.83k stars 2.3k forks source link

Downloader fails to load [p]cog update does not work #3456

Closed senethz closed 4 years ago

senethz commented 4 years ago

Command bugs

Command name

*cog update

What cog is this command from?

downloader

What were you expecting to happen?

Update repos/cogs

What actually happened?

`"There was an error during Downloader's initialization. Check logs for more information."

Traceback (most recent call last):
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/installable.py", line 172, in _process_info_file
    min_bot_version = VersionInfo.from_str(str(info.get("min_bot_version", __version__)))
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/__init__.py", line 91, in from_str
    raise ValueError(f"Invalid version string: {version_str}")
ValueError: Invalid version string: 3.2`

How can we reproduce this issue?

Not sure? Here is the debuginfo: Red version 3.3.0 Python version 3.8.1 (64bit) Discord.py version 1.3.1 Pip version 20.0.2 System arch x86_64 User ubuntu OS version Ubuntu 18.04 Python executable /home/ubuntu/redenv/bin/python

EDIT: Code block -Flame

Flame442 commented 4 years ago

Hi Sparkfiber! Would you mind posting the output of [p]cogs?

senethz commented 4 years ago

72 loaded: addimage, admin, alias, anisearch, antimentionspam, audio, audiotrivia, away, bank, battleship, cah, casino, ccrole, cleverbot, confession, conversationgames, counting, customcom, dadjokes, downloader, economy, economyraffle, economytrickle, eventmaker, exclusiverole, extendedmodlog, feedback, filter, forward, generalchannel, giftaway, hangman, image, leveler, lmgtfy, marriage, mod, modlog, modroles, nolinks, notsobot, osu, partygames, pokemon, pottermore, race, recyclingplant, reddit, remindme, requestbox, rolemanagement, roleplay, roomtools, scanner, shop, simpleembed, space, sparkles, starboard, statuswarn, streams, suggestion, sw, tarot, twenty, unbelievaboat, updatered, uwu, warnings, weather, welcome, youtube 23 unloaded: application, booru, cleanup, clear, dicetable, evolution, general, heist, instantcmd, League, lovecalculator, minecraftdata, nestedcommands, permissions, pokedex, register, reports, retrigger, scheduler, serverstats, tickets, trivia, warnsystem

Jackenmen commented 4 years ago

Hi, are you sure there's nothing below or above the part of log you sent that could be a part of error too?

senethz commented 4 years ago
Traceback (most recent call last):
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/installable.py", line 172, in _process_info_file
    min_bot_version = VersionInfo.from_str(str(info.get("min_bot_version", __version__)))
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/__init__.py", line 91, in from_str
    raise ValueError(f"Invalid version string: {version_str}")
ValueError: Invalid version string: 3.2

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/downloader.py", line 97, in initialize
    await self._repo_manager.initialize()
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/repo_manager.py", line 993, in initialize
    await self._load_repos(set_repos=True)
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/repo_manager.py", line 1189, in _load_repos
    ret[folder.stem] = await Repo.from_folder(folder, branch)
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/repo_manager.py", line 976, in from_folder
    repo._update_available_modules()
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/repo_manager.py", line 497, in _update_available_modules
    Installable(location=self.folder_path / name, repo=self, commit=self.commit)
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/installable.py", line 81, in __init__
    super().__init__(location)
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/json_mixins.py", line 19, in __init__
    self._read_info_file()
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/installable.py", line 144, in _read_info_file
    self._process_info_file()
  File "/home/ubuntu/redenv/lib/python3.8/site-packages/redbot/cogs/downloader/installable.py", line 174, in _process_info_file
    min_bot_version = self.min_bot_version
AttributeError: 'Installable' object has no attribute 'min_bot_version'
/home/ubuntu/redenv/lib/python3.8/site-packages/discord/client.py:312: RuntimeWarning: coroutine 'Value._get' was never awaited
  await coro(*args, **kwargs)
RuntimeWarning: Enable tracemalloc to get the object allocation traceback
Jackenmen commented 4 years ago

Postponing to 3.3.2.