GNOME Bugzilla – Bug 785571
gnome-sound-recorder should use var instead of let/const for gjs 1.49.4
Last modified: 2018-05-22 13:00:35 UTC
gnome-sound-recorder 3.24.0.1 3.25.4 on Ubuntu 17.10 Alpha When I try to run it with gjs 1.49.4 built with mozjs52, it won't start ----------------------- $ gnome-sound-recorder Gjs-Message: JS WARNING: [resource:///org/gnome/SoundRecorder/js/main.js 42]: reference to undefined property "Application" (org.gnome.SoundRecorder:3782): Gjs-WARNING **: JS ERROR: TypeError: Application.Application is not a constructor main@resource:///org/gnome/SoundRecorder/js/main.js:42:13 run@resource:///org/gnome/gjs/modules/package.js:221:12 @/usr/bin/gnome-sound-recorder:6:1 JS_EvaluateScript() failed ---------------- Packages are at https://launchpad.net/~gnome3-team/+archive/ubuntu/gnome3-staging/+packages?field.series_filter=artful https://launchpad.net/~jbicha/+archive/ubuntu/temp20170721/+packages
I suspect this is the same problem as bug 785556 of missing https://github.com/ptomato/mozjs/commit/1b82d28588ad5fe74116c6e6099c8f2f2eb392ff in your mozjs.
Yes, after we rebuilt mozjs52 with that patch, gnome-sound-recorder starts but emits warnings like this: Gjs-WARNING **: Some code accessed the property 'Application' on the module 'application'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway. I'm updating the bug title accordingly.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gnome-sound-recorder/issues/32.