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
If the annotated return type of a field operator does not match the deduced one, the error message should point the user to the annotation. Currently the error looks like this:
Traceback (most recent call last):
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File ".../FVM_advection_sphere/src/fvm_advection_sphere/advection.py", line 337, in <module>
def upwind_scheme(
File ".../gt4py_functional/src/gt4py/next/ffront/decorator.py", line 637, in field_operator_inner
return FieldOperator.from_function(definition, backend)
File ".../gt4py_functional/src/gt4py/next/ffront/decorator.py", line 467, in from_function
foast_definition_node = FieldOperatorParser.apply(source_def, closure_vars, annotations)
File ".../gt4py_functional/src/gt4py/next/ffront/dialect_parser.py", line 119, in apply
output_ast = cls._postprocess_dialect_ast(
File ".../gt4py_functional/src/gt4py/next/ffront/func_to_foast.py", line 112, in _postprocess_dialect_ast
raise common.GTTypeError(
gt4py.next.common.GTTypeError: Annotated return type does not match deduced return type. Expected `Field[[Vertex, K], float64]`, but got `Field[[Vertex], float64]`.
python-BaseException
The text was updated successfully, but these errors were encountered:
If the annotated return type of a field operator does not match the deduced one, the error message should point the user to the annotation. Currently the error looks like this:
The text was updated successfully, but these errors were encountered: