reflex-frp / reflex-platform

A curated package set and set of tools that let you build Haskell packages so they can run on a variety of platforms. reflex-platform is built on top of the nix package manager.
https://reflex-frp.org
BSD 3-Clause "New" or "Revised" License
713 stars 163 forks source link

GTK webview HTTPS ajax #705

Open NCrashed opened 3 years ago

NCrashed commented 3 years ago

If you try to request https with servant-reflex on desktop build you will get:

CONSOLE ERROR TLS/SSL support not available; install glib-networking
CONSOLE ERROR XMLHttpRequest cannot load https://localhost:8080/auth/api/login due to access control checks.
file:///home/user/dev/project/admin/front/index.html:386:20: CONSOLE LOG h$wrapBuffer: not an ArrayBuffer
A JavaScript exception was thrown! (may not reach Haskell code)
h$wrapBuffer: not an ArrayBuffer
project-admin-front: JSException

I tried to to add overlay to add glib-networking into gtkwebview, but without any luck:

self: super: {
  webkitgtk = super.webkitgtk.overrideAttrs(oldAttrs: rec {
    buildInputs = oldAttrs.buildInputs ++ [ super.glib-networking ];
    nativeBuildInputs = with super; [
        bison
        cmake
        gettext
        gobject-introspection
        gperf
        ninja
        perl
        pkgconfig
        python3
        ruby
        glib-networking # for gdbus-codegen
        wayland # for wayland-scanner
      ];
  });
}
danwdart commented 2 years ago

I'm not sure if it's to do with installing it, but compiling webkit2gtk or whichever the package that's complaining with it.

iogrt commented 5 months ago

Can someone with more intel point at what package would be the culprit? My guess is we should be looking at jsaddle-webkit2gtk

EDIT: Seems like webkit2gtk is being deprecated. Should this issue be closed then?