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

TypeError: 'type' object is not subscriptable #65

Open
gkyh opened this issue Apr 24, 2024 · 2 comments
Open

TypeError: 'type' object is not subscriptable #65

gkyh opened this issue Apr 24, 2024 · 2 comments

Comments

@gkyh
Copy link

gkyh commented Apr 24, 2024

Run:
from solathon import Client, PublicKey

client = Client("https://api.devnet.solana.com")
public_key = PublicKey("B3BhJ1nvPvEhx3hq3nfK8hx4WYcKZdbhavSobZEA44ai")

balance = client.get_balance(public_key)
print(balance)

from solathon import Client, PublicKey
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/init.py", line 3, in
from .client import Client
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/client.py", line 5, in
from .utils import RPCRequestError, validate_commitment
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/utils.py", line 6, in
from solathon.core.types import Commitment, RPCErrorType, RPCResponse
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/core/types/init.py", line 1, in
from .account_info import AccountInfo, AccountInfoType, ProgramAccount, ProgramAccountType
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/core/types/account_info.py", line 3, in
class AccountInfoType(TypedDict):
File "/Users/mac/opt/miniconda3/envs/py/lib/python3.8/site-packages/solathon/core/types/account_info.py", line 12, in AccountInfoType
data: Union[str, dict[str, Any]]
TypeError: 'type' object is not subscriptable

What's happened????

@GitBolt
Copy link
Collaborator

GitBolt commented Apr 25, 2024

@gkyh What Python version are you using?

@gkyh
Copy link
Author

gkyh commented May 8, 2024

python3.8,
yet,Virtual memory is too small

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants