Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mapping type is not well supported in expressions #46

Open
vmagamedov opened this issue Jan 31, 2019 · 0 comments
Open

Mapping type is not well supported in expressions #46

vmagamedov opened this issue Jan 31, 2019 · 0 comments
Labels

Comments

@vmagamedov
Copy link
Contributor

When we have a function definition which accepts Mapping[String, Any], and we pass an option's value with the same type, currently we get this error:

Traceback (most recent call last):
  ...
  File "/usr/local/lib/python3.7/dist-packages/hiku/sources/graph.py", line 57, in __postprocess__
    reqs = RequirementsExtractor.extract(self.sub_graph.types, expr)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/refs.py", line 122, in extract
    extractor.visit(expr)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/refs.py", line 131, in visit
    super(RequirementsExtractor, self).visit(node)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/nodes.py", line 71, in visit
    node.accept(self)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/nodes.py", line 40, in accept
    return visitor.visit_tuple(self)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/refs.py", line 143, in visit_tuple
    self.visit(arg)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/refs.py", line 128, in visit
    req = ref_to_req(self._types, ref)
  File "/usr/local/lib/python3.7/dist-packages/hiku/expr/refs.py", line 82, in ref_to_req
    assert not isinstance(ref_type, _CONTAINER_TYPES), ref_type
AssertionError: Mapping[String, Any]
@vmagamedov vmagamedov added the bug label Jan 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant