Skip to content

ZeroDivisionError: float division by zero -- seems to be a different one from reported previously #34

Description

@lazydroid

This happened for the game downloaded from lichess, it had a proper PGN header, but the game was "1. e4 e6 0-1" -- that's it, white resigned.

An unhandled exception occurred: <class 'ZeroDivisionError'>
Traceback (most recent call last):
  File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/usr/local/lib/python3.6/dist-packages/annotator/__main__.py", line 811, in <module>
    main()
  File "/usr/local/lib/python3.6/dist-packages/annotator/__main__.py", line 801, in main
    raise e
  File "/usr/local/lib/python3.6/dist-packages/annotator/__main__.py", line 794, in main
    engine, args.threads)
  File "/usr/local/lib/python3.6/dist-packages/annotator/__main__.py", line 655, in analyze_game
    time_per_move = get_time_per_move(pass1_budget, ply_count)
  File "/usr/local/lib/python3.6/dist-packages/annotator/__main__.py", line 543, in get_time_per_move
    return float(pass_budget) / float(ply_count)
ZeroDivisionError: float division by zero

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions