Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor Bug: Unhelpful exception when generating with no missions toggled on #190

Open
samkester opened this issue Apr 13, 2024 · 2 comments
Assignees
Labels
awaiting feedback Awaiting feedback from the issue creator

Comments

@samkester
Copy link

What happened?

While test-generating some yamls with triggers, I messed up one of my trigger definitions and ended up with no missions toggled on, which resulted in this error:

Traceback (most recent call last):
  File "__startup__.py", line 124, in run
  File "console.py", line 16, in run
  File "Generate.py", line 549, in <module>
  File "Generate.py", line 240, in main
  File "Main.py", line 135, in main
  File "worlds\AutoWorld.py", line 155, in call_all
  File "worlds\AutoWorld.py", line 145, in call_single
  File "worlds\AutoWorld.py", line 138, in call_single
  File "worlds\AutoWorld.py", line 124, in _timed_call
  File "worlds\sc2\__init__.py", line 70, in create_regions
  File "worlds\sc2\Regions.py", line 34, in create_regions
  File "worlds\sc2\Regions.py", line 277, in create_grid_regions
  File "worlds\sc2\PoolFilter.py", line 72, in filter_missions
ValueError: max() arg is an empty sequence

What were the expected results?

Expected an error message that was clear about the underlying config error, along the lines of "No missions detected for Starcraft 2 player [Slotname], please fix your yaml."

Software

Local generation

@Ziktofel
Copy link
Owner

I have no clue, the YAMLs aren't in the report

Without an additional information I'll close that as invalid as attempt to reproduce that will be futile

@Ziktofel Ziktofel added the awaiting feedback Awaiting feedback from the issue creator label Apr 17, 2024
@MatthewMarinets
Copy link

Managed to get a similar error on sc2-next by trying very hard. Error:

...
  File "D:\Archipelago\matthew\Archipelago\worlds\sc2\pool_filter.py", line 54, in filter_missions
    goal_level = max(goal_priorities.values())
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: max() iterable argument is empty

Steps:

  • mission_order: vanilla
  • either of:
    • disable all campaigns with enable_* options
    • Enable some campaigns with enable_* but disable them with selected_races option

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting feedback Awaiting feedback from the issue creator
Projects
None yet
Development

No branches or pull requests

3 participants