Skip to content
New issue

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

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

Already on GitHub? # to your account

BF-60: JS function corrupts after round-trip back from a Python function #18

Merged
merged 2 commits into from
Jun 16, 2023

Conversation

Xmader
Copy link
Member

@Xmader Xmader commented Apr 26, 2023

Before the patch

def ident(x):
  print(x()) # 123.0
  return x
a = pm.eval("""(py_fn) => {
  const fn = py_fn(()=>{ return 123 })
  fn instanceof Function // true
  fn() // ??? TypeError: fn is not a function
  return fn
}""")(ident)
print(a()) #segfault

After patch


This pull request resolves the following internal ticket:

@Xmader Xmader self-assigned this Apr 26, 2023
@Xmader Xmader requested a review from zollqir April 26, 2023 22:43
@Xmader
Copy link
Member Author

Xmader commented May 30, 2023

GC subsystem overhaul won't land anytime soon before our first public release.

Copy link
Collaborator

@zollqir zollqir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

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

Successfully merging this pull request may close these issues.

2 participants