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

Segmentation Fault when converting to images #3

Open
charlesfsl opened this issue Dec 20, 2024 · 4 comments
Open

Segmentation Fault when converting to images #3

charlesfsl opened this issue Dec 20, 2024 · 4 comments

Comments

@charlesfsl
Copy link

charlesfsl commented Dec 20, 2024

Updated: to mention where the call to vega_lite_convert exists in the example repo.

Is there any additional setup to use this library, like some OS libraries to install? We discovered a segfault kept happening in CI when we would call VegaLite.Convert.to_svg(). We've since determined this happens reliably in Debian Bookworm and NixOS 24.11—we're currently using Debian Bookworm in Docker on CircleCI. We've not tested other distros. This isn't a problem in MacOS 15.2.

To work around this for now, we're using VegaLite.Export, which does not seem to have this issue but is also deprecated in favor of vega_lite_convert.

Testing other functions, these all cause a segmentation fault in both MacOS and Linux:

  • to_png/2
  • to_jpeg/2

However to_json/2 works fine on both OSs. I didn't test all conversion functions.

I've created a somewhat minimal repo that reproduces the issue: https://github.com/smartlogic/vega_lite_segfault. The no-graph-render branch removes the rendering and assigns part to show that the segfault is unrelated to rendering. The calls to vega_lite_convert are in VegaLiteSegfaultWeb.SegFaultExampleLive.Index.

Is there any additional info that would be useful?

@jonatanklosko
Copy link
Member

Hey @charlesfsl! Can you share what is the Debian base image (with the price Elixir and Erlang versions)? Also, which architecture do you use?

@charlesfsl
Copy link
Author

Hi @jonatanklosko! The Debian image used in CI is hexpm/elixir:1.17.3-erlang-27.0.1-debian-bookworm-20241202. The architectures are:

  • MacOS: M3 Max (ARM)
  • NixOS: Intel 12th Gen i7-1260p (x86-64)
  • CircleCI/Debian: x86-64

Thanks

@jonatanklosko
Copy link
Member

@charlesfsl thank you! I managed to reproduce it on a x86_64 machine and I reported the issue upstream in vega/vl-convert#206 :)

@charlesfsl
Copy link
Author

Thanks @jonatanklosko . I'll keep an eye on that issue.

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

2 participants