GNOME Bugzilla – Bug 794298
Cannot inspect GStreamer static pad templates in GJS
Last modified: 2020-04-22 17:42:31 UTC
I'm trying to sketch a pipeline editor using GJS, but I'm hitting what seems to be a binding issue. I've isolated a simple test below: const Lang = imports.lang; const Gst = imports.gi.Gst; Gst.init(null); let registry = Gst.Registry.get(); let elementFeatureList = registry.get_feature_list(Gst.ElementFactory); elementFeatureList.forEach(Lang.bind(this, function(factory) { let padTemplates = factory.get_static_pad_templates(); })); This is giving the following error: Gjs-WARNING **: JS ERROR: Error: Can't create a Javascript object for StaticPadTemplate; no way to copy Am I missing something? Thanks for your efforts!
The StaticPadTemplate are usable from python, the decoration seems correct in the documentation. Closing. Can you refile against gjs ?
Let's just move it to gjs then :) The error makes sense though, static pad templates are by design not copyable. They just exist globally forever, but G-I can't express that.
Can you move this to https://gitlab.gnome.org/GNOME/gjs, please? I only came across it by chance.
Closing per last comment.