iranathan / robloxapi

A python module for using the roblox api
MIT License
33 stars 13 forks source link

NameError: name 'json' is not defined #9

Closed Jaguar-515 closed 5 years ago

Jaguar-515 commented 5 years ago

I am getting a name error with this code:

import robloxapi
rbx = robloxapi.client()
print(rbx.Auth.IsUsernameTaken("Roblox"))

Error:

line 28, in IsUsernameTaken
if json.loads(r)['code'] == 0:
NameError: name 'json' is not defined
iranathan commented 5 years ago

Hello, Thank you for reporting this error.

This is not a problem. with the lib. It's because the stable version (on pypi) has not been updated yet.

But, Due to this being a real problem. I will leave this open till I update pypi.

Thanks, Ira.

Jaguar-515 commented 5 years ago

Any updates to this?

Jaguar-515 commented 5 years ago

hello @iranathan, you still here?

sbhadr commented 5 years ago

That’s an internal import issue.

iranathan commented 5 years ago

This has been fixed in the pypi project.

>>> import robloxapi
>>> rbx=robloxapi.client()
>>> rbx.Auth.IsUsernameTaken('roblox')
True

To install the update do: pip install robloxapi -U

Thanks, Ira.