You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/Users/dkh/venv/clean-datachain/bin/datachain", line 8, in
sys.exit(main())
File "/Users/dkh/dvcx/src/datachain/cli.py", line 916, in main
return udf_entrypoint()
File "/Users/dkh/dvcx/src/datachain/query/dispatch.py", line 88, in udf_entrypoint
udf_info = load(stdin.buffer) # noqa: S301
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 289, in load
return Unpickler(file, ignore=ignore, **kwds).load()
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 444, in load
obj = StockUnpickler.load(self)
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 434, in find_class
return StockUnpickler.find_class(self, module, name)
File "/Users/dkh/dvcx/tmpFunjoHv5uo.py", line 75, in
class ClaudeMessage(Feature):
File "/Users/dkh/dvcx/tmpFunjoHv5uo.py", line 80, in ClaudeMessage
stop_reason: Optional[Literal["end_turn", "max_tokens", "stop_sequence"]] = None
TypeError: 'type' object is not subscriptable
Traceback (most recent call last):
File "", line 2, in
File "/Users/dkh/dvcx/src/datachain/lib/dc.py", line 399, in save
return super().save(name=name, version=version, feature_schema=schema)
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 1720, in save
query = self.apply_steps()
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 1256, in apply_steps
result = step.apply(
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 708, in apply
self.populate_udf_table(udf_table, query)
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 541, in populate_udf_table
raise RuntimeError("UDF Execution Failed!")
RuntimeError: UDF Execution Failed!
### Version Info
```Text
datachain -V
0.1.14.dev43+g9bef8c7c
python --version
Python 3.9.4
The text was updated successfully, but these errors were encountered:
Description
This code works:
But replace "type" field with a Literal from src/datachain/lib/claude.py and it stops working:
-->
Traceback (most recent call last):
File "/Users/dkh/venv/clean-datachain/bin/datachain", line 8, in
sys.exit(main())
File "/Users/dkh/dvcx/src/datachain/cli.py", line 916, in main
return udf_entrypoint()
File "/Users/dkh/dvcx/src/datachain/query/dispatch.py", line 88, in udf_entrypoint
udf_info = load(stdin.buffer) # noqa: S301
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 289, in load
return Unpickler(file, ignore=ignore, **kwds).load()
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 444, in load
obj = StockUnpickler.load(self)
File "/Users/dkh/venv/clean-datachain/lib/python3.9/site-packages/dill/_dill.py", line 434, in find_class
return StockUnpickler.find_class(self, module, name)
File "/Users/dkh/dvcx/tmpFunjoHv5uo.py", line 75, in
class ClaudeMessage(Feature):
File "/Users/dkh/dvcx/tmpFunjoHv5uo.py", line 80, in ClaudeMessage
stop_reason: Optional[Literal["end_turn", "max_tokens", "stop_sequence"]] = None
TypeError: 'type' object is not subscriptable
Traceback (most recent call last):
File "", line 2, in
File "/Users/dkh/dvcx/src/datachain/lib/dc.py", line 399, in save
return super().save(name=name, version=version, feature_schema=schema)
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 1720, in save
query = self.apply_steps()
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 1256, in apply_steps
result = step.apply(
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 708, in apply
self.populate_udf_table(udf_table, query)
File "/Users/dkh/dvcx/src/datachain/query/dataset.py", line 541, in populate_udf_table
raise RuntimeError("UDF Execution Failed!")
RuntimeError: UDF Execution Failed!
The text was updated successfully, but these errors were encountered: