ShoobyDoo / OPGG.py

An unofficial Python library for accessing OPGG data.
BSD 3-Clause "New" or "Revised" License
13 stars 5 forks source link

Reporting an Issue with OPGG.py #12

Closed ShoobyDoo closed 5 months ago

ShoobyDoo commented 5 months ago

Hello!

If you've run into an issue with OPGG.py, please refer to the following template on how to report an issue:

  1. Python version
  2. OPGG.py version
  3. Summoner + Region Identifier (#NA1, #EUW, etc.)
  4. Any applicable error message(s)
  5. Reproducable?

Brief description of issue, steps to reproduce, etc. Please be as descriptive as possible.

In addition, please attach a debug log as well. You can enable debugging by using the example below:

# main.py
from opgg import opgg
from opgg.params import Region

def main():    
    opgg_obj = opgg.OPGG()
    opgg_obj.logger.setLevel("DEBUG") # <-- this will enable debug logging

    # this is the typical syntax for when searching with an identifier
    print(opgg_obj.search("Deadly Moon#EUWX", Region.EUW))

if __name__ == "__main__":
    main()

Logs will be generated and stored in the ./logs folder. If you don't have a ./logs folder next to your main.py, please create it to prevent OPGG.py from crashing on launch.

Typical folder structure:

python-scripts/
├── logs/
│   └── opgg_2024-05-14.log
└── main.py