Repository: truera/trulens
Issue: TypeError: Parameters to generic types must be types. Got Ellipsis.
Root cause: Validation Gap

Anyone also got this error by running the demo notebook?

from trulens_eval import Tru
tru = Tru()

Version info:
trulens-eval                       0.21.0
llama-index                        0.9.27
html2text                          2020.1.16


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-1-4e23edbcc0c3> in <module>
----> 1 from trulens_eval import Tru
      2 tru = Tru()

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\__init__.py in <module>
     81 __version__ = "0.21.0"
     82 
---> 83 from trulens_eval.feedback import Feedback
     84 from trulens_eval.feedback import Huggingface
     85 from trulens_eval.feedback import Langchain

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\__init__.py in <module>
     19 from trulens_eval.feedback.embeddings import Embeddings
     20 # Main class holding and running feedback functions:
---> 21 from trulens_eval.feedback.feedback import Feedback
     22 from trulens_eval.feedback.groundedness import Groundedness
     23 from trulens_eval.feedback.groundtruth import GroundTruthAgreement

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\feedback.py in <module>
     15 from trulens_eval.feedback import AggCallable
     16 from trulens_eval.feedback import ImpCallable
---> 17 from trulens_eval.feedback.provider.endpoint.base import Endpoint
     18 from trulens_eval.schema import AppDefinition
     19 from trulens_eval.schema import Cost

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\provider\__init__.py in <module>
----> 1 from trulens_eval.feedback.provider.base import Provider
      2 from trulens_eval.feedback.provider.hugs import Huggingface
      3 from trulens_eval.feedback.provider.langchain import Langchain
      4 from trulens_eval.utils.imports import OptionalImports
      5 from trulens_eval.utils.imports import REQUIREMENT_BEDROCK

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\provider\base.py in <module>
      8 
      9 from trulens_eval.feedback import prompts
---> 10 from trulens_eval.feedback.provider.endpoint.base import Endpoint
     11 from trulens_eval.utils.generated import re_0_10_rating
     12 from trulens_eval.utils.pyschema import WithClassInfo

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\provider\endpoint\__init__.py in <module>
----> 1 from trulens_eval.feedback.provider.endpoint.base import DummyEndpoint
      2 from trulens_eval.feedback.provider.endpoint.base import Endpoint
      3 from trulens_eval.feedback.provider.endpoint.hugs import HuggingfaceEndpoint
      4 from trulens_eval.feedback.provider.endpoint.langchain import LangchainEndpoint
      5 from trulens_eval.utils.imports import OptionalImports

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\feedback\provider\endpoint\base.py in <module>
     22 
     23 from trulens_eval.schema import Cost
---> 24 from trulens_eval.utils.asynchro import desync
     25 from trulens_eval.utils.asynchro import sync
     26 from trulens_eval.utils.asynchro import ThunkMaybeAwaitable

~\AppData\Roaming\Python\Python38\site-packages\trulens_eval\utils\asynchro.py in <module>
     66 
     67 async def desync(
---> 68     func: CallableMaybeAwaitable[..., T], *args, **kwargs
     69 ) -> T:  # effectively Awaitable[T]:
     70     """

C:\ProgramData\Anaconda3\lib\typing.py in inner(*args, **kwds)
    259         except TypeError:
    260             pass  # All real errors (not unhashable args) are raised below.
--> 261         return func(*args, **kwds)
    262     return inner
    263 

C:\ProgramData\Anaconda3\lib\typing.py in __getitem__(self, params)
    683             params = (params,)
    684         msg = "Parameters to generic types must be types."
--> 685         params = tuple(_type_check(p, msg) for p in params)
    686         _check_generic(self, params)
    687         return _subs_tvars(self, self.__parameters__, params)

C:\ProgramData\Anaconda3\lib\typing.py in <genexpr>(.0)
    683             params = (params,)
    684         msg = "Parameters to generic types must be types."
--> 685         params = tuple(_type_check(p, msg) for p in params)
    686         _check_generic(self, params)
    687         return _subs_tvars(self, self.__parameters__, params)

C:\ProgramData\Anaconda3\lib\typing.py in _type_check(arg, msg, is_argument)
    147         return arg
    148     if not callable(arg):
--> 149         raise TypeError(f"{msg} Got {arg!r:.100}.")
    150     return arg
    151 

TypeError: Parameters to generic types must be types. Got Ellipsis.

I second this. This and previous versions of trulens-eval consistently have bugs pertaining to data typing (RESPONSE_TYPE, generic types, etc).

met the same error, how can i ignore this temprorily? 

second this😥😥😥

This might be related to an earlier version of python, may I confirm that people with the issue are using python 3.8? If not, can you let me know which python you are using?

@piotrm0  mine is 3.8

@mw-hv @LLLeoLi @liyuxia713 @abdelatifsd - this should be fixed by #840 now merged into main. Please try installing from GitHub and let us know if this issue is resolved.

You can install the latest version from GitHub with the following commands:

```
pip uninstall trulens_eval -y # to remove existing PyPI version
pip install git+https://github.com/truera/trulens#subdirectory=trulens_eval
```

Spoke too soon. We missed some ellipses, try my branch: 
```
pip uninstall trulens_eval -y # to remove existing PyPI version
pip install git+https://github.com/truera/trulens@piotrm/more_ellipses#subdirectory=trulens_eval
```

My branch is now merged into main, so ok to try that.