ImportError while loading conftest 'C:\Users\tyler\OneDrive\Desktop\App Ideas and Work\mirascope\mirascope\tests\conftest.py'.
tests\conftest.py:6: in
from anthropic.types import (
E ModuleNotFoundError: No module named 'anthropic'
Ok I think I solved that issue, now I am getting a different issue: Fatal Python error: init_import_site: Failed to import the site module
Python runtime state: initialized
Traceback (most recent call last):
File "C:\Python310\lib\site.py", line 186, in addpackage
exec(line)
File "", line 1, in
File "C:\Users\tyler\OneDrive\Desktop\App Ideas and Work\mirascope\mirascope\mirascope\types.py", line 1, in
from typing import TypeVar
File "C:\Python310\lib\typing.py", line 25, in
import contextlib
File "C:\Python310\lib\contextlib.py", line 6, in
from functools import wraps
File "C:\Python310\lib\functools.py", line 22, in
from types import GenericAlias
ImportError: cannot import name 'GenericAlias' from partially initialized module 'types' (most likely due to a circular import) (C:\Users\tyler\OneDrive\Desktop\App Ideas and Work\mirascope\mirascope\mirascope\types.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Python310\lib\site.py", line 617, in
main()
File "C:\Python310\lib\site.py", line 603, in main
known_paths = addusersitepackages(known_paths)
File "C:\Python310\lib\site.py", line 343, in addusersitepackages
addsitedir(user_site, known_paths)
File "C:\Python310\lib\site.py", line 226, in addsitedir
addpackage(sitedir, name, known_paths)
File "C:\Python310\lib\site.py", line 196, in addpackage
import traceback
File "C:\Python310\lib\traceback.py", line 5, in
import linecache
File "C:\Python310\lib\linecache.py", line 8, in
import functools
File "C:\Python310\lib\functools.py", line 22, in
from types import GenericAlias
File "C:\Users\tyler\OneDrive\Desktop\App Ideas and Work\mirascope\mirascope\mirascope\types.py", line 1, in
from typing import TypeVar
File "C:\Python310\lib\typing.py", line 25, in
import contextlib
File "C:\Python310\lib\contextlib.py", line 6, in
from functools import wraps
ImportError: cannot import name 'wraps' from partially initialized module 'functools' (most likely due to a circular import) (C:\Python310\lib\functools.py)
I just pulled from dev and ran poetry run pytest tests
with no issue.
Are you running this from current dev or from a different fork/branch?
I am going to close this issue as I haven't been able to reproduce locally. If this problem still persists, please reopen this issue with additional details for how to reproduce.