frissyn / valorant.py

Complete Python interface for the Valorant API. Works right out of the box!
https://valorantpy.readthedocs.io
MIT License
125 stars 19 forks source link

Attribute Error: 'AsyncClient' object has no attribute 'handle' #26

Closed Itz-MrJ closed 2 years ago

Itz-MrJ commented 2 years ago

I have this simple code as mentioned below

import valorant

KEY = "token"
client = valorant.AsyncClient(KEY)
async def _main():

  agents = await client.get_characters()

  for agent in agents:
      print(agent.name)

  print("done")
valorant.run(_main())

So when I run this simple code I get an error saying Attribute Error: 'AsyncClient' object has no attribute 'handle'

Any idea on what wrong I'm doing?

frissyn commented 2 years ago

I'm taking a look right now @Itz-MrJ, thanks for reporting!

frissyn commented 2 years ago

uhh... looks like I forgot to copy-paste the __init__ function for AsyncClient after the refactoring update 😅 easy fix, should be good to go in the latest update 0.5.1. Thanks for using the package!