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

Issue with returning integers #33

Open
JustRedTTG opened this issue Jan 28, 2025 · 0 comments
Open

Issue with returning integers #33

JustRedTTG opened this issue Jan 28, 2025 · 0 comments

Comments

@JustRedTTG
Copy link
Contributor

It's trying to use assign on Val but Val only has _assign and no it doesn't fix the issue

Exception ignored from cffi callback <function handle_args at 0x779894456af0>:
Traceback (most recent call last):
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 842, in handle_args
    HOST_FN_REGISTRY[idx](CurrentPlugin(current), inp, outp, *udata)
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 390, in __call__
    return self.func(*args, **kwargs)
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 421, in inner_func
    emplace(plugin, slot, result)
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 333, in <lambda>
    return [(ValType.I64, lambda _, slot, value: slot.assign(value))]
AttributeError: 'Val' object has no attribute 'assign'

After a bit of tinkering, this is a secondary issue I encountered:

Traceback (most recent call last):
  File "/home/red/PPG/moss-desktop/gui/extensions/extension_manager.py", line 153, in load_wasm_source
    extension.call('moss_extension_register', self.state,
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 543, in call
    self._check_error(
  File "/home/red/PPG/moss-desktop/.venv/lib/python3.9/site-packages/extism/extism.py", line 515, in _check_error
    raise Error(_ffi.string(error).decode())

on all extism versions.
python: 3.9 and 3.13
rust-pdk wasi but I think it's python extism that is broken

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant