Skip to content

[python] Python lists, maps, and tuples are not properly handled #641

@olebole

Description

@olebole

This is observed when testing #468, with Python 3.7.4.

function ARG_PASS_RETURN, arg
  return, arg
end

Python lists, maps, and tuples are not properly handled

>>> import GDL
>>> arg = [1, 2, 3, 4, 5]
>>> retval = GDL.function('arg_pass_return', arg)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
GDL.error: Calling ARG_PASS_RETURN: Cannot convert python scalar.
>>> arg = {'1': 2}
>>> retval = GDL.function('arg_pass_return', arg)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
GDL.error: Calling ARG_PASS_RETURN: Cannot convert python scalar.
>>> arg = (1, 2, 3, 4, 5)
>>> retval = GDL.function('arg_pass_return', arg)
>>> print(retval)
1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions