aim icon indicating copy to clipboard operation
aim copied to clipboard

cannot import aimstack without aimos package

Open MrZoidberg opened this issue 1 year ago • 1 comments

❓Question

I'm trying to setup a Langchain debugger on Windows. Since aimos cannot be installed on Windows I installed aimstack and have the following code:


def get_callbacks() -> list:
    callbacks = []
    aimos_url = os.environ["AIMOS_URL"]
    if aimos_url:
        try:
            from aimstack.langchain_debugger.callback_handlers import \
                GenericCallbackHandler
            callbacks.append(GenericCallbackHandler(aimos_url))
        except ImportError:
            pass        
    return callbacks

For some reason I'm getting ImportError. I've checked that correct venv is used and double checked I've installed aimstack. Please help

MrZoidberg avatar Dec 21 '23 14:12 MrZoidberg

  1. Check Python Version.

  2. Double-check that aimstack is installed in the correct virtual environment. Use pip list command to list all installed packages in your virtual environment. Make sure that aimstack is listed.

  3. Inspect the installed aimstack package to verify that the required module is present. You can navigate to your virtual environment's site-packages directory and check for the existence of aimstack/langchain_debugger/callback_handlers.py. Ensure that the required module is indeed present.

  4. Sometimes, changes to the environment or installed packages might not take effect until you restart the Python interpreter or your development environment.

DevNandini02 avatar Jan 31 '24 13:01 DevNandini02