Skip to content

Error importing WalmartIO #3

@shayan-NECX

Description

@shayan-NECX

Trying to run the code, but it gives error on first line. Can you help ?

from WIOpy import WalmartIO

wiopy = WalmartIO(private_key_version='1', private_key_filename='./WM_IO_private_key.pem', consumer_id='XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX')
data = wiopy.product_lookup('33093101')[0]


TypeError Traceback (most recent call last)
~\AppData\Local\Temp\ipykernel_17576\2346209252.py in
----> 1 from WIOpy import WalmartIO
2
3 wiopy = WalmartIO(private_key_version='1', private_key_filename='./WM_IO_private_key.pem', consumer_id='XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX')
4 data = wiopy.product_lookup('33093101')[0]

~\Anaconda3\envs\QI_MVP_env\lib\site-packages\WIOpy_init_.py in
----> 1 from .WalmartIO import *
2 from .AsyncWIO import *

~\Anaconda3\envs\QI_MVP_env\lib\site-packages\WIOpy\WalmartIO.py in
9 from requests.api import request
10
---> 11 from .arguments import get_items_ids
12 from .errors import *
13 from .WalmartResponse import *

~\Anaconda3\envs\QI_MVP_env\lib\site-packages\WIOpy\arguments.py in
6
7
----> 8 def get_items_ids(items: Union[str, list[str]]) -> list[str]:
9 if not isinstance(items, str) and not isinstance(items, list):
10 raise InvalidParameterException('Invalid items argument, it should be a string or List of strings')

TypeError: 'type' object is not subscriptable

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions